|
|
|
@ -60,7 +60,6 @@ |
|
|
|
<el-form-item :label="' '"> |
|
|
|
<el-button @click="getDataList()">查询</el-button> |
|
|
|
<el-button v-if="isAuth('104001001:save')" type="primary" @click="addModal()">新增</el-button> |
|
|
|
<el-button v-if="isAuth('104001001:delete')" type="primary" @click="delModal()">删除</el-button> |
|
|
|
<download-excel |
|
|
|
:fields="fields()" |
|
|
|
:data="exportData" |
|
|
|
@ -95,7 +94,6 @@ |
|
|
|
type="selection" |
|
|
|
header-align="center" |
|
|
|
align="center" |
|
|
|
:selectable="selectFlag" |
|
|
|
width="50"> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
@ -138,6 +136,7 @@ |
|
|
|
<el-dropdown-item @click.native="toMenu('Routing', scope.row)">Routing</el-dropdown-item> |
|
|
|
<el-dropdown-item v-if="scope.row.temporaryPartFlag === 'Y' && scope.row.status === 'N'" @click.native="toBecomeOfficialPartModal(scope.row)">转正式物料</el-dropdown-item> |
|
|
|
<el-dropdown-item v-if="scope.row.drawingNo" @click.native="handlePartDrawingDetail(scope.row)">编码详情</el-dropdown-item> |
|
|
|
<el-dropdown-item v-if="isAuth('104001001:delete')" @click.native="delModal(scope.row)">删除</el-dropdown-item> |
|
|
|
</el-dropdown-menu> |
|
|
|
</el-dropdown> |
|
|
|
</template> |
|
|
|
@ -5244,23 +5243,22 @@ |
|
|
|
}, |
|
|
|
|
|
|
|
// 物料信息删除 |
|
|
|
delModal () { |
|
|
|
if (this.partSelections.length === 0) { |
|
|
|
this.$message.warning('请勾选要删除的物料信息!') |
|
|
|
return |
|
|
|
} |
|
|
|
this.$confirm(`是否删除这 `+ this.partSelections.length +` 条物料信息?`, '提示', { |
|
|
|
delModal (row) { |
|
|
|
this.$confirm(`是否删除该物料信息 [${row.partNo}]?`, '提示', { |
|
|
|
confirmButtonText: '确定', |
|
|
|
cancelButtonText: '取消', |
|
|
|
type: 'warning' |
|
|
|
}).then(() => { |
|
|
|
let tempData = { |
|
|
|
informationList: this.partSelections |
|
|
|
} |
|
|
|
partInformationDelete(tempData).then(({data}) => { |
|
|
|
const loading = this.$loading({ |
|
|
|
lock: true, |
|
|
|
text: '正在删除,请稍候...', |
|
|
|
spinner: 'el-icon-loading', |
|
|
|
background: 'rgba(0, 0, 0, 0.7)' |
|
|
|
}) |
|
|
|
partInformationDelete(row).then(({data}) => { |
|
|
|
loading.close() |
|
|
|
if (data && data.code === 0) { |
|
|
|
this.getDataList() |
|
|
|
this.partSelections = [] |
|
|
|
this.$message({ |
|
|
|
message: '操作成功', |
|
|
|
type: 'success', |
|
|
|
@ -5272,6 +5270,8 @@ |
|
|
|
confirmButtonText: '确定' |
|
|
|
}) |
|
|
|
} |
|
|
|
}).catch(() => { |
|
|
|
loading.close() |
|
|
|
}) |
|
|
|
}) |
|
|
|
}, |
|
|
|
|