Commit da6c1b90 authored by 刘学辉's avatar 刘学辉

品质异常单按需求调整

parent a79efb3d
...@@ -67,3 +67,11 @@ DEFAULT CHARSET=utf8mb4 ...@@ -67,3 +67,11 @@ DEFAULT CHARSET=utf8mb4
COLLATE=utf8mb4_general_ci; COLLATE=utf8mb4_general_ci;
--2024-09-19 异常单增加产品类别字段 --2024-09-19 异常单增加产品类别字段
ALTER TABLE topsun_dev.sap_exception_report ADD product_type varchar(100) NULL COMMENT '产品类别'; ALTER TABLE topsun_dev.sap_exception_report ADD product_type varchar(100) NULL COMMENT '产品类别';
-- 2024-09-23 异常单增加来源单据编号
ALTER TABLE topsun_dev.sap_exception_report ADD source_bill_code varchar(100) NULL COMMENT '来源单据编号';
--2024-09-24 异常单责任明细增加长度
ALTER TABLE topsun_dev.sap_exception_duty_person MODIFY COLUMN person_name varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL COMMENT '姓名/供应商名称/客户名';
ALTER TABLE topsun_dev.sap_exception_duty_person MODIFY COLUMN dept_name varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL COMMENT '部门名称';
ALTER TABLE topsun_dev.sap_exception_duty_person MODIFY COLUMN person_no varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL COMMENT '号/供应商编码/客户名编码';
ALTER TABLE topsun_dev.sap_exception_report MODIFY COLUMN customer_order_no varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL COMMENT '客户单号';
var itemGridManager, purchaseGridManager, dutyPersonGridManager = null var itemGridManager, purchaseGridManager, dutyPersonGridManager = null
var colRowNum =2;
$(function () { $(function () {
initialize(); initialize();
initProduceGrid(); initProduceGrid();
...@@ -39,7 +40,7 @@ function initialize() { ...@@ -39,7 +40,7 @@ function initialize() {
$('#dutyDept').val(data.deptId); $('#dutyDept').val(data.deptId);
} }
}); });
if ($('#exceptionReasonType').val() == "3") { if ($('#exceptionReasonType').val() == "1") {
showPurchaseDiv(); showPurchaseDiv();
} else { } else {
showProduceDiv(); showProduceDiv();
...@@ -47,7 +48,7 @@ function initialize() { ...@@ -47,7 +48,7 @@ function initialize() {
$('#exceptionReasonType').combox({ $('#exceptionReasonType').combox({
onChange: function (v) { onChange: function (v) {
//alert(v.value+'==========='); //alert(v.value+'===========');
if (v.value == 3) { //采购 if (v.value == 1) { //采购
// $('#editDataSourceKindId').combox('setValue','4'); // $('#editDataSourceKindId').combox('setValue','4');
showPurchaseDiv(); showPurchaseDiv();
} else { } else {
...@@ -149,10 +150,10 @@ function initProduceGrid() { ...@@ -149,10 +150,10 @@ function initProduceGrid() {
}); });
var toolbarOptions = UICtrl.getDefaultToolbarOptions({ var toolbarOptions = UICtrl.getDefaultToolbarOptions({
addHandler: function () { addHandler: function () {
if (Public.isBlank($('#customerOrderNo').val())) { /* if (Public.isBlank($('#customerOrderNo').val())) {
Public.tip("请先输入客户订单号!") Public.tip("请先输入客户订单号!")
return false return false
} }*/
UICtrl.addGridRow(itemGridManager); UICtrl.addGridRow(itemGridManager);
}, },
deleteHandler: function () { deleteHandler: function () {
...@@ -174,7 +175,7 @@ function initProduceGrid() { ...@@ -174,7 +175,7 @@ function initProduceGrid() {
dataAction: 'server', dataAction: 'server',
url: web_app.name + '/exceptionReport/slicedExceptionReportItemList.ajax', url: web_app.name + '/exceptionReport/slicedExceptionReportItemList.ajax',
parms: {exceptionReportId: getId()}, parms: {exceptionReportId: getId()},
height: '300px', height:'auto', // colRowNum*35+90
heightDiff: -4, heightDiff: -4,
sortName: 'id', sortName: 'id',
sortOrder: 'asc', sortOrder: 'asc',
...@@ -224,6 +225,10 @@ function getGridColumns() { ...@@ -224,6 +225,10 @@ function getGridColumns() {
type: 'system', type: 'system',
name: "sapCustomerProduceNo", name: "sapCustomerProduceNo",
getParam: function (item) { getParam: function (item) {
if (Public.isBlank($('#customerOrderNo').val())) {
Public.tip("请先输入客户订单号!")
return false;
}
return { return {
werks: $("#werks").val(), werks: $("#werks").val(),
kunnr: $("#customerNo").val(), kunnr: $("#customerNo").val(),
...@@ -305,7 +310,7 @@ function initDutyPersonGridGrid() { ...@@ -305,7 +310,7 @@ function initDutyPersonGridGrid() {
dataAction: 'server', dataAction: 'server',
url: web_app.name + '/exceptionReport/slicedExceptionReportDutyPersonList.ajax', url: web_app.name + '/exceptionReport/slicedExceptionReportDutyPersonList.ajax',
parms: {exceptionReportId: getId()}, parms: {exceptionReportId: getId()},
height: '300px', height: 'auto',
heightDiff: -4, heightDiff: -4,
sortName: 'id', sortName: 'id',
sortOrder: 'asc', sortOrder: 'asc',
...@@ -347,7 +352,7 @@ function initPurchaseGrid() { ...@@ -347,7 +352,7 @@ function initPurchaseGrid() {
dataAction: 'server', dataAction: 'server',
url: web_app.name + '/exceptionReport/slicedExceptionReportItemList.ajax', url: web_app.name + '/exceptionReport/slicedExceptionReportItemList.ajax',
parms: {exceptionReportId: getId()}, parms: {exceptionReportId: getId()},
height: '300px', height: 'auto',
heightDiff: -4, heightDiff: -4,
sortName: 'id', sortName: 'id',
sortOrder: 'asc', sortOrder: 'asc',
...@@ -383,18 +388,52 @@ function getPurchaseGridColumns() { ...@@ -383,18 +388,52 @@ function getPurchaseGridColumns() {
columns = [ columns = [
{ {
display: "采购单号", name: "produceNo", width: "160", align: "left", type: "string", display: "采购单号", name: "produceNo", width: "160", align: "left", type: "string",
editor: {type: 'text', required: true} // editor: {type: 'text', required: true}
editor: {
required: false, type: "select",
data: {
type: 'system',
name: "dictionary",
getParam: function (item) {
return {fieldName: "EKKO"}
},
back: {
EBELN: "produceNo"
// MSEHL: "unitName"
}
}
}
}, },
// {display: "产品类别", name: "productType", width: "160", align: "left", type: "string" // {display: "产品类别", name: "productType", width: "160", align: "left", type: "string"
// ,editor: {type: 'text',required:true} // ,editor: {type: 'text',required:true}
// }, // },
{ {
display: "产品编码", name: "productCode", width: "160", align: "left", type: "string" display: "产品名称", name: "productName", width: "200", align: "left", type: "string"
, editor: {type: 'text', required: true} // , editor: {type: 'text', required: true}
,editor: {
required: true, type: "select",
data: {
type: 'system',
name: "sapMaterialSelect",
getParam: function (item) {
return {
// filterValue:item.company
}
},
back: {
MATNR: "productCode",
MAKTX: "productName",
// EKGRP: "ekgrp",
MEINS: "unit",
MSEHL: "unitName"
}
}
}
}, },
{ {
display: "产品名称", name: "productName", width: "200", align: "left", type: "string" display: "产品编码", name: "productCode", width: "160", align: "left", type: "string"
, editor: {type: 'text', required: true} //, editor: {type: 'text', required: true}
}, },
{ {
display: "数量", name: "number", width: "100", align: "left", type: "string" display: "数量", name: "number", width: "100", align: "left", type: "string"
...@@ -415,7 +454,7 @@ function getPurchaseGridColumns() { ...@@ -415,7 +454,7 @@ function getPurchaseGridColumns() {
MSEH3: "unit", MSEH3: "unit",
MSEHL: "unitName" MSEHL: "unitName"
} }
}, }
} }
}, },
{ {
...@@ -502,7 +541,7 @@ function getExtendedData(processAction) { ...@@ -502,7 +541,7 @@ function getExtendedData(processAction) {
} }
var extendedData = {}; var extendedData = {};
var _grid = UICtrl.getGridManager('#maingrid'); var _grid = UICtrl.getGridManager('#maingrid');
if ($('#exceptionReasonType').val() == "3") { //采购异常 if ($('#exceptionReasonType').val() == "1") { //供应商材料问题
_grid = UICtrl.getGridManager('#purchasegrid'); _grid = UICtrl.getGridManager('#purchasegrid');
} }
if (_grid) { if (_grid) {
......
...@@ -105,7 +105,7 @@ function initItemGrid() { ...@@ -105,7 +105,7 @@ function initItemGrid() {
}); });
//物料编码 //物料编码
$('#maktx').searchbox({ /*$('#maktx').searchbox({
type: "system", name: "sapMaterialSelect", type: "system", name: "sapMaterialSelect",
getParam: function (item) { getParam: function (item) {
return { return {
...@@ -115,12 +115,6 @@ function initItemGrid() { ...@@ -115,12 +115,6 @@ function initItemGrid() {
onChange: function (value, data) { onChange: function (value, data) {
$('#matnr').val(data.MATNR); $('#matnr').val(data.MATNR);
$('#maktx').val(data.MAKTX); $('#maktx').val(data.MAKTX);
// $('#matkl').val(data.MATKL); // alert(data.MATKL+"--"+data.WGBEZ);
// $('#matklName').val(data.WGBEZ);
// $('#ekgrp').val(data.EKGRP);
// $('#ekgrpName').val(data.EKNAM);
// $('#bprme').val(data.MEINS);
// $('#bprmeName').val(data.MSEHL);
} }
}); });
$('#customerOrderNo').searchbox({ $('#customerOrderNo').searchbox({
...@@ -132,7 +126,7 @@ function initItemGrid() { ...@@ -132,7 +126,7 @@ function initItemGrid() {
$('#customerOrderNo').val(data.EBELN); $('#customerOrderNo').val(data.EBELN);
} }
}); });
/*$('#customerName').searchbox({ $('#customerName').searchbox({
type: "system", name: "sapCustomerOrderSelect", type: "system", name: "sapCustomerOrderSelect",
getParam: function (item) { getParam: function (item) {
if (Public.isBlank($('#werksName').val())){ if (Public.isBlank($('#werksName').val())){
......
...@@ -28,6 +28,10 @@ ...@@ -28,6 +28,10 @@
<x:hidden name="personMemberName"/> <x:hidden name="personMemberName"/>
<x:hidden name="exceptionType" value="out"/> <x:hidden name="exceptionType" value="out"/>
<x:hidden name="frgdt"/> <x:hidden name="frgdt"/>
<x:hidden name="werks"/>
<x:hidden name="manager"/>
<x:hidden name="deputyManager"/>
<x:hidden name="generalManager"/>
<div class="hg-form-cols"> <div class="hg-form-cols">
<c:if test="${statusId==1||statusId==3}"> <c:if test="${statusId==1||statusId==3}">
<div style="float: right; margin-right: 10px;" class="btn-group" id="buttonBox"> <div style="float: right; margin-right: 10px;" class="btn-group" id="buttonBox">
...@@ -50,9 +54,9 @@ ...@@ -50,9 +54,9 @@
</div> </div>
<div class="hg-form-row"> <div class="hg-form-row">
<x:inputC name="matnr" label="材料编码" labelCol="1" fieldCol="2" required="false" readonly="true"/> <x:inputC name="matnr" label="材料编码" labelCol="1" fieldCol="2" required="false" readonly="true"/>
<x:inputC name="maktx" label="材料名称" labelCol="1" fieldCol="2" required="true" wrapper="select"/> <x:inputC name="maktx" label="材料名称" labelCol="1" fieldCol="2" required="false" readonly="true"/>
<x:inputC name="customerOrderNo" label="采购单号" labelCol="1" fieldCol="2" required="true" wrapper="select"/> <x:inputC name="customerOrderNo" label="采购单号" labelCol="1" fieldCol="2" required="false" readonly="true"/>
<x:inputC name="loseMoney" label="损失金额" labelCol="1" fieldCol="2" required="true" mask="nnnnnn.nn" /> <x:inputC name="loseMoney" label="损失金额" labelCol="1" fieldCol="2" required="true" mask="nnnnnn.nn" />
<x:selectC name="statusId" label="处理进度" labelCol="1" fieldCol="2" disabled="true" required="false" dictionary="bizBillStatus"/> <x:selectC name="statusId" label="处理进度" labelCol="1" fieldCol="2" disabled="true" required="false" dictionary="bizBillStatus"/>
......
...@@ -96,6 +96,7 @@ function initGrid() { ...@@ -96,6 +96,7 @@ function initGrid() {
fixedCellHeight: true, fixedCellHeight: true,
selectRowButtonOnly: true, selectRowButtonOnly: true,
enableObjectBag: true, enableObjectBag: true,
allowAdjustColWidth: true,
onSuccess: function (data) { onSuccess: function (data) {
if (data.error) { if (data.error) {
Public.tip(data.error); Public.tip(data.error);
......
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
.td1{border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:40pt} .td1{border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:40pt}
.td2{border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid;border-top-width:0.75pt;vertical-align:top;width:100pt} .td2{border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid;border-top-width:0.75pt;vertical-align:top;width:100pt}
.p1{margin:5pt; orphans:0; widows:0;width:60pt} .p1{margin:5pt; orphans:0; widows:0;width:60pt}
.autoLine{word-break:normal; width:auto; display:block; word-wrap: break-word ;overflow: hidden;line-height:1}
</style></head> </style></head>
<body> <body>
<div> <div>
...@@ -74,21 +75,21 @@ ...@@ -74,21 +75,21 @@
<td class="td2" style="width:90%"> <td class="td2" style="width:90%">
<#if (itemList)?? && ((itemList)?size > 0)> <#if (itemList)?? && ((itemList)?size > 0)>
<#list itemList as list> <#list itemList as list>
<p class="p1" style="width:auto" ><span>${(list.produceNo)!' '}</span></p> <p class="p1" style="width:auto" ><span class="autoLine">${(list.produceNo)!' '}</span></p>
</#list> </#list>
</#if> </#if>
</td> </td>
</tr> </tr>
</table> </table>
<table> <table>
<tr> <tr style="height: 30pt">
<td class="td1"> <td class="td1">
<p class="p1"><span style="font-weight:bolder ">产品编号</span></p> <p class="p1"><span style="font-weight:bolder ">产品编号</span></p>
</td> </td>
<td class="td2" > <td class="td2" >
<#if (itemList)?? && ((itemList)?size > 0)> <#if (itemList)?? && ((itemList)?size > 0)>
<#list itemList as list> <#list itemList as list>
<p class="p1" style="width:90pt" ><span>${(list.productCode)!' '}</span></p> <p class="p1" style="width:90pt" ><span class="autoLine">${(list.productCode)!' '}</span></p>
</#list> </#list>
</#if> </#if>
</td> </td>
...@@ -98,7 +99,7 @@ ...@@ -98,7 +99,7 @@
<td class="td2" style="width:90%"> <td class="td2" style="width:90%">
<#if (itemList)?? && ((itemList)?size > 0)> <#if (itemList)?? && ((itemList)?size > 0)>
<#list itemList as list> <#list itemList as list>
<p class="p1" style="width:auto" ><span>${(list.productName)!' '}</span></p> <p class="p1" style="width:auto" ><span class="autoLine">${(list.productName)!' '}</span></p>
</#list> </#list>
</#if> </#if>
</td> </td>
...@@ -155,10 +156,10 @@ ...@@ -155,10 +156,10 @@
<td class="td1"> <td class="td1">
<p class="p1"><span style="font-weight:bolder ">折算金额</span></p> <p class="p1"><span style="font-weight:bolder ">折算金额</span></p>
</td> </td>
<td class="td2" style="width:50%"> <td class="td2">
<#if (itemList)?? && ((itemList)?size > 0)> <#if (itemList)?? && ((itemList)?size > 0)>
<#list itemList as list> <#list itemList as list>
<p class="p1" style="width:auto" ><span>${(list.rmbMoney)!' '}</span></p> <p class="p1" style="width:85pt" ><span>${(list.rmbMoney)!' '}</span></p>
</#list> </#list>
</#if> </#if>
</td> </td>
...@@ -172,7 +173,7 @@ ...@@ -172,7 +173,7 @@
</table> </table>
<table> <table>
<tr> <tr style="height: 80pt;">
<td class="td1"> <td class="td1">
<p class="p1"><span style="font-weight:bolder ">异常陈述</span></p> <p class="p1"><span style="font-weight:bolder ">异常陈述</span></p>
</td> </td>
...@@ -182,7 +183,7 @@ ...@@ -182,7 +183,7 @@
</tr> </tr>
</table> </table>
<table > <table >
<tr> <tr style="height: 80pt;">
<td class="td1"> <td class="td1">
<p class="p1"><span style="font-weight:bolder ">发生原因</span></p> <p class="p1"><span style="font-weight:bolder ">发生原因</span></p>
</td> </td>
...@@ -192,7 +193,7 @@ ...@@ -192,7 +193,7 @@
</tr> </tr>
</table> </table>
<table> <table>
<tr> <tr style="height: 80pt;">
<td class="td1"> <td class="td1">
<p class="p1"><span style="font-weight:bolder ">改善措施</span></p> <p class="p1"><span style="font-weight:bolder ">改善措施</span></p>
</td> </td>
...@@ -208,19 +209,19 @@ ...@@ -208,19 +209,19 @@
<p class="p1"><span style="font-weight:bolder ">责任部门</span></p> <p class="p1"><span style="font-weight:bolder ">责任部门</span></p>
</td> </td>
<td class="td2"> <td class="td2">
<p class="p1"><span style="">${(head.dutyDeptName)!' '}</span></p> <p class="p1" style="width:90pt"><span>${(head.dutyDeptName)!' '}</span></p>
</td> </td>
<td class="td1"> <td class="td1">
<p class="p1"><span style="font-weight:bolder ">校验员</span></p> <p class="p1"><span style="font-weight:bolder ">校验员</span></p>
</td> </td>
<td class="td2"> <td class="td2" style="width:90%">
<p class="p1"><span style="">${(head.checkOperatorName)!' '}</span></p> <p class="p1" style="width:auto" ><span style="">${(head.checkOperatorName)!' '}</span></p>
</td> </td>
</tr> </tr>
</table> </table>
<table > <table >
<tr> <tr style="height: 60pt;">
<td class="td1"> <td class="td1">
<p class="p1"><span style="font-weight:bolder ">处理结果</span></p> <p class="p1"><span style="font-weight:bolder ">处理结果</span></p>
</td> </td>
...@@ -266,25 +267,25 @@ ...@@ -266,25 +267,25 @@
<table> <table>
<tr> <tr>
<td class="td1"> <td class="td1">
<p class="p1"><span style="font-weight:bolder ">工号/客户编码</span></p> <p class="p1"><span style="font-weight:bolder;font-size:10pt">工号/客户编码</span></p>
</td> </td>
<td class="td1"> <td class="td1">
<p class="p1"><span style="font-weight:bolder ">姓名/客户</span></p> <p class="p1"><span style="font-weight:bolder;font-size:10pt ">姓名/客户</span></p>
</td> </td>
<td class="td1"> <td class="td1">
<p class="p1"><span style="font-weight:bolder">部门/客户名称</span></p> <p class="p1"><span style="font-weight:bolder;font-size:10pt">部门/客户名称</span></p>
</td> </td>
<td class="td1"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-weight:bolder">定责比例</span></p> <p style="margin:5pt; orphans:0; widows:0"><span style="font-weight:bolder;font-size:10pt">定责比例</span></p>
</td> </td>
<td class="td1"> <td class="td1">
<p class="p1"><span style="font-weight:bolder">个人责任比例</span></p> <p class="p1"><span style="font-weight:bolder;font-size:10pt">个人责任比例</span></p>
</td> </td>
<td class="td1"> <td class="td1">
<p class="p1"><span style="font-weight:bolder">责任金额</span></p> <p class="p1"><span style="font-weight:bolder;font-size:10pt">责任金额</span></p>
</td> </td>
<td class="td1" style="width:20%"> <td class="td1" style="width:20%">
<p class="p1"><span style="font-weight:bolder">备注</span></p> <p class="p1"><span style="font-weight:bolder;font-size:10pt">备注</span></p>
</td> </td>
</tr> </tr>
<#if (dutyList)?? && ((dutyList)?size > 0)> <#if (dutyList)?? && ((dutyList)?size > 0)>
...@@ -292,36 +293,35 @@ ...@@ -292,36 +293,35 @@
<tr> <tr>
<td class="td1"> <td class="td1">
<p class="p1"> <p class="p1">
<span>${(list.personNo)!''}</span> <span class="autoLine">${(list.personNo)!''}</span>
</p> </p>
</td> </td>
<td class="td1"> <td class="td1">
<p class="p1"> <p class="p1">
<span >${(list.personName)!''}</span> <span class="autoLine">${(list.personName)!''}</span>
</p> </p>
</td> </td>
<td class="td2"> <td class="td2">
<p class="p1"> <p class="p1">
<span style="">${(list.deptName)!''}</span> <span class="autoLine">${(list.deptName)!''}</span>
</p> </p>
</td> </td>
<td class="td2"> <td class="td2">
<p class="p1"> <p class="p1">
<span style="">${(list.dutyRate)!''}</span> <span class="autoLine">${(list.dutyRate)!''}</span>
</p> </p>
</td> </td>
<td class="td2"> <td class="td2">
<p class="p1"><span style=" ">${(list.personDutyRate)!''}</span> <p class="p1"><span class="autoLine">${(list.personDutyRate)!''}</span>
</p> </p>
</td> </td>
<td class="td2"> <td class="td2">
<p class="p1"> <p class="p1">
<span style=" ">${(list.dutyMoney)!''}</span> <span class="autoLine">${(list.dutyMoney)!''}</span>
</p> </p>
</td> </td>
<td class="td2"> <td class="td2">
<p class="p1"><span <p class="p1"><span class="autoLine">${(list.remark)!''}</span>
style=" ">${(list.remark)!''}</span>
</p> </p>
</td> </td>
</tr> </tr>
...@@ -350,7 +350,7 @@ ...@@ -350,7 +350,7 @@
</td> </td>
</tr> </tr>
</table> </table>
<p style="margin:0pt; orphans:0; text-align:left;margin-top: 1pt; widows:0"> <p style="margin:0pt; orphans:0; text-align:left;margin-top: 10pt; widows:0">
<span class="fs" style="font-weight:bolder ">注:内部、外部异常均须填写此表单。</span> <span class="fs" style="font-weight:bolder ">注:内部、外部异常均须填写此表单。</span>
<span class="fs" style="font-weight:bolder ">本人已清楚公司的异常责任处理规定。</span> <span class="fs" style="font-weight:bolder ">本人已清楚公司的异常责任处理规定。</span>
</p> </p>
......
...@@ -11,6 +11,11 @@ ...@@ -11,6 +11,11 @@
span{ span{
font-size: 12pt; font-size: 12pt;
} }
table {border-collapse:collapse; margin-left:0pt;text-align: center;font-size:12pt;line-height: 8pt;}
.td1{border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:40pt}
.td2{border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid;border-top-width:0.75pt;vertical-align:top;width:100pt}
.p1{margin:5pt; orphans:0; widows:0;width:60pt}
.autoLine{word-break:normal; width:auto; display:block; word-wrap: break-word ;overflow: hidden;line-height: 1}
</style></head> </style></head>
<body> <body>
<div> <div>
...@@ -18,333 +23,275 @@ ...@@ -18,333 +23,275 @@
<span style="font-family:SimSun;margin-left:0pt;vertical-align:top;position: absolute; top: 0;left:6pt"> <span style="font-family:SimSun;margin-left:0pt;vertical-align:top;position: absolute; top: 0;left:6pt">
<img style="width:50px; height:40px;display: inline-block" src="${baoshen}"></img> <img style="width:50px; height:40px;display: inline-block" src="${baoshen}"></img>
</span> </span>
<span style="font-family:SimSun; font-size:18pt; font-weight:bolder">异常报告(供应商)</span> <span style="font-family:SimSun; font-size:18pt; font-weight:bolder">异常报告(供应商)</span>
<p style="margin:0pt; orphans:0; text-align:right;margin-top: -3pt; widows:0"> <p style="margin:0pt; orphans:0; text-align:right;margin-top: -3pt; widows:0">
<span class="fs" style="font-family:SimSun;font-weight:bolder ">编号:${(head.billCode)}</span> <span class="fs" style="font-family:SimSun;font-weight:bolder ">编号:${(head.billCode)}</span>
</p> </p>
</p> </p>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size:12pt;line-height: 10pt;"> <table>
<tr style=""> <tr>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-weight:bolder ">异常类型</span></p> <p class="p1"><span style="font-weight:bolder ">异常类型</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:80pt"> <td class="td2">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun;">${(head.exceptionType)!' '}</span></p> <p class="p1" style="width:90pt"><span>${(head.exceptionType)!' '}</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-weight:bolder ">呈报日期</span></p> <p class="p1"><span style="font-weight:bolder">呈报日期</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:80%;"> <td class="td2" style="width:80%">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;width:300pt ">${(head.reportDate?substring(0,9))!' '}</span></p> <p class="p1"><span>${(head.reportDate?substring(0,9))!' '}</span></p>
</td> </td>
</tr> </tr>
</table> </table>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;"> <table>
<tr style=""> <tr>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-weight:bolder ">供应商</span></p> <p class="p1"><span style="font-weight:bolder ">供应商编号</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:100%"> <td class="td2" >
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun; width:70%">${(head.customerName)!' '}</span></p> <p class="p1" style="width:90pt"><span>${(head.customerNo)!' '}</span></p>
</td>
<td class="td1">
<p class="p1"><span style="font-weight:bolder ">供应商名称</span></p>
</td>
<td class="td2" style="width:80%">
<p class="p1" style="width: auto"><span class="autoLine">${(head.customerName)!' '}</span></p>
</td> </td>
</tr> </tr>
</table> </table>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;"> <table>
<tr style=""> <tr>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-weight:bolder ">异常标题</span></p> <p class="p1"><span style="font-weight:bolder ">异常标题</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:90%"> <td class="td2" style="width:90%">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;">${(head.exceptionTitle)!' '}</span></p> <p class="p1" style="width: auto"><span class="autoLine">${(head.exceptionTitle)!' '}</span></p>
</td> </td>
</tr> </tr>
</table> </table>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;"> <table>
<tr style=""> <tr style="height: 35pt">
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-weight:bolder ">采购单号</span></p> <p class="p1"><span style="font-weight:bolder ">材料编码</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:81%"> <td class="td2">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;">${(head.customerOrderNo)!' '}</span></p> <p class="p1" style="width:90pt"><span class="autoLine">${(head.matnr)!' '}</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-weight:bolder ">损失金额</span></p> <p class="p1"><span style="font-weight:bolder ">材料名称</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:80%;"> <td class="td2" style="width:80%">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;width:300pt ">${(head.loseMoney)!' '}</span></p> <p class="p1" style="width:auto"><span class="autoLine" >${(head.maktx)!' '}</span></p>
</td> </td>
</tr> </tr>
</table> </table>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size:12pt;line-height: 10pt;">
<tr style=""> <table>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <tr>
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-weight:bolder ">材料编码</span></p> <td class="td1">
<p class="p1"><span style="font-weight:bolder ">影响数量</span></p>
</td>
<td class="td2" style="width:90pt">
<#if (itemList)?? && ((itemList)?size > 0)>
<#list itemList as list>
<p class="p1" style="width:90pt" ><span>${(list.number)!' '}</span></p>
</#list>
</#if>
</td>
<td class="td1">
<p class="p1"><span style="font-weight:bolder">单位</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:80pt"> <td class="td2" style="width:100pt" >
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun;">${(head.matnr)!' '}</span></p> <#if (itemList)?? && ((itemList)?size > 0)>
<#list itemList as list>
<p class="p1" style="width:100pt" ><span>${(list.unitName)!' '}</span></p>
</#list>
</#if>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0;width:99pt"><span style="font-family:SimSun; font-weight:bolder ">材料名称</span></p> <p class="p1"><span style="font-weight:bolder ">币别</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:180pt"> <td class="td2" style="width:100pt">
<p style="margin:5pt; orphans:0; widows:0;width:160pt"><span style="font-family:SimSun;">${(head.maktx)!' '}</span></p> <#if (itemList)?? && ((itemList)?size > 0)>
<#list itemList as list>
<p class="p1" style="width:auto" ><span>${(list.currencyName)!' '}</span></p>
</#list>
</#if>
</td> </td>
</tr> </tr>
</table> </table>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;"> <table>
<tr style="text-align: center;font-size:6.5pt;line-height: 10pt;"> <tr>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-weight:bolder ">处理方式</span></p> <p class="p1"><span style="font-weight:bolder ">损失金额</span></p>
</td>
<td class="td2" style="width:90pt">
<#if (itemList)?? && ((itemList)?size > 0)>
<#list itemList as list>
<p class="p1" style="width:90pt" ><span>${(list.money)!' '}</span></p>
</#list>
</#if>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt;font-size: 10pt; vertical-align:top; width:90%"> <td class="td1">
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;"> <p class="p1"><span style=" font-weight:bolder ">罚款金额</span></p>
<#if (paylist)?? && ((paylist)?size > 0)>
<tr style="">
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0pt; border-left-color:#000000; border-left-style:solid; border-left-width:0pt; border-right-color:#000000; border-right-style:solid; border-right-width:0pt; border-top-color:#000000; border-top-style:solid; border-top-width:0pt; vertical-align:top; width:100%">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;font-size: 10pt; font-weight:bolder ">货币结算(扣除应付款)</span></p>
</td> </td>
</tr> <td class="td2" style="width:100pt ">
<#if (itemList)?? && ((itemList)?size > 0)>
<#list itemList as list>
<p class="p1" style="width:100pt" ><span>${(list.rmbMoney)!' '}</span></p>
</#list>
</#if> </#if>
</table>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;">
<#if (paylist)?? && ((paylist)?size > 0)>
<tr style="">
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun;font-size: 10pt; font-weight:bolder ">采购订单</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:110pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;font-size: 10pt; font-weight:bolder ">金额</span></p> <p class="p1"><span style="font-weight:bolder ">采购单号</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:180pt"> <td class="td2" style="width:100pt" >
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;font-size: 10pt; font-weight:bolder ">日期</span></p> <p class="p1" ><span class="autoLine">${(head.customerOrderNo)!' '}</span></p>
</td> </td>
</tr> </tr>
</#if> </table>
<table>
<tr>
<td class="td1">
<p class="p1"><span style="font-weight:bolder ">处理方式</span></p>
</td>
<td class="td2" style="width: 90%">
<#if (paylist)?? && ((paylist)?size > 0)>
<p class="p1" style="width: 90%"><span class="autoLine" style="font-size: 10pt; font-weight:bolder ">货币结算(扣除应付款):
<#if (paylist)?? && ((paylist)?size > 0)> <#if (paylist)?? && ((paylist)?size > 0)>
<#list paylist as list> <#list paylist as list>
<tr style="text-align: center;font-size:6.5pt;line-height: 10pt;"> ${(list.purchaseNo)!''} ${(list.money)!''} ${(list.sendDate?substring(0,9))!''};
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt">
<p style="margin:5pt; orphans:0; widows:0;width: 100pt">
<span style="font-family:SimSun;">${(list.purchaseNo)!''}</span>
</p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:110pt">
<p style="margin:5pt; orphans:0; widows:0"><span
style="font-family:SimSun; ">${(list.money)!''}</span>
</p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:180pt">
<p style="margin:5pt; orphans:0; widows:0"><span
style="font-family:SimSun; ">${(list.sendDate?substring(0,9))!''}</span>
</p>
</td>
</tr>
</#list> </#list>
</#if> </#if>
</table> </span></p>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;">
<#if (cashlist)?? && ((cashlist)?size > 0)>
<tr style="">
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0pt; border-left-color:#000000; border-left-style:solid; border-left-width:0pt; border-right-color:#000000; border-right-style:solid; border-right-width:0pt; border-top-color:#000000; border-top-style:solid; border-top-width:0pt; vertical-align:top; width:100%">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun; font-size: 10pt;font-weight:bolder ">货币结算(现金/转账)</span></p>
</td>
</tr>
</#if> </#if>
</table>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;">
<#if (cashlist)?? && ((cashlist)?size > 0)> <#if (cashlist)?? && ((cashlist)?size > 0)>
<tr style=""> <p class="p1" style="width: 90%"><span class="autoLine" style="font-size: 10pt; font-weight:bolder ">货币结算(现金/转账):
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-size: 10pt;font-weight:bolder ">付款方式</span></p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:110pt">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;font-size: 10pt; font-weight:bolder ">金额</span></p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:180pt">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun; font-size: 10pt;font-weight:bolder ">币种</span></p>
</td>
</tr>
</#if>
<#if (cashlist)?? && ((cashlist)?size > 0)> <#if (cashlist)?? && ((cashlist)?size > 0)>
<#list cashlist as list> <#list cashlist as list>
<tr style="text-align: center;font-size:6.5pt;line-height: 10pt;"> ${(list.payment)!''} ${(list.money)!''} ${(list.currencyName)!''};
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt">
<p style="margin:5pt; orphans:0; widows:0;width: 100pt">
<span style="font-family:SimSun;">${(list.payment)!''}</span>
</p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:110pt">
<p style="margin:5pt; orphans:0; widows:0"><span
style="font-family:SimSun; ">${(list.money)!''}</span>
</p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:180pt">
<p style="margin:5pt; orphans:0; widows:0"><span
style="font-family:SimSun; ">${(list.currencyName)!''}</span>
</p>
</td>
</tr>
</#list> </#list>
</#if> </#if>
</table> </span></p>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;">
<#if (goodslist)?? && ((goodslist)?size > 0)>
<tr style="">
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0pt; border-left-color:#000000; border-left-style:solid; border-left-width:0pt; border-right-color:#000000; border-right-style:solid; border-right-width:0pt; border-top-color:#000000; border-top-style:solid; border-top-width:0pt; vertical-align:top; width:100%">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun; font-weight:bolder;font-size: 10pt; ">商品赔付</span></p>
</td>
</tr>
</#if> </#if>
</table>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;">
<#if (goodslist)?? && ((goodslist)?size > 0)> <#if (goodslist)?? && ((goodslist)?size > 0)>
<tr style=""> <p class="p1" style="width: 90%"><span class="autoLine" style="font-size: 10pt; font-weight:bolder ">商品赔付:
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-size: 10pt;font-weight:bolder ">公司</span></p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:100pt">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;font-size: 10pt; font-weight:bolder ">采购组织</span></p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:100pt">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun; font-size: 10pt;font-weight:bolder ">物料名称</span></p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:100pt">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;font-size: 10pt; font-weight:bolder ">数量</span></p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:100pt">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;font-size: 10pt; font-weight:bolder ">单位</span></p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:100pt">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;font-size: 10pt; font-weight:bolder ">需求日期</span></p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:100pt">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;font-size: 10pt; font-weight:bolder ">收货工厂</span></p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:100pt">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;font-size: 10pt; font-weight:bolder ">收货地点</span></p>
</td>
</tr>
</#if>
<#if (goodslist)?? && ((goodslist)?size > 0)> <#if (goodslist)?? && ((goodslist)?size > 0)>
<#list goodslist as list> <#list goodslist as list>
<tr style="text-align: center;font-size:6.5pt;line-height: 10pt;"> ${(list.companyName)!''} ${(list.purchaseTeamName)!''} ${(list.productName)!''} ${(list.number)!''} ${(list.unitName)!''} ${(list.needDate?substring(0,9))!''} ${(list.werksName)!''} ${(list.locationName)!''};
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> </#list>
<p style="margin:5pt; orphans:0; widows:0;width: 100pt"> </#if>
<span style="font-family:SimSun;">${(list.companyName)!''}</span> </span></p>
</p> </#if>
</td> </td>
</tr>
</table>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <table>
<p style="margin:5pt; orphans:0; widows:0"><span <tr style="height: 90pt;">
style="font-family:SimSun; ">${(list.purchaseTeamName)!''}</span> <td class="td1">
</p> <p class="p1"><span style=" font-weight:bolder ">异常描述</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td2" style="width: 90%">
<p style="margin:5pt; orphans:0; widows:0"><span <p class="p1" style="width: auto"><span>${(head.exceptionState)!' '}</span></p>
style="font-family:SimSun; ">${(list.productName)!''}</span>
</p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt">
<p style="margin:5pt; orphans:0; widows:0"><span
style="font-family:SimSun; ">${(list.number)!''}</span>
</p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt">
<p style="margin:5pt; orphans:0; widows:0"><span
style="font-family:SimSun; ">${(list.unitName)!''}</span>
</p>
</td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt">
<p style="margin:5pt; orphans:0; widows:0"><span
style="font-family:SimSun; ">${(list.needDate?substring(0,9))!''}</span>
</p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> </tr>
<p style="margin:5pt; orphans:0; widows:0"><span </table>
style="font-family:SimSun; ">${(list.werksName)!''}</span> <table>
</p> <tr style="height: 80pt;">
<td class="td1">
<p class="p1"><span style="font-weight:bolder ">发生原因</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td2" style="width:90%">
<p style="margin:5pt; orphans:0; widows:0"><span <p class="p1" style="width:auto"><span>${(head.exceptionReason)!' '}</span></p>
style="font-family:SimSun; ">${(list.locationName)!''}</span>
</p>
</td> </td>
</tr> </tr>
</#list>
</#if>
</table> </table>
<table>
<tr style="height: 80pt;">
<td class="td1">
<p class="p1"><span style="font-weight:bolder ">改善措施</span></p>
</td>
<td class="td2" style="width:90%">
<p class="p1" style="width:auto"><span>${(head.dealMethod)!' '}</span></p>
</td> </td>
</tr> </tr>
</table> </table>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;"> <table>
<tr style="text-align: center;font-size:6.5pt;line-height: 10pt;height: 200pt;"> <tr >
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-weight:bolder ">异常描述</span></p> <p class="p1"><span style="font-weight:bolder">单位主管</span></p>
</td>
<td class="td2">
<p class="p1" style="width:90pt"><span>${(head.manager)!' '}</span></p>
</td>
<td class="td1">
<p class="p1"><span style="font-weight:bolder ">副理</span></p>
</td>
<td class="td2">
<p class="p1"><span>${(head.deputyManager)!' '}</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:90%"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;">${(head.exceptionState)!' '}</span></p> <p class="p1"><span style="font-weight:bolder ">经理</span></p>
</td>
<td class="td2">
<p class="p1"><span >${(head.generalManager)!' '}</span></p>
</td> </td>
</tr> </tr>
</table> </table>
<table>
<tr style="height: 70pt;">
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;"> <td class="td1">
<p class="p1"><span style="font-family:SimSun; font-weight:bolder ">处理结果</span></p>
<tr style="text-align: center;font-size:6.5pt;line-height: 10pt;">
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-weight:bolder ">处理结果</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:90%"> <td class="td2" style="width: 90%">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;">${(head.dealResult)!' '}</span></p> <p class="p1" style="width: auto"><span style="">${(head.dealResult)!' '}</span></p>
</td> </td>
</tr> </tr>
</table> </table>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;"> <table>
<tr style="height: 30pt;">
<tr style="text-align: center;font-size:6.5pt;line-height: 10pt;"> <td class="td1">
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <p class="p1"><span style="font-weight:bolder ">备注</span></p>
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-weight:bolder ">备注</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:90%"> <td class="td2" style="width: 90%">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;">${(head.remark)!' '}</span></p> <p class="p1" style="width: auto"><span style="">${(head.remark)!' '}</span></p>
</td> </td>
</tr> </tr>
</table> </table>
<table cellspacing="0" cellpadding="0" style="border-collapse:collapse; margin-left:0pt;text-align: center;font-size: 9.5pt;line-height: 10pt;"> <table>
<tr style="text-align: center;font-size:6.5pt;line-height: 10pt;"> <tr>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0;width:100pt"><span style="font-family:SimSun; font-weight:bolder ">核准</span></p> <p class="p1"><span style="font-weight:bolder ">核准</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:80pt"> <td class="td2">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;">${(lastAuditPerson)!' '}</span></p> <p class="p1"><span style="">${(lastAuditPerson)!' '}</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0;width:80pt"><span style="font-family:SimSun; font-weight:bolder ">审核</span></p> <p class="p1"><span style="font-weight:bolder ">审核</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:85pt"> <td class="td2">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;">${(preAuditPerson)!' '}</span></p> <p class="p1"><span style="">${(preAuditPerson)!' '}</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-left-color:#000000; border-left-style:solid; border-left-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:50pt"> <td class="td1">
<p style="margin:5pt; orphans:0; widows:0;width:80pt"><span style="font-family:SimSun; font-weight:bolder ">制表</span></p> <p class="p1"><span style="font-weight:bolder ">制表</span></p>
</td> </td>
<td style="border-bottom-color:#000000; border-bottom-style:solid; border-bottom-width:0.75pt; border-right-color:#000000; border-right-style:solid; border-right-width:0.75pt; border-top-color:#000000; border-top-style:solid; border-top-width:0.75pt; vertical-align:top; width:85pt"> <td class="td2">
<p style="margin:5pt; orphans:0; widows:0"><span style="font-family:SimSun;">${(head.personMemberName)!' '}</span></p> <p class="p1"><span style="">${(head.personMemberName)!' '}</span></p>
</td> </td>
</tr> </tr>
</table> </table>
<p style="margin:0pt; orphans:0; text-align:left;margin-top: 1pt; widows:0"> <p style="margin:0pt; orphans:0; text-align:left;margin-top: 10pt; widows:0">
<span class="fs" style="font-family:SimSun;font-weight:bolder ">注:内部、外部异常均须填写此表单。</span> <span class="fs" style="font-weight:bolder ">注:内部、外部异常均须填写此表单。</span>
<span class="fs" style="font-family:SimSun;font-weight:bolder ">本人已清楚公司的异常责任处理规定。</span> <span class="fs" style="font-weight:bolder ">本人已清楚公司的异常责任处理规定。</span>
</p> </p>
</div> </div>
......
...@@ -5,6 +5,7 @@ import cn.hutool.core.collection.CollectionUtil; ...@@ -5,6 +5,7 @@ import cn.hutool.core.collection.CollectionUtil;
import cn.hutool.core.util.ObjectUtil; import cn.hutool.core.util.ObjectUtil;
import com.alibaba.fastjson.JSON; import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.google.gson.JsonObject;
import com.huigou.cache.DictUtil; import com.huigou.cache.DictUtil;
import com.huigou.cache.SystemCache; import com.huigou.cache.SystemCache;
import com.huigou.context.Operator; import com.huigou.context.Operator;
...@@ -165,12 +166,11 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -165,12 +166,11 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
if (StringUtils.isBlank(exceptionReport.getDutyDept())){ if (StringUtils.isBlank(exceptionReport.getDutyDept())){
exceptionReport.setDutyDept("0"); exceptionReport.setDutyDept("0");
} }
//异常原因分类是供应商原材料问题
if (!"supplier".equals(exceptionReport.getBillType())&&"3".equals(exceptionReport.getExceptionReasonType())){ //客户异常 if (!"supplier".equals(exceptionReport.getBillType())&&"1".equals(exceptionReport.getExceptionReasonType())){
exceptionReport.setCustomerNo(exceptionReport.getCustomerNoPur()); exceptionReport.setCustomerNo(exceptionReport.getCustomerNoPur());
exceptionReport.setCustomerName(exceptionReport.getCustomerNamePur()); exceptionReport.setCustomerName(exceptionReport.getCustomerNamePur());
exceptionReport.setCustomerOrderNo(exceptionReport.getCustomerOrderNoPur()); exceptionReport.setCustomerOrderNo(exceptionReport.getCustomerOrderNoPur());
exceptionReport.setBillType("purchase");
} }
/* 采购的单据 根据加减签 去更改为责任人 /* 采购的单据 根据加减签 去更改为责任人
if (exceptionReport.getStatusId()==1&&("purchase".equals(exceptionReport.getBillType())||"outgoing".equals(exceptionReport.getBillType())) if (exceptionReport.getStatusId()==1&&("purchase".equals(exceptionReport.getBillType())||"outgoing".equals(exceptionReport.getBillType()))
...@@ -193,21 +193,19 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -193,21 +193,19 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
exceptionReport.setDutyDept(org.getDeptId()); exceptionReport.setDutyDept(org.getDeptId());
} }
} */ } */
//
SDO params = this.getBizAndApprovalData(); SDO params = this.getBizAndApprovalData();
if ("produce".equals(exceptionReport.getBillType()) if ("produce".equals(exceptionReport.getBillType())
&&"advance".equals(params.getProperty("processAction")) &&"advance".equals(params.getProperty("processAction")) // 提交
) { ) {
// Operator operator = ThreadLocalUtil.getOperator(); Operator operator = ThreadLocalUtil.getOperator();
List <ExceptionReportResponsible>rslist=exceptionReportResponsibleRepository.findByExceptionReportId(exceptionReport.getId()); //当前操作人 不是责任人
if (!ObjectUtils.isEmpty(rslist)){ if (!exceptionReport.getCheckOperator().equals(operator.getPersonMemberId())) {
ExceptionReportResponsible lastResponsible=rslist.get(rslist.size()-1); saveResponsibleToApprover(params, exceptionReport);
if (!lastResponsible.getCheckOperator().equals(exceptionReport.getCheckOperator())){
saveResponsibles(params,exceptionReport);
}
} else {
saveResponsibles(params,exceptionReport);
} }
} }
exceptionReport = this.saveExceptionReport(exceptionReport); exceptionReport = this.saveExceptionReport(exceptionReport);
if (CollectionUtil.isNotEmpty(exceptionReportItems)){ if (CollectionUtil.isNotEmpty(exceptionReportItems)){
...@@ -222,7 +220,7 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -222,7 +220,7 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
List<ExceptionReportGoods> exceptionReportGoodsList = this.getBizEntities(ExceptionReportGoods.class, "handleGoods"); List<ExceptionReportGoods> exceptionReportGoodsList = this.getBizEntities(ExceptionReportGoods.class, "handleGoods");
if ("supplier".equals(exceptionReport.getBillType())){ //供应商 默认类型 if ("supplier".equals(exceptionReport.getBillType())){ //供应商 默认类型
exceptionReport.setExceptionType("out"); exceptionReport.setExceptionType("out");
exceptionReport.setExceptionReasonType("3"); // exceptionReport.setExceptionReasonType("3");
} }
if (("supplier".equals(exceptionReport.getBillType()))&&"pay".equals(exceptionReport.getDealWay()) if (("supplier".equals(exceptionReport.getBillType()))&&"pay".equals(exceptionReport.getDealWay())
...@@ -252,10 +250,29 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -252,10 +250,29 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
return exceptionReport.getId(); return exceptionReport.getId();
} }
private void saveResponsibleToApprover(SDO params,ExceptionReport exceptionReport){
List <ExceptionReportResponsible>rslist=exceptionReportResponsibleRepository.findByExceptionReportId(exceptionReport.getId());
if (!ObjectUtils.isEmpty(rslist)){
ExceptionReportResponsible lastResponsible=rslist.get(rslist.size()-1);
if (!lastResponsible.getCheckOperator().equals(exceptionReport.getCheckOperator())){
saveResponsibles(params,exceptionReport);
}
} else {
saveResponsibles(params,exceptionReport);
}
}
private void saveResponsibles(SDO params,ExceptionReport exceptionReport){ private void saveResponsibles(SDO params,ExceptionReport exceptionReport){
Operator operator = ThreadLocalUtil.getOperator();
if (StringUtils.isNotBlank(exceptionReport.getDutyDept())){ //责任部门不为空 if (StringUtils.isNotBlank(exceptionReport.getDutyDept())){ //责任部门不为空
//增加责任人的审批 params.getProperty("processAction") advance
saveHistoryCheckOperator(exceptionReport);
this.saveResponsibleApprover(params,exceptionReport);
}
}
private void saveHistoryCheckOperator(ExceptionReport exceptionReport){
Operator operator = ThreadLocalUtil.getOperator();
ExceptionReportResponsible exceptionReportResponsible = new ExceptionReportResponsible(); ExceptionReportResponsible exceptionReportResponsible = new ExceptionReportResponsible();
exceptionReportResponsible.setExceptionReportId(exceptionReport.getId()); exceptionReportResponsible.setExceptionReportId(exceptionReport.getId());
exceptionReportResponsible.setBillCode(exceptionReport.getBillCode()); exceptionReportResponsible.setBillCode(exceptionReport.getBillCode());
...@@ -268,11 +285,7 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -268,11 +285,7 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
exceptionReportResponsible.setCreatedName(operator.getPersonMemberName()); exceptionReportResponsible.setCreatedName(operator.getPersonMemberName());
exceptionReportResponsibleRepository.save(exceptionReportResponsible); exceptionReportResponsibleRepository.save(exceptionReportResponsible);
//增加责任人的审批 params.getProperty("processAction") advance
this.saveResponsibleApprover(params,exceptionReport);
}
} }
//责任人审批 //责任人审批
private void saveResponsibleApprover( SDO params,ExceptionReport exceptionReport){ private void saveResponsibleApprover( SDO params,ExceptionReport exceptionReport){
String bizId = params.getString("bizId"); String bizId = params.getString("bizId");
...@@ -303,8 +316,9 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -303,8 +316,9 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
procUnitHandler.setStatus(0); procUnitHandler.setStatus(0);
procUnitHandler.setSequence(1); procUnitHandler.setSequence(1);
procUnitHandler.setBizCode(exceptionReport.getBillCode()); procUnitHandler.setBizCode(exceptionReport.getBillCode());
procUnitHandler.setCooperationModelId(params.getProperty("currentHandleCooperationModelId").toString()); procUnitHandler.setCooperationModelId(params.getProperty("currentHandleCooperationModelId")!=null?params.getProperty("currentHandleCooperationModelId").toString():"chief");
procUnitHandler.setGroupId(Integer.parseInt(params.getProperty("currentHandleGroupId").toString()) + 10);
procUnitHandler.setGroupId(Integer.parseInt(params.getProperty("currentHandleGroupId").toString())+1);
//System.out.print("isNew=========" + procUnitHandler.isNew()); //System.out.print("isNew=========" + procUnitHandler.isNew());
...@@ -433,21 +447,22 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -433,21 +447,22 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
} }
} }
this.saveExceptionReport(exceptionReport); this.saveExceptionReport(exceptionReport);
//采购异常单根据责任部门是采购部门则生成供应商异常单 //根据责任部门是采购部门 则生成供应商异常单
if ("purchase".equals(exceptionReport.getBillType()) if ("produce".equals(exceptionReport.getBillType())
//&&StringUtil.isNotBlank(exceptionReport.getDutyDept()) //&&StringUtil.isNotBlank(exceptionReport.getDutyDept())
&&!"0".equals(exceptionReport.getDutyDept())) { &&!"0".equals(exceptionReport.getDutyDept())) {
Org org = orgApplication.loadOrg(exceptionReport.getDutyDept()); Org org = orgApplication.loadOrg(exceptionReport.getDutyDept());
if (org.getCode().startsWith("CGB")){ //是采购部 if (org.getCode().startsWith("CGB")){ //是采购部
ExceptionReport suppExceptionReport = new ExceptionReport(); ExceptionReport suppExceptionReport = new ExceptionReport();
suppExceptionReport.setBillType("supplier"); suppExceptionReport.setBillType("supplier");
suppExceptionReport.setSourceBillCode(exceptionReport.getBillCode());
suppExceptionReport.setReportDate(exceptionReport.getReportDate()); suppExceptionReport.setReportDate(exceptionReport.getReportDate());
suppExceptionReport.setExceptionReasonType(exceptionReport.getExceptionReasonType()); suppExceptionReport.setExceptionReasonType(exceptionReport.getExceptionReasonType());
suppExceptionReport.setExceptionType(exceptionReport.getExceptionType()); suppExceptionReport.setExceptionType(exceptionReport.getExceptionType());
suppExceptionReport.setExceptionTitle(exceptionReport.getExceptionTitle()); suppExceptionReport.setExceptionTitle(exceptionReport.getExceptionTitle());
suppExceptionReport.setExceptionDate(exceptionReport.getExceptionDate()); suppExceptionReport.setExceptionDate(exceptionReport.getExceptionDate());
suppExceptionReport.setCustomerOrderNo(exceptionReport.getCustomerOrderNo()); // suppExceptionReport.setCustomerOrderNo(exceptionReport.getCustomerOrderNo());
suppExceptionReport.setCustomerName(exceptionReport.getCustomerName()); // suppExceptionReport.setCustomerName(exceptionReport.getCustomerName());
suppExceptionReport.setUrgency(exceptionReport.getUrgency()); suppExceptionReport.setUrgency(exceptionReport.getUrgency());
suppExceptionReport.setExceptionState(exceptionReport.getExceptionState()); suppExceptionReport.setExceptionState(exceptionReport.getExceptionState());
suppExceptionReport.setExceptionReason(exceptionReport.getExceptionReason()); suppExceptionReport.setExceptionReason(exceptionReport.getExceptionReason());
...@@ -457,6 +472,11 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -457,6 +472,11 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
suppExceptionReport.setWerks(exceptionReport.getWerks()); suppExceptionReport.setWerks(exceptionReport.getWerks());
suppExceptionReport.setWerksName(exceptionReport.getWerksName()); suppExceptionReport.setWerksName(exceptionReport.getWerksName());
suppExceptionReport.setBrandName(exceptionReport.getBrandName()); suppExceptionReport.setBrandName(exceptionReport.getBrandName());
suppExceptionReport.setManager(exceptionReport.getManager());
suppExceptionReport.setDeputyManager(exceptionReport.getDeputyManager());
suppExceptionReport.setGeneralManager(exceptionReport.getGeneralManager());
suppExceptionReport.setLoseMoney(exceptionReport.getLoseMoney()); suppExceptionReport.setLoseMoney(exceptionReport.getLoseMoney());
suppExceptionReport.setAttbizId(exceptionReport.getAttbizId()); suppExceptionReport.setAttbizId(exceptionReport.getAttbizId());
suppExceptionReport.setDealWay("special"); suppExceptionReport.setDealWay("special");
...@@ -465,7 +485,8 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -465,7 +485,8 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
suppExceptionReport.setPersonMemberId(operator.getPersonMemberId()); suppExceptionReport.setPersonMemberId(operator.getPersonMemberId());
suppExceptionReport.setPersonMemberName(operator.getPersonMemberName()); suppExceptionReport.setPersonMemberName(operator.getPersonMemberName());
/* ExceptionReportQueryRequest queryRequest = new ExceptionReportQueryRequest();
ExceptionReportQueryRequest queryRequest = new ExceptionReportQueryRequest();
queryRequest.setExceptionReportId(bizId); queryRequest.setExceptionReportId(bizId);
QueryDescriptor queryDescriptor = this.sqlExecutorDao.getQuery(QUERY_XML_FILE_PATH, "exceptionReportItems"); QueryDescriptor queryDescriptor = this.sqlExecutorDao.getQuery(QUERY_XML_FILE_PATH, "exceptionReportItems");
...@@ -473,8 +494,29 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -473,8 +494,29 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
queryModel.setPageIndex(1); queryModel.setPageIndex(1);
queryModel.setPageSize(200); queryModel.setPageSize(200);
Map<String,Object> mapItems= this.sqlExecutorDao.executeSlicedQuery(queryModel); Map<String,Object> mapItems= this.sqlExecutorDao.executeSlicedQuery(queryModel);
List<ExceptionReportItem> exceptionReportItems=(List<ExceptionReportItem>)mapItems.get("Rows"); List<Map<String,Object>> itemList=(List)mapItems.get("Rows");
StringBuffer orderNos=new StringBuffer("");
StringBuffer matnrs=new StringBuffer("");
StringBuffer maktxs=new StringBuffer("");
List<Map<String,Object>> newItemList=new ArrayList<Map<String,Object>>();
for (int u=0;u<itemList.size();u++){
Map map=(Map)itemList.get(u);
orderNos.append(map.get("produceNo"));
matnrs.append(map.get("productCode"));
maktxs.append(map.get("productName"));
if (u<itemList.size()-1){
orderNos.append("/");
matnrs.append("/");
maktxs.append("/");
}
map.put("id","");
newItemList.add(u,map);
}
suppExceptionReport.setCustomerOrderNo(orderNos.toString());
suppExceptionReport.setMaktx(maktxs.toString());
suppExceptionReport.setMatnr(matnrs.toString());
/*
queryDescriptor = this.sqlExecutorDao.getQuery(QUERY_XML_FILE_PATH, "exceptionReportDutyPersons"); queryDescriptor = this.sqlExecutorDao.getQuery(QUERY_XML_FILE_PATH, "exceptionReportDutyPersons");
queryModel = this.sqlExecutorDao.getQueryModel(queryDescriptor, queryRequest); queryModel = this.sqlExecutorDao.getQueryModel(queryDescriptor, queryRequest);
queryModel.setPageIndex(1); queryModel.setPageIndex(1);
...@@ -487,14 +529,14 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -487,14 +529,14 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
//创建供应商异常 //创建供应商异常
asyncWriteExecutor.execute(()-> asyncWriteExecutor.execute(()->
// mannualStartWorkApplication.startWorkflow(suppExceptionReport,PROCESS_DEFINITION_KEY,"exceptionReport") // mannualStartWorkApplication.startWorkflow(suppExceptionReport,PROCESS_DEFINITION_KEY,"exceptionReport")
saveSupplierExceptionReport(suppExceptionReport) saveSupplierExceptionReport(suppExceptionReport,newItemList)
); );
} }
} }
} }
public void saveSupplierExceptionReport(ExceptionReport exceptionReportVo){ public void saveSupplierExceptionReport(ExceptionReport exceptionReportVo, List<Map<String,Object>> exceptionItems){
ExceptionReport exceptionReport = new ExceptionReport(); ExceptionReport exceptionReport = new ExceptionReport();
BeanUtil.copyProperties(exceptionReportVo,exceptionReport); BeanUtil.copyProperties(exceptionReportVo,exceptionReport);
//初始化用户信息 //初始化用户信息
...@@ -502,7 +544,7 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -502,7 +544,7 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
exceptionReport.setDefaultValues(new OrgUnit(operator.getFullId(), operator.getFullName())); exceptionReport.setDefaultValues(new OrgUnit(operator.getFullId(), operator.getFullName()));
Map<String, Object> formData = BeanUtil.beanToMap(exceptionReport); Map<String, Object> formData = BeanUtil.beanToMap(exceptionReport);
// formData.put("exceptionReportItems",exceptionItems); formData.put("exceptionReportItems",exceptionItems);
// formData.put("personList",exceptionDutyItems); // formData.put("personList",exceptionDutyItems);
//启动流程实例 //启动流程实例
this.startProcessInstance(PROCESS_DEFINITION_KEY, formData); this.startProcessInstance(PROCESS_DEFINITION_KEY, formData);
...@@ -556,6 +598,28 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -556,6 +598,28 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
if (this.isApplyProcUnit(delegateTask) && this.getApprovalParameter().isAdvanceProcessAction()) { if (this.isApplyProcUnit(delegateTask) && this.getApprovalParameter().isAdvanceProcessAction()) {
updateStatus(bizId, BizBillStatus.APPROVING); updateStatus(bizId, BizBillStatus.APPROVING);
} }
/* if (this.isApplyProcUnit(delegateTask)) { //申请后的提交 去掉 改在流程中配置有责任部门来实现
System.out.println("===============提交======================= ");
SDO params = this.getBizAndApprovalData();
ExceptionReport exceptionReport=this.exceptionReportRepository.findOne(bizId);
params.putProperty("procUnitId","Approve");
saveResponsibleToApprover(params,exceptionReport);
} */
if (this.isApplyProcUnit(delegateTask)) { //申请后的提交
//首次 提交时 保存责任人历史记录
ExceptionReport exceptionReport=this.exceptionReportRepository.findOne(bizId);
if (StringUtils.isNotBlank(exceptionReport.getDutyDept())) { //责任部门不为空
List<ExceptionReportResponsible> rslist = exceptionReportResponsibleRepository.findByExceptionReportId(exceptionReport.getId());
if (!ObjectUtils.isEmpty(rslist)) {
ExceptionReportResponsible lastResponsible = rslist.get(rslist.size() - 1);
if (!lastResponsible.getCheckOperator().equals(exceptionReport.getCheckOperator())) {
saveHistoryCheckOperator(exceptionReport);
}
} else {
saveHistoryCheckOperator(exceptionReport);
}
}
}
} }
/** /**
...@@ -699,6 +763,7 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except ...@@ -699,6 +763,7 @@ public class ExceptionReportApplicationImpl extends FlowBroker implements Except
protected void setTaskDescription(DelegateTask delegateTask) { protected void setTaskDescription(DelegateTask delegateTask) {
String bizId = delegateTask.getExecution().getProcessBusinessKey(); String bizId = delegateTask.getExecution().getProcessBusinessKey();
delegateTask.setDescription(this.getApprovalSubjectName(bizId)); delegateTask.setDescription(this.getApprovalSubjectName(bizId));
} }
/** /**
......
...@@ -113,7 +113,7 @@ public class ExceptionReportController extends CommonController { ...@@ -113,7 +113,7 @@ public class ExceptionReportController extends CommonController {
String id = sdo.getBizId(); String id = sdo.getBizId();
ExceptionReport exceptionReport = exceptionReportApplication.findById(id); ExceptionReport exceptionReport = exceptionReportApplication.findById(id);
if ("purchase".equals(exceptionReport.getBillType())||"outgoing".equals(exceptionReport.getBillType())) { if ("produce".equals(exceptionReport.getBillType())||"outgoing".equals(exceptionReport.getBillType())) {
exceptionReport.setCustomerNoPur(exceptionReport.getCustomerOrderNo()); exceptionReport.setCustomerNoPur(exceptionReport.getCustomerOrderNo());
exceptionReport.setCustomerNamePur(exceptionReport.getCustomerName()); exceptionReport.setCustomerNamePur(exceptionReport.getCustomerName());
exceptionReport.setCustomerOrderNoPur(exceptionReport.getCustomerOrderNo()); exceptionReport.setCustomerOrderNoPur(exceptionReport.getCustomerOrderNo());
......
...@@ -205,6 +205,10 @@ public class ExceptionReport extends FlowBillAbstractEntity { ...@@ -205,6 +205,10 @@ public class ExceptionReport extends FlowBillAbstractEntity {
@Column(name = "product_type") @Column(name = "product_type")
private String productType; private String productType;
@Column(name = "source_bill_code")
private String sourceBillCode;
@Override @Override
protected String getCodeRuleId() { protected String getCodeRuleId() {
return "exceptionReport"; return "exceptionReport";
......
...@@ -127,8 +127,8 @@ public class SapMaterialApplicationImpl implements SapMaterialApplication { ...@@ -127,8 +127,8 @@ public class SapMaterialApplicationImpl implements SapMaterialApplication {
} else if (StringUtils.isNotBlank(queryRequest.getKunnr())) { //查询订单号 } else if (StringUtils.isNotBlank(queryRequest.getKunnr())) { //查询订单号
for (Map map : mapList) { for (Map map : mapList) {
Map newMap = new HashMap(); Map newMap = new HashMap();
//newMap.put("VBELN", map.get("VBELN")); BSTNK newMap.put("VBELN", map.get("VBELN"));
newMap.put("VBELN", map.get("BSTNK")); // newMap.put("VBELN", map.get("BSTNK")); 09.21冯要求改为BSTNK
newMap.put("KUNNR", map.get("KUNNR")); newMap.put("KUNNR", map.get("KUNNR"));
newMap.put("NAME1", map.get("NAME1")); newMap.put("NAME1", map.get("NAME1"));
sapOrderVoList.add(newMap); sapOrderVoList.add(newMap);
......
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