Skip to content

Commit

Permalink
fix(permission/menu): 调整权限菜单创建逻辑顺序并优化欢迎页链接展示
Browse files Browse the repository at this point in the history
  • Loading branch information
kanyxmo committed Jan 9, 2025
1 parent cb236fe commit 9c8634b
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 7 deletions.
6 changes: 3 additions & 3 deletions web/src/modules/base/views/permission/menu/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -93,10 +93,10 @@ function createOrSaveMenu() {
const elForm = getElFormRef() as typeof ElForm
loading.value = true
elForm.validate().then(() => {
if (!model.parent_id) {
model.parent_id = 0
}
if (model.dataType && model.dataType === 'add') {
if (!model.parent_id) {
model.parent_id = 0
}
create(model).then(async (res: any) => {
res.code === ResultCode.SUCCESS ? msg.success(t('crud.createSuccess')) : msg.error(res.message)
await getMenu()
Expand Down
25 changes: 21 additions & 4 deletions web/src/modules/base/views/welcome/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import useTable from '@/hooks/useTable.ts'

defineOptions({ name: 'welcome' })
const userinfo = useUserStore().getUserInfo()
console.log(useUserStore().getPermissions())

useTable('table').then((table: MaTableExpose) => {
table.setColumns([
Expand Down Expand Up @@ -135,10 +136,26 @@ useTable('table').then((table: MaTableExpose) => {
</div>
<div class="p-2 text-sm text-gray-5 dark-text-[#ccc]">
<ul class="ma-link">
<li>官方网站:<el-link>https://www.mineadmin.com</el-link></li>
<li>开发文档:<el-link>https://doc.mineadmin.com</el-link></li>
<li>应用市场:<el-link>https://www.mineadmin.com/store</el-link></li>
<li>QQ交流群:<el-link>150105478,点击加入</el-link></li>
<li>
官方网站:<el-link target="_blank" href="https://www.mineadmin.com">
https://www.mineadmin.com
</el-link>
</li>
<li>
开发文档:<el-link target="_blank" href="https://doc.mineadmin.com">
https://doc.mineadmin.com
</el-link>
</li>
<li>
应用市场:<el-link target="_blank" href="https://www.mineadmin.com/store">
https://www.mineadmin.com/store
</el-link>
</li>
<li>
QQ交流群:<el-link target="_blank" href="https://qm.qq.com/cgi-bin/qm/qr?k=Uq4VW1H9jtDhEKsUb3hfjHraiSG80FI4&jump_from=webapi&authKey=bpaCvnQ65RpLdyQx8m57iQNc9OtgJgyIjrcG3qDrJZhnL4QdqzDLLQS8fx5jkevE">
150105478,点击加入
</el-link>
</li>
</ul>
</div>
</div>
Expand Down

0 comments on commit 9c8634b

Please sign in to comment.