fix:修改菜单管理兼容多系统
This commit is contained in:
@@ -13,6 +13,18 @@
|
||||
class="filter-item"
|
||||
@keyup.enter.native="crud.toQuery"
|
||||
/>
|
||||
<el-select
|
||||
v-model="query.system_type"
|
||||
style="width: 150px"
|
||||
placeholder="请选择系统"
|
||||
@change="crud.toQuery"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in dict.system_type"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
/>
|
||||
</el-select>
|
||||
<rrOperation />
|
||||
</div>
|
||||
<crudOperation :permission="permission" />
|
||||
@@ -204,6 +216,7 @@ import rrOperation from '@crud/RR.operation'
|
||||
import crudOperation from '@crud/CRUD.operation'
|
||||
import udOperation from '@crud/UD.operation'
|
||||
import DateRangePicker from '@/components/DateRangePicker'
|
||||
import crudDictDetail from '@/api/system/dictDetail'
|
||||
|
||||
// crud交由presenter持有
|
||||
const defaultForm = {
|
||||
@@ -234,6 +247,8 @@ export default {
|
||||
dicts: ['system_type'],
|
||||
data() {
|
||||
return {
|
||||
typeList: [],
|
||||
defaultType: '',
|
||||
menus: [],
|
||||
permission: {
|
||||
add: ['admin', 'menu:add'],
|
||||
@@ -257,7 +272,22 @@ export default {
|
||||
}
|
||||
}
|
||||
},
|
||||
beforeMount() {
|
||||
// const _this=this
|
||||
// crudDictDetail.get('system_type').then(data => {
|
||||
// if (data.content.length > 0) {
|
||||
// const shift = data.content.shift()
|
||||
// _this.defaultType = shift.para1
|
||||
// }
|
||||
// })
|
||||
},
|
||||
methods: {
|
||||
[CRUD.HOOK.beforeRefresh]() {
|
||||
if (this.crud.query.system_type == null) {
|
||||
this.crud.query.system_type = '1'
|
||||
}
|
||||
return true
|
||||
},
|
||||
// 新增与编辑前做的操作
|
||||
[CRUD.HOOK.afterToCU](crud, form) {
|
||||
console.log(this.dict)
|
||||
|
||||
Reference in New Issue
Block a user