From 85470a1549f6394398b5745ed29ef65de2377d6b Mon Sep 17 00:00:00 2001
From: RuoYi <yzz_ivy@163.com>
Date: 星期三, 02 六月 2021 20:43:34 +0800
Subject: [PATCH] 修复表单构建选择下拉选择控制台报错问题
---
ruoyi-ui/src/views/system/menu/index.vue | 41 ++++++++++++++++++++---------------------
1 files changed, 20 insertions(+), 21 deletions(-)
diff --git a/ruoyi-ui/src/views/system/menu/index.vue b/ruoyi-ui/src/views/system/menu/index.vue
index 6cf8d3b..cee61b7 100644
--- a/ruoyi-ui/src/views/system/menu/index.vue
+++ b/ruoyi-ui/src/views/system/menu/index.vue
@@ -21,7 +21,7 @@
</el-select>
</el-form-item>
<el-form-item>
- <el-button type="cyan" icon="el-icon-search" size="mini" @click="handleQuery">鎼滅储</el-button>
+ <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">鎼滅储</el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">閲嶇疆</el-button>
</el-form-item>
</el-form>
@@ -30,20 +30,14 @@
<el-col :span="1.5">
<el-button
type="primary"
+ plain
icon="el-icon-plus"
size="mini"
@click="handleAdd"
v-hasPermi="['system:menu:add']"
>鏂板</el-button>
</el-col>
- <div class="top-right-btn">
- <el-tooltip class="item" effect="dark" content="鍒锋柊" placement="top">
- <el-button size="mini" circle icon="el-icon-refresh" @click="handleQuery" />
- </el-tooltip>
- <el-tooltip class="item" effect="dark" :content="showSearch ? '闅愯棌鎼滅储' : '鏄剧ず鎼滅储'" placement="top">
- <el-button size="mini" circle icon="el-icon-search" @click="showSearch=!showSearch" />
- </el-tooltip>
- </div>
+ <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table
@@ -169,7 +163,7 @@
</el-col>
<el-col :span="12">
<el-form-item v-if="form.menuType != 'M'" label="鏉冮檺鏍囪瘑">
- <el-input v-model="form.perms" placeholder="璇锋潈闄愭爣璇�" maxlength="50" />
+ <el-input v-model="form.perms" placeholder="璇锋潈闄愭爣璇�" maxlength="100" />
</el-form-item>
</el-col>
<el-col :span="12">
@@ -191,6 +185,14 @@
:key="dict.dictValue"
:label="dict.dictValue"
>{{dict.dictLabel}}</el-radio>
+ </el-radio-group>
+ </el-form-item>
+ </el-col>
+ <el-col :span="12">
+ <el-form-item v-if="form.menuType == 'C'" label="鏄惁缂撳瓨">
+ <el-radio-group v-model="form.isCache">
+ <el-radio label="0">缂撳瓨</el-radio>
+ <el-radio label="1">涓嶇紦瀛�</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
@@ -323,6 +325,7 @@
menuType: "M",
orderNum: undefined,
isFrame: "1",
+ isCache: "0",
visible: "0",
status: "0"
};
@@ -365,19 +368,15 @@
if (valid) {
if (this.form.menuId != undefined) {
updateMenu(this.form).then(response => {
- if (response.code === 200) {
- this.msgSuccess("淇敼鎴愬姛");
- this.open = false;
- this.getList();
- }
+ this.msgSuccess("淇敼鎴愬姛");
+ this.open = false;
+ this.getList();
});
} else {
addMenu(this.form).then(response => {
- if (response.code === 200) {
- this.msgSuccess("鏂板鎴愬姛");
- this.open = false;
- this.getList();
- }
+ this.msgSuccess("鏂板鎴愬姛");
+ this.open = false;
+ this.getList();
});
}
}
@@ -394,7 +393,7 @@
}).then(() => {
this.getList();
this.msgSuccess("鍒犻櫎鎴愬姛");
- }).catch(function() {});
+ })
}
}
};
--
Gitblit v1.9.3