提现功能需要添加

This commit is contained in:
bobobobo
2026-01-04 23:35:06 +08:00
parent a4ae562396
commit 42eba945e8
58 changed files with 4825 additions and 1015 deletions

View File

@@ -28,6 +28,12 @@
default: () => []
})
/** 图片回显列表 */
const fileLists = defineModel('list', {
type: Array,
default: () => []
})
/** 是否为身份证状态 */
const isIdCard = computed(() => props.isFront || props.isBack)
@@ -61,25 +67,31 @@
}
const onSelect = async e => {
e.tempFiles.forEach(v => {
uploadFile(v.path)
})
return
const upData = e.tempFiles.map(v => v.path)[0]
imageValue.value = await uploadSingleFile(upData, {
url: '/api/common/admin/upload/up/single'
})
if (props.limit === '1') {
const upData = e.tempFiles.map(v => v.path)[0]
imageValue.value = await uploadSingleFile(upData, {
url: '/api/common/admin/upload/up/single'
})
} else {
e.tempFiles.forEach(v => {
uploadFile(v.path)
})
}
}
const onDelete = e => {
imageValue.value.splice(e.index, 1)
if (props.limit === '1') {
imageValue.value = ''
} else {
imageValue.value.splice(e.index, 1)
}
}
</script>
<template>
<view :class="{ 'file_card-box': isIdCard }" class="cb-file-picker">
<uni-file-picker
v-model="fileLists"
:file-mediatype="props.type"
:image-styles="imageStyles"
:limit="props.limit"