Commit 698553d0 by yyq1988

调整入库功能

parent dd8f1ccf
...@@ -282,6 +282,8 @@ $(document).ready(function() { ...@@ -282,6 +282,8 @@ $(document).ready(function() {
data1[i].storageId = row.id; data1[i].storageId = row.id;
data1[i].batchNum = row.batchNum; data1[i].batchNum = row.batchNum;
data1[i].jsonStr = JSON.stringify(data1[i]); data1[i].jsonStr = JSON.stringify(data1[i]);
data1[i].isNotStorage = data1[i].state === '1';
data1[i].isStorage = data1[i].state === '2';
addRow('#storageChild-'+row.id+'-1-List', storageChild1RowIdx, storageChild1Tpl, data1[i]); addRow('#storageChild-'+row.id+'-1-List', storageChild1RowIdx, storageChild1Tpl, data1[i]);
storageChild1RowIdx = storageChild1RowIdx + 1; storageChild1RowIdx = storageChild1RowIdx + 1;
} }
...@@ -333,9 +335,9 @@ $(document).ready(function() { ...@@ -333,9 +335,9 @@ $(document).ready(function() {
jp.loading('入库中...'); jp.loading('入库中...');
jp.post("${ctx}/warehouse/ledger/ledger/save", $("#ledgerForm").serialize(), function (res){ jp.post("${ctx}/warehouse/ledger/ledger/save", $("#ledgerForm").serialize(), function (res){
if(res.success){ if(res.success){
jp.success(res.msg); jp.success('入库成功!');
}else { }else {
jp.error(res.msg); jp.error('入库失败!');
} }
}) })
} }
...@@ -392,8 +394,15 @@ $(document).ready(function() { ...@@ -392,8 +394,15 @@ $(document).ready(function() {
<td> <td>
{{row.num}} {{row.num}}
</td> </td>
{{#row.isNotStorage}}
<td> <td>
<a href="javascript:void(0);" onclick="onStorage('{{row.jsonStr}}','{{row.goodsInfo.id}}')">入库</a> <a href="javascript:void(0);" onclick="onStorage('{{row.jsonStr}}','{{row.goodsInfo.id}}')">入库</a>
</td> </td>
{{/row.isNotStorage}}
{{#row.isStorage}}
<td>
<a href="javascript:void(0);" onclick="onStorage('{{row.jsonStr}}','{{row.goodsInfo.id}}')">入库</a>
</td>
{{/row.isStorage}}
</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