|
@@ -268,7 +268,8 @@ export default {
|
268
|
268
|
stockTotal:[],
|
269
|
269
|
goodInfoData:[],
|
270
|
270
|
orgId:"",
|
271
|
|
- tableData:[]
|
|
271
|
+ tableData:[],
|
|
272
|
+ tableOut:[],
|
272
|
273
|
};
|
273
|
274
|
},
|
274
|
275
|
methods: {
|
|
@@ -755,19 +756,19 @@ export default {
|
755
|
756
|
},
|
756
|
757
|
|
757
|
758
|
exportList(){
|
758
|
|
- for(let i=0;i<this.tableData.length;i++){
|
759
|
|
- this.tableData[i].index = i+1
|
760
|
|
- this.tableData[i].good_name = this.tableData[i].good_name
|
761
|
|
- this.tableData[i].specification_name = this.tableData[i].specification_name
|
762
|
|
- this.tableData[i].packing_unit = this.tableData[i].packing_unit
|
763
|
|
- this.tableData[i].total_price = (this.tableData[i].count * this.tableData[i].packing_price).toFixed(2)
|
764
|
|
- this.tableData[i].out_count = this.getStockCount(this.tableData[i].good_id)
|
|
759
|
+ for(let i=0;i<this.tableOut.length;i++){
|
|
760
|
+ this.tableOut[i].index = i+1
|
|
761
|
+ this.tableOut[i].good_name = this.tableOut[i].good_name
|
|
762
|
+ this.tableOut[i].specification_name = this.tableOut[i].specification_name
|
|
763
|
+ this.tableOut[i].packing_unit = this.tableOut[i].packing_unit
|
|
764
|
+ this.tableOut[i].total_price = (this.tableOut[i].count * this.tableOut[i].packing_price).toFixed(2)
|
|
765
|
+ this.tableOut[i].out_count = this.getStockCount(this.tableOut[i].good_id)
|
765
|
766
|
}
|
766
|
767
|
import('@/vendor/Export2Excel').then(excel => {
|
767
|
768
|
const tHeader = ['序号','耗材名称', '规格型号', '单位','数量','出货价','总价','备注']
|
768
|
769
|
const filterVal = ['index','good_name', 'specification_name', 'packing_unit','out_count','packing_price','total_price','remark']
|
769
|
770
|
|
770
|
|
- const data = this.formatJson(filterVal, this.tableData)
|
|
771
|
+ const data = this.formatJson(filterVal, this.tableOut)
|
771
|
772
|
console.log("data",data)
|
772
|
773
|
|
773
|
774
|
excel.export_json_to_excel({
|
|
@@ -808,7 +809,7 @@ export default {
|
808
|
809
|
if(response.data.state == 1){
|
809
|
810
|
var list = response.data.data.list
|
810
|
811
|
console.log("出库单详单",list)
|
811
|
|
- this.tableData = list
|
|
812
|
+ this.tableOut = list
|
812
|
813
|
var stockTotal = response.data.data.stockTotal
|
813
|
814
|
this.stockTotal = stockTotal
|
814
|
815
|
}
|