|
@@ -40,9 +40,7 @@
|
|
|
{{ boxItem.rubbishTypeDictValue }}
|
|
|
</view>
|
|
|
<view class="rule-con">
|
|
|
- {{ getRule(boxItem.rubbishType).rubbishWeight }}g/
|
|
|
- <text class="goleNum">{{ getRule(boxItem.rubbishType).goleNum }}</text>
|
|
|
- <image src="/static/ledou.png" class="ld-pic"></image>
|
|
|
+ {{ boxItem.boxCode | stockVal(item) }}
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
@@ -68,6 +66,27 @@
|
|
|
deviceData: [], // 设备信息
|
|
|
};
|
|
|
},
|
|
|
+ filters: {
|
|
|
+ stockVal: function (val, obj) { // 各个内置箱体的当前【库存量】
|
|
|
+ let num
|
|
|
+ if(val == 1){
|
|
|
+ num = obj.boxOne ? (obj.boxOne/1000).toFixed(2) : 0
|
|
|
+ return num + 'kg'
|
|
|
+ }else if(val == 2){
|
|
|
+ num = obj.boxTwo ? (obj.boxTwo/1000).toFixed(2) : 0
|
|
|
+ return num + 'kg'
|
|
|
+ }else if(val == 3){
|
|
|
+ num = obj.boxThree ? (obj.boxThree/1000).toFixed(2) : 0
|
|
|
+ return num + 'kg'
|
|
|
+ }else if(val == 4){
|
|
|
+ num = obj.boxFour ? (obj.boxFour/1000).toFixed(2) : 0
|
|
|
+ return num + 'kg'
|
|
|
+ }else if(val == 5){
|
|
|
+ num = obj.boxFive ? (obj.boxFive/1000).toFixed(2) : 0
|
|
|
+ return num + 'kg'
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
onLoad(options) {
|
|
|
this.stationNo = options.stationNo
|
|
|
this.getStation() // 网点信息
|