--[[
|
编码: JX-35-14
|
名称: 指定出库容器明细-3053-点中当前任务
|
作者:HAN
|
日期:2025-1-29
|
|
级别:固定 (说明本段代码在项目中不太会变化)
|
|
函数: ClickItem
|
功能:
|
-- 3053 中的功能,点中出库任务后把入库信息 加到自定义表单的{3053-出库分拣}
|
|
更改记录:
|
|
--]]
|
|
json = require ("json")
|
mobox = require ("OILua_JavelinExt")
|
m3 = require("oi_base_mobox")
|
|
function ClickItem ( strLuaDEID )
|
local nRet, strRetInfo
|
local data_json
|
|
-- 获取点中的【指定出库容器货品明细】
|
nRet, data_json = m3.GetSysDataJson( strLuaDEID )
|
if (nRet ~= 0) then lua.Error( strLuaDEID, debug.getinfo(1), data_json ) end
|
if ( #data_json ~= 1 ) then lua.Error( strLuaDEID, debug.getinfo(1), " datajson数据输入不正确 !" ) end
|
local id = lua.trim_guid_str( data_json[1].id )
|
|
local action_array = {}
|
local obj_attrs = m3.KeyValueAttrsToObjAttr( data_json[1].attrs )
|
|
|
-- 设置面板【3053-指定出库】中的输入信息
|
local action = {
|
{
|
action_type = "refresh_related_panel",
|
value = {
|
{
|
panel_name = "指定出库",
|
input_parameter = {
|
id = id,
|
item_code = obj_attrs.S_ITEM_CODE,
|
item_name = obj_attrs.S_ITEM_NAME,
|
cntr_code = obj_attrs.S_CNTR_CODE,
|
cell_no = obj_attrs.S_CELL_NO,
|
station = obj_attrs.S_STATION_NO,
|
qty = lua.StrToNumber(obj_attrs.F_QTY)
|
}
|
},
|
{
|
panel_name = "料格显示",
|
input_parameter = {
|
cell_no = obj_attrs.S_CELL_NO
|
}
|
}
|
}
|
}
|
}
|
|
nRet, strRetInfo = mobox.setAction( strLuaDEID, lua.table2str(action) )
|
if ( nRet ~= 0 ) then lua.Error( strLuaDEID, debug.getinfo(1), "setAction失败! "..strRetInfo ) end
|
end
|