fix 组件优化,搜索按钮修复
This commit is contained in:
parent
07b69bfc71
commit
b6674e0667
@ -1,7 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "vue-next-admin",
|
"name": "vue-next-admin",
|
||||||
"version": "2.4.33",
|
"version": "2.4.33",
|
||||||
"GFastVersion": "2.3.0",
|
|
||||||
"description": "vue3 vite next admin template",
|
"description": "vue3 vite next admin template",
|
||||||
"author": "lyt_20201208",
|
"author": "lyt_20201208",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
|
@ -76,7 +76,7 @@ export function uploadPart(data:Object,progress:Callback,cancelToken:CancelToken
|
|||||||
}
|
}
|
||||||
})*/
|
})*/
|
||||||
return axios({
|
return axios({
|
||||||
url: baseURL+'/api/v1/system/upload/uploadPart',
|
url: baseURL+'api/v1/system/upload/uploadPart',
|
||||||
method: 'post',
|
method: 'post',
|
||||||
data:data,
|
data:data,
|
||||||
headers: {
|
headers: {
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
</el-upload>
|
</el-upload>
|
||||||
|
|
||||||
<el-dialog v-model="dialogVisible">
|
<el-dialog v-model="dialogVisible">
|
||||||
<img w-full :src="dialogImageUrl" alt="Preview Image" />
|
<el-image :src="dialogImageUrl" fit="contain" />
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
<div class="up-img" v-else>
|
<div class="up-img" v-else>
|
||||||
|
@ -8,7 +8,11 @@
|
|||||||
v-model:file-list="dataFileList"
|
v-model:file-list="dataFileList"
|
||||||
ref="upImageRef"
|
ref="upImageRef"
|
||||||
:list-type="fileType=='image'?'picture-card':'text'"
|
:list-type="fileType=='image'?'picture-card':'text'"
|
||||||
|
:on-preview="handlePictureCardPreview"
|
||||||
></el-upload>
|
></el-upload>
|
||||||
|
<el-dialog v-model="dialogVisible">
|
||||||
|
<el-image :src="dialogImageUrl" fit="contain" />
|
||||||
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
<el-dialog title="选择文件" v-model="isShowDialog" width="1000px" :close-on-click-modal="false" :destroy-on-close="true">
|
<el-dialog title="选择文件" v-model="isShowDialog" width="1000px" :close-on-click-modal="false" :destroy-on-close="true">
|
||||||
<el-card shadow="hover">
|
<el-card shadow="hover">
|
||||||
@ -159,7 +163,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import {toRefs, reactive, ref, computed,getCurrentInstance} from 'vue';
|
import {toRefs, reactive, ref, computed,getCurrentInstance} from 'vue';
|
||||||
import {FormInstance, UploadUserFile} from 'element-plus';
|
import {FormInstance, type UploadProps, UploadUserFile} from 'element-plus';
|
||||||
import {
|
import {
|
||||||
listSysAttachment,
|
listSysAttachment,
|
||||||
} from "/@/api/system/sysAttachment";
|
} from "/@/api/system/sysAttachment";
|
||||||
@ -213,6 +217,8 @@ const isShowDialog = ref(false)
|
|||||||
const loading = ref(false)
|
const loading = ref(false)
|
||||||
const queryRef = ref()
|
const queryRef = ref()
|
||||||
const editRef = ref();
|
const editRef = ref();
|
||||||
|
const dialogImageUrl = ref('')
|
||||||
|
const dialogVisible = ref(false)
|
||||||
// 是否显示所有搜索选项
|
// 是否显示所有搜索选项
|
||||||
const showAll = ref(false)
|
const showAll = ref(false)
|
||||||
// 非单个禁用
|
// 非单个禁用
|
||||||
@ -335,6 +341,10 @@ const reset = ()=>{
|
|||||||
resetQuery(queryRef.value)
|
resetQuery(queryRef.value)
|
||||||
state.ids = []
|
state.ids = []
|
||||||
}
|
}
|
||||||
|
const handlePictureCardPreview: UploadProps['onPreview'] = (uploadFile) => {
|
||||||
|
dialogImageUrl.value = uploadFile.url!
|
||||||
|
dialogVisible.value = true
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.system-sysAttachment-container{
|
.system-sysAttachment-container{
|
||||||
|
@ -105,7 +105,7 @@ const onHandleSelect = (item: any) => {
|
|||||||
const onSearchBlur = () => {
|
const onSearchBlur = () => {
|
||||||
closeSearch();
|
closeSearch();
|
||||||
};
|
};
|
||||||
|
defineExpose({openSearch})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped lang="scss">
|
<style scoped lang="scss">
|
||||||
|
@ -205,7 +205,7 @@ const handleUserScope = ((row:any)=>{
|
|||||||
setRole.value = row.id
|
setRole.value = row.id
|
||||||
getUsersById(row.id).then((res:any)=>{
|
getUsersById(row.id).then((res:any)=>{
|
||||||
ld.close()
|
ld.close()
|
||||||
roleUsers.value=res.data.userList??[]
|
roleUsers.value=res.data.userList?res.data.userList.map((user:any)=>user.id):[]
|
||||||
selectUserRef.value.openDialog()
|
selectUserRef.value.openDialog()
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user