This commit is contained in:
helloDy
2023-11-27 09:38:31 +08:00
parent 7f5b9d5228
commit b0efd66a75
16 changed files with 392 additions and 144 deletions

View File

@@ -2,14 +2,14 @@
* @Author: zwq
* @Date: 2021-11-18 14:16:25
* @LastEditors: DY
* @LastEditTime: 2023-11-22 11:22:38
* @LastEditTime: 2023-11-27 09:36:44
* @Description:
-->
<template>
<el-drawer
:visible.sync="visible"
:show-close="false"
:wrapper-closable="false"
:wrapper-closable="isdetail"
class="drawer"
size="60%">
<small-title slot="title" :no-padding="true">
@@ -156,12 +156,12 @@
@pagination="getList" />
</div>
<div class="drawer-body__footer">
<el-button style="" @click="goback()">{{ isdetail ? '关闭' : '取消' }}</el-button>
<div v-if="!isdetail" class="drawer-body__footer">
<el-button style="" @click="goback()">取消</el-button>
<!-- <el-button v-if="isdetail" type="primary" @click="goEdit()">
编辑
</el-button> -->
<el-button v-if="!isdetail" type="primary" @click="dataFormSubmit()">确定</el-button>
<el-button type="primary" @click="dataFormSubmit()">确定</el-button>
</div>
</div>
@@ -432,7 +432,7 @@ export default {
}
.action_btn {
float: right;
margin: -35px 15px;
margin: -40px 15px;
font-size: 14px;
}
.add {

View File

@@ -13,7 +13,7 @@
<method-btn
v-if="tableBtn.length"
slot="handleBtn"
:width="220"
:width="120"
label="操作"
:method-list="tableBtn"
@clickBtn="handleClick" />
@@ -85,25 +85,25 @@ export default {
},
tableProps,
tableBtn: [
this.$auth.hasPermi(`base:material:queryAttr`)
? {
type: 'detail',
btnName: '查看属性',
}
: undefined,
this.$auth.hasPermi(`base:material:update`)
? {
type: 'edit',
btnName: '编辑',
}
: undefined,
this.$auth.hasPermi(`base:material:queryAttr`)
? {
type: 'search',
btnName: '查看属性',
}
: undefined,
this.$auth.hasPermi(`base:material:editAttr`)
? {
type: 'editAttr',
btnName: '编辑属性',
}
: undefined,
this.$auth.hasPermi(`base:material:delete`)
// this.$auth.hasPermi(`base:material:editAttr`)
// ? {
// type: 'editAttr',
// btnName: '编辑属性',
// }
// : undefined,
this.$auth.hasPermi(`base:material:delete`)
? {
type: 'delete',
btnName: '删除',
@@ -136,7 +136,7 @@ export default {
},
{
type: this.$auth.hasPermi('base:material:create') ? 'button' : '',
btnName: '新增物料',
btnName: '新增',
name: 'add',
color: 'success',
plain: true
@@ -166,7 +166,7 @@ export default {
});
},
otherMethods(val) {
if (val.type === 'search') {
if (val.type === 'detail') {
this.addOrUpdateVisible = true;
this.addOrEditTitle = '详情';
this.$nextTick(() => {