修复小区背景颜色,巡检点顺序一致,投诉处理按钮
This commit is contained in:
@@ -179,6 +179,7 @@
|
||||
:on-progress="handleFileUploadProgress"
|
||||
:on-success="handleFileSuccess"
|
||||
:auto-upload="false"
|
||||
:on-change="handleChangeFile"
|
||||
drag
|
||||
>
|
||||
<el-icon class="el-icon--upload">
|
||||
@@ -214,6 +215,7 @@ import { checkPermi } from '@/utils/permission';
|
||||
import { useUserStore } from '@/store/modules/user';
|
||||
import { getCommunitylistAPI } from '@/api/system/community';
|
||||
import { communitylist_rows_type } from '@/api/system/community/type';
|
||||
import { UploadRawFile } from 'element-plus';
|
||||
|
||||
const router = useRouter();
|
||||
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
|
||||
@@ -464,6 +466,14 @@ const handleFileSuccess = (response: any, file: UploadFile) => {
|
||||
});
|
||||
getList();
|
||||
};
|
||||
const forbidSuffix = ['exe', 'msi', 'bat', 'cmd', 'sh', 'apk', 'dmg', 'zip', 'rar', '7z', 'tar', 'gz'];
|
||||
const handleChangeFile = (uploadFile: UploadFile) => {
|
||||
const type = uploadFile.raw.name.split('.')[1];
|
||||
if (forbidSuffix.includes(type)) {
|
||||
ElMessage.warning('不允许上传exe、安装包等文件');
|
||||
return;
|
||||
}
|
||||
};
|
||||
|
||||
/** 提交上传文件 */
|
||||
function submitFileForm() {
|
||||
|
||||
Reference in New Issue
Block a user