Commit a35c0be3 by wancheng

其他入库单,其他出库单

parent 18b3df0f
......@@ -10,6 +10,7 @@ import com.baosight.hggp.hg.cw.tools.HGCWTools;
import com.baosight.hggp.hg.cw.vo.UserVO;
import com.baosight.hggp.hg.kc.domain.HGKC003;
import com.baosight.hggp.hg.kc.domain.HGKC006;
import com.baosight.hggp.hg.kc.domain.HGKC006;
import com.baosight.hggp.hg.kc.utils.HGKCUtils;
import com.baosight.hggp.hg.utils.HGUtils;
import com.baosight.hggp.hg.xs.tools.HGXSTools;
......@@ -44,7 +45,11 @@ public class ServiceHGKC006 extends ServiceBase {
@OperationLogAnnotation(operModul = "其他入库单", operType = "查询", operDesc = "初始化")
public EiInfo initLoad(EiInfo inInfo) {
try {
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.WH_RECORD_BLOCK_ID));
Map map = new HashMap();
map.put(HGKC006.FIELD_ACCOUNT_CODE, UserSessionUtils.getAccountCode());
CommonMethod.initBlock(inInfo,
Arrays.asList(DdynamicEnum.COMPANY_BOX_BLOCK_ID,DdynamicEnum.WH_RECORD_BLOCK_ID),map,false
);
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HGKC006().eiMetadata);
} catch (PlatException e) {
LogUtils.setDetailMsg(inInfo, e, "初始化失败");
......@@ -89,7 +94,9 @@ public class ServiceHGKC006 extends ServiceBase {
for (int i = 0; i < resultRows.size(); i++) {
HGKC006 hgkc006 = new HGKC006();
hgkc006.fromMap(resultRows.get(i));
hgkc006.setOtherEnterDate(DateUtils.formatShort(hgkc006.getOtherEnterDate()));
if (hgkc006.getId() == null || hgkc006.getId() == 0) {
hgkc006.setSubmitStatus(HGConstant.ProductStatus.WTJ);
this.add(hgkc006);
} else {
this.modify(hgkc006);
......
......@@ -3,6 +3,7 @@ package com.baosight.hggp.hg.kc.service;
import com.baosight.hggp.aspect.annotation.OperationLogAnnotation;
import com.baosight.hggp.common.DdynamicEnum;
import com.baosight.hggp.core.dao.DaoUtils;
import com.baosight.hggp.core.security.UserSessionUtils;
import com.baosight.hggp.hg.constant.HGConstant;
import com.baosight.hggp.hg.cw.tools.HGCWTools;
......@@ -10,6 +11,7 @@ import com.baosight.hggp.hg.cw.vo.UserVO;
import com.baosight.hggp.hg.kc.domain.HGKC003;
import com.baosight.hggp.hg.kc.domain.HGKC007;
import com.baosight.hggp.hg.kc.domain.HGKC007;
import com.baosight.hggp.hg.kc.domain.HGKC007;
import com.baosight.hggp.hg.kc.utils.HGKCUtils;
import com.baosight.hggp.hg.utils.HGUtils;
import com.baosight.hggp.hg.xs.tools.HGXSTools;
......@@ -22,6 +24,7 @@ import com.baosight.iplat4j.core.service.impl.ServiceBase;
import com.baosight.iplat4j.ed.util.SequenceGenerator;
import java.util.Arrays;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
......@@ -43,7 +46,11 @@ public class ServiceHGKC007 extends ServiceBase {
@OperationLogAnnotation(operModul = "其他出库单", operType = "查询", operDesc = "初始化")
public EiInfo initLoad(EiInfo inInfo) {
try {
CommonMethod.initBlock(inInfo, Arrays.asList(DdynamicEnum.WH_RECORD_BLOCK_ID));
Map map = new HashMap();
map.put(HGKC007.FIELD_ACCOUNT_CODE, UserSessionUtils.getAccountCode());
CommonMethod.initBlock(inInfo,
Arrays.asList(DdynamicEnum.COMPANY_BOX_BLOCK_ID,DdynamicEnum.WH_RECORD_BLOCK_ID),map,false
);
inInfo.addBlock(EiConstant.resultBlock).addBlockMeta(new HGKC007().eiMetadata);
} catch (PlatException e) {
LogUtils.setDetailMsg(inInfo, e, "初始化失败");
......@@ -88,7 +95,9 @@ public class ServiceHGKC007 extends ServiceBase {
for (int i = 0; i < resultRows.size(); i++) {
HGKC007 hgkc007 = new HGKC007();
hgkc007.fromMap(resultRows.get(i));
hgkc007.setOtherOutDate(DateUtils.formatShort(hgkc007.getOtherOutDate()));
if (hgkc007.getId() == null || hgkc007.getId() == 0) {
hgkc007.setSubmitStatus(HGConstant.ProductStatus.WTJ);
this.add(hgkc007);
} else {
this.modify(hgkc007);
......
let whNameGlobalData = [];
$(function () {
var companyCodes = __eiInfo.getBlock("companyBox_block_id").getMappedRows();
IPLATUI.EFGrid.result = {
pageable: {
pageSize: 20,
......@@ -25,6 +25,17 @@ $(function () {
return template;
}
},{
field: "companyCode",
template: function (dataItem) {
for (let i = 0; i < companyCodes.length; i++) {
if (companyCodes[i]['valueField'] === dataItem['companyCode']){
dataItem['companyName'] = companyCodes[i]['textField']
return companyCodes[i]['textField'];
}
}
return dataItem["companyCode"];
}
},{
field: "otherEnterDate",
attributes: {
class: "i-input-readonly"
......
......@@ -38,13 +38,20 @@
<EF:EFGrid blockId="result" autoDraw="override" isFloat="true" checkMode="row">
<EF:EFColumn ename="id" cname="内码" hidden="true"/>
<EF:EFColumn ename="operator" cname="操作" locked="true" enable="false" width="100" align="center"/>
<EF:EFColumn ename="companyName" cname="公司名称" enable="false" width="140" align="center"/>
<EF:EFColumn ename="otherEnterDate" cname="单据日期" enable="false" width="100" align="center" editType="date"
<EF:EFComboColumn ename="companyCode" cname="公司名称"
columnTemplate="#=textField#" itemTemplate="#=textField#"
textField="textField" valueField="valueField"
maxLength="16" width="120" required="true"
align="center" filter="contains" sort="true">
<EF:EFOptions blockId="companyBox_block_id" textField="textField" valueField="valueField"/>
</EF:EFComboColumn>
<EF:EFColumn ename="companyName" cname="公司名称" hidden="true"/>
<EF:EFColumn ename="otherEnterDate" cname="单据日期" width="100" align="center" editType="date"
dateFormat="yyyy-MM-dd" parseFormats="['yyyyMMdd']" required="true"/>
<EF:EFColumn ename="otherEnterNo" cname="其他入库单号" enable="false" width="140" align="center"/>
<EF:EFColumn ename="whCode" cname="仓库名称" width="120" align="center" required="true"/>
<EF:EFColumn ename="whName" cname="仓库名称" hidden="true"/>
<EF:EFComboColumn cname="状态" ename="submitStatus" width="90" align="center" required="true" defaultValue="0">
<EF:EFComboColumn cname="状态" ename="submitStatus" width="90" align="center" enable="false">
<EF:EFCodeOption codeName="hggp.hpkc.submitStatus"/>
</EF:EFComboColumn>
</EF:EFGrid>
......
......@@ -25,6 +25,17 @@ $(function () {
return template;
}
},{
field: "companyCode",
template: function (dataItem) {
for (let i = 0; i < companyCodes.length; i++) {
if (companyCodes[i]['valueField'] === dataItem['companyCode']){
dataItem['companyName'] = companyCodes[i]['textField']
return companyCodes[i]['textField'];
}
}
return dataItem["companyCode"];
}
},{
field: "otherOutDate",
attributes: {
class: "i-input-readonly"
......
......@@ -39,13 +39,20 @@
<EF:EFGrid blockId="result" autoDraw="override" isFloat="true" checkMode="row">
<EF:EFColumn ename="id" cname="内码" hidden="true"/>
<EF:EFColumn ename="operator" cname="操作" locked="true" enable="false" width="100" align="center"/>
<EF:EFColumn ename="companyName" cname="公司名称" enable="false" width="140" align="center"/>
<EF:EFColumn ename="otherOutDate" cname="单据日期" enable="false" width="100" align="center" editType="date"
<EF:EFComboColumn ename="companyCode" cname="公司名称"
columnTemplate="#=textField#" itemTemplate="#=textField#"
textField="textField" valueField="valueField"
maxLength="16" width="120" required="true"
align="center" filter="contains" sort="true">
<EF:EFOptions blockId="companyBox_block_id" textField="textField" valueField="valueField"/>
</EF:EFComboColumn>
<EF:EFColumn ename="companyName" cname="公司名称" hidden="true"/>
<EF:EFColumn ename="otherOutDate" cname="单据日期" width="100" align="center" editType="date"
dateFormat="yyyy-MM-dd" parseFormats="['yyyyMMdd']" required="true"/>
<EF:EFColumn ename="otherOutNo" cname="其他入库单号" enable="false" width="140" align="center"/>
<EF:EFColumn ename="whCode" cname="仓库名称" width="120" align="center" required="true" />
<EF:EFColumn ename="whName" cname="仓库名称" hidden="true"/>
<EF:EFComboColumn cname="状态" ename="submitStatus" width="90" align="center" required="true" defaultValue="0">
<EF:EFComboColumn cname="状态" ename="submitStatus" width="90" align="center" enable="false" >
<EF:EFCodeOption codeName="hggp.hpkc.submitStatus"/>
</EF:EFComboColumn>
......
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