|
@@ -136,15 +136,25 @@
|
136
|
136
|
</el-table-column>
|
137
|
137
|
<el-table-column label="数量" align="center">
|
138
|
138
|
<template slot-scope="scope">
|
139
|
|
- {{scope.row.count}}
|
|
139
|
+ {{scope.row.count}}
|
140
|
140
|
</template>
|
141
|
141
|
</el-table-column>
|
142
|
142
|
<el-table-column label="总价" align="center">
|
143
|
143
|
<template slot-scope="scope">
|
144
|
144
|
<span v-if="org_id == 9919">{{(scope.row.last_price * scope.row.count).toFixed(2)}} </span>
|
145
|
145
|
<span v-else>
|
146
|
|
- <span v-if="scope.row.price >0">{{(scope.row.last_price * scope.row.count).toFixed(2)}}</span>
|
147
|
|
- <span v-if="scope.row.price == 0">{{(getPrice(scope.row.drug_id)* scope.row.count).toFixed(2)}}</span>
|
|
146
|
+ <span v-if="scope.row.price >0">
|
|
147
|
+ <span v-if="scope.row.count >= scope.row.min_number">
|
|
148
|
+ {{((scope.row.last_price * scope.row.count)/scope.row.min_number).toFixed(2)}}
|
|
149
|
+ </span>
|
|
150
|
+ <span v-else>{{(scope.row.last_price * scope.row.count).toFixed(2)}}</span>
|
|
151
|
+ </span>
|
|
152
|
+ <span v-if="scope.row.price == 0">
|
|
153
|
+ <span v-if="scope.row.count >=scope.row.min_number">
|
|
154
|
+ {{((getPrice(scope.row.drug_id)* scope.row.count)/scope.row.min_number).toFixed(2)}}
|
|
155
|
+ </span>
|
|
156
|
+ <span v-else>{{(getPrice(scope.row.drug_id)* scope.row.count).toFixed(2)}}</span>
|
|
157
|
+ </span>
|
148
|
158
|
</span>
|
149
|
159
|
<!-- {{scope.row.total_price}} -->
|
150
|
160
|
</template>
|
|
@@ -569,10 +579,20 @@ export default {
|
569
|
579
|
this.tableData[i].user_name = this.getAdminUser(this.tableData[i].creater)
|
570
|
580
|
if(this.org_id == 9671 || this.org_id == 9919){
|
571
|
581
|
this.tableData[i].total = (this.tableData[i].count * this.tableData[i].last_price)
|
572
|
|
- this.tableData[i].total_price = (this.tableData[i].count * this.tableData[i].last_price)
|
|
582
|
+ if(this.tableData[i].count >=this.tableData[i].min_number){
|
|
583
|
+ this.tableData[i].total_price = (this.tableData[i].count * this.tableData[i].last_price)/this.tableData[i].min_number
|
|
584
|
+ }else{
|
|
585
|
+ this.tableData[i].total_price = (this.tableData[i].count * this.tableData[i].last_price)
|
|
586
|
+ }
|
|
587
|
+
|
573
|
588
|
}else{
|
574
|
589
|
this.tableData[i].total = (this.tableData[i].count * this.tableData[i].price)
|
575
|
|
- this.tableData[i].total_price = (this.tableData[i].count * this.tableData[i].price)
|
|
590
|
+ if(this.tableData[i].count >=this.tableData[i].min_number){
|
|
591
|
+ this.tableData[i].total_price = (this.tableData[i].count * this.tableData[i].price)/this.tableData[i].min_number
|
|
592
|
+ }else{
|
|
593
|
+ this.tableData[i].total_price = (this.tableData[i].count * this.tableData[i].price)
|
|
594
|
+ }
|
|
595
|
+
|
576
|
596
|
}
|
577
|
597
|
}
|
578
|
598
|
}
|