Commit 72330993 by yyq1988

细节调整

parent 037e5c5e
...@@ -270,6 +270,9 @@ $(document).ready(function() { ...@@ -270,6 +270,9 @@ $(document).ready(function() {
for (var i=0; i<data1.length; i++){ for (var i=0; i<data1.length; i++){
data1[i].dict = {}; data1[i].dict = {};
data1[i].qrCodeStr = data1[i].qrCode && JSON.stringify(data1[i].qrCode); data1[i].qrCodeStr = data1[i].qrCode && JSON.stringify(data1[i].qrCode);
data1[i].status = data1[i].qrCode.state === '2';
data1[i].hasQr = data1[i].qrCode;
data1[i].mainRowIndex = index;
addRow('#profitWarehousingChild-'+row.id+'-1-List', profitWarehousingChild1RowIdx, profitWarehousingChild1Tpl, data1[i]); addRow('#profitWarehousingChild-'+row.id+'-1-List', profitWarehousingChild1RowIdx, profitWarehousingChild1Tpl, data1[i]);
profitWarehousingChild1RowIdx = profitWarehousingChild1RowIdx + 1; profitWarehousingChild1RowIdx = profitWarehousingChild1RowIdx + 1;
} }
...@@ -289,12 +292,12 @@ $(document).ready(function() { ...@@ -289,12 +292,12 @@ $(document).ready(function() {
} }
function printQr(id, qrCodeStr) { function printQr(id, qrCodeStr) {
jp.loading('loading...');
try{ try{
if(!LODOP){ if(!LODOP){
initLodop(); initLodop();
} }
if(LODOP){ if(LODOP){
jp.loading('loading...');
if(qrCodeStr){ if(qrCodeStr){
var qrCode = JSON.parse(qrCodeStr); var qrCode = JSON.parse(qrCodeStr);
preview_LODOP(qrCode); preview_LODOP(qrCode);
...@@ -336,6 +339,20 @@ $(document).ready(function() { ...@@ -336,6 +339,20 @@ $(document).ready(function() {
}) })
}) })
} }
function inLedgerInfo(id, rowIndex ){
jp.get("${ctx}/warehouse/profitwarehousing/profitWarehousing/inLedgerInfo?profitWarehousingInfoId="+ id, function (res){
if(res.success){
jp.success(res.msg);
$('#profitWarehousingTable').bootstrapTable('collapseRow', rowIndex);
setTimeout(function (){
$('#profitWarehousingTable').bootstrapTable('expandRow', rowIndex);
},0)
}else{
jp.error(res.msg);
}
})
}
</script> </script>
<script type="text/template" id="profitWarehousingChildrenTpl">//<!-- <script type="text/template" id="profitWarehousingChildrenTpl">//<!--
<div class="tabs-container"> <div class="tabs-container">
...@@ -393,6 +410,16 @@ $(document).ready(function() { ...@@ -393,6 +410,16 @@ $(document).ready(function() {
<button class="btn btn-danger btn-sm" onclick="cleanQr('{{row.id}}')"> <button class="btn btn-danger btn-sm" onclick="cleanQr('{{row.id}}')">
清除二维码 清除二维码
</button> </button>
{{#row.hasQr}}
{{#row.status}}
已入库
{{/row.status}}
{{^row.status}}
<button onclick="inLedgerInfo('{{row.id}}')" class="btn btn-primary btn-sm" onclick="cleanQr('{{row.id}}',{{row.mainRowIndex}})">
入库
</button>
{{/row.status}}
{{/row.hasQr}}
</td> </td>
</tr>//--> </tr>//-->
</script> </script>
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