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>
238 lines
7.2 KiB
JSON
238 lines
7.2 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" : "FORMNO",
|
|
"label" : "表单号",
|
|
"required" : true,
|
|
"type" : "input-text"
|
|
} ]
|
|
}, {
|
|
"md" : 6,
|
|
"body" : [ {
|
|
"name" : "APPLYNAME",
|
|
"label" : "申请人",
|
|
"type" : "static",
|
|
"tpl" : "${APPLYNAME_DISPLAY__ ? APPLYNAME_DISPLAY__ : (DISPLAYNAME ? DISPLAYNAME : APPLYNAME)}",
|
|
"value" : "${currentUser}"
|
|
} ]
|
|
} ]
|
|
}, {
|
|
"type" : "grid",
|
|
"columns" : [ {
|
|
"md" : 6,
|
|
"body" : [ {
|
|
"name" : "DEPART_ID",
|
|
"label" : "申请部门",
|
|
"required" : true,
|
|
"type" : "select",
|
|
"clearable" : true,
|
|
"source" : "/api/picker/SYS_DEPART/list?perPage=500",
|
|
"value" : "${currentDepart}"
|
|
} ]
|
|
}, {
|
|
"md" : 6,
|
|
"body" : [ {
|
|
"name" : "APPLYDATE",
|
|
"label" : "申请日期",
|
|
"required" : true,
|
|
"type" : "input-date",
|
|
"value" : "${now}"
|
|
} ]
|
|
} ]
|
|
}, {
|
|
"type" : "grid",
|
|
"columns" : [ {
|
|
"md" : 12,
|
|
"body" : [ {
|
|
"name" : "BUYREASON",
|
|
"label" : "购置原因",
|
|
"required" : true,
|
|
"type" : "textarea"
|
|
} ]
|
|
} ]
|
|
}, {
|
|
"type" : "grid",
|
|
"columns" : [ {
|
|
"md" : 12,
|
|
"body" : [ {
|
|
"name" : "PURCHASEDETAIL",
|
|
"label" : "申请资产",
|
|
"required" : true,
|
|
"type" : "input-table",
|
|
"id" : "eg-PURCHASEDETAIL",
|
|
"addable" : true,
|
|
"removable" : true,
|
|
"staticOn" : "${__readonly}",
|
|
"columns" : [ {
|
|
"name" : "ASSETS_NAME",
|
|
"label" : "资产名称",
|
|
"quickEdit" : {
|
|
"name" : "ASSETS_NAME",
|
|
"required" : true,
|
|
"type" : "input-text"
|
|
}
|
|
}, {
|
|
"name" : "STANDARD",
|
|
"label" : "规格型号",
|
|
"quickEdit" : {
|
|
"name" : "STANDARD",
|
|
"type" : "input-text"
|
|
}
|
|
}, {
|
|
"name" : "AMOUNT",
|
|
"label" : "数量",
|
|
"quickEdit" : {
|
|
"name" : "AMOUNT",
|
|
"required" : true,
|
|
"type" : "input-number",
|
|
"precision" : 0,
|
|
"step" : 1,
|
|
"min" : 1.0,
|
|
"onEvent" : {
|
|
"change" : {
|
|
"actions" : [ {
|
|
"actionType" : "ajax",
|
|
"outputVar" : "egRow",
|
|
"args" : {
|
|
"api" : {
|
|
"method" : "post",
|
|
"url" : "/api/script/execute-editgrid-row",
|
|
"data" : {
|
|
"templateId" : "44504046-2f92-4b74-a578-42ebf3e40bc8",
|
|
"editgridField" : "PURCHASEDETAIL",
|
|
"scriptKey" : "1a33e848-4c2f-4685-be76-7630a5ad4cf8",
|
|
"changedField" : "AMOUNT",
|
|
"row" : "${__rendererData}",
|
|
"parent" : {
|
|
"PURCHASEDETAIL" : "${__rendererData.PURCHASEDETAIL || PURCHASEDETAIL}"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}, {
|
|
"actionType" : "setValue",
|
|
"componentId" : "eg-PURCHASEDETAIL",
|
|
"args" : {
|
|
"index" : "${index}",
|
|
"value" : "${egRow.rowSetValues}"
|
|
}
|
|
}, {
|
|
"actionType" : "setValue",
|
|
"componentId" : "eip4-edit-form",
|
|
"args" : {
|
|
"value" : "${egRow.parentSetValues}"
|
|
}
|
|
} ]
|
|
}
|
|
}
|
|
}
|
|
}, {
|
|
"name" : "UNITPRICE",
|
|
"label" : "单价(元)",
|
|
"quickEdit" : {
|
|
"name" : "UNITPRICE",
|
|
"required" : true,
|
|
"type" : "input-number",
|
|
"precision" : 2,
|
|
"min" : 0.01,
|
|
"onEvent" : {
|
|
"change" : {
|
|
"actions" : [ {
|
|
"actionType" : "ajax",
|
|
"outputVar" : "egRow",
|
|
"args" : {
|
|
"api" : {
|
|
"method" : "post",
|
|
"url" : "/api/script/execute-editgrid-row",
|
|
"data" : {
|
|
"templateId" : "44504046-2f92-4b74-a578-42ebf3e40bc8",
|
|
"editgridField" : "PURCHASEDETAIL",
|
|
"scriptKey" : "1a33e848-4c2f-4685-be76-7630a5ad4cf8",
|
|
"changedField" : "UNITPRICE",
|
|
"row" : "${__rendererData}",
|
|
"parent" : {
|
|
"PURCHASEDETAIL" : "${__rendererData.PURCHASEDETAIL || PURCHASEDETAIL}"
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}, {
|
|
"actionType" : "setValue",
|
|
"componentId" : "eg-PURCHASEDETAIL",
|
|
"args" : {
|
|
"index" : "${index}",
|
|
"value" : "${egRow.rowSetValues}"
|
|
}
|
|
}, {
|
|
"actionType" : "setValue",
|
|
"componentId" : "eip4-edit-form",
|
|
"args" : {
|
|
"value" : "${egRow.parentSetValues}"
|
|
}
|
|
} ]
|
|
}
|
|
}
|
|
}
|
|
}, {
|
|
"name" : "TOTALPRICE",
|
|
"label" : "金额(元)",
|
|
"quickEdit" : {
|
|
"name" : "TOTALPRICE",
|
|
"disabled" : true,
|
|
"type" : "input-number",
|
|
"precision" : 2
|
|
}
|
|
} ],
|
|
"needConfirm" : false
|
|
} ]
|
|
} ]
|
|
}, {
|
|
"type" : "grid",
|
|
"columns" : [ {
|
|
"md" : 6,
|
|
"body" : [ {
|
|
"name" : "SUMPRICE",
|
|
"label" : "申请总金额(元)",
|
|
"disabled" : true,
|
|
"type" : "input-number",
|
|
"precision" : 2
|
|
} ]
|
|
} ]
|
|
}, {
|
|
"type" : "grid",
|
|
"columns" : [ {
|
|
"md" : 12,
|
|
"body" : [ {
|
|
"name" : "DOCUMENT",
|
|
"label" : "附件",
|
|
"type" : "input-file",
|
|
"receiver" : "/api/file/upload?tableName=OA_FIXEDASSETS_PURCHASEAPPLY&businessKey=${OA_FIXEDASSETS_PURCHASEAPPLY_ID}",
|
|
"downloadUrl" : "/api/file/${id}",
|
|
"multiple" : true,
|
|
"staticOn" : "${__readonly}",
|
|
"joinValues" : false,
|
|
"extractValue" : false
|
|
} ]
|
|
} ]
|
|
}, {
|
|
"name" : "OA_FIXEDASSETS_PURCHASEAPPLY_ID",
|
|
"label" : "主键",
|
|
"hidden" : true,
|
|
"type" : "input-text"
|
|
} ],
|
|
"actions" : [ ]
|
|
}
|
|
} |