Merge branch 'develop' of https://gitee.com/likeadmin/likeadmin_java into develop
This commit is contained in:
commit
f4d1344bd3
|
|
@ -20,7 +20,7 @@ export function useCate(type: number) {
|
||||||
const cateLists = ref<any[]>([])
|
const cateLists = ref<any[]>([])
|
||||||
|
|
||||||
// 选中的分组id
|
// 选中的分组id
|
||||||
const cateId = ref('')
|
const cateId = ref<number | string>('')
|
||||||
|
|
||||||
// 获取分组列表
|
// 获取分组列表
|
||||||
const getCateLists = async () => {
|
const getCateLists = async () => {
|
||||||
|
|
@ -39,6 +39,9 @@ export function useCate(type: number) {
|
||||||
]
|
]
|
||||||
cateLists.value = data
|
cateLists.value = data
|
||||||
cateLists.value.unshift(...item)
|
cateLists.value.unshift(...item)
|
||||||
|
setTimeout(() => {
|
||||||
|
treeRef.value?.setCurrentKey(cateId.value)
|
||||||
|
}, 0)
|
||||||
}
|
}
|
||||||
|
|
||||||
// 添加分组
|
// 添加分组
|
||||||
|
|
@ -66,6 +69,7 @@ export function useCate(type: number) {
|
||||||
const handleDeleteCate = async (id: number) => {
|
const handleDeleteCate = async (id: number) => {
|
||||||
await feedback.confirm('确定要删除?')
|
await feedback.confirm('确定要删除?')
|
||||||
await fileCateDelete({ id })
|
await fileCateDelete({ id })
|
||||||
|
cateId.value = ''
|
||||||
getCateLists()
|
getCateLists()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -87,7 +91,12 @@ export function useCate(type: number) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// 处理文件的钩子函数
|
// 处理文件的钩子函数
|
||||||
export function useFile(cateId: Ref<string>, type: Ref<number>, limit: Ref<number>, size: number) {
|
export function useFile(
|
||||||
|
cateId: Ref<string | number>,
|
||||||
|
type: Ref<number>,
|
||||||
|
limit: Ref<number>,
|
||||||
|
size: number
|
||||||
|
) {
|
||||||
const tableRef = shallowRef()
|
const tableRef = shallowRef()
|
||||||
const listShowType = ref('normal')
|
const listShowType = ref('normal')
|
||||||
const moveId = ref(0)
|
const moveId = ref(0)
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,28 @@
|
||||||
|
/**
|
||||||
|
* perm 操作权限处理
|
||||||
|
* 指令用法:
|
||||||
|
* <el-button v-perms="['auth.menu/edit']">编辑</el-button>
|
||||||
|
*/
|
||||||
|
|
||||||
|
import feedback from '@/utils/feedback'
|
||||||
|
import useClipboard from 'vue-clipboard3'
|
||||||
|
const clipboard = 'data-clipboard-text'
|
||||||
|
export default {
|
||||||
|
mounted: (el: HTMLElement, binding: any) => {
|
||||||
|
el.setAttribute(clipboard, binding.value)
|
||||||
|
const { toClipboard } = useClipboard()
|
||||||
|
|
||||||
|
el.onclick = () => {
|
||||||
|
toClipboard(el.getAttribute(clipboard)!)
|
||||||
|
.then(() => {
|
||||||
|
feedback.msgSuccess('复制成功')
|
||||||
|
})
|
||||||
|
.catch(() => {
|
||||||
|
feedback.msgError('复制失败')
|
||||||
|
})
|
||||||
|
}
|
||||||
|
},
|
||||||
|
updated: (el: HTMLElement, binding: any) => {
|
||||||
|
el.setAttribute(clipboard, binding.value)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -27,7 +27,7 @@
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="访问链接">
|
<el-form-item label="访问链接">
|
||||||
<div>{{ formData.accessLink }}</div>
|
<div>{{ formData.accessLink }}</div>
|
||||||
<el-button class="ml-4" @click="copy(formData.accessLink)">复制</el-button>
|
<el-button class="ml-4" v-copy="formData.accessLink">复制</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
</el-card>
|
</el-card>
|
||||||
|
|
@ -39,7 +39,6 @@
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { getH5Config, setH5Config } from '@/api/channel/h5'
|
import { getH5Config, setH5Config } from '@/api/channel/h5'
|
||||||
import feedback from '@/utils/feedback'
|
import feedback from '@/utils/feedback'
|
||||||
import { useClipboard } from '@vueuse/core'
|
|
||||||
|
|
||||||
const formData = reactive({
|
const formData = reactive({
|
||||||
status: 0,
|
status: 0,
|
||||||
|
|
@ -48,7 +47,7 @@ const formData = reactive({
|
||||||
accessLink: ''
|
accessLink: ''
|
||||||
})
|
})
|
||||||
|
|
||||||
const { copy } = useClipboard()
|
// const { copy } = useClipboard()
|
||||||
const getDetail = async () => {
|
const getDetail = async () => {
|
||||||
const data = await getH5Config()
|
const data = await getH5Config()
|
||||||
for (const key in formData) {
|
for (const key in formData) {
|
||||||
|
|
|
||||||
|
|
@ -36,7 +36,7 @@
|
||||||
<el-table-column label="用户编号" prop="sn" min-width="120" />
|
<el-table-column label="用户编号" prop="sn" min-width="120" />
|
||||||
<el-table-column label="头像" min-width="100">
|
<el-table-column label="头像" min-width="100">
|
||||||
<template #default="{ row }">
|
<template #default="{ row }">
|
||||||
<el-avatar :src="row.image" :size="50" />
|
<el-avatar :src="row.avatar" :size="50" />
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="昵称" prop="nickname" min-width="100" />
|
<el-table-column label="昵称" prop="nickname" min-width="100" />
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue