mirror of
https://gitee.com/victor123/jjjerp-java.git
synced 2025-12-07 04:15:35 +08:00
修改
This commit is contained in:
parent
de1784480b
commit
de78d556f9
@ -15,7 +15,11 @@
|
|||||||
<div class="plus-list">
|
<div class="plus-list">
|
||||||
<div class="item" v-for="(child, num) in item.children" :key="num">
|
<div class="item" v-for="(child, num) in item.children" :key="num">
|
||||||
<div class="item-box pr">
|
<div class="item-box pr">
|
||||||
<a href="javascript:void(0);" class="close-btn" @click="deleteClick(child)">
|
<a
|
||||||
|
href="javascript:void(0);"
|
||||||
|
class="close-btn"
|
||||||
|
@click="deleteClick(child)"
|
||||||
|
>
|
||||||
<el-icon :size="20">
|
<el-icon :size="20">
|
||||||
<CloseBold />
|
<CloseBold />
|
||||||
</el-icon>
|
</el-icon>
|
||||||
@ -31,9 +35,11 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="item">
|
<div class="item">
|
||||||
<div class="d-s-c mt10">
|
<div class="d-s-c mt10">
|
||||||
<div class="add-item-box d-c-c" @click="addClick(item)"> <el-icon>
|
<div class="add-item-box d-c-c" @click="addClick(item)">
|
||||||
|
<el-icon>
|
||||||
<Plus />
|
<Plus />
|
||||||
</el-icon></div>
|
</el-icon>
|
||||||
|
</div>
|
||||||
<div class="ml10">
|
<div class="ml10">
|
||||||
<p class="f14 gray9">添加插件到此类别下</p>
|
<p class="f14 gray9">添加插件到此类别下</p>
|
||||||
</div>
|
</div>
|
||||||
@ -42,19 +48,22 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!--添加-->
|
<!--添加-->
|
||||||
<Add v-if="open_add" :open_add="open_add" :curModel="curModel" @closeDialog="closeDialogFunc($event, 'add')"></Add>
|
<Add
|
||||||
|
v-if="open_add"
|
||||||
|
:open_add="open_add"
|
||||||
|
:curModel="curModel"
|
||||||
|
@closeDialog="closeDialogFunc($event, 'add')"
|
||||||
|
></Add>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import PlusApi from '@/api/plus.js';
|
import PlusApi from "@/api/plus.js";
|
||||||
import Add from './dialog/Add.vue';
|
import Add from "./dialog/Add.vue";
|
||||||
import {
|
import { deepClone } from "@/utils/base.js";
|
||||||
deepClone
|
|
||||||
} from '@/utils/base.js';
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
Add
|
Add,
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@ -65,12 +74,12 @@
|
|||||||
/*是否打开添加弹窗*/
|
/*是否打开添加弹窗*/
|
||||||
open_add: false,
|
open_add: false,
|
||||||
/*当前编辑的对象*/
|
/*当前编辑的对象*/
|
||||||
curModel: {}
|
curModel: {},
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
/*获取列表*/
|
/*获取列表*/
|
||||||
this.getData();
|
// this.getData();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
/*获取列表*/
|
/*获取列表*/
|
||||||
@ -78,16 +87,15 @@
|
|||||||
let self = this;
|
let self = this;
|
||||||
let Params = {};
|
let Params = {};
|
||||||
PlusApi.pluslist(Params, true)
|
PlusApi.pluslist(Params, true)
|
||||||
.then(res => {
|
.then((res) => {
|
||||||
self.loading = false;
|
self.loading = false;
|
||||||
self.tableData = res.data;
|
self.tableData = res.data;
|
||||||
})
|
})
|
||||||
.catch(error => {
|
.catch((error) => {
|
||||||
self.loading = false;
|
self.loading = false;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
/*打开添加*/
|
/*打开添加*/
|
||||||
addClick(e) {
|
addClick(e) {
|
||||||
this.curModel = e;
|
this.curModel = e;
|
||||||
@ -95,9 +103,9 @@
|
|||||||
},
|
},
|
||||||
|
|
||||||
closeDialogFunc(e, f) {
|
closeDialogFunc(e, f) {
|
||||||
if (f == 'add') {
|
if (f == "add") {
|
||||||
this.open_add = e.openDialog;
|
this.open_add = e.openDialog;
|
||||||
if (e.type == 'success') {
|
if (e.type == "success") {
|
||||||
this.getData();
|
this.getData();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -105,29 +113,30 @@
|
|||||||
/*删除插件*/
|
/*删除插件*/
|
||||||
deleteClick(row) {
|
deleteClick(row) {
|
||||||
let self = this;
|
let self = this;
|
||||||
ElMessageBox.confirm('删除后不可恢复,确认删除该记录吗?', '提示', {
|
ElMessageBox.confirm("删除后不可恢复,确认删除该记录吗?", "提示", {
|
||||||
confirmButtonText: '确定',
|
confirmButtonText: "确定",
|
||||||
cancelButtonText: '取消',
|
cancelButtonText: "取消",
|
||||||
type: 'warning'
|
type: "warning",
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
self.loading = true;
|
self.loading = true;
|
||||||
PlusApi.deleteplus({
|
PlusApi.deleteplus(
|
||||||
id: row.accessId
|
{
|
||||||
|
id: row.accessId,
|
||||||
},
|
},
|
||||||
true
|
true
|
||||||
)
|
)
|
||||||
.then(data => {
|
.then((data) => {
|
||||||
if (data.code == 1) {
|
if (data.code == 1) {
|
||||||
self.loading = false;
|
self.loading = false;
|
||||||
ElMessage({
|
ElMessage({
|
||||||
message: data.msg,
|
message: data.msg,
|
||||||
type: 'success'
|
type: "success",
|
||||||
});
|
});
|
||||||
self.getData();
|
self.getData();
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.catch(error => {
|
.catch((error) => {
|
||||||
self.loading = false;
|
self.loading = false;
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
@ -138,10 +147,10 @@
|
|||||||
if (e != null && e.length > 0) {
|
if (e != null && e.length > 0) {
|
||||||
return e;
|
return e;
|
||||||
} else {
|
} else {
|
||||||
return 'icon-chajian1';
|
return "icon-chajian1";
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
@ -151,7 +160,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.plus-container .common-form .close-btn {
|
.plus-container .common-form .close-btn {
|
||||||
color: #CCCCCC;
|
color: #cccccc;
|
||||||
}
|
}
|
||||||
|
|
||||||
.plus-list {
|
.plus-list {
|
||||||
@ -166,7 +175,7 @@
|
|||||||
|
|
||||||
.plus-list .item .item-box {
|
.plus-list .item .item-box {
|
||||||
margin: 0 10px 20px;
|
margin: 0 10px 20px;
|
||||||
border: 1px solid #FFFFFF;
|
border: 1px solid #ffffff;
|
||||||
}
|
}
|
||||||
|
|
||||||
.plus-list .item .item-box .close-btn {
|
.plus-list .item .item-box .close-btn {
|
||||||
@ -182,7 +191,7 @@
|
|||||||
|
|
||||||
.plus-list .item .item-box:hover {
|
.plus-list .item .item-box:hover {
|
||||||
border-radius: 8px;
|
border-radius: 8px;
|
||||||
border: 1px dashed #CCCCCC;
|
border: 1px dashed #cccccc;
|
||||||
}
|
}
|
||||||
|
|
||||||
.plus-list .item .item-box:hover .close-btn {
|
.plus-list .item .item-box:hover .close-btn {
|
||||||
@ -232,6 +241,6 @@
|
|||||||
|
|
||||||
.plus-list .item a .icon.iconfont {
|
.plus-list .item a .icon.iconfont {
|
||||||
color: #ffffff;
|
color: #ffffff;
|
||||||
font-size: 22px
|
font-size: 22px;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
Loading…
x
Reference in New Issue
Block a user