Files
eip4-platform/转换产物-attach/schema/1e6bb549-8238-4c54-9092-ed65653f2a14.json
zhengwr 8fe377b0c8 feat(blueprint): master-detail-v1 编译器分支 + PageBlueprintChild
PageBlueprint 加 RECIPE_MASTER_DETAIL 常量与可空 child 组件(14-arg,
保留 13-arg 兼容构造);新增 PageBlueprintChild record。
PageBlueprintCompiler.masterDetail 复用 maintenance 列表骨架,
新增/编辑表单内联 house-style input-table 子表(name=listColumn,
quickEdit 控件),编辑表单 initApi 走 _LOAD 回显主+子行。
validate 接受 master-detail 并要求 child 非空/childTable/listColumn
非空/fields 非空。

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-20 15:16:30 +08:00

291 lines
8.9 KiB
JSON

{
"type" : "page",
"title" : "周转(租赁)材料出场材料明细编辑页面",
"body" : {
"type" : "form",
"id" : "eip4-edit-form",
"title" : "",
"mode" : "horizontal",
"horizontal" : {
"leftFixed" : 120
},
"body" : [ {
"type" : "grid",
"columns" : [ {
"md" : 6,
"body" : [ {
"name" : "VIEW_TURNOVERMATERIALSTOCK_ID",
"label" : "选择",
"type" : "picker",
"clearable" : true,
"source" : "/api/picker/7943c2d9-a0d1-46d8-86a7-31347362c567/list",
"labelField" : "_label",
"valueField" : "_id",
"modalMode" : "dialog",
"modalSize" : "lg",
"pickerSchema" : {
"mode" : "table",
"headerToolbar" : [ {
"type" : "search-box",
"name" : "q",
"placeholder" : "输入关键字搜索"
} ],
"footerToolbar" : [ "pagination" ]
}
} ]
} ]
}, {
"type" : "grid",
"columns" : [ {
"md" : 6,
"body" : [ {
"name" : "MATERIALCODE",
"label" : "材料编码",
"disabled" : true,
"type" : "input-text"
} ]
}, {
"md" : 6,
"body" : [ {
"name" : "MATERIALNAME",
"label" : "材料名称",
"type" : "static",
"tpl" : "${MATERIALNAME_DISPLAY__ ? MATERIALNAME_DISPLAY__ : (MATERIALNAME ? MATERIALNAME : MATERIALNAME)}"
} ]
} ]
}, {
"type" : "grid",
"columns" : [ {
"md" : 6,
"body" : [ {
"name" : "MATERIALALIASID",
"label" : "材料别名",
"type" : "static",
"tpl" : "${MATERIALALIASID_DISPLAY__ ? MATERIALALIASID_DISPLAY__ : (MATERIALALIAS ? MATERIALALIAS : MATERIALALIASID)}"
} ]
}, {
"md" : 6,
"body" : [ {
"name" : "SPECIFICATIONS",
"label" : "规格",
"disabled" : true,
"type" : "input-text"
} ]
} ]
}, {
"type" : "grid",
"columns" : [ {
"md" : 6,
"body" : [ {
"name" : "UNIT",
"label" : "单位",
"disabled" : true,
"type" : "select",
"clearable" : true,
"source" : "/api/picker/PM_UNITLIST/list?perPage=500"
} ]
}, {
"md" : 6,
"body" : [ {
"name" : "UNITPRICE",
"label" : "租赁单价(元/日)",
"disabled" : true,
"type" : "input-number",
"precision" : 4
} ]
} ]
}, {
"type" : "grid",
"columns" : [ {
"md" : 6,
"body" : [ {
"name" : "EXPORTNUMBER",
"label" : "出场数量",
"required" : true,
"type" : "input-number",
"precision" : 4
} ]
}, {
"md" : 6,
"body" : [ {
"name" : "STOCKNUMBER",
"label" : "库存数量",
"disabled" : true,
"type" : "input-number",
"precision" : 4
} ]
} ]
}, {
"type" : "grid",
"columns" : [ {
"md" : 12,
"body" : [ {
"name" : "REPAIRDETAILS",
"label" : "维修明细",
"type" : "input-table",
"id" : "eg-REPAIRDETAILS",
"addable" : true,
"removable" : true,
"staticOn" : "${__readonly}",
"columns" : [ {
"name" : "REPAIRITEM",
"label" : "维修项",
"quickEdit" : {
"name" : "REPAIRITEM",
"required" : true,
"type" : "select",
"clearable" : true,
"source" : "/api/poc/dict/repairItem"
}
}, {
"name" : "REPAIRNUMBER",
"label" : "维修数量",
"quickEdit" : {
"name" : "REPAIRNUMBER",
"required" : true,
"type" : "input-number",
"precision" : 4,
"onEvent" : {
"change" : {
"actions" : [ {
"actionType" : "ajax",
"outputVar" : "egRow",
"args" : {
"api" : {
"method" : "post",
"url" : "/api/script/execute-editgrid-row",
"data" : {
"templateId" : "1e6bb549-8238-4c54-9092-ed65653f2a14",
"editgridField" : "REPAIRDETAILS",
"scriptKey" : "e44c3e82-3c42-4345-a02a-77d12beb65c8",
"changedField" : "REPAIRNUMBER",
"row" : "${__rendererData}",
"parent" : {
"REPAIRDETAILS" : "${__rendererData.REPAIRDETAILS || REPAIRDETAILS}"
}
}
}
}
}, {
"actionType" : "setValue",
"componentId" : "eg-REPAIRDETAILS",
"args" : {
"index" : "${index}",
"value" : "${egRow.rowSetValues}"
}
}, {
"actionType" : "setValue",
"componentId" : "eip4-edit-form",
"args" : {
"value" : "${egRow.parentSetValues}"
}
} ]
}
}
}
}, {
"name" : "REPAIRPRICE",
"label" : "维修单价(元)",
"quickEdit" : {
"name" : "REPAIRPRICE",
"required" : true,
"type" : "input-number",
"precision" : 4,
"onEvent" : {
"change" : {
"actions" : [ {
"actionType" : "ajax",
"outputVar" : "egRow",
"args" : {
"api" : {
"method" : "post",
"url" : "/api/script/execute-editgrid-row",
"data" : {
"templateId" : "1e6bb549-8238-4c54-9092-ed65653f2a14",
"editgridField" : "REPAIRDETAILS",
"scriptKey" : "e44c3e82-3c42-4345-a02a-77d12beb65c8",
"changedField" : "REPAIRPRICE",
"row" : "${__rendererData}",
"parent" : {
"REPAIRDETAILS" : "${__rendererData.REPAIRDETAILS || REPAIRDETAILS}"
}
}
}
}
}, {
"actionType" : "setValue",
"componentId" : "eg-REPAIRDETAILS",
"args" : {
"index" : "${index}",
"value" : "${egRow.rowSetValues}"
}
}, {
"actionType" : "setValue",
"componentId" : "eip4-edit-form",
"args" : {
"value" : "${egRow.parentSetValues}"
}
} ]
}
}
}
}, {
"name" : "REPAIRMONEY",
"label" : "维修金额(元)",
"quickEdit" : {
"name" : "REPAIRMONEY",
"disabled" : true,
"type" : "input-number",
"precision" : 2
}
} ],
"needConfirm" : false
} ]
} ]
}, {
"name" : "STOCKNUMBERTEMP",
"label" : "库存数量(临时存储)",
"hidden" : true,
"type" : "input-number",
"precision" : 4
}, {
"name" : "PM_TURNOVERMATERIALEXPORT_ID",
"label" : "选择",
"hidden" : true,
"type" : "input-text"
}, {
"name" : "TURNOVERMATERIALEXPORTBATCHID",
"label" : "周转租赁材料出场批次表ID",
"hidden" : true,
"type" : "select",
"clearable" : true,
"searchable" : true,
"source" : "/api/picker//list?q=${term}&page=${page}&perPage=${perPage}"
}, {
"name" : "MATERIALID",
"label" : "材料名称",
"required" : true,
"validationErrors" : {
"required" : "请选择材料信息!"
},
"hidden" : true,
"type" : "picker",
"clearable" : true,
"source" : "/api/picker/201b1408-368b-463d-8b66-9123474b0183/list",
"labelField" : "_label",
"valueField" : "_id",
"modalMode" : "dialog",
"modalSize" : "lg",
"pickerSchema" : {
"mode" : "table",
"headerToolbar" : [ {
"type" : "search-box",
"name" : "q",
"placeholder" : "输入关键字搜索"
} ],
"footerToolbar" : [ "pagination" ]
}
} ],
"actions" : [ ]
}
}