|
@@ -4,7 +4,23 @@
|
|
<!-- 操作栏 -->
|
|
<!-- 操作栏 -->
|
|
<!-- 基本信息栏 -->
|
|
<!-- 基本信息栏 -->
|
|
<div v-if="activeMainTab == 'material'">
|
|
<div v-if="activeMainTab == 'material'">
|
|
- <el-row :gutter="10" class="mb10" v-if="!updateButtonGroup">
|
|
|
|
|
|
+
|
|
|
|
+ <!-- 基本信息修改状态下—— 保存、保存新增、更新导入、取消 -->
|
|
|
|
+ <el-row :gutter="10" class="mb10" v-if="updateButtonGroup || maintainNewVersion">
|
|
|
|
+ <el-col :span="1.5">
|
|
|
|
+ <el-button-group>
|
|
|
|
+ <el-button size="small" @click="handleSave" v-hasPermi="['system:material:add']">保存</el-button>
|
|
|
|
+ </el-button-group>
|
|
|
|
+ </el-col>
|
|
|
|
+
|
|
|
|
+ <el-col :span="1.5">
|
|
|
|
+ <el-button-group>
|
|
|
|
+ <el-button size="small" @click="handleCancel">取消</el-button>
|
|
|
|
+ </el-button-group>
|
|
|
|
+ </el-col>
|
|
|
|
+ </el-row>
|
|
|
|
+
|
|
|
|
+ <el-row :gutter="10" class="mb10" v-else>
|
|
<!-- 新增、修改、删除、复制 -->
|
|
<!-- 新增、修改、删除、复制 -->
|
|
<el-col :span="1.5">
|
|
<el-col :span="1.5">
|
|
<el-button-group>
|
|
<el-button-group>
|
|
@@ -19,17 +35,6 @@
|
|
<el-col :span="1.5">
|
|
<el-col :span="1.5">
|
|
<el-button-group>
|
|
<el-button-group>
|
|
|
|
|
|
- <!-- <el-dropdown size="small" @command="handleFilter">
|
|
|
|
- <el-button size="small">
|
|
|
|
- 过滤<i class="el-icon-arrow-down el-icon--right"></i>
|
|
|
|
- </el-button>
|
|
|
|
- <el-dropdown-menu slot="dropdown">
|
|
|
|
- <el-dropdown-item :command="filterCondition('stop')">显示停用</el-dropdown-item>
|
|
|
|
- <el-dropdown-item :command="filterCondition('allot')">显示已分配</el-dropdown-item>
|
|
|
|
- </el-dropdown-menu>
|
|
|
|
- </el-dropdown>
|
|
|
|
-
|
|
|
|
- <el-button size="small" @click="handleQuery">查询</el-button> -->
|
|
|
|
<el-button size="small" @click="handleRefresh">刷新</el-button>
|
|
<el-button size="small" @click="handleRefresh">刷新</el-button>
|
|
|
|
|
|
</el-button-group>
|
|
</el-button-group>
|
|
@@ -43,47 +48,19 @@
|
|
<!-- 0:启用 2:停用 -->
|
|
<!-- 0:启用 2:停用 -->
|
|
{{ basicData.value.isEnable == '已启用' ? '停用' : '启用' }}
|
|
{{ basicData.value.isEnable == '已启用' ? '停用' : '启用' }}
|
|
</el-button>
|
|
</el-button>
|
|
- <!-- <el-dropdown split-button size="small" @click="handleIsInvoke(true)" @command="handleIsInvoke">
|
|
|
|
- 启用
|
|
|
|
- <el-dropdown-menu slot="dropdown">
|
|
|
|
- <el-dropdown-item :command="isInvoke(true)">启用</el-dropdown-item>
|
|
|
|
- <el-dropdown-item :command="isInvoke(false)">停用</el-dropdown-item></el-dropdown-menu></el-dropdown> -->
|
|
|
|
</el-button-group>
|
|
</el-button-group>
|
|
</el-col>
|
|
</el-col>
|
|
|
|
|
|
- <!-- 申请单查询 -->
|
|
|
|
|
|
+ <!-- 维护新版本 -->
|
|
<!-- <el-col :span="1.5">
|
|
<!-- <el-col :span="1.5">
|
|
<el-button-group>
|
|
<el-button-group>
|
|
- <el-button size="small" @click="handleQueryForm">申请单查询</el-button>
|
|
|
|
|
|
+ <el-button size="small" @click="handleNewVersion">维护新版本</el-button>
|
|
</el-button-group>
|
|
</el-button-group>
|
|
- </el-col> -->
|
|
|
|
-
|
|
|
|
- <!-- 导入导出 -->
|
|
|
|
- <!-- <el-col :span="1.5">
|
|
|
|
- <el-button-group>
|
|
|
|
- <el-button size="small" @click="handleImport">批量导入</el-button>
|
|
|
|
- <el-button size="small" @click="handleExport">批量导出</el-button>
|
|
|
|
- </el-button-group>
|
|
|
|
- </el-col> -->
|
|
|
|
|
|
+ </el-col> -->
|
|
|
|
|
|
</el-row>
|
|
</el-row>
|
|
|
|
|
|
- <!-- 基本信息修改状态下—— 保存、保存新增、更新导入、取消 -->
|
|
|
|
- <el-row :gutter="10" class="mb10" v-else>
|
|
|
|
- <el-col :span="1.5">
|
|
|
|
- <el-button-group>
|
|
|
|
- <el-button size="small" @click="handleSave" v-hasPermi="['system:material:add']">保存</el-button>
|
|
|
|
- <!-- <el-button size="small" @click="handleSaveAdd" :disabled="true">保存新增</el-button> -->
|
|
|
|
- <!-- <el-button size="small" @click="handleUpdateImport">更新导入</el-button> -->
|
|
|
|
- </el-button-group>
|
|
|
|
- </el-col>
|
|
|
|
|
|
|
|
- <el-col :span="1.5">
|
|
|
|
- <el-button-group>
|
|
|
|
- <el-button size="small" @click="handleCancel">取消</el-button>
|
|
|
|
- </el-button-group>
|
|
|
|
- </el-col>
|
|
|
|
- </el-row>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<!-- 其他标签页操作 修改、删除 -->
|
|
<!-- 其他标签页操作 修改、删除 -->
|
|
@@ -109,7 +86,7 @@
|
|
<el-col :span="6" style="text-align: right;">
|
|
<el-col :span="6" style="text-align: right;">
|
|
<!-- 附件管理 -->
|
|
<!-- 附件管理 -->
|
|
<!-- <el-button-group>
|
|
<!-- <el-button-group>
|
|
- <el-button size="small" icon="el-icon-paperclip" @click="handleFile"></el-button></el-button-group> -->
|
|
|
|
|
|
+ <el-button size="small" icon="el-icon-paperclip" @click="handleFile"></el-button></el-button-group> -->
|
|
|
|
|
|
<!-- 切换 -->
|
|
<!-- 切换 -->
|
|
<!-- <el-button-group>
|
|
<!-- <el-button-group>
|
|
@@ -120,7 +97,7 @@
|
|
<el-button size="small" icon="el-icon-arrow-right" :disabled="!handleBasicEdit"
|
|
<el-button size="small" icon="el-icon-arrow-right" :disabled="!handleBasicEdit"
|
|
@click="handleChangePage('next')" />
|
|
@click="handleChangePage('next')" />
|
|
<el-button size="small" icon="el-icon-d-arrow-right" :disabled="!handleBasicEdit"
|
|
<el-button size="small" icon="el-icon-d-arrow-right" :disabled="!handleBasicEdit"
|
|
- @click="handleChangePage('end')" /></el-button-group> -->
|
|
|
|
|
|
+ @click="handleChangePage('end')" /></el-button-group> -->
|
|
</el-col>
|
|
</el-col>
|
|
</el-row>
|
|
</el-row>
|
|
|
|
|
|
@@ -430,7 +407,7 @@
|
|
:disabled="!(materialType.isEdit && mt.edit)" v-model="scope.row[mt.prop]" :key="scope.row[mt.prop]">
|
|
:disabled="!(materialType.isEdit && mt.edit)" v-model="scope.row[mt.prop]" :key="scope.row[mt.prop]">
|
|
<el-option v-if="mt.dictId" v-for="d in mt.dictId" :key="d.dictValue" :label="d.dictLabel"
|
|
<el-option v-if="mt.dictId" v-for="d in mt.dictId" :key="d.dictValue" :label="d.dictLabel"
|
|
:value="d.dictValue">
|
|
:value="d.dictValue">
|
|
- </el-option></el-select> -->
|
|
|
|
|
|
+ </el-option></el-select> -->
|
|
|
|
|
|
<!-- 其他类型 -->
|
|
<!-- 其他类型 -->
|
|
<el-input v-else size="small" v-model="scope.row[mt.prop]" :readonly="!(materialType.isEdit && mt.edit)" />
|
|
<el-input v-else size="small" v-model="scope.row[mt.prop]" :readonly="!(materialType.isEdit && mt.edit)" />
|
|
@@ -631,6 +608,8 @@ export default {
|
|
return {
|
|
return {
|
|
count: 1,
|
|
count: 1,
|
|
loading: false,
|
|
loading: false,
|
|
|
|
+ // 维护新版本
|
|
|
|
+ maintainNewVersion: false,
|
|
// 详情固定标签页
|
|
// 详情固定标签页
|
|
detailsTabs,
|
|
detailsTabs,
|
|
defaultProps: {
|
|
defaultProps: {
|
|
@@ -1481,13 +1460,6 @@ export default {
|
|
// 启用
|
|
// 启用
|
|
handleIsInvoke(e) {
|
|
handleIsInvoke(e) {
|
|
console.log('启用', this.basicData.value.isEnable);
|
|
console.log('启用', this.basicData.value.isEnable);
|
|
- // if (this.basicData.value.isEnable == '已启用') {
|
|
|
|
- // this.basicData.value.isEnable = '2';
|
|
|
|
- // } else {
|
|
|
|
- // // this.basicData.isEnable 为空或者为2
|
|
|
|
- // this.basicData.value.isEnable = '0';
|
|
|
|
- // }
|
|
|
|
- // this.handleSave();
|
|
|
|
|
|
|
|
let param = {
|
|
let param = {
|
|
isEnable: this.basicData.value.isEnable == '已启用' ? '2' : '0',
|
|
isEnable: this.basicData.value.isEnable == '已启用' ? '2' : '0',
|
|
@@ -1499,22 +1471,11 @@ export default {
|
|
if (res.code == 200) this.handleRefresh();
|
|
if (res.code == 200) this.handleRefresh();
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- isInvoke(val) {
|
|
|
|
- return val;
|
|
|
|
- },
|
|
|
|
- // 申请单查询
|
|
|
|
- handleQueryForm() {
|
|
|
|
- console.log('申请单查询');
|
|
|
|
- },
|
|
|
|
- // 批量导入
|
|
|
|
- handleImport() {
|
|
|
|
- console.log('批量导入');
|
|
|
|
- },
|
|
|
|
- // 批量导出
|
|
|
|
- handleExport() {
|
|
|
|
- console.log('批量导出');
|
|
|
|
|
|
+ // 维护新版本
|
|
|
|
+ handleNewVersion() {
|
|
|
|
+ console.log('维护新版本');
|
|
|
|
+ this.maintainNewVersion = true;
|
|
},
|
|
},
|
|
-
|
|
|
|
// 取消保存
|
|
// 取消保存
|
|
handleCancel() {
|
|
handleCancel() {
|
|
console.log('取消保存');
|
|
console.log('取消保存');
|
|
@@ -1524,10 +1485,14 @@ export default {
|
|
// 保存修改
|
|
// 保存修改
|
|
handleSave() {
|
|
handleSave() {
|
|
console.log('保存修改');
|
|
console.log('保存修改');
|
|
- this.handleSaveMaterial(() => {
|
|
|
|
|
|
+ // 普通保存修改
|
|
|
|
+ this.updateButtonGroup && this.handleSaveMaterial(() => {
|
|
this.updateButtonGroup = false;
|
|
this.updateButtonGroup = false;
|
|
this.handleRefresh();
|
|
this.handleRefresh();
|
|
});
|
|
});
|
|
|
|
+
|
|
|
|
+ // 维护新版本保存修改
|
|
|
|
+ this.maintainNewVersion && console.log('维护新版本保存修改');
|
|
},
|
|
},
|
|
// 物料类别列表选中
|
|
// 物料类别列表选中
|
|
handleSelectionType(list) {
|
|
handleSelectionType(list) {
|
|
@@ -1712,6 +1677,7 @@ export default {
|
|
|
|
|
|
this.optionDialog.show = false;
|
|
this.optionDialog.show = false;
|
|
|
|
|
|
|
|
+ // 取消基本信息修改
|
|
if (this.updateButtonGroup) {
|
|
if (this.updateButtonGroup) {
|
|
this.updateButtonGroup = false;
|
|
this.updateButtonGroup = false;
|
|
this.handleRest();
|
|
this.handleRest();
|
|
@@ -1723,10 +1689,18 @@ export default {
|
|
})
|
|
})
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ // 取消其他主页签详情弹窗修改
|
|
if (this.otherDeatils.isEdit) {
|
|
if (this.otherDeatils.isEdit) {
|
|
this.otherDeatils.isEdit = false;
|
|
this.otherDeatils.isEdit = false;
|
|
this.handleOtherRefresh();
|
|
this.handleOtherRefresh();
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ // 取消维护新版本修改
|
|
|
|
+ if (this.maintainNewVersion) {
|
|
|
|
+ console.log('取消维护新版本修改');
|
|
|
|
+ this.maintainNewVersion = false;
|
|
|
|
+ this.handleRefresh();
|
|
|
|
+ }
|
|
},
|
|
},
|
|
// 参照弹窗过滤
|
|
// 参照弹窗过滤
|
|
handleFilterRefer() {
|
|
handleFilterRefer() {
|