Explorar el Código

始宁农业小程序:商品管理-商品上架

panyong hace 2 años
padre
commit
a1596c15fa

+ 5 - 1
htmldev/shiningWxMini/pages/businessGoodsManage/businessGoodsManage.js

@@ -262,7 +262,11 @@ Page({
           const _list = originScrollViewData[i].list
           const _delIndex = _list.findIndex(item => item.id === id)
           if (_delIndex > -1) {
-            _list.splice(_delIndex, 1, { ...this.data.itemData, product_status: product_status === 0 ? 1 : 0 })
+            _list.splice(_delIndex, 1, {
+              ...this.data.itemData,
+              product_status: product_status === 0 ? 1 : 0,
+              ...this.getStatusTextAndColor(product_status === 0 ? 1 : 0, this.data.itemData.product_check_status)
+            })
             this.setData({
               ['originScrollViewData[' + i + '].list']: _list
             })