Commit 610f12f4 by 宋祥

1.fixBug:计划保存报错问题修复

parent c73f86ff
...@@ -101,6 +101,7 @@ public class ServiceHGCG001 extends ServiceBase { ...@@ -101,6 +101,7 @@ public class ServiceHGCG001 extends ServiceBase {
// 写入数据 // 写入数据
for (int i = 0; i < fCg001s.size(); i++) { for (int i = 0; i < fCg001s.size(); i++) {
HGCG001 hgcg001 = fCg001s.get(i); HGCG001 hgcg001 = fCg001s.get(i);
hgcg001.setPlanDate(DateUtils.formatShort(hgcg001.getPlanDate()));
if (hgcg001.getId() == null || hgcg001.getId() == 0) { if (hgcg001.getId() == null || hgcg001.getId() == 0) {
// 修改数据 // 修改数据
this.saveData(hgcg001); this.saveData(hgcg001);
......
...@@ -210,6 +210,19 @@ ...@@ -210,6 +210,19 @@
</update> </update>
<!-- 修改采购信息 --> <!-- 修改采购信息 -->
<update id="update">
UPDATE ${hggpSchema}.HGCG001
SET
COMPANY_CODE = #companyCode#,
COMPANY_NAME = #companyName#,
PROJ_CODE = #projCode#,
PROJ_NAME = #projName#,
PLAN_DATE = #planDate#,
<include refid="updateRevise"/>
WHERE PLAN_NO = #planNo#
</update>
<!-- 修改采购信息 -->
<update id="updatePur"> <update id="updatePur">
UPDATE ${hggpSchema}.HGCG001 UPDATE ${hggpSchema}.HGCG001
SET SET
......
...@@ -8,22 +8,22 @@ $(function () { ...@@ -8,22 +8,22 @@ $(function () {
pageSize: 20, pageSize: 20,
pageSizes: [20, 50, 70, 100], pageSizes: [20, 50, 70, 100],
}, },
columns: [ columns: [{
{ field: "operator",
field: "operator", title: "操作",
title: "操作", template: function (item) {
template: function (item) { let template = '';
let template = ''; if (!isBlank(item.id)) {
if (!isBlank(item.id)){ template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" '
template += '<a style="cursor: pointer;display: inline-flex;justify-content: center;margin:auto 5px" ' + 'onclick="showDetail(' + item.id + ', ' + item.status + ', ' + item.source
+ 'onclick="showDetail(' + item.id + ', ' + item.status + ', ' + item.source + ')" >详情</a>'; + ')" >详情</a>';
}
return template;
} }
}, { return template;
field: "companyCode", }
title: "公司编码", }, {
template: function (dataItem) { field: "companyCode",
title: "公司编码",
template: function (dataItem) {
for (let i = 0; i < companyCodeBox.length; i++) { for (let i = 0; i < companyCodeBox.length; i++) {
if (companyCodeBox[i]['companyCode'] === dataItem['companyCode']) { if (companyCodeBox[i]['companyCode'] === dataItem['companyCode']) {
return companyCodeBox[i]['companyCode']; return companyCodeBox[i]['companyCode'];
...@@ -41,9 +41,9 @@ $(function () { ...@@ -41,9 +41,9 @@ $(function () {
return projCodeBox[i]['valueField']; return projCodeBox[i]['valueField'];
} }
} }
return dataItem["projCode"]; return dataItem["projCode"] == null ? "" : dataItem["projCode"];
}, },
editor: function (container, options) { editor: function (container, options) {
let inInfo = new EiInfo(); let inInfo = new EiInfo();
inInfo.set("inqu_status-0-companyCode", options.model["companyCode"]); inInfo.set("inqu_status-0-companyCode", options.model["companyCode"]);
inInfo.set("inqu_status-0-approvalStatus", 2); inInfo.set("inqu_status-0-approvalStatus", 2);
......
...@@ -45,11 +45,11 @@ ...@@ -45,11 +45,11 @@
align="center" filter="contains" sort="true"> align="center" filter="contains" sort="true">
<EF:EFOptions blockId="roleCompany" textField="companyName" valueField="companyCode"/> <EF:EFOptions blockId="roleCompany" textField="companyName" valueField="companyCode"/>
</EF:EFComboColumn> </EF:EFComboColumn>
<EF:EFColumn ename="companyName" cname="公司名称" width="120" enable="false" readonly="true" align="center"/> <EF:EFColumn ename="companyName" cname="公司名称" width="220" enable="false" readonly="true" align="left"/>
<EF:EFColumn ename="projCode" cname="项目编码" enable="true" width="120" align="center" required="true"/> <EF:EFColumn ename="projCode" cname="项目编码" enable="true" width="140" align="center" required="true"/>
<EF:EFColumn ename="projName" cname="项目名称" width="120" align="center" enable="false"/> <EF:EFColumn ename="projName" cname="项目名称" width="120" align="left" enable="false"/>
<EF:EFColumn ename="planDate" cname="计划日期" width="100" align="center" editType="date" <EF:EFColumn ename="planDate" cname="计划日期" width="100" align="center" editType="date"
dateFormat="yyyy-MM-dd" parseFormats="['yyyyMMdd']" required="true"/> dateFormat="yyyy-MM-dd" parseFormats="['yyyyMMdd']" required="true"/>
<EF:EFColumn ename="planNo" cname="计划单号" enable="false" width="120" align="center"/> <EF:EFColumn ename="planNo" cname="计划单号" enable="false" width="120" align="center"/>
<EF:EFComboColumn ename="status" cname="状态" enable="false" width="80" align="center"> <EF:EFComboColumn ename="status" cname="状态" enable="false" width="80" align="center">
<EF:EFCodeOption codeName="hggp.hgcg.planStatus"/> <EF:EFCodeOption codeName="hggp.hgcg.planStatus"/>
......
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