فهرست منبع

解决 中药处方 药品剂量 输入值,无法正确更新问题

cc12458 1 سال پیش
والد
کامیت
ddc467ead6
1فایلهای تغییر یافته به همراه3 افزوده شده و 2 حذف شده
  1. 3 2
      src/components/ChineseMedicine.vue

+ 3 - 2
src/components/ChineseMedicine.vue

@@ -1810,16 +1810,17 @@ export default {
         scope.row.id - 1
       ].total = total;
 
+      const forceUpdate = (data) => Object.assign({}, data);
       this.recipe_tabs[this.recipe_tabs_c].tableData = totalData.filter(
         (item, index) => {
           return item.id % 2 != 0;
         }
-      );
+      ).map(forceUpdate);
       this.recipe_tabs[this.recipe_tabs_c].tableData1 = totalData.filter(
         (item, index) => {
           return item.id % 2 == 0;
         }
-      );
+      ).map(forceUpdate);
 
       if (this.recipe_tabs[this.recipe_tabs_c].bottom_form.doseNum) {
         // this.countNowRecipeMoney();