Browse Source

修改bug

qukaidi 2 years ago
parent
commit
d6e3791c80

+ 10 - 10
src/views/InventoryManagement/inventory/detailsPage.vue

@@ -58,9 +58,9 @@
             <div style="display:flex;justify-content: center;">
               <el-button size="small" icon="el-icon-edit" type="text" @click="rowCell(row, index)"
                 :disabled="disabled || detailData.status == 1">{{ row.$cellEdit ? "保存" : "修改" }}</el-button>
-            </div>
-            <el-button size="small" icon="el-icon-delete" type="text" @click="rowDel(row, index)"
+                <el-button size="small" icon="el-icon-delete" type="text" @click="rowDel(row, index)"
                 :disabled="detailData.status == 1">删除</el-button>
+            </div>
           </template>
           <template slot="storageIdHeader" slot-scope="{column}">
             <span style="color: #409EFF;cursor: pointer" @click.stop="addData(column.prop)">{{column.label}}</span>
@@ -93,7 +93,7 @@
 </template>
 
 <script>
-import { detail, submit, checkWarehousing, getStoragetree, getStorage, getAllgoods, revokeWarehousing } from "@/api/purchasingManagement/inStock";
+import { detail, submit, checkWarehousing, getStoragetree, getStorage, getAllgoods, revokeWarehousing,delItem } from "@/api/purchasingManagement/inStock";
 import tableOption from "./config/customerContact.json";
 import feeInfo from "@/components/fee-info/main";
 import checkSchedule from "../../../components/check/checkSchedule";
@@ -316,13 +316,13 @@ export default {
         type: "warning"
       }).then(() => {
         if (row.id) {
-          // delItem({ itemId: row.id }).then(res => {
-          //   this.$message({
-          //     type: "success",
-          //     message: "删除成功!"
-          //   });
-          //   this.itemsVOList.splice(row.$index, 1);
-          // });
+          delItem({ itemId: row.id }).then(res => {
+            this.$message({
+              type: "success",
+              message: "删除成功!"
+            });
+            this.itemsVOList.splice(row.$index, 1);
+          });
         } else {
           this.$message({
             type: "success",

+ 0 - 1
src/views/salesManagement/outStock/config/mainList.json

@@ -7,7 +7,6 @@
   "editBtn": false,
   "delBtn": false,
   "addBtn": false,
-  "menu":false,
   "headerAlign": "center",
   "menuWidth": "70",
   "showSummary": true,

+ 5 - 0
src/views/salesManagement/outStock/index.vue

@@ -10,6 +10,11 @@
                     <el-button type="primary" icon="el-icon-plus" size="small" @click.stop="newAdd()">创建单据
                     </el-button>
                 </template> -->
+                <template slot-scope="{ row,index}" slot="menu">
+                    <el-button type="text" icon="el-icon-delete" size="small" :disabled="row.status>0"
+                        @click.stop="rowDel(row, index)">删除
+                    </el-button>
+                </template>
                 <template slot="stockTimeSearch">
                     <el-date-picker v-model="search.stockTime" type="daterange" start-placeholder="开始日期"
                         end-placeholder="结束日期" format="yyyy-MM-dd" value-format="yyyy-MM-dd">