优化积分锁客 优化角色模板问题

This commit is contained in:
gyq
2025-12-12 11:49:07 +08:00
parent b860fa0009
commit b16c530306
9 changed files with 109 additions and 42 deletions

View File

@@ -25,8 +25,9 @@
<el-button @click="visible = false" size="large" style="width: 100%;">自己创建</el-button>
</div>
<div class="btn">
<el-button type="primary" size="large" @click="submitHandle" :loading="loading" style="width: 100%;">
</el-button>
<el-button type="primary" size="large" @click="submitHandle" :loading="loading" style="width: 100%;">
</el-button>
</div>
</div>
</template>
@@ -45,7 +46,7 @@ const list = ref([])
// 获取角色模板列表
async function roleTemplateListAjax() {
try {
const res = await roleTemplateList()
const res = await roleTemplateList({ isEnable: 1 })
res.forEach(el => {
el.cehcked = false
});

View File

@@ -160,6 +160,19 @@ function handlePlatformTypeChange(e) {
handleOpenAssignPermDialog(dialog.row);
}
// 打开分配菜单菜单弹窗
async function handleOpenAssignPermDialog(row) {
const roleId = row.id;
dialog.row = row;
if (roleId) {
assignPermDialogVisible.value = true;
loading.value = true;
checkedRole.value.id = roleId;
checkedRole.value.name = row.name;
getMenuIds(roleId);
}
}
const permKeywords = ref("");
const isExpanded = ref(true);
const parentChildLinked = ref(false);
@@ -233,6 +246,7 @@ function getMenuIds(roleId) {
if (!roleId) {
return;
}
RoleApi.getMenu(roleId, platformType.value)
.then((data) => {
if (platformType.value == 0) {