Commit f5855b27 by liuyang

物料清单功能优化

parent 4a86cb76
......@@ -177,7 +177,14 @@ public enum DdynamicEnum {
* 用途:项目档案下拉框
* 编写:wwl
*/
COMPANY_RECORD_BLOCK_ID("company_record_block_id","companyCode","companyName","HPXSUser.queryCompanyComboBox");
COMPANY_RECORD_BLOCK_ID("company_record_block_id","companyCode","companyName","HPXSUser.queryCompanyComboBox"),
/**
* 模块:物料清单
* 用途:物料清单部件类型 耗材 零部件 部件
* 编写:ly
*/
CODESET_CODE_BLOCK_ID("codeset_code_block_id","itemCode","itemCname","HPSC002.querySmallCode");
/** 将结果集放入的块名 */
private final String blockId;
......
......@@ -18,7 +18,6 @@ import com.baosight.iplat4j.core.ei.EiInfo;
import com.baosight.iplat4j.core.exception.PlatException;
import com.baosight.iplat4j.core.service.impl.ServiceBase;
import com.baosight.iplat4j.core.util.NumberUtils;
import com.baosight.iplat4j.core.web.threadlocal.UserSession;
import com.baosight.iplat4j.ed.util.SequenceGenerator;
import org.apache.commons.lang.StringUtils;
......@@ -38,7 +37,10 @@ public class ServiceHPSC002 extends ServiceBase {
*/
public EiInfo initLoad(EiInfo inInfo) {
try {
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.INVENT_NAME_BLOCK_ID), null);
Map<String, Object> map = new HashMap<>();
CommonMethod.initBlock(inInfo,
Arrays.asList(DdynamicEnum.INVENT_NAME_BLOCK_ID,DdynamicEnum.CODESET_CODE_BLOCK_ID),map,
false);
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HPSC002().eiMetadata);
} catch (Exception e) {
LogUtils.setDetailMsg(inInfo, e, "初始化失败");
......
......@@ -40,7 +40,7 @@ public class ServiceHPSC003 extends ServiceBase {
*/
public EiInfo initLoad(EiInfo inInfo) {
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.FACTORY_RECORD_BLOCK_ID,DdynamicEnum.INVENT_NAME_BLOCK_ID),
new HashMap<String,Object>(){{put("prdtType",4);}});
new HashMap<String,Object>(){{put("inventType",4);}});
HPSC003 HPSC003 = new HPSC003();
EiInfo outInfo = super.initLoad(inInfo, HPSC003);
outInfo.addBlock(EiConstant.resultBlock).addBlockMeta(HPSC003.eiMetadata);
......
......@@ -494,4 +494,14 @@
PARENT_ID = #parentId#
</isNotEmpty>
</select>
<select id="querySmallCode" parameterClass="java.util.HashMap" resultClass="java.util.HashMap">
select distinct
ITEM_CODE as "itemCode",
ITEM_CNAME as "itemCname"
from
iplat.tedcm01
where STATUS = '1' and CODESET_CODE = 'hpjx.hpkc.inventType' and ITEM_CODE IN ('2','3','4')
</select>
</sqlMap>
\ No newline at end of file
......@@ -342,6 +342,7 @@ $(function () {
]
},
};
IPLATUI
// 关闭事件
IPLATUI.EFWindow = {
......
......@@ -41,7 +41,7 @@
<div id="right-pane" class="i-fit-height" style="width: 80%;float: right">
<EF:EFRegion id="result" title="明细信息">
<EF:EFGrid blockId="result" autoDraw="no" checkMode="single">
<EF:EFGrid blockId="result" autoDraw="override" checkMode="single">
<EF:EFColumn ename="id" cname="主键" hidden="true"/>
<EF:EFColumn ename="level" cname="层级" hidden="true"/>
<EF:EFColumn enable="false" ename="projCode" cname="项目编码"/>
......@@ -51,12 +51,11 @@
itemTemplate="#=textField#"
textField="textField"
valueField="valueField">
<EF:EFCodeOption codeName="hpjx.hpkc.inventType" condition="ITEM_CODE IN ('3','4')"/>
<EF:EFCodeOption codeName="hpjx.hpkc.inventType" condition="ITEM_CODE IN ('2','3','4')"/>
</EF:EFComboColumn>--%>
<EF:EFComboColumn ename="prdtType" cname="部件类型" align="center" required="true"
filter="contains" width="90">
<EF:EFOption label="零部件" value="3"/>
<EF:EFOption label="部件" value="4"/>
<EF:EFOptions blockId="codeset_code_block_id" valueField="valueField" textField="textField"/>
</EF:EFComboColumn>
<%--<EF:EFPopupColumn ename="prdtName" cname="部件名称" width="200" popupType="ServiceGrid"
popupTitle="部件信息" serviceName="HPPZ006" methodName="queryPrdtComboBox" resultId="invent_prdt_name_block_id"
......@@ -67,15 +66,27 @@
valueField="param1Field" textField="param1Field"/>--%>
<EF:EFColumn ename="prdtName" cname="部件名称" width="200" align="center" maxLength="50"/>
<EF:EFColumn ename="prdtCode" cname="部件编码" hidden = 'true'/>
<EF:EFColumn ename="length" cname="长" format="{0:N3}"/>
<EF:EFColumn ename="width" cname="宽" format="{0:N3}"/>
<EF:EFColumn ename="thick" cname="厚" format="{0:N3}"/>
<EF:EFColumn ename="length" cname="长" format="{0:N3}" maxLength="12" displayType="0.000"
data-regex="/^-?[0-9]{1,9}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置9位整数和3位小数!"/>
<EF:EFColumn ename="width" cname="宽" format="{0:N3}" maxLength="12" displayType="0.000"
data-regex="/^-?[0-9]{1,9}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置9位整数和3位小数!"/>
<EF:EFColumn ename="thick" cname="厚" format="{0:N3}" maxLength="12" displayType="0.000"
data-regex="/^-?[0-9]{1,9}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置9位整数和3位小数!"/>
<EF:EFColumn ename="remark" cname="备注" />
<EF:EFColumn enable="false" ename="parentId" hidden="true" cname="上级部件名称"/>
<EF:EFColumn enable="false" ename="parentPrdtName" hidden="true" cname="上级部件名称"/>
<EF:EFColumn ename="num" required="true" cname="数量"/>
<EF:EFColumn ename="unitWt" required="true" format="{0:N3}" cname="单重"/>
<EF:EFColumn enable="false" format="{0:N3}" ename="totalWt" cname="总重"/>
<EF:EFColumn ename="num" required="true" cname="数量" maxLength="15" displayType="0.000"
data-regex="/^-?[0-9]{1,12}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置12位整数和3位小数!"/>
<EF:EFColumn ename="unitWt" required="true" format="{0:N3}" cname="单重" maxLength="15" displayType="0.000"
data-regex="/^-?[0-9]{1,12}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置12位整数和3位小数!"/>
<EF:EFColumn enable="false" format="{0:N3}" ename="totalWt" cname="总重"
data-regex="/^-?[0-9]{1,12}([.][0-9]{1,3})?$/"
data-errorprompt="请输入数字,该值最大可设置12位整数和3位小数!"/>
<EF:EFComboColumn enable="false" ename="status" align="center"
columnTemplate="#=textField#" optionLabel=" "
itemTemplate="#=textField#" textField="textField"
......
......@@ -114,6 +114,7 @@ $(function () {
// 绑定grid
detailGrid.setEiInfo(ei);
query();
}
//释放禁用按钮
btnNode.attr("disabled", false);
......@@ -143,6 +144,7 @@ $(function () {
columns: [
{
field: "operator",
title: "操作",
template: function (item) {
let filePath1 = item.filePath1;
let template = '';
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment