Commit c59b9fbcad93429984428c7a15ac8c202784ed5f
1 parent
7b3b5f0d
修复bug
Showing
28 changed files
with
1526 additions
and
1255 deletions
trash-admin/src/main/resources/application-dev.yml
| ... | ... | @@ -10,17 +10,16 @@ trash: |
| 10 | 10 | demoEnabled: true |
| 11 | 11 | # 文件路径 示例( Windows配置D:/trash/uploadPath,Linux配置 /home/trash/uploadPath,存储桶 trash/uploadPath,nginx配置 /trash/upload) |
| 12 | 12 | # profile: E:/trash/uploadPath |
| 13 | - profile: c:/work/uploadPath/trash | |
| 13 | + profile: D:/work/project/Documents/uploadPath/trash | |
| 14 | 14 | # 获取ip地址开关 |
| 15 | 15 | addressEnabled: false |
| 16 | 16 | # 验证码类型 math 数组计算 char 字符验证 |
| 17 | 17 | captchaType: math |
| 18 | 18 | # 远程服务器地址 |
| 19 | - #remotePath: http://175.6.47.84:8008 | |
| 20 | - #token: durable:auth:token:eyJhbGciOiJIUzUxMiJ9.eyJ5ZWEiOiJjc3poIiwiZXhwIjo0MTAyNDE1OTk5LCJjcmVhdGVkIjoxNjg0MzI3NzQ1ODkyfQ.4BrpgD9i_1TwjLRGqa3wo4Ikx8t8Gcl3FzHfjL_uolPnNMm2rd7fCvrUoBBN4Qp4cMGzg9h2Nt4NNx8PYThTaQ | |
| 19 | +# remotePath: http://183.66.242.6:6001 | |
| 21 | 20 | remotePath: http://183.66.242.6:14601 |
| 22 | - token: durable:auth:token:eyJhbGciOiJIUzUxMiJ9.eyJ5ZWEiOiJjc3poIiwiZXhwIjo0MTAyNDE1OTk5LCJjcmVhdGVkIjoxNjg0NDU5MjEzNzQ2fQ.85oIrOnU7cz7L_-IGt4Bt1LXDTkFtyrdqNt05K0v9-4nsrrzzpbjbemK-yMlbnUpe4Fx2FFES-Wbw8Yr8ML69w | |
| 23 | - | |
| 21 | + token: auth:token:eyJhbGciOiJIUzUxMiJ9.eyJ5ZWEiOiJjc3poIiwiZXhwIjoxNjg2MjcwMTcyLCJjcmVhdGVkIjoxNjg2MjEwMTcyODk2fQ.T_azsalyEnb1dukZ0CghG2GfQt3M41zwi18sutPXhjM8hYfca74WWJT6kXETFaUbOHICWp-OcEqydHhVE-Ewjg | |
| 22 | + | |
| 24 | 23 | # 数据源配置 |
| 25 | 24 | spring: |
| 26 | 25 | datasource: |
| ... | ... | @@ -31,7 +30,7 @@ spring: |
| 31 | 30 | master: |
| 32 | 31 | url: jdbc:mysql://localhost:3306/trash?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true |
| 33 | 32 | username: root |
| 34 | - password: root | |
| 33 | + password: asd0731. | |
| 35 | 34 | # 从库数据源 |
| 36 | 35 | slave: |
| 37 | 36 | # 从数据源开关/默认关闭 |
| ... | ... | @@ -85,7 +84,7 @@ spring: |
| 85 | 84 | # 端口,默认为6379 |
| 86 | 85 | port: 6379 |
| 87 | 86 | # 密码 |
| 88 | - password: | |
| 87 | + password: bsth123 | |
| 89 | 88 | # 连接超时时间 |
| 90 | 89 | timeout: 10s |
| 91 | 90 | database: 10 | ... | ... |
trash-admin/src/main/resources/logback.xml
| ... | ... | @@ -2,7 +2,7 @@ |
| 2 | 2 | <configuration> |
| 3 | 3 | <!-- 日志存放路径 --> |
| 4 | 4 | <!-- <property name="log.path" value="/home/trash/logs" />--> |
| 5 | - <property name="log.path" value="C:/work/project/logs/trash" /> | |
| 5 | + <property name="log.path" value="D:/work/project/logs/trash" /> | |
| 6 | 6 | <!-- 日志输出格式 --> |
| 7 | 7 | <property name="log.pattern" value="%d{HH:mm:ss.SSS} [%thread] %-5level %logger{20} - [%method,%line] - %msg%n" /> |
| 8 | 8 | ... | ... |
trash-ui/package.json
trash-ui/src/api/leave.js
| ... | ... | @@ -87,9 +87,38 @@ export default { |
| 87 | 87 | openInfo: false, |
| 88 | 88 | idInfo: null, |
| 89 | 89 | fileEntityList:[], |
| 90 | - depts:[] | |
| 90 | + depts:[], | |
| 91 | + slide1: [] | |
| 91 | 92 | }; |
| 92 | 93 | }, |
| 94 | + watch: { | |
| 95 | + fileEntityList(value) { | |
| 96 | + this.slide1 = [] | |
| 97 | + if (this.fileEntityList.length != 0) { | |
| 98 | + this.fileEntityList.map(item => { | |
| 99 | + if (item.name.indexOf(".jpg") > -1 || item.name.indexOf(".png") > -1 || item.name.indexOf(".jpeg") > -1 || item.name.indexOf(".jpg") > -1) { | |
| 100 | + if(item.raw!=null){ | |
| 101 | + this.slide1.push({ | |
| 102 | + src: URL.createObjectURL(item.raw), | |
| 103 | + msrc: URL.createObjectURL(item.raw), | |
| 104 | + alt: item.uid, | |
| 105 | + w: 1920, | |
| 106 | + h: 1080 | |
| 107 | + }); | |
| 108 | + }else{ | |
| 109 | + this.slide1.push({ | |
| 110 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 111 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 112 | + w: 1920, | |
| 113 | + h: 1080 | |
| 114 | + }); | |
| 115 | + } | |
| 116 | + } | |
| 117 | + }) | |
| 118 | + } | |
| 119 | + | |
| 120 | + } | |
| 121 | + }, | |
| 93 | 122 | created() { |
| 94 | 123 | let dep = {type:"CSUserDepartmentType"}; |
| 95 | 124 | getDict(dep).then(res=>{ |
| ... | ... | @@ -300,6 +329,7 @@ export default { |
| 300 | 329 | // 删除文件 |
| 301 | 330 | handleDeleteFile(index) { |
| 302 | 331 | this.fileEntityList.splice(index, 1); |
| 332 | + this.slide1.splice(index, 1); | |
| 303 | 333 | }, |
| 304 | 334 | /** 文件下载 */ |
| 305 | 335 | downloadFA(row) { | ... | ... |
trash-ui/src/api/three_step.js
| 1 | - import { | |
| 2 | - listThreestep, | |
| 3 | - getThreestep, | |
| 4 | - delThreestep, | |
| 5 | - addThreestep, | |
| 6 | - updateThreestep, | |
| 7 | - exportThreestep, | |
| 8 | - getNames | |
| 9 | - } from "@/api/business/threestep"; | |
| 10 | - | |
| 11 | - | |
| 12 | - | |
| 13 | - import threestepInfo from "@/views/business/threestep/threestepInfo"; | |
| 14 | - | |
| 15 | - import h5Info from "@/views/h5/task/threestepInfo"; | |
| 16 | - import h5Page from '@/views/h5/Pagination'; | |
| 17 | - | |
| 18 | - import { | |
| 19 | - Upload | |
| 20 | - } from "element-ui"; | |
| 21 | - import { | |
| 22 | - getToken | |
| 23 | - } from "@/utils/auth"; | |
| 24 | - | |
| 25 | - import { | |
| 26 | - earthsitesList, | |
| 27 | - constructionsitesList, | |
| 28 | - getDict, | |
| 29 | - getArea, | |
| 30 | - mainworkcompany, | |
| 31 | - truckList, | |
| 32 | - companyList, | |
| 33 | - contractList, | |
| 34 | - getConstructionTruck, | |
| 35 | - } from "@/api/dict"; | |
| 36 | - | |
| 37 | - export default { | |
| 38 | - name: "Threestep", | |
| 39 | - components: { | |
| 40 | - threestepInfo, | |
| 41 | - h5Info, | |
| 42 | - | |
| 43 | - h5Page | |
| 44 | - }, | |
| 45 | - data() { | |
| 46 | - return { | |
| 47 | - // 遮罩层 | |
| 48 | - loading: true, | |
| 49 | - reUpdate : false, | |
| 50 | - info: false, | |
| 51 | - infoData: null, | |
| 52 | - businessKey:null, | |
| 53 | - picSample: false, | |
| 54 | - uploadImageDialog: false, | |
| 55 | - // 选中数组 | |
| 56 | - ids: [], | |
| 57 | - // 非单个禁用 | |
| 58 | - single: true, | |
| 59 | - // 非多个禁用 | |
| 60 | - multiple: true, | |
| 61 | - // 显示搜索条件 | |
| 62 | - showSearch: true, | |
| 63 | - // 总条数 | |
| 64 | - total: 0, | |
| 65 | - // 报工自查表格数据 | |
| 66 | - names:[], | |
| 67 | - threestepList: [], | |
| 68 | - fileList: [], | |
| 69 | - companyList:[], | |
| 70 | - truckList:[], | |
| 71 | - contractList:[], | |
| 72 | - // 弹出层标题 | |
| 73 | - title: "", | |
| 74 | - labelName: "工地名称", | |
| 75 | - labelName2: "绑定消纳场", | |
| 76 | - upload: { | |
| 77 | - // 是否显示弹出层(用户导入) | |
| 78 | - open: false, | |
| 79 | - // 弹出层标题(用户导入) | |
| 80 | - title: "", | |
| 81 | - // 是否禁用上传 | |
| 82 | - isUploading: false, | |
| 83 | - // 设置上传的请求头部 | |
| 84 | - headers: { | |
| 85 | - Authorization: "Bearer " + getToken() | |
| 86 | - }, | |
| 87 | - // 上传的地址 | |
| 88 | - url: process.env.VUE_APP_BASE_API + "/business/threestep/upload", | |
| 89 | - }, | |
| 90 | - // 是否显示弹出层 | |
| 1 | +import { | |
| 2 | + listThreestep, | |
| 3 | + getThreestep, | |
| 4 | + delThreestep, | |
| 5 | + addThreestep, | |
| 6 | + updateThreestep, | |
| 7 | + exportThreestep, | |
| 8 | + getNames | |
| 9 | +} from "@/api/business/threestep"; | |
| 10 | + | |
| 11 | + | |
| 12 | +import threestepInfo from "@/views/business/threestep/threestepInfo"; | |
| 13 | + | |
| 14 | +import h5Info from "@/views/h5/task/threestepInfo"; | |
| 15 | +import h5Page from '@/views/h5/Pagination'; | |
| 16 | + | |
| 17 | +import { | |
| 18 | + Upload | |
| 19 | +} from "element-ui"; | |
| 20 | +import { | |
| 21 | + getToken | |
| 22 | +} from "@/utils/auth"; | |
| 23 | + | |
| 24 | +import { | |
| 25 | + earthsitesList, | |
| 26 | + constructionsitesList, | |
| 27 | + getDict, | |
| 28 | + getArea, | |
| 29 | + mainworkcompany, | |
| 30 | + truckList, | |
| 31 | + companyList, | |
| 32 | + contractList, | |
| 33 | + getConstructionTruck, | |
| 34 | +} from "@/api/dict"; | |
| 35 | + | |
| 36 | +export default { | |
| 37 | + name: "Threestep", | |
| 38 | + components: { | |
| 39 | + threestepInfo, | |
| 40 | + h5Info, | |
| 41 | + | |
| 42 | + h5Page | |
| 43 | + }, | |
| 44 | + data() { | |
| 45 | + return { | |
| 46 | + // 遮罩层 | |
| 47 | + loading: true, | |
| 48 | + reUpdate: false, | |
| 49 | + info: false, | |
| 50 | + infoData: null, | |
| 51 | + businessKey: null, | |
| 52 | + picSample: false, | |
| 53 | + uploadImageDialog: false, | |
| 54 | + // 选中数组 | |
| 55 | + ids: [], | |
| 56 | + // 非单个禁用 | |
| 57 | + single: true, | |
| 58 | + // 非多个禁用 | |
| 59 | + multiple: true, | |
| 60 | + // 显示搜索条件 | |
| 61 | + showSearch: true, | |
| 62 | + // 总条数 | |
| 63 | + total: 0, | |
| 64 | + // 报工自查表格数据 | |
| 65 | + names: [], | |
| 66 | + threestepList: [], | |
| 67 | + fileList: [], | |
| 68 | + companyList: [], | |
| 69 | + truckList: [], | |
| 70 | + contractList: [], | |
| 71 | + // 弹出层标题 | |
| 72 | + title: "", | |
| 73 | + labelName: "工地名称", | |
| 74 | + labelName2: "绑定消纳场", | |
| 75 | + upload: { | |
| 76 | + // 是否显示弹出层(用户导入) | |
| 91 | 77 | open: false, |
| 92 | - // 查询参数 | |
| 93 | - queryParams: { | |
| 94 | - pageStatus:0,//当前处于哪一个tag | |
| 95 | - pageNum: 1, | |
| 96 | - pageSize: 10, | |
| 97 | - name: null, | |
| 98 | - type: null, | |
| 99 | - place: null, | |
| 100 | - selfCheckTime: null, | |
| 101 | - objectId: null, | |
| 102 | - earthsitesId: null, | |
| 103 | - checkTime: null, | |
| 104 | - earthsitesName: null, | |
| 105 | - contract: null, | |
| 106 | - companys: null, | |
| 107 | - companyTrucks: null, | |
| 108 | - status:null, | |
| 109 | - workStartTime:null, | |
| 110 | - workEndTime:null, | |
| 78 | + // 弹出层标题(用户导入) | |
| 79 | + title: "", | |
| 80 | + // 是否禁用上传 | |
| 81 | + isUploading: false, | |
| 82 | + // 设置上传的请求头部 | |
| 83 | + headers: { | |
| 84 | + Authorization: "Bearer " + getToken() | |
| 111 | 85 | }, |
| 112 | - // 表单参数 | |
| 113 | - form: { | |
| 114 | - companys:null, | |
| 115 | - companyTrucks:null, | |
| 86 | + // 上传的地址 | |
| 87 | + url: process.env.VUE_APP_BASE_API + "/business/threestep/upload", | |
| 88 | + }, | |
| 89 | + // 是否显示弹出层 | |
| 90 | + open: false, | |
| 91 | + // 查询参数 | |
| 92 | + queryParams: { | |
| 93 | + pageStatus: 0,//当前处于哪一个tag | |
| 94 | + pageNum: 1, | |
| 95 | + pageSize: 10, | |
| 96 | + name: null, | |
| 97 | + type: null, | |
| 98 | + place: null, | |
| 99 | + selfCheckTime: null, | |
| 100 | + objectId: null, | |
| 101 | + earthsitesId: null, | |
| 102 | + checkTime: null, | |
| 103 | + earthsitesName: null, | |
| 104 | + contract: null, | |
| 105 | + companys: null, | |
| 106 | + companyTrucks: null, | |
| 107 | + status: null, | |
| 108 | + workStartTime: null, | |
| 109 | + workEndTime: null, | |
| 110 | + }, | |
| 111 | + // 表单参数 | |
| 112 | + form: { | |
| 113 | + companys: null, | |
| 114 | + companyTrucks: null, | |
| 116 | 115 | |
| 116 | + }, | |
| 117 | + picIndex: null, | |
| 118 | + // 表单校验 | |
| 119 | + rules: { | |
| 120 | + name: [{ | |
| 121 | + required: true, | |
| 122 | + message: '请填写完整', | |
| 123 | + trigger: 'change' | |
| 124 | + },], | |
| 125 | + contract: [{ | |
| 126 | + required: true, | |
| 127 | + message: '请填写完整', | |
| 128 | + trigger: 'change' | |
| 129 | + },], | |
| 130 | + type: [{ | |
| 131 | + required: true, | |
| 132 | + message: '请填写完整', | |
| 133 | + trigger: 'change' | |
| 134 | + },], | |
| 135 | + place: [{ | |
| 136 | + required: true, | |
| 137 | + message: '请填写完整', | |
| 138 | + trigger: 'change' | |
| 139 | + },], | |
| 140 | + companys: [{ | |
| 141 | + required: false, | |
| 142 | + message: '请填写完整', | |
| 143 | + trigger: 'change' | |
| 144 | + },], | |
| 145 | + companyTrucks: [{ | |
| 146 | + required: false, | |
| 147 | + message: '请填写完整', | |
| 148 | + trigger: 'change' | |
| 149 | + },], | |
| 150 | + objectId: [{ | |
| 151 | + required: true, | |
| 152 | + message: '请填写完整', | |
| 153 | + trigger: 'change' | |
| 154 | + },], | |
| 155 | + person: [{ | |
| 156 | + required: true, | |
| 157 | + message: '请填写完整', | |
| 158 | + trigger: 'change' | |
| 159 | + },], | |
| 160 | + phone: [{ | |
| 161 | + required: true, | |
| 162 | + message: '请填写完整', | |
| 163 | + trigger: 'change' | |
| 117 | 164 | }, |
| 118 | - picIndex: null, | |
| 119 | - // 表单校验 | |
| 120 | - rules: { | |
| 121 | - name: [{ | |
| 122 | - required: true, | |
| 123 | - message: '请填写完整', | |
| 124 | - trigger: 'change' | |
| 125 | - }, ], | |
| 126 | - contract: [{ | |
| 127 | - required: true, | |
| 128 | - message: '请填写完整', | |
| 165 | + { | |
| 166 | + pattern: /^1(3|4|5|7|8|9)\d{9}$/, | |
| 167 | + message: '手机号格式错误', | |
| 129 | 168 | trigger: 'change' |
| 130 | - }, ], | |
| 131 | - objectId: [{ | |
| 132 | - required: true, | |
| 133 | - message: '请填写完整', | |
| 134 | - trigger: 'change' | |
| 135 | - }, ], | |
| 136 | - type: [{ | |
| 137 | - required: true, | |
| 138 | - message: '请填写完整', | |
| 139 | - trigger: 'change' | |
| 140 | - }, ], | |
| 141 | - place: [{ | |
| 142 | - required: true, | |
| 143 | - message: '请填写完整', | |
| 144 | - trigger: 'change' | |
| 145 | - }, ], | |
| 146 | - companys: [{ | |
| 147 | - required: false, | |
| 148 | - message: '请填写完整', | |
| 149 | - trigger: 'change' | |
| 150 | - }, ], | |
| 151 | - companyTrucks: [{ | |
| 152 | - required: false, | |
| 153 | - message: '请填写完整', | |
| 154 | - trigger: 'change' | |
| 155 | - }, ], | |
| 156 | - objectId: [{ | |
| 157 | - required: true, | |
| 158 | - message: '请填写完整', | |
| 159 | - trigger: 'change' | |
| 160 | - }, ], | |
| 161 | - person: [{ | |
| 162 | - required: true, | |
| 163 | - message: '请填写完整', | |
| 164 | - trigger: 'change' | |
| 165 | - }, ], | |
| 166 | - phone: [{ | |
| 167 | - required: true, | |
| 168 | - message: '请填写完整', | |
| 169 | - trigger: 'change' | |
| 170 | - }, | |
| 171 | - { | |
| 172 | - pattern: /^1(3|4|5|7|8|9)\d{9}$/, | |
| 173 | - message: '手机号格式错误', | |
| 174 | - trigger: 'change' | |
| 175 | - }, | |
| 176 | - ] | |
| 177 | - }, | |
| 178 | - SiteWorkAreaCodeType: [], | |
| 179 | - remoteData: [], | |
| 180 | - remoteQueryData: { | |
| 181 | - "page": 1, | |
| 182 | - "size": 9999, | |
| 183 | - "auditStatus":1, | |
| 184 | - "creditStatus":0, | |
| 185 | - }, | |
| 186 | - areas: [], | |
| 187 | - areaCode: null, | |
| 188 | - bindData: [], | |
| 189 | - bindname:null, | |
| 190 | - info2:false, | |
| 191 | - | |
| 192 | - }; | |
| 193 | - }, | |
| 194 | - created() { | |
| 195 | - if(window.location.search){ | |
| 196 | - let arr = window.location.search.split("&"); | |
| 197 | - if(arr[0].split("=")[0] != "?token") | |
| 198 | - this.queryParams.pageStatus = arr[0].split("=")[1]; | |
| 199 | - } | |
| 169 | + }, | |
| 170 | + ] | |
| 171 | + }, | |
| 172 | + SiteWorkAreaCodeType: [], | |
| 173 | + remoteData: [], | |
| 174 | + remoteQueryData: { | |
| 175 | + "page": 1, | |
| 176 | + "size": 9999, | |
| 177 | + "auditStatus": 1, | |
| 178 | + "creditStatus": 0, | |
| 179 | + }, | |
| 180 | + areas: [], | |
| 181 | + areaCode: null, | |
| 182 | + bindData: [], | |
| 183 | + bindname: null, | |
| 184 | + info2: false, | |
| 185 | + slides: [], | |
| 186 | + slidesArys: [], | |
| 187 | + }; | |
| 188 | + }, | |
| 189 | + created() { | |
| 190 | + if (window.location.search) { | |
| 191 | + let arr = window.location.search.split("&"); | |
| 192 | + if (arr[0].split("=")[0] != "?token") | |
| 193 | + this.queryParams.pageStatus = arr[0].split("=")[1]; | |
| 194 | + } | |
| 200 | 195 | |
| 201 | 196 | |
| 202 | - getArea().then(res => { | |
| 203 | - this.areas = res.result; | |
| 204 | - for(let i =0;i< this.threestepList.length;i++){ | |
| 205 | - this.threestepList[i].place = this.getAreaName(this.threestepList[i].place); | |
| 197 | + getArea().then(res => { | |
| 198 | + this.areas = res.result; | |
| 199 | + for (let i = 0; i < this.threestepList.length; i++) { | |
| 200 | + this.threestepList[i].place = this.getAreaName(this.threestepList[i].place); | |
| 201 | + } | |
| 202 | + }); | |
| 203 | + | |
| 204 | + this.getList(this.queryParams.pageStatus); | |
| 205 | + | |
| 206 | + }, | |
| 207 | + methods: { | |
| 208 | + conractCheck(value) { | |
| 209 | + let item | |
| 210 | + for (let i in this.contractList) { | |
| 211 | + if (this.contractList[i].contractNo == value) { | |
| 212 | + item = this.contractList[i]; | |
| 213 | + break; | |
| 206 | 214 | } |
| 207 | - }); | |
| 215 | + } | |
| 208 | 216 | |
| 209 | - this.getList(this.queryParams.pageStatus); | |
| 210 | 217 | |
| 211 | - }, | |
| 212 | - methods: { | |
| 213 | - conractCheck(value){ | |
| 214 | - let item | |
| 215 | - for(let i in this.contractList){ | |
| 216 | - if(this.contractList[i].contractNo == value){ | |
| 217 | - item = this.contractList[i]; | |
| 218 | - break; | |
| 219 | - } | |
| 220 | - } | |
| 218 | + if (new Date(item.endTime).getTime() < new Date().getTime()) { | |
| 219 | + this.form.contract = null; | |
| 220 | + this.$message("合同已过期"); | |
| 221 | + return; | |
| 222 | + } | |
| 223 | + if (new Date(item.startTime).getTime() > new Date().getTime()) { | |
| 224 | + this.form.contract = null; | |
| 225 | + this.$message("合同未生效"); | |
| 226 | + return; | |
| 227 | + } | |
| 221 | 228 | |
| 229 | + if (this.form.type == 0) { | |
| 230 | + this.form.name = item.constructionSiteName; | |
| 231 | + this.form.objectId = item.constructionSiteID; | |
| 232 | + this.form.earthsitesName = item.earthSiteName; | |
| 233 | + this.form.earthsitesId = item.earthSiteID; | |
| 222 | 234 | |
| 223 | - if(new Date(item.endTime).getTime() < new Date().getTime()){ | |
| 224 | - this.form.contract = null; | |
| 225 | - this.$message("合同已过期"); | |
| 226 | - return; | |
| 227 | - } | |
| 228 | - if(new Date(item.startTime).getTime() > new Date().getTime()){ | |
| 229 | - this.form.contract = null; | |
| 230 | - this.$message("合同未生效"); | |
| 231 | - return; | |
| 235 | + let constru; | |
| 236 | + for (let i in this.remoteData) { | |
| 237 | + if (this.remoteData[i].name == item.constructionSiteName) { | |
| 238 | + constru = this.remoteData[i]; | |
| 239 | + break; | |
| 240 | + } | |
| 232 | 241 | } |
| 233 | 242 | |
| 234 | - if(this.form.type == 0){ | |
| 235 | - this.form.name = item.constructionSiteName; | |
| 236 | - this.form.objectId = item.constructionSiteID; | |
| 237 | - this.form.earthsitesName = item.earthSiteName; | |
| 238 | - this.form.earthsitesId = item.earthSiteID; | |
| 239 | - | |
| 240 | - let constru; | |
| 241 | - for(let i in this.remoteData){ | |
| 242 | - if(this.remoteData[i].name == item.constructionSiteName){ | |
| 243 | - constru = this.remoteData[i]; | |
| 244 | - break; | |
| 245 | - } | |
| 246 | - } | |
| 243 | + this.filterCompany(constru); | |
| 244 | + | |
| 245 | + } else { | |
| 246 | + this.form.earthsitesName = item.constructionSiteName; | |
| 247 | + this.form.earthsitesId = item.constructionSiteID; | |
| 248 | + this.form.name = item.earthSiteName; | |
| 249 | + this.form.objectId = item.earthSiteID; | |
| 250 | + } | |
| 247 | 251 | |
| 248 | - this.filterCompany(constru); | |
| 252 | + for (let i = 0; i < this.remoteData.length; i++) { | |
| 249 | 253 | |
| 250 | - }else{ | |
| 251 | - this.form.earthsitesName = item.constructionSiteName; | |
| 252 | - this.form.earthsitesId = item.constructionSiteID; | |
| 253 | - this.form.name = item.earthSiteName; | |
| 254 | - this.form.objectId = item.earthSiteID; | |
| 254 | + if (this.remoteData[i].name == this.form.name) { | |
| 255 | + this.form.place = Number(this.remoteData[i].areaCode); | |
| 256 | + break; | |
| 255 | 257 | } |
| 258 | + } | |
| 259 | + | |
| 260 | + this.form.contractId = item.id; | |
| 261 | + this.bindname = this.form.earthsitesName; | |
| 262 | + }, | |
| 263 | + checkCompany(item) { | |
| 256 | 264 | |
| 257 | - for(let i =0;i<this.remoteData.length ;i++){ | |
| 265 | + let arr = []; | |
| 258 | 266 | |
| 259 | - if(this.remoteData[i].name == this.form.name){ | |
| 260 | - this.form.place = Number(this.remoteData[i].areaCode); | |
| 267 | + for (var i in this.form.companyTrucks) { | |
| 268 | + let truck = this.form.companyTrucks[i]; | |
| 269 | + for (let j in this.truckList) { | |
| 270 | + if (truck == this.truckList[j].id && item.indexOf(this.truckList[j].companyName) > -1) { | |
| 271 | + arr.push(truck) | |
| 261 | 272 | break; |
| 262 | 273 | } |
| 263 | 274 | } |
| 275 | + } | |
| 264 | 276 | |
| 265 | - this.form.contractId = item.id; | |
| 266 | - this.bindname = this.form.earthsitesName; | |
| 267 | - }, | |
| 268 | - checkCompany(item){ | |
| 277 | + this.form.companyTrucks = arr; | |
| 278 | + // for(let i = 0;) | |
| 269 | 279 | |
| 270 | - let arr = []; | |
| 280 | + // let arr = []; | |
| 281 | + // for(var i in this.form.companyTrucks){ | |
| 282 | + // if(this.form.companys.indexOf(this.form.companyTrucks[i]) > -1){ | |
| 283 | + // arr.push(this.form.companyTrucks[i]); | |
| 284 | + // } | |
| 285 | + // } | |
| 271 | 286 | |
| 272 | - for(var i in this.form.companyTrucks){ | |
| 273 | - let truck = this.form.companyTrucks[i]; | |
| 274 | - for(let j in this.truckList){ | |
| 275 | - if(truck == this.truckList[j].id && item.indexOf(this.truckList[j].companyName) > -1){ | |
| 276 | - arr.push(truck) | |
| 277 | - break; | |
| 278 | - } | |
| 279 | - } | |
| 280 | - } | |
| 287 | + // this.form.companyTrucks = arr; | |
| 288 | + }, | |
| 281 | 289 | |
| 282 | - this.form.companyTrucks = arr; | |
| 283 | - // for(let i = 0;) | |
| 290 | + areaClear() { | |
| 291 | + this.areaCode = null; | |
| 292 | + }, | |
| 293 | + selectArea(a) { | |
| 294 | + this.areaCode = a; | |
| 295 | + this.form.name = ""; | |
| 296 | + }, | |
| 297 | + getObjId(value) { | |
| 298 | + let item; | |
| 299 | + for (let i in this.remoteData) { | |
| 300 | + if (this.remoteData[i].name == value) { | |
| 301 | + item = this.remoteData[i]; | |
| 302 | + break; | |
| 303 | + } | |
| 304 | + } | |
| 305 | + this.form.earthsitesName = null; | |
| 306 | + this.form.earthsitesId = null; | |
| 307 | + this.form.contract = null; | |
| 308 | + this.form.contractId = null; | |
| 309 | + this.bindname = null; | |
| 310 | + | |
| 311 | + let name = this.form.earthsitesName; | |
| 312 | + let objId = this.form.earthsitesId; | |
| 313 | + | |
| 314 | + this.form.objectId = item.id; | |
| 315 | + this.form.place = Number(item.areaCode); | |
| 316 | + this.filterConract(); | |
| 317 | + | |
| 318 | + if (this.filterContract.length == 0) { | |
| 319 | + this.$message("未找到对应消纳合同"); | |
| 320 | + this.form.objectId = null; | |
| 321 | + this.form.name = null; | |
| 322 | + } | |
| 284 | 323 | |
| 285 | - // let arr = []; | |
| 286 | - // for(var i in this.form.companyTrucks){ | |
| 287 | - // if(this.form.companys.indexOf(this.form.companyTrucks[i]) > -1){ | |
| 288 | - // arr.push(this.form.companyTrucks[i]); | |
| 289 | - // } | |
| 290 | - // } | |
| 324 | + this.filterConract(); | |
| 291 | 325 | |
| 292 | - // this.form.companyTrucks = arr; | |
| 293 | - }, | |
| 326 | + for (let i in this.filterContract) { | |
| 327 | + if (this.filterContract[i].constructionSiteID == objId || this.filterContract[i].earthSiteID == objId) { | |
| 328 | + this.form.earthsitesName = name; | |
| 329 | + this.form.earthsitesId = objId; | |
| 330 | + break; | |
| 331 | + } | |
| 332 | + } | |
| 294 | 333 | |
| 295 | - areaClear() { | |
| 296 | - this.areaCode = null; | |
| 297 | - }, | |
| 298 | - selectArea(a) { | |
| 299 | - this.areaCode = a; | |
| 300 | - this.form.name = ""; | |
| 301 | - }, | |
| 302 | - getObjId(value) { | |
| 303 | - let item; | |
| 304 | - for(let i in this.remoteData){ | |
| 305 | - if(this.remoteData[i].name == value){ | |
| 306 | - item = this.remoteData[i]; | |
| 307 | - break; | |
| 308 | - } | |
| 334 | + if (this.form.type == 0) { | |
| 335 | + let query = { | |
| 336 | + 'page': 1, | |
| 337 | + 'size': 9999, | |
| 309 | 338 | } |
| 310 | - this.form.earthsitesName = null; | |
| 311 | - this.form.earthsitesId = null; | |
| 312 | - this.form.contract = null; | |
| 313 | - this.form.contractId = null; | |
| 314 | - this.bindname = null; | |
| 315 | - | |
| 316 | - let name = this.form.earthsitesName; | |
| 317 | - let objId = this.form.earthsitesId; | |
| 318 | - | |
| 319 | - this.form.objectId = item.id; | |
| 320 | - this.form.place = Number(item.areaCode); | |
| 321 | - this.filterConract(); | |
| 322 | - | |
| 323 | - if(this.filterContract.length == 0){ | |
| 324 | - this.$message("未找到对应消纳合同"); | |
| 325 | - this.form.objectId = null; | |
| 326 | - this.form.name = null; | |
| 327 | - } | |
| 328 | 339 | |
| 329 | - this.filterConract(); | |
| 330 | 340 | |
| 331 | - for(let i in this.filterContract){ | |
| 332 | - if(this.filterContract[i].constructionSiteID == objId || this.filterContract[i].earthSiteID == objId){ | |
| 333 | - this.form.earthsitesName = name; | |
| 334 | - this.form.earthsitesId = objId; | |
| 335 | - break; | |
| 336 | - } | |
| 337 | - } | |
| 341 | + this.filterCompany(item); | |
| 342 | + } | |
| 338 | 343 | |
| 339 | - if(this.form.type == 0){ | |
| 340 | - let query = { | |
| 341 | - 'page':1, | |
| 342 | - 'size':9999, | |
| 343 | - } | |
| 344 | + }, | |
| 345 | + filterCompany(item) { | |
| 346 | + this.form.companys = null; | |
| 347 | + this.form.companyTrucks = null; | |
| 348 | + this.companyList = []; | |
| 349 | + this.truckList = []; | |
| 344 | 350 | |
| 345 | - | |
| 351 | + mainworkcompany(item.id).then(response => { | |
| 346 | 352 | |
| 347 | - this.filterCompany(item); | |
| 348 | - } | |
| 353 | + this.companyList.push({id: item.transportCompanyId, name: item.transportCompany}); | |
| 349 | 354 | |
| 350 | - }, | |
| 351 | - filterCompany(item){ | |
| 352 | - this.form.companys = null; | |
| 353 | - this.form.companyTrucks = null; | |
| 354 | - this.companyList = []; | |
| 355 | - this.truckList = []; | |
| 356 | - | |
| 357 | - mainworkcompany(item.id).then(response => { | |
| 358 | - | |
| 359 | - this.companyList.push({id:item.transportCompanyId , name: item.transportCompany}); | |
| 360 | - | |
| 361 | - let query = { | |
| 362 | - 'page':1, | |
| 363 | - 'size':9999, | |
| 364 | - 'dishonestState':0, | |
| 365 | - 'valid':0 | |
| 366 | - } | |
| 355 | + let query = { | |
| 356 | + 'page': 1, | |
| 357 | + 'size': 9999, | |
| 358 | + 'dishonestState': 0, | |
| 359 | + 'valid': 0 | |
| 360 | + } | |
| 367 | 361 | |
| 368 | - let ids = []; | |
| 362 | + let ids = []; | |
| 369 | 363 | |
| 370 | - ids.push(item.transportCompanyId); | |
| 364 | + ids.push(item.transportCompanyId); | |
| 371 | 365 | |
| 372 | - query.companyID = ids +""; | |
| 373 | - query.valid = 0; | |
| 366 | + query.companyID = ids + ""; | |
| 367 | + query.valid = 0; | |
| 374 | 368 | |
| 375 | - getConstructionTruck(item.id).then(res=>{ | |
| 376 | - for(let i in res.result){ | |
| 377 | - this.companyList.push({id:res.result[i].companyId , name: res.result[i].companyName}); | |
| 378 | - for(let j in res.result[i].vehicleList){ | |
| 379 | - this.truckList.push({id:res.result[i].vehicleList[j].id,licenseplateNo:res.result[i].vehicleList[j].licenseplateNo,companyName:res.result[i].companyName}); | |
| 380 | - } | |
| 369 | + getConstructionTruck(item.id).then(res => { | |
| 370 | + for (let i in res.result) { | |
| 371 | + this.companyList.push({id: res.result[i].companyId, name: res.result[i].companyName}); | |
| 372 | + for (let j in res.result[i].vehicleList) { | |
| 373 | + this.truckList.push({ | |
| 374 | + id: res.result[i].vehicleList[j].id, | |
| 375 | + licenseplateNo: res.result[i].vehicleList[j].licenseplateNo, | |
| 376 | + companyName: res.result[i].companyName | |
| 377 | + }); | |
| 378 | + } | |
| 379 | + } | |
| 380 | + truckList(query).then(res => { | |
| 381 | + for (let i in res.result.list) { | |
| 382 | + this.truckList.push(res.result.list[i]); | |
| 381 | 383 | } |
| 382 | - truckList(query).then(res=>{ | |
| 383 | - for(let i in res.result.list){ | |
| 384 | - this.truckList.push(res.result.list[i]); | |
| 385 | - } | |
| 386 | - }); | |
| 387 | - | |
| 388 | 384 | }); |
| 389 | - }); | |
| 390 | - }, | |
| 391 | - filterConract(){ | |
| 392 | - let cId; | |
| 393 | - let eId; | |
| 394 | - if(this.form.type == 0){ | |
| 395 | - cId = this.form.objectId; | |
| 396 | - eId = this.form.earthsitesId; | |
| 397 | - }else{ | |
| 398 | - cId = this.form.earthsitesId; | |
| 399 | - eId = this.form.objectId; | |
| 400 | - } | |
| 401 | - | |
| 402 | - this.filterContract = []; | |
| 403 | - for(let i in this.contractList){ | |
| 404 | - let obj = this.contractList[i]; | |
| 405 | - let canId = true; | |
| 406 | 385 | |
| 386 | + }); | |
| 387 | + }); | |
| 388 | + }, | |
| 389 | + filterConract() { | |
| 390 | + let cId; | |
| 391 | + let eId; | |
| 392 | + if (this.form.type == 0) { | |
| 393 | + cId = this.form.objectId; | |
| 394 | + eId = this.form.earthsitesId; | |
| 395 | + } else { | |
| 396 | + cId = this.form.earthsitesId; | |
| 397 | + eId = this.form.objectId; | |
| 398 | + } | |
| 407 | 399 | |
| 408 | - //constructionSiteID //earthSiteID | |
| 409 | - if(cId && cId != obj.constructionSiteID){ | |
| 410 | - continue; | |
| 411 | - } | |
| 400 | + this.filterContract = []; | |
| 401 | + for (let i in this.contractList) { | |
| 402 | + let obj = this.contractList[i]; | |
| 403 | + let canId = true; | |
| 412 | 404 | |
| 413 | - if(eId && eId != obj.earthSiteID){ | |
| 414 | - continue; | |
| 415 | - } | |
| 416 | 405 | |
| 417 | - this.filterContract.push(obj); | |
| 406 | + //constructionSiteID //earthSiteID | |
| 407 | + if (cId && cId != obj.constructionSiteID) { | |
| 408 | + continue; | |
| 418 | 409 | } |
| 419 | 410 | |
| 411 | + if (eId && eId != obj.earthSiteID) { | |
| 412 | + continue; | |
| 413 | + } | |
| 420 | 414 | |
| 421 | - for(let j in this.bindData){ | |
| 415 | + this.filterContract.push(obj); | |
| 416 | + } | |
| 422 | 417 | |
| 423 | - this.bindData[j].show = false; | |
| 424 | 418 | |
| 425 | - for(let i in this.filterContract){ | |
| 419 | + for (let j in this.bindData) { | |
| 426 | 420 | |
| 427 | - if(this.form.type == 0 && this.filterContract[i].earthSiteID == this.bindData[j].id){ | |
| 428 | - this.bindData[j].show = true; | |
| 429 | - } | |
| 421 | + this.bindData[j].show = false; | |
| 430 | 422 | |
| 431 | - if(this.form.type == 1 && this.filterContract[i].constructionSiteID == this.bindData[j].id){ | |
| 432 | - this.bindData[j].show = true; | |
| 433 | - } | |
| 423 | + for (let i in this.filterContract) { | |
| 434 | 424 | |
| 425 | + if (this.form.type == 0 && this.filterContract[i].earthSiteID == this.bindData[j].id) { | |
| 426 | + this.bindData[j].show = true; | |
| 435 | 427 | } |
| 436 | - } | |
| 437 | - }, | |
| 438 | - getEarthsiteId(value) { | |
| 439 | 428 | |
| 440 | - this.form.contract = null; | |
| 441 | - this.form.contractId = null; | |
| 429 | + if (this.form.type == 1 && this.filterContract[i].constructionSiteID == this.bindData[j].id) { | |
| 430 | + this.bindData[j].show = true; | |
| 431 | + } | |
| 442 | 432 | |
| 443 | - let name = this.form.name; | |
| 444 | - let objId = this.form.objectId; | |
| 433 | + } | |
| 434 | + } | |
| 435 | + }, | |
| 436 | + getEarthsiteId(value) { | |
| 445 | 437 | |
| 446 | - this.form.name = null; | |
| 447 | - this.form.objectId = null; | |
| 438 | + this.form.contract = null; | |
| 439 | + this.form.contractId = null; | |
| 448 | 440 | |
| 441 | + let name = this.form.name; | |
| 442 | + let objId = this.form.objectId; | |
| 449 | 443 | |
| 450 | - let item; | |
| 451 | - for(let i in this.bindData){ | |
| 452 | - if(this.bindData[i].name == value){ | |
| 453 | - item = this.bindData[i]; | |
| 454 | - break; | |
| 455 | - } | |
| 456 | - } | |
| 444 | + this.form.name = null; | |
| 445 | + this.form.objectId = null; | |
| 457 | 446 | |
| 458 | - this.form.earthsitesName = item.name; | |
| 459 | - this.form.earthsitesId = item.id; | |
| 460 | - this.filterConract(); | |
| 461 | 447 | |
| 462 | - if(this.filterContract.length == 0){ | |
| 463 | - this.form.earthSiteName = null; | |
| 464 | - this.form.earthSiteID = null; | |
| 465 | - this.$message("未找到对应消纳合同!!"); | |
| 466 | - } | |
| 448 | + let item; | |
| 449 | + for (let i in this.bindData) { | |
| 450 | + if (this.bindData[i].name == value) { | |
| 451 | + item = this.bindData[i]; | |
| 452 | + break; | |
| 453 | + } | |
| 454 | + } | |
| 467 | 455 | |
| 468 | - this.filterConract(); | |
| 456 | + this.form.earthsitesName = item.name; | |
| 457 | + this.form.earthsitesId = item.id; | |
| 458 | + this.filterConract(); | |
| 469 | 459 | |
| 470 | - for(let i in this.filterContract){ | |
| 471 | - if(this.filterContract[i].constructionSiteID == objId || this.filterContract[i].earthSiteID == objId){ | |
| 472 | - this.form.name = name; | |
| 473 | - this.form.objectId = objId; | |
| 474 | - break; | |
| 475 | - } | |
| 476 | - } | |
| 460 | + if (this.filterContract.length == 0) { | |
| 461 | + this.form.earthSiteName = null; | |
| 462 | + this.form.earthSiteID = null; | |
| 463 | + this.$message("未找到对应消纳合同!!"); | |
| 464 | + } | |
| 477 | 465 | |
| 466 | + this.filterConract(); | |
| 478 | 467 | |
| 479 | - }, | |
| 480 | - downloadFile(path) { | |
| 481 | - window.location.href = process.env.VUE_APP_BASE_API + "/business/threestep/download?path=" + encodeURI(path); | |
| 482 | - }, | |
| 483 | - removeImage(index, img) { | |
| 484 | - let target = "img" + index; | |
| 485 | - this.form[target].splice(this.form[target].indexOf(img), 1); | |
| 486 | - this.$forceUpdate(); | |
| 468 | + for (let i in this.filterContract) { | |
| 469 | + if (this.filterContract[i].constructionSiteID == objId || this.filterContract[i].earthSiteID == objId) { | |
| 470 | + this.form.name = name; | |
| 471 | + this.form.objectId = objId; | |
| 472 | + break; | |
| 473 | + } | |
| 474 | + } | |
| 487 | 475 | |
| 488 | - }, | |
| 489 | - removeAttchItem(index, img) { | |
| 490 | - let target = "attchItem" + index; | |
| 491 | - this.form[target].splice(this.form[target].indexOf(img), 1); | |
| 492 | - this.$forceUpdate(); | |
| 493 | - }, | |
| 494 | 476 | |
| 495 | - uploadSuccess(res, file, fileList) { | |
| 496 | - if(res.code){ | |
| 497 | - this.$message(res.message); | |
| 498 | - return; | |
| 499 | - } | |
| 500 | - if(this.picIndex > 90){ | |
| 501 | - let target = "attchItem" + (this.picIndex-90); | |
| 502 | - if (!this.form[target]) { | |
| 503 | - this.form[target] = []; | |
| 504 | - } | |
| 505 | - this.form[target].push(res); | |
| 506 | - return; | |
| 477 | + }, | |
| 478 | + downloadFile(path) { | |
| 479 | + window.location.href = process.env.VUE_APP_BASE_API + "/business/threestep/download?path=" + encodeURI(path); | |
| 480 | + }, | |
| 481 | + removeImage(index, img) { | |
| 482 | + for(let i=0;i<this.slides[index].length;i++){ | |
| 483 | + if(this.slides[index][i].alt == img){ | |
| 484 | + this.slides[index].splice(i,1); | |
| 507 | 485 | } |
| 508 | - let target = "img" + this.picIndex; | |
| 486 | + } | |
| 487 | + let target = "img" + index; | |
| 488 | + this.form[target].splice(this.form[target].indexOf(img), 1); | |
| 489 | + this.$forceUpdate(); | |
| 490 | + }, | |
| 491 | + removeAttchItem(index, img) { | |
| 492 | + let target = "attchItem" + index; | |
| 493 | + this.form[target].splice(this.form[target].indexOf(img), 1); | |
| 494 | + this.$forceUpdate(); | |
| 495 | + }, | |
| 509 | 496 | |
| 497 | + uploadSuccess(res, file, fileList) { | |
| 498 | + if (res.code) { | |
| 499 | + this.$message(res.message); | |
| 500 | + return; | |
| 501 | + } | |
| 502 | + if (this.picIndex > 90) { | |
| 503 | + let target = "attchItem" + (this.picIndex - 90); | |
| 510 | 504 | if (!this.form[target]) { |
| 511 | 505 | this.form[target] = []; |
| 512 | 506 | } |
| 513 | - | |
| 514 | 507 | this.form[target].push(res); |
| 508 | + return; | |
| 509 | + } | |
| 510 | + let target = "img" + this.picIndex; | |
| 515 | 511 | |
| 516 | - }, | |
| 517 | - showFileUpload(i) { | |
| 518 | - this.uploadImageDialog = true; | |
| 519 | - this.picIndex = i; | |
| 520 | - }, | |
| 521 | - beforeUpload(file) { | |
| 522 | - let isRightSize = file.size / 1024 / 1024 < 20 | |
| 523 | - if (!isRightSize) { | |
| 524 | - this.$message.error('文件大小超过 20MB') | |
| 525 | - return isRightSize; | |
| 526 | - } | |
| 527 | - let isAccept = false; | |
| 528 | - if (file.name.indexOf('.docx') > -1 || file.name.indexOf(".jpg") > -1 || file.name.indexOf('.doc') > -1 || file | |
| 529 | - .name.indexOf('.pdf') > -1) { | |
| 530 | - isAccept = true; | |
| 531 | - } | |
| 532 | - if (!isAccept) { | |
| 533 | - this.$message.error('应该选择PDF、JPG、WORD类型的文件') | |
| 534 | - return isAccept; | |
| 535 | - } | |
| 512 | + if (!this.form[target]) { | |
| 513 | + this.form[target] = []; | |
| 514 | + } | |
| 536 | 515 | |
| 537 | - }, | |
| 538 | - handleClose() { | |
| 539 | - this.uploadImageDialog = false; | |
| 540 | - this.fileList = []; | |
| 541 | - }, | |
| 542 | - selectType(value) { | |
| 516 | + this.form[target].push(res); | |
| 517 | + if(file.name.indexOf('.jpg') > -1){ | |
| 518 | + let url = URL.createObjectURL(file.raw) | |
| 519 | + this.slidesArys.push( | |
| 520 | + { | |
| 521 | + src: url, | |
| 522 | + msrc: url, | |
| 523 | + alt: res, | |
| 524 | + w: 1920, | |
| 525 | + h: 1080 | |
| 526 | + } | |
| 527 | + ) | |
| 528 | + this.slides[this.picIndex] = this.slidesArys; | |
| 529 | + } | |
| 530 | + }, | |
| 531 | + showFileUpload(i) { | |
| 532 | + this.uploadImageDialog = true; | |
| 533 | + this.picIndex = i; | |
| 534 | + }, | |
| 535 | + beforeUpload(file) { | |
| 536 | + let isRightSize = file.size / 1024 / 1024 < 20 | |
| 537 | + if (!isRightSize) { | |
| 538 | + this.$message.error('文件大小超过 20MB') | |
| 539 | + return isRightSize; | |
| 540 | + } | |
| 541 | + let isAccept = false; | |
| 542 | + if (file.name.indexOf('.docx') > -1 || file.name.indexOf(".jpg") > -1 || file.name.indexOf('.doc') > -1 || file | |
| 543 | + .name.indexOf('.pdf') > -1) { | |
| 544 | + isAccept = true; | |
| 545 | + } | |
| 546 | + if (!isAccept) { | |
| 547 | + this.$message.error('应该选择PDF、JPG、WORD类型的文件') | |
| 548 | + return isAccept; | |
| 549 | + } | |
| 543 | 550 | |
| 544 | - this.rules.companys[0].required = false; | |
| 545 | - this.rules.companyTrucks[0].required = false; | |
| 546 | - if (value == "0") { | |
| 547 | - this.labelName = "工地名称"; | |
| 548 | - this.labelName2 = "绑定消纳场"; | |
| 551 | + }, | |
| 552 | + handleClose() { | |
| 553 | + this.uploadImageDialog = false; | |
| 554 | + this.slidesArys = []; | |
| 555 | + this.fileList = []; | |
| 556 | + }, | |
| 557 | + selectType(value) { | |
| 549 | 558 | |
| 550 | - } else { | |
| 551 | - this.labelName = "消纳场名称"; | |
| 552 | - this.labelName2 = "绑定工地"; | |
| 553 | - } | |
| 559 | + this.rules.companys[0].required = false; | |
| 560 | + this.rules.companyTrucks[0].required = false; | |
| 561 | + if (value == "0") { | |
| 562 | + this.labelName = "工地名称"; | |
| 563 | + this.labelName2 = "绑定消纳场"; | |
| 554 | 564 | |
| 555 | - this.form.name = null; | |
| 556 | - this.bindname = null; | |
| 557 | - constructionsitesList(this.remoteQueryData).then(res => { | |
| 558 | - if (value == 0) { | |
| 559 | - this.remoteData = res.result.list; | |
| 560 | - } else { | |
| 561 | - this.bindData = res.result.list; | |
| 565 | + } else { | |
| 566 | + this.labelName = "消纳场名称"; | |
| 567 | + this.labelName2 = "绑定工地"; | |
| 568 | + } | |
| 562 | 569 | |
| 563 | - for(let i in this.bindData){ | |
| 564 | - this.bindData[i].show = true; | |
| 565 | - } | |
| 570 | + this.form.name = null; | |
| 571 | + this.bindname = null; | |
| 572 | + constructionsitesList(this.remoteQueryData).then(res => { | |
| 573 | + if (value == 0) { | |
| 574 | + this.remoteData = res.result.list; | |
| 575 | + } else { | |
| 576 | + this.bindData = res.result.list; | |
| 577 | + | |
| 578 | + for (let i in this.bindData) { | |
| 579 | + this.bindData[i].show = true; | |
| 566 | 580 | } |
| 567 | - }); | |
| 581 | + } | |
| 582 | + }); | |
| 568 | 583 | |
| 569 | - earthsitesList(this.remoteQueryData).then(res => { | |
| 570 | - if (value == 0) { | |
| 571 | - this.bindData = res.result.list; | |
| 572 | - for(let i in this.bindData){ | |
| 573 | - this.bindData[i].show = true; | |
| 574 | - } | |
| 584 | + earthsitesList(this.remoteQueryData).then(res => { | |
| 585 | + if (value == 0) { | |
| 586 | + this.bindData = res.result.list; | |
| 587 | + for (let i in this.bindData) { | |
| 588 | + this.bindData[i].show = true; | |
| 589 | + } | |
| 575 | 590 | this.rules.companys[0].required = true; |
| 576 | 591 | this.rules.companyTrucks[0].required = true; |
| 577 | - } else { | |
| 578 | - this.remoteData = res.result.list; | |
| 579 | - } | |
| 580 | - }); | |
| 581 | - }, | |
| 592 | + } else { | |
| 593 | + this.remoteData = res.result.list; | |
| 594 | + } | |
| 595 | + }); | |
| 596 | + }, | |
| 582 | 597 | |
| 583 | - getAreaName(code){ | |
| 584 | - for(let i =0;i<this.areas.length;i++){ | |
| 585 | - if(Number(code) == this.areas[i].code){ | |
| 586 | - return this.areas[i].name; | |
| 587 | - break; | |
| 588 | - } | |
| 598 | + getAreaName(code) { | |
| 599 | + for (let i = 0; i < this.areas.length; i++) { | |
| 600 | + if (Number(code) == this.areas[i].code) { | |
| 601 | + return this.areas[i].name; | |
| 602 | + break; | |
| 589 | 603 | } |
| 590 | - return code; | |
| 591 | - }, | |
| 604 | + } | |
| 605 | + return code; | |
| 606 | + }, | |
| 592 | 607 | |
| 593 | - /** 查询报工自查列表 */ | |
| 594 | - getList(tabIdx) { | |
| 595 | - if(tabIdx == 1){ | |
| 596 | - this.resetQuery(); | |
| 597 | - this.queryParams.pageStatus = tabIdx; | |
| 598 | - this.queryParams.status = tabIdx; | |
| 608 | + /** 查询报工自查列表 */ | |
| 609 | + getList(tabIdx) { | |
| 610 | + if (tabIdx == 1) { | |
| 611 | + this.resetQuery(); | |
| 612 | + this.queryParams.pageStatus = tabIdx; | |
| 613 | + this.queryParams.status = tabIdx; | |
| 599 | 614 | |
| 600 | - getNames(this.queryParams).then(res=>{ | |
| 615 | + getNames(this.queryParams).then(res => { | |
| 601 | 616 | |
| 602 | - this.names = res; | |
| 603 | - }) | |
| 617 | + this.names = res; | |
| 618 | + }) | |
| 604 | 619 | |
| 605 | - }else if(tabIdx == 0){ | |
| 606 | - this.resetQuery(); | |
| 607 | - this.queryParams.pageStatus = tabIdx; | |
| 608 | - this.queryParams.status = null; | |
| 620 | + } else if (tabIdx == 0) { | |
| 621 | + this.resetQuery(); | |
| 622 | + this.queryParams.pageStatus = tabIdx; | |
| 623 | + this.queryParams.status = null; | |
| 609 | 624 | |
| 610 | - getNames(this.queryParams).then(res=>{ | |
| 625 | + getNames(this.queryParams).then(res => { | |
| 611 | 626 | |
| 612 | - this.names = res; | |
| 613 | - }) | |
| 614 | - } | |
| 627 | + this.names = res; | |
| 628 | + }) | |
| 629 | + } | |
| 615 | 630 | |
| 616 | - let query = { | |
| 617 | - "page": 1, | |
| 618 | - "size": 9999, | |
| 619 | - "auditStatus":1, | |
| 620 | - }; | |
| 621 | - | |
| 622 | - contractList(query).then(res=>{ | |
| 623 | - this.contractList = res.result.list; | |
| 624 | - this.filterContract = this.contractList | |
| 625 | - }); | |
| 631 | + let query = { | |
| 632 | + "page": 1, | |
| 633 | + "size": 9999, | |
| 634 | + "auditStatus": 1, | |
| 635 | + }; | |
| 626 | 636 | |
| 627 | - this.loading = true; | |
| 628 | - listThreestep(this.queryParams).then(response => { | |
| 629 | - this.threestepList = response.rows; | |
| 630 | - this.total = response.total; | |
| 631 | - this.loading = false; | |
| 632 | - for(let i =0;i< this.threestepList.length;i++){ | |
| 633 | - this.threestepList[i].place = this.getAreaName(this.threestepList[i].place); | |
| 634 | - } | |
| 635 | - }); | |
| 636 | - }, | |
| 637 | - // 取消按钮 | |
| 638 | - cancel() { | |
| 639 | - this.open = false; | |
| 640 | - this.reset(); | |
| 641 | - }, | |
| 642 | - // 表单重置 | |
| 643 | - reset() { | |
| 644 | - this.form = { | |
| 645 | - id: null, | |
| 646 | - name: null, | |
| 647 | - type: null, | |
| 648 | - place: null, | |
| 649 | - selfCheckTime: null, | |
| 650 | - objectId: null, | |
| 651 | - earthsitesId: null, | |
| 652 | - createTime: null, | |
| 653 | - checkTime: null, | |
| 654 | - earthsitesName: null, | |
| 655 | - contract: null, | |
| 656 | - companys: null, | |
| 657 | - companyTrucks: null, | |
| 658 | - img0: null, | |
| 659 | - img1: null, | |
| 660 | - img2: null, | |
| 661 | - img3: null, | |
| 662 | - img4: null, | |
| 663 | - img5: null, | |
| 664 | - img6: null, | |
| 665 | - img7: null, | |
| 666 | - img8: null, | |
| 667 | - img9: null, | |
| 668 | - img10: null, | |
| 669 | - img11: null, | |
| 670 | - img12: null, | |
| 671 | - person: null, | |
| 672 | - phone: null | |
| 673 | - }; | |
| 674 | - this.resetForm("form"); | |
| 675 | - this.filterConract(); | |
| 676 | - }, | |
| 677 | - /** 搜索按钮操作 */ | |
| 678 | - handleQuery() { | |
| 679 | - this.queryParams.pageNum = 1; | |
| 680 | - this.getList(); | |
| 681 | - }, | |
| 682 | - /** 重置按钮操作 */ | |
| 683 | - resetQuery() { | |
| 684 | - this.resetForm("queryForm"); | |
| 685 | - this.queryParams.workStartTime = null; | |
| 686 | - this.queryParams.workEndTime = null; | |
| 687 | - this.handleQuery(); | |
| 688 | - }, | |
| 689 | - // 多选框选中数据 | |
| 690 | - handleSelectionChange(selection) { | |
| 691 | - this.ids = selection.map(item => item.id) | |
| 692 | - this.single = selection.length !== 1 | |
| 693 | - this.multiple = !selection.length | |
| 694 | - }, | |
| 695 | - /** 新增按钮操作 */ | |
| 696 | - handleAdd() { | |
| 697 | - this.reset(); | |
| 698 | - this.open = true; | |
| 699 | - this.title = "报工自查"; | |
| 700 | - }, | |
| 701 | - /** 修改按钮操作 */ | |
| 702 | - handleUpdate(row,idx) { | |
| 703 | - this.reset(); | |
| 704 | - this.businessKey = row.id +""; | |
| 705 | - if(idx == 0){ | |
| 706 | - this.info = true; | |
| 707 | - }else{ | |
| 708 | - this.info2 = true; | |
| 637 | + contractList(query).then(res => { | |
| 638 | + this.contractList = res.result.list; | |
| 639 | + this.filterContract = this.contractList | |
| 640 | + }); | |
| 641 | + | |
| 642 | + this.loading = true; | |
| 643 | + listThreestep(this.queryParams).then(response => { | |
| 644 | + this.threestepList = response.rows; | |
| 645 | + this.total = response.total; | |
| 646 | + this.loading = false; | |
| 647 | + for (let i = 0; i < this.threestepList.length; i++) { | |
| 648 | + this.threestepList[i].place = this.getAreaName(this.threestepList[i].place); | |
| 649 | + } | |
| 650 | + }); | |
| 651 | + }, | |
| 652 | + // 取消按钮 | |
| 653 | + cancel() { | |
| 654 | + this.open = false; | |
| 655 | + this.reset(); | |
| 656 | + }, | |
| 657 | + // 表单重置 | |
| 658 | + reset() { | |
| 659 | + this.form = { | |
| 660 | + id: null, | |
| 661 | + name: null, | |
| 662 | + type: null, | |
| 663 | + place: null, | |
| 664 | + selfCheckTime: null, | |
| 665 | + objectId: null, | |
| 666 | + earthsitesId: null, | |
| 667 | + createTime: null, | |
| 668 | + checkTime: null, | |
| 669 | + earthsitesName: null, | |
| 670 | + contract: null, | |
| 671 | + companys: null, | |
| 672 | + companyTrucks: null, | |
| 673 | + img0: null, | |
| 674 | + img1: null, | |
| 675 | + img2: null, | |
| 676 | + img3: null, | |
| 677 | + img4: null, | |
| 678 | + img5: null, | |
| 679 | + img6: null, | |
| 680 | + img7: null, | |
| 681 | + img8: null, | |
| 682 | + img9: null, | |
| 683 | + img10: null, | |
| 684 | + img11: null, | |
| 685 | + img12: null, | |
| 686 | + person: null, | |
| 687 | + phone: null | |
| 688 | + }; | |
| 689 | + this.resetForm("form"); | |
| 690 | + this.filterConract(); | |
| 691 | + }, | |
| 692 | + /** 搜索按钮操作 */ | |
| 693 | + handleQuery() { | |
| 694 | + this.queryParams.pageNum = 1; | |
| 695 | + this.getList(); | |
| 696 | + }, | |
| 697 | + /** 重置按钮操作 */ | |
| 698 | + resetQuery() { | |
| 699 | + this.resetForm("queryForm"); | |
| 700 | + this.queryParams.workStartTime = null; | |
| 701 | + this.queryParams.workEndTime = null; | |
| 702 | + this.handleQuery(); | |
| 703 | + }, | |
| 704 | + // 多选框选中数据 | |
| 705 | + handleSelectionChange(selection) { | |
| 706 | + this.ids = selection.map(item => item.id) | |
| 707 | + this.single = selection.length !== 1 | |
| 708 | + this.multiple = !selection.length | |
| 709 | + }, | |
| 710 | + /** 新增按钮操作 */ | |
| 711 | + handleAdd() { | |
| 712 | + this.reset(); | |
| 713 | + this.open = true; | |
| 714 | + this.title = "报工自查"; | |
| 715 | + }, | |
| 716 | + /** 修改按钮操作 */ | |
| 717 | + handleUpdate(row, idx) { | |
| 718 | + this.reset(); | |
| 719 | + this.businessKey = row.id + ""; | |
| 720 | + if (idx == 0) { | |
| 721 | + this.info = true; | |
| 722 | + } else { | |
| 723 | + this.info2 = true; | |
| 724 | + } | |
| 725 | + }, | |
| 726 | + reSub(row) { | |
| 727 | + this.reset(); | |
| 728 | + | |
| 729 | + this.open = true; | |
| 730 | + this.title = "再次提交"; | |
| 731 | + getThreestep(row.id).then(res => { | |
| 732 | + this.form = res.data; | |
| 733 | + this.form.type = this.form.type + ""; | |
| 734 | + this.form.place = Number(this.form.place); | |
| 735 | + this.bindname = res.data.earthsitesName; | |
| 736 | + if (res.data.companys) { | |
| 737 | + this.form.companys = res.data.companys.split(","); | |
| 738 | + } | |
| 739 | + if (res.data.companyTrucks) { | |
| 740 | + this.form.companyTrucks = res.data.companyTrucks.split(","); | |
| 741 | + } | |
| 742 | + for (let i = 0; i < 13; i++) { | |
| 743 | + if (this.form["img" + i]) { | |
| 744 | + this.form["img" + i] = this.form["img" + i].split(","); | |
| 709 | 745 | } |
| 710 | - }, | |
| 711 | - reSub(row){ | |
| 712 | - this.reset(); | |
| 713 | - | |
| 714 | - this.open = true; | |
| 715 | - this.title = "再次提交"; | |
| 716 | - getThreestep(row.id).then(res=>{ | |
| 717 | - this.form = res.data; | |
| 718 | - this.form.type = this.form.type + ""; | |
| 719 | - this.form.place = Number(this.form.place); | |
| 720 | - this.bindname = res.data.earthsitesName; | |
| 721 | - if(res.data.companys){ | |
| 722 | - this.form.companys = res.data.companys.split(","); | |
| 723 | - } | |
| 724 | - if(res.data.companyTrucks){ | |
| 725 | - this.form.companyTrucks = res.data.companyTrucks.split(","); | |
| 726 | - } | |
| 727 | - for (let i = 0; i < 13; i++) { | |
| 728 | - if (this.form["img" + i]) { | |
| 729 | - this.form["img" + i] = this.form["img" + i].split(","); | |
| 730 | - } | |
| 731 | - } | |
| 732 | - }); | |
| 733 | - }, | |
| 746 | + } | |
| 747 | + }); | |
| 748 | + }, | |
| 734 | 749 | |
| 735 | - checkEndSuccess(){ | |
| 750 | + checkEndSuccess() { | |
| 736 | 751 | |
| 737 | - let year = new Date().getFullYear(); | |
| 738 | - let month = (new Date().getMonth() + 1) < 10 ? "0" + (new Date().getMonth() + 1) : (new Date().getMonth() + 1); | |
| 739 | - let date = new Date().getDate() < 10 ? "0" + new Date().getDate() : new Date().getDate(); | |
| 740 | - let hour = new Date().getHours() < 10 ? "0" + new Date().getHours() : new Date().getHours(); | |
| 741 | - let minute = new Date().getMinutes() < 10 ? "0" + new Date().getMinutes() : new Date().getMinutes(); | |
| 742 | - let second = new Date().getSeconds() < 10 ? "0" + new Date().getSeconds() : new Date().getSeconds(); | |
| 752 | + let year = new Date().getFullYear(); | |
| 753 | + let month = (new Date().getMonth() + 1) < 10 ? "0" + (new Date().getMonth() + 1) : (new Date().getMonth() + 1); | |
| 754 | + let date = new Date().getDate() < 10 ? "0" + new Date().getDate() : new Date().getDate(); | |
| 755 | + let hour = new Date().getHours() < 10 ? "0" + new Date().getHours() : new Date().getHours(); | |
| 756 | + let minute = new Date().getMinutes() < 10 ? "0" + new Date().getMinutes() : new Date().getMinutes(); | |
| 757 | + let second = new Date().getSeconds() < 10 ? "0" + new Date().getSeconds() : new Date().getSeconds(); | |
| 743 | 758 | |
| 744 | 759 | |
| 745 | - this.form.checkEndTime = year + "-" + month + "-" + date + " " + hour + ":" + minute + ":" + second; | |
| 746 | - this.form.id = this.businessKey; | |
| 747 | - for (let i = 1; i < 4; i++) { | |
| 748 | - if (this.form["attchItem" + i]) { | |
| 749 | - this.form["attchItem" + i] = this.form["attchItem" + i] + ""; | |
| 750 | - } | |
| 760 | + this.form.checkEndTime = year + "-" + month + "-" + date + " " + hour + ":" + minute + ":" + second; | |
| 761 | + this.form.id = this.businessKey; | |
| 762 | + for (let i = 1; i < 4; i++) { | |
| 763 | + if (this.form["attchItem" + i]) { | |
| 764 | + this.form["attchItem" + i] = this.form["attchItem" + i] + ""; | |
| 751 | 765 | } |
| 752 | - this.submitForm(); | |
| 753 | - }, | |
| 754 | - checkEndError(){ | |
| 755 | - this.$router.push({path:"/other/caseOffline/" ,query:{businessKey:this.businessKey}}); | |
| 756 | - //发起案卷 | |
| 757 | - }, | |
| 758 | - /** 提交按钮 */ | |
| 759 | - submitForm() { | |
| 760 | - | |
| 761 | - this.$refs["form"].validate(valid => { | |
| 762 | - if (valid) { | |
| 763 | - this.loading = true; | |
| 764 | - if (this.form.id != null) { | |
| 765 | - if(this.queryParams.pageStatus==1){ | |
| 766 | - updateThreestep(this.form).then(response => { | |
| 767 | - this.msgSuccess("提交成功"); | |
| 768 | - this.open = false; | |
| 769 | - this.open2 = false; | |
| 770 | - this.info = false; | |
| 771 | - this.info2 =false; | |
| 772 | - this.getList(); | |
| 773 | - this.loading = false; | |
| 774 | - },error=>{ | |
| 775 | - this.loading = false; | |
| 776 | - this.form.companys = this.form.companys.split(","); | |
| 777 | - this.form.companyTrucks = this.form.companyTrucks.split(","); | |
| 778 | - | |
| 779 | - for (let i = 0; i < 13; i++) { | |
| 780 | - if (this.form["img" + i]) { | |
| 781 | - this.form["img" + i] = this.form["img" + i].split(","); | |
| 782 | - } | |
| 783 | - } | |
| 784 | - }); | |
| 785 | - }else{ | |
| 786 | - this.form.companys = this.form.companys + ""; | |
| 787 | - this.form.companyTrucks = this.form.companyTrucks + ""; | |
| 766 | + } | |
| 767 | + this.submitForm(); | |
| 768 | + }, | |
| 769 | + checkEndError() { | |
| 770 | + this.$router.push({path: "/other/caseOffline/", query: {businessKey: this.businessKey}}); | |
| 771 | + //发起案卷 | |
| 772 | + }, | |
| 773 | + /** 提交按钮 */ | |
| 774 | + submitForm() { | |
| 775 | + | |
| 776 | + this.$refs["form"].validate(valid => { | |
| 777 | + if (valid) { | |
| 778 | + this.loading = true; | |
| 779 | + if (this.form.id != null) { | |
| 780 | + if (this.queryParams.pageStatus == 1) { | |
| 781 | + updateThreestep(this.form).then(response => { | |
| 782 | + this.msgSuccess("提交成功"); | |
| 783 | + this.open = false; | |
| 784 | + this.open2 = false; | |
| 785 | + this.info = false; | |
| 786 | + this.info2 = false; | |
| 787 | + this.getList(); | |
| 788 | + this.loading = false; | |
| 789 | + }, error => { | |
| 790 | + this.loading = false; | |
| 791 | + this.form.companys = this.form.companys.split(","); | |
| 792 | + this.form.companyTrucks = this.form.companyTrucks.split(","); | |
| 788 | 793 | |
| 789 | 794 | for (let i = 0; i < 13; i++) { |
| 790 | 795 | if (this.form["img" + i]) { |
| 791 | - this.form["img" + i] = this.form["img" + i] + ""; | |
| 796 | + this.form["img" + i] = this.form["img" + i].split(","); | |
| 792 | 797 | } |
| 793 | 798 | } |
| 794 | - | |
| 795 | - addThreestep(this.form).then(response => { | |
| 796 | - this.msgSuccess("修改成功"); | |
| 797 | - this.open = false; | |
| 798 | - this.open2 = false; | |
| 799 | - this.info = false; | |
| 800 | - this.info2 =false; | |
| 801 | - this.getList(); | |
| 802 | - this.loading = false; | |
| 803 | - },error=>{ | |
| 804 | - this.loading = false; | |
| 805 | - this.form.companys = this.form.companys.split(","); | |
| 806 | - this.form.companyTrucks = this.form.companyTrucks.split(","); | |
| 807 | - | |
| 808 | - for (let i = 0; i < 13; i++) { | |
| 809 | - if (this.form["img" + i]) { | |
| 810 | - this.form["img" + i] = this.form["img" + i].split(","); | |
| 811 | - } | |
| 812 | - } | |
| 813 | 799 | }); |
| 814 | - } | |
| 815 | - | |
| 816 | - | |
| 817 | - | |
| 818 | 800 | } else { |
| 819 | 801 | this.form.companys = this.form.companys + ""; |
| 820 | 802 | this.form.companyTrucks = this.form.companyTrucks + ""; |
| ... | ... | @@ -824,52 +806,84 @@ |
| 824 | 806 | this.form["img" + i] = this.form["img" + i] + ""; |
| 825 | 807 | } |
| 826 | 808 | } |
| 809 | + | |
| 827 | 810 | addThreestep(this.form).then(response => { |
| 828 | - this.msgSuccess("新增成功"); | |
| 811 | + this.msgSuccess("修改成功"); | |
| 829 | 812 | this.open = false; |
| 830 | 813 | this.open2 = false; |
| 814 | + this.info = false; | |
| 815 | + this.info2 = false; | |
| 831 | 816 | this.getList(); |
| 832 | - },error=>{ | |
| 833 | - this.loading = false; | |
| 834 | - this.form.companys = this.form.companys.split(","); | |
| 835 | - this.form.companyTrucks = this.form.companyTrucks.split(","); | |
| 836 | - | |
| 837 | - for (let i = 0; i < 13; i++) { | |
| 838 | - if (this.form["img" + i]) { | |
| 839 | - this.form["img" + i] = this.form["img" + i].split(","); | |
| 840 | - } | |
| 817 | + this.loading = false; | |
| 818 | + }, error => { | |
| 819 | + this.loading = false; | |
| 820 | + this.form.companys = this.form.companys.split(","); | |
| 821 | + this.form.companyTrucks = this.form.companyTrucks.split(","); | |
| 822 | + | |
| 823 | + for (let i = 0; i < 13; i++) { | |
| 824 | + if (this.form["img" + i]) { | |
| 825 | + this.form["img" + i] = this.form["img" + i].split(","); | |
| 841 | 826 | } |
| 842 | - }) | |
| 827 | + } | |
| 828 | + }); | |
| 829 | + } | |
| 830 | + | |
| 831 | + | |
| 832 | + } else { | |
| 833 | + this.form.companys = this.form.companys + ""; | |
| 834 | + this.form.companyTrucks = this.form.companyTrucks + ""; | |
| 835 | + | |
| 836 | + for (let i = 0; i < 13; i++) { | |
| 837 | + if (this.form["img" + i]) { | |
| 838 | + this.form["img" + i] = this.form["img" + i] + ""; | |
| 839 | + } | |
| 843 | 840 | } |
| 841 | + addThreestep(this.form).then(response => { | |
| 842 | + this.msgSuccess("新增成功"); | |
| 843 | + this.open = false; | |
| 844 | + this.open2 = false; | |
| 845 | + this.getList(); | |
| 846 | + }, error => { | |
| 847 | + this.loading = false; | |
| 848 | + this.form.companys = this.form.companys.split(","); | |
| 849 | + this.form.companyTrucks = this.form.companyTrucks.split(","); | |
| 850 | + | |
| 851 | + for (let i = 0; i < 13; i++) { | |
| 852 | + if (this.form["img" + i]) { | |
| 853 | + this.form["img" + i] = this.form["img" + i].split(","); | |
| 854 | + } | |
| 855 | + } | |
| 856 | + }) | |
| 844 | 857 | } |
| 845 | - }); | |
| 846 | - }, | |
| 847 | - /** 删除按钮操作 */ | |
| 848 | - handleDelete(row) { | |
| 849 | - const ids = row.id || this.ids; | |
| 850 | - this.$confirm('是否确认删除报工自查编号为"' + ids + '"的数据项?', "警告", { | |
| 851 | - confirmButtonText: "确定", | |
| 852 | - cancelButtonText: "取消", | |
| 853 | - type: "warning" | |
| 854 | - }).then(function() { | |
| 855 | - return delThreestep(ids); | |
| 856 | - }).then(() => { | |
| 857 | - this.getList(); | |
| 858 | - this.msgSuccess("删除成功"); | |
| 859 | - }) | |
| 860 | - }, | |
| 861 | - /** 导出按钮操作 */ | |
| 862 | - handleExport() { | |
| 863 | - const queryParams = this.queryParams; | |
| 864 | - this.$confirm('是否确认导出所有报工数据项?', "警告", { | |
| 865 | - confirmButtonText: "确定", | |
| 866 | - cancelButtonText: "取消", | |
| 867 | - type: "warning" | |
| 868 | - }).then(function() { | |
| 869 | - return exportThreestep(queryParams); | |
| 870 | - }).then(response => { | |
| 871 | - this.download(response.message); | |
| 872 | - }) | |
| 873 | - } | |
| 858 | + } | |
| 859 | + }); | |
| 860 | + }, | |
| 861 | + /** 删除按钮操作 */ | |
| 862 | + handleDelete(row) { | |
| 863 | + const ids = row.id || this.ids; | |
| 864 | + this.$confirm('是否确认删除报工自查编号为"' + ids + '"的数据项?', "警告", { | |
| 865 | + confirmButtonText: "确定", | |
| 866 | + cancelButtonText: "取消", | |
| 867 | + type: "warning" | |
| 868 | + }).then(function () { | |
| 869 | + return delThreestep(ids); | |
| 870 | + }).then(() => { | |
| 871 | + this.getList(); | |
| 872 | + this.msgSuccess("删除成功"); | |
| 873 | + }) | |
| 874 | + }, | |
| 875 | + /** 导出按钮操作 */ | |
| 876 | + handleExport() { | |
| 877 | + const queryParams = this.queryParams; | |
| 878 | + this.$confirm('是否确认导出所有报工数据项?', "警告", { | |
| 879 | + confirmButtonText: "确定", | |
| 880 | + cancelButtonText: "取消", | |
| 881 | + type: "warning" | |
| 882 | + }).then(function () { | |
| 883 | + return exportThreestep(queryParams); | |
| 884 | + }).then(response => { | |
| 885 | + this.download(response.message); | |
| 886 | + }) | |
| 874 | 887 | } |
| 875 | - }; | |
| 888 | + } | |
| 889 | +}; | ... | ... |
trash-ui/src/api/threestepInfo.js
| 1 | +import { | |
| 2 | + getThreestep, | |
| 3 | + getBase64, | |
| 4 | +} from "@/api/business/threestep"; | |
| 1 | 5 | |
| 2 | - import {getThreestep, | |
| 3 | - getBase64, | |
| 4 | - } from "@/api/business/threestep"; | |
| 6 | +import {getToken} from "@/utils/auth"; | |
| 5 | 7 | |
| 6 | - import {getToken} from "@/utils/auth"; | |
| 7 | 8 | |
| 9 | +import { | |
| 10 | + getArea, | |
| 11 | + truckList, | |
| 12 | +} from "@/api/dict"; | |
| 8 | 13 | |
| 9 | - import { | |
| 10 | - getArea, | |
| 11 | - truckList, | |
| 12 | - } from "@/api/dict"; | |
| 13 | 14 | |
| 14 | - | |
| 15 | - export default { | |
| 16 | - name: "ThreestepInfo", | |
| 17 | - props: { | |
| 18 | - businessKey: { | |
| 19 | - type: String | |
| 20 | - } | |
| 15 | +export default { | |
| 16 | + name: "ThreestepInfo", | |
| 17 | + props: { | |
| 18 | + businessKey: { | |
| 19 | + type: String | |
| 20 | + } | |
| 21 | + }, | |
| 22 | + data() { | |
| 23 | + return { | |
| 24 | + areas: [], | |
| 25 | + labelName: "工地名称", | |
| 26 | + labelName2: "绑定消纳场", | |
| 27 | + infoData: {type: 0}, | |
| 28 | + loading: null, | |
| 29 | + showPic: false, | |
| 30 | + picImage: null, | |
| 31 | + slide1:[] | |
| 32 | + } | |
| 33 | + }, | |
| 34 | + created() { | |
| 35 | + this.loading = true; | |
| 36 | + this.getInfo(); | |
| 37 | + | |
| 38 | + | |
| 39 | + }, | |
| 40 | + methods: { | |
| 41 | + slides1(img){ | |
| 42 | + console.log(img) | |
| 43 | + let slide = [{ | |
| 44 | + src: process.env.VUE_APP_BASE_API + img, | |
| 45 | + msrc: process.env.VUE_APP_BASE_API + img, | |
| 46 | + w: 1920, | |
| 47 | + h: 1080 | |
| 48 | + }] | |
| 49 | + return slide | |
| 21 | 50 | }, |
| 22 | - data() { | |
| 23 | - return{ | |
| 24 | - areas:[], | |
| 25 | - labelName : "工地名称", | |
| 26 | - labelName2: "绑定消纳场", | |
| 27 | - infoData:{type:0}, | |
| 28 | - loading:null, | |
| 29 | - showPic:false, | |
| 30 | - picImage:null, | |
| 31 | - } | |
| 51 | + downloadFile(path) { | |
| 52 | + window.location.href = process.env.VUE_APP_BASE_API + "/business/threestep/download?path=" + encodeURI(path); | |
| 32 | 53 | }, |
| 33 | - created() { | |
| 34 | - this.loading = true; | |
| 35 | - this.getInfo(); | |
| 36 | 54 | |
| 55 | + getInfo() { | |
| 56 | + let id; | |
| 57 | + if (this.businessKey.split(":").length == 2) { | |
| 58 | + id = this.businessKey.split(":")[1]; | |
| 59 | + } else { | |
| 60 | + id = this.businessKey; | |
| 61 | + } | |
| 37 | 62 | |
| 38 | - }, | |
| 39 | - methods:{ | |
| 40 | - downloadFile(path) { | |
| 41 | - if(path.indexOf(".jpg") > -1){ | |
| 42 | - | |
| 43 | - getBase64({"path":path}).then(res=>{ | |
| 44 | - if(res){ | |
| 45 | - this.picImage = "data:image/jpg;base64," + res; | |
| 46 | - this.showPic = true; | |
| 47 | - } | |
| 48 | - }); | |
| 63 | + getThreestep(id).then(response => { | |
| 64 | + this.infoData = response.data; | |
| 49 | 65 | |
| 50 | - return; | |
| 51 | - } | |
| 66 | + this.selectType(this.infoData.type); | |
| 67 | + this.infoData.type = this.infoData.type + ""; | |
| 52 | 68 | |
| 53 | 69 | |
| 54 | - window.location.href = process.env.VUE_APP_BASE_API + "/business/threestep/download?path=" + encodeURI(path); | |
| 55 | - }, | |
| 70 | + getArea().then(res => { | |
| 71 | + this.areas = res.result; | |
| 72 | + this.loading = false; | |
| 73 | + for (let i = 0; i < this.areas.length; i++) { | |
| 74 | + if (Number(this.infoData.place) == this.areas[i].code) { | |
| 75 | + this.infoData.place = this.areas[i].name; | |
| 76 | + } | |
| 77 | + } | |
| 78 | + }); | |
| 56 | 79 | |
| 57 | - getInfo() { | |
| 58 | - let id; | |
| 59 | - if(this.businessKey.split(":").length == 2){ | |
| 60 | - id = this.businessKey.split(":")[1]; | |
| 61 | - }else{ | |
| 62 | - id = this.businessKey; | |
| 80 | + let query = { | |
| 81 | + 'page': 1, | |
| 82 | + 'size': 9999, | |
| 83 | + 'valid': 0 | |
| 63 | 84 | } |
| 85 | + truckList(query).then(res => { | |
| 86 | + this.truckList = res.result.list; | |
| 64 | 87 | |
| 65 | - getThreestep(id).then(response => { | |
| 66 | - this.infoData = response.data; | |
| 67 | - | |
| 68 | - this.selectType(this.infoData.type); | |
| 69 | - this.infoData.type = this.infoData.type + ""; | |
| 70 | - | |
| 88 | + let trucks = ""; | |
| 71 | 89 | |
| 72 | - getArea().then(res => { | |
| 73 | - this.areas = res.result; | |
| 74 | - this.loading = false; | |
| 75 | - for(let i =0;i<this.areas.length;i++){ | |
| 76 | - if(Number(this.infoData.place) == this.areas[i].code){ | |
| 77 | - this.infoData.place = this.areas[i].name; | |
| 78 | - } | |
| 79 | - } | |
| 80 | - }); | |
| 81 | - | |
| 82 | - let query = { | |
| 83 | - 'page':1, | |
| 84 | - 'size':9999, | |
| 85 | - 'valid':0 | |
| 86 | - } | |
| 87 | - truckList(query).then(res=>{ | |
| 88 | - this.truckList = res.result.list; | |
| 89 | - | |
| 90 | - let trucks = ""; | |
| 91 | - | |
| 92 | - for(let i in this.truckList){ | |
| 93 | - if(this.infoData.companyTrucks.split(",").indexOf(this.truckList[i].id ) > -1){ | |
| 94 | - trucks += this.truckList[i].licenseplateNo + ","; | |
| 95 | - } | |
| 90 | + for (let i in this.truckList) { | |
| 91 | + if (this.infoData.companyTrucks.split(",").indexOf(this.truckList[i].id) > -1) { | |
| 92 | + trucks += this.truckList[i].licenseplateNo + ","; | |
| 96 | 93 | } |
| 97 | - this.infoData.companyTrucks = trucks; | |
| 94 | + } | |
| 95 | + this.infoData.companyTrucks = trucks; | |
| 98 | 96 | |
| 99 | - }); | |
| 97 | + }); | |
| 100 | 98 | |
| 101 | 99 | |
| 102 | - }); | |
| 103 | - }, | |
| 104 | - selectType(value) { | |
| 105 | - if (value == "0") { | |
| 106 | - this.labelName = "工地名称"; | |
| 107 | - this.labelName2 = "绑定消纳场"; | |
| 108 | - } else { | |
| 109 | - this.labelName = "消纳场名称"; | |
| 110 | - this.labelName2 = "绑定工地"; | |
| 111 | - } | |
| 112 | - }, | |
| 113 | - } | |
| 100 | + }); | |
| 101 | + }, | |
| 102 | + selectType(value) { | |
| 103 | + if (value == "0") { | |
| 104 | + this.labelName = "工地名称"; | |
| 105 | + this.labelName2 = "绑定消纳场"; | |
| 106 | + } else { | |
| 107 | + this.labelName = "消纳场名称"; | |
| 108 | + this.labelName2 = "绑定工地"; | |
| 109 | + } | |
| 110 | + }, | |
| 111 | + } | |
| 114 | 112 | |
| 115 | 113 | } | ... | ... |
trash-ui/src/api/vio_casefile.js
| ... | ... | @@ -127,8 +127,37 @@ export default { |
| 127 | 127 | isLoadingCompany: false, |
| 128 | 128 | idInfo:null, |
| 129 | 129 | openInfo:false, |
| 130 | + slide1: [] | |
| 130 | 131 | }; |
| 131 | 132 | }, |
| 133 | + watch: { | |
| 134 | + fileEntityList(value) { | |
| 135 | + this.slide1 = [] | |
| 136 | + if (this.fileEntityList.length != 0) { | |
| 137 | + this.fileEntityList.map(item => { | |
| 138 | + if (item.name.indexOf(".jpg") > -1 || item.name.indexOf(".png") > -1 || item.name.indexOf(".jpeg") > -1 || item.name.indexOf(".jpg") > -1) { | |
| 139 | + if(item.raw!=null){ | |
| 140 | + this.slide1.push({ | |
| 141 | + src: URL.createObjectURL(item.raw), | |
| 142 | + msrc: URL.createObjectURL(item.raw), | |
| 143 | + alt: item.uid, | |
| 144 | + w: 1920, | |
| 145 | + h: 1080 | |
| 146 | + }); | |
| 147 | + }else{ | |
| 148 | + this.slide1.push({ | |
| 149 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 150 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 151 | + w: 1920, | |
| 152 | + h: 1080 | |
| 153 | + }); | |
| 154 | + } | |
| 155 | + } | |
| 156 | + }) | |
| 157 | + } | |
| 158 | + | |
| 159 | + } | |
| 160 | + }, | |
| 132 | 161 | created() { |
| 133 | 162 | getArea().then(res=>{ |
| 134 | 163 | |
| ... | ... | @@ -416,6 +445,7 @@ export default { |
| 416 | 445 | // 删除文件 |
| 417 | 446 | handleDeleteFile(index) { |
| 418 | 447 | this.fileEntityList.splice(index, 1); |
| 448 | + this.slide1.splice(index, 1); | |
| 419 | 449 | }, |
| 420 | 450 | /** 文件下载 */ |
| 421 | 451 | downloadFA(row) { | ... | ... |
trash-ui/src/api/warningInfo.js
| ... | ... | @@ -179,8 +179,37 @@ export default { |
| 179 | 179 | data: {}, |
| 180 | 180 | showPic: null, |
| 181 | 181 | picImage: null, |
| 182 | + slide1: [] | |
| 182 | 183 | }; |
| 183 | 184 | }, |
| 185 | + watch: { | |
| 186 | + fileEntityList(value) { | |
| 187 | + this.slide1 = [] | |
| 188 | + if (this.fileEntityList.length != 0) { | |
| 189 | + this.fileEntityList.map(item => { | |
| 190 | + if (item.name.indexOf(".jpg") > -1 || item.name.indexOf(".png") > -1 || item.name.indexOf(".jpeg") > -1 || item.name.indexOf(".jpg") > -1) { | |
| 191 | + if(item.raw!=null){ | |
| 192 | + this.slide1.push({ | |
| 193 | + src: URL.createObjectURL(item.raw), | |
| 194 | + msrc: URL.createObjectURL(item.raw), | |
| 195 | + alt: item.uid, | |
| 196 | + w: 1920, | |
| 197 | + h: 1080 | |
| 198 | + }); | |
| 199 | + }else{ | |
| 200 | + this.slide1.push({ | |
| 201 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 202 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 203 | + w: 1920, | |
| 204 | + h: 1080 | |
| 205 | + }); | |
| 206 | + } | |
| 207 | + } | |
| 208 | + }) | |
| 209 | + } | |
| 210 | + | |
| 211 | + } | |
| 212 | + }, | |
| 184 | 213 | created() { |
| 185 | 214 | getAreaList().then(res => { |
| 186 | 215 | this.areas = res.data; |
| ... | ... | @@ -480,6 +509,7 @@ export default { |
| 480 | 509 | // 删除文件 |
| 481 | 510 | handleDeleteFile(index) { |
| 482 | 511 | this.fileEntityList.splice(index, 1); |
| 512 | + this.slide1.splice(index, 1); | |
| 483 | 513 | }, |
| 484 | 514 | /** 文件下载 */ |
| 485 | 515 | downloadFA(row) { | ... | ... |
trash-ui/src/assets/styles/trash.scss
| 1 | - /** | |
| 2 | - * 通用css样式布局处理 | |
| 3 | - * Copyright (c) 2019 trash | |
| 4 | - */ | |
| 1 | +/** | |
| 2 | +* 通用css样式布局处理 | |
| 3 | +* Copyright (c) 2019 trash | |
| 4 | +*/ | |
| 5 | 5 | |
| 6 | - /** 基础通用 **/ | |
| 6 | +/** 基础通用 **/ | |
| 7 | 7 | .pt5 { |
| 8 | - padding-top: 5px; | |
| 8 | + padding-top: 5px; | |
| 9 | 9 | } |
| 10 | + | |
| 10 | 11 | .pr5 { |
| 11 | - padding-right: 5px; | |
| 12 | + padding-right: 5px; | |
| 12 | 13 | } |
| 14 | + | |
| 13 | 15 | .pb5 { |
| 14 | - padding-bottom: 5px; | |
| 16 | + padding-bottom: 5px; | |
| 15 | 17 | } |
| 18 | + | |
| 16 | 19 | .mt5 { |
| 17 | - margin-top: 5px; | |
| 20 | + margin-top: 5px; | |
| 18 | 21 | } |
| 22 | + | |
| 19 | 23 | .mr5 { |
| 20 | - margin-right: 5px; | |
| 24 | + margin-right: 5px; | |
| 21 | 25 | } |
| 26 | + | |
| 22 | 27 | .mb5 { |
| 23 | - margin-bottom: 5px; | |
| 28 | + margin-bottom: 5px; | |
| 24 | 29 | } |
| 30 | + | |
| 25 | 31 | .mb8 { |
| 26 | - margin-bottom: 8px; | |
| 32 | + margin-bottom: 8px; | |
| 27 | 33 | } |
| 34 | + | |
| 28 | 35 | .ml5 { |
| 29 | - margin-left: 5px; | |
| 36 | + margin-left: 5px; | |
| 30 | 37 | } |
| 38 | + | |
| 31 | 39 | .mt10 { |
| 32 | - margin-top: 10px; | |
| 40 | + margin-top: 10px; | |
| 33 | 41 | } |
| 42 | + | |
| 34 | 43 | .mr10 { |
| 35 | - margin-right: 10px; | |
| 44 | + margin-right: 10px; | |
| 36 | 45 | } |
| 46 | + | |
| 37 | 47 | .mb10 { |
| 38 | - margin-bottom: 10px; | |
| 48 | + margin-bottom: 10px; | |
| 39 | 49 | } |
| 50 | + | |
| 40 | 51 | .ml0 { |
| 41 | - margin-left: 10px; | |
| 52 | + margin-left: 10px; | |
| 42 | 53 | } |
| 54 | + | |
| 43 | 55 | .mt20 { |
| 44 | - margin-top: 20px; | |
| 56 | + margin-top: 20px; | |
| 45 | 57 | } |
| 58 | + | |
| 46 | 59 | .mr20 { |
| 47 | - margin-right: 20px; | |
| 60 | + margin-right: 20px; | |
| 48 | 61 | } |
| 62 | + | |
| 49 | 63 | .mb20 { |
| 50 | - margin-bottom: 20px; | |
| 64 | + margin-bottom: 20px; | |
| 51 | 65 | } |
| 66 | + | |
| 52 | 67 | .m20 { |
| 53 | - margin-left: 20px; | |
| 68 | + margin-left: 20px; | |
| 54 | 69 | } |
| 55 | 70 | |
| 56 | -.el-dialog:not(.is-fullscreen){ | |
| 57 | - margin-top: 6vh !important; | |
| 71 | +.el-dialog:not(.is-fullscreen) { | |
| 72 | + margin-top: 6vh !important; | |
| 58 | 73 | } |
| 59 | 74 | |
| 60 | 75 | .el-table { |
| 61 | - .el-table__header-wrapper, .el-table__fixed-header-wrapper { | |
| 62 | - th { | |
| 63 | - word-break: break-word; | |
| 64 | - background-color: #f8f8f9; | |
| 65 | - color: #515a6e; | |
| 66 | - height: 40px; | |
| 67 | - font-size: 13px; | |
| 68 | - } | |
| 69 | - } | |
| 70 | - .el-table__body-wrapper { | |
| 71 | - .el-button [class*="el-icon-"] + span { | |
| 72 | - margin-left: 1px; | |
| 73 | - } | |
| 74 | - } | |
| 76 | + .el-table__header-wrapper, .el-table__fixed-header-wrapper { | |
| 77 | + th { | |
| 78 | + word-break: break-word; | |
| 79 | + background-color: #f8f8f9; | |
| 80 | + color: #515a6e; | |
| 81 | + height: 40px; | |
| 82 | + font-size: 13px; | |
| 83 | + } | |
| 84 | + } | |
| 85 | + | |
| 86 | + .el-table__body-wrapper { | |
| 87 | + .el-button [class*="el-icon-"] + span { | |
| 88 | + margin-left: 1px; | |
| 89 | + } | |
| 90 | + } | |
| 75 | 91 | } |
| 76 | 92 | |
| 77 | 93 | /** 表单布局 **/ |
| 78 | 94 | .form-header { |
| 79 | - font-size:15px; | |
| 80 | - color:#6379bb; | |
| 81 | - border-bottom:1px solid #ddd; | |
| 82 | - margin:8px 10px 25px 10px; | |
| 83 | - padding-bottom:5px | |
| 95 | + font-size: 15px; | |
| 96 | + color: #6379bb; | |
| 97 | + border-bottom: 1px solid #ddd; | |
| 98 | + margin: 8px 10px 25px 10px; | |
| 99 | + padding-bottom: 5px | |
| 84 | 100 | } |
| 85 | 101 | |
| 86 | 102 | /** 表格布局 **/ |
| 87 | 103 | .pagination-container { |
| 88 | - position: relative; | |
| 89 | - height: 25px; | |
| 90 | - margin-bottom: 10px; | |
| 91 | - margin-top: 15px; | |
| 92 | - padding: 10px 20px !important; | |
| 104 | + position: relative; | |
| 105 | + height: 25px; | |
| 106 | + margin-bottom: 10px; | |
| 107 | + margin-top: 15px; | |
| 108 | + padding: 10px 20px !important; | |
| 93 | 109 | } |
| 94 | 110 | |
| 95 | 111 | /* tree border */ |
| 96 | 112 | .tree-border { |
| 97 | - margin-top: 5px; | |
| 98 | - border: 1px solid #e5e6e7; | |
| 99 | - background: #FFFFFF none; | |
| 100 | - border-radius:4px; | |
| 113 | + margin-top: 5px; | |
| 114 | + border: 1px solid #e5e6e7; | |
| 115 | + background: #FFFFFF none; | |
| 116 | + border-radius: 4px; | |
| 101 | 117 | } |
| 102 | 118 | |
| 103 | 119 | .pagination-container .el-pagination { |
| 104 | - right: 0; | |
| 105 | - position: absolute; | |
| 120 | + right: 0; | |
| 121 | + position: absolute; | |
| 106 | 122 | } |
| 107 | 123 | |
| 108 | 124 | .el-table .fixed-width .el-button--mini { |
| 109 | - color: #409EFF; | |
| 110 | - padding-left: 0; | |
| 111 | - padding-right: 0; | |
| 112 | - width: inherit; | |
| 125 | + color: #409EFF; | |
| 126 | + padding-left: 0; | |
| 127 | + padding-right: 0; | |
| 128 | + width: inherit; | |
| 113 | 129 | } |
| 114 | 130 | |
| 115 | 131 | .el-tree-node__content > .el-checkbox { |
| 116 | - margin-right: 8px; | |
| 132 | + margin-right: 8px; | |
| 117 | 133 | } |
| 118 | 134 | |
| 119 | 135 | .list-group-striped > .list-group-item { |
| 120 | - border-left: 0; | |
| 121 | - border-right: 0; | |
| 122 | - border-radius: 0; | |
| 123 | - padding-left: 0; | |
| 124 | - padding-right: 0; | |
| 136 | + border-left: 0; | |
| 137 | + border-right: 0; | |
| 138 | + border-radius: 0; | |
| 139 | + padding-left: 0; | |
| 140 | + padding-right: 0; | |
| 125 | 141 | } |
| 126 | 142 | |
| 127 | 143 | .list-group { |
| 128 | - padding-left: 0px; | |
| 129 | - list-style: none; | |
| 144 | + padding-left: 0px; | |
| 145 | + list-style: none; | |
| 130 | 146 | } |
| 131 | 147 | |
| 132 | 148 | .list-group-item { |
| 133 | - border-bottom: 1px solid #e7eaec; | |
| 134 | - border-top: 1px solid #e7eaec; | |
| 135 | - margin-bottom: -1px; | |
| 136 | - padding: 11px 0px; | |
| 137 | - font-size: 13px; | |
| 149 | + border-bottom: 1px solid #e7eaec; | |
| 150 | + border-top: 1px solid #e7eaec; | |
| 151 | + margin-bottom: -1px; | |
| 152 | + padding: 11px 0px; | |
| 153 | + font-size: 13px; | |
| 138 | 154 | } |
| 139 | 155 | |
| 140 | 156 | .pull-right { |
| 141 | - float: right !important; | |
| 157 | + float: right !important; | |
| 142 | 158 | } |
| 143 | 159 | |
| 144 | 160 | .el-card__header { |
| 145 | - padding: 14px 15px 7px; | |
| 146 | - min-height: 40px; | |
| 161 | + padding: 14px 15px 7px; | |
| 162 | + min-height: 40px; | |
| 147 | 163 | } |
| 148 | 164 | |
| 149 | 165 | .el-card__body { |
| 150 | - padding: 15px 20px 20px 20px; | |
| 166 | + padding: 15px 20px 20px 20px; | |
| 151 | 167 | } |
| 152 | 168 | |
| 153 | 169 | .card-box { |
| 154 | - padding-right: 15px; | |
| 155 | - padding-left: 15px; | |
| 156 | - margin-bottom: 10px; | |
| 170 | + padding-right: 15px; | |
| 171 | + padding-left: 15px; | |
| 172 | + margin-bottom: 10px; | |
| 157 | 173 | } |
| 158 | 174 | |
| 159 | 175 | /* button color */ |
| ... | ... | @@ -179,62 +195,77 @@ |
| 179 | 195 | |
| 180 | 196 | /* text color */ |
| 181 | 197 | .text-navy { |
| 182 | - color: #1ab394; | |
| 198 | + color: #1ab394; | |
| 183 | 199 | } |
| 184 | 200 | |
| 185 | 201 | .text-primary { |
| 186 | - color: inherit; | |
| 202 | + color: inherit; | |
| 187 | 203 | } |
| 188 | 204 | |
| 189 | 205 | .text-success { |
| 190 | - color: #1c84c6; | |
| 206 | + color: #1c84c6; | |
| 191 | 207 | } |
| 192 | 208 | |
| 193 | 209 | .text-info { |
| 194 | - color: #23c6c8; | |
| 210 | + color: #23c6c8; | |
| 195 | 211 | } |
| 196 | 212 | |
| 197 | 213 | .text-warning { |
| 198 | - color: #f8ac59; | |
| 214 | + color: #f8ac59; | |
| 199 | 215 | } |
| 200 | 216 | |
| 201 | 217 | .text-danger { |
| 202 | - color: #ed5565; | |
| 218 | + color: #ed5565; | |
| 203 | 219 | } |
| 204 | 220 | |
| 205 | 221 | .text-muted { |
| 206 | - color: #888888; | |
| 222 | + color: #888888; | |
| 207 | 223 | } |
| 208 | 224 | |
| 209 | 225 | /* image */ |
| 210 | 226 | .img-circle { |
| 211 | - border-radius: 50%; | |
| 227 | + border-radius: 50%; | |
| 212 | 228 | } |
| 213 | 229 | |
| 214 | 230 | .img-lg { |
| 215 | - width: 120px; | |
| 216 | - height: 120px; | |
| 231 | + width: 120px; | |
| 232 | + height: 120px; | |
| 217 | 233 | } |
| 218 | 234 | |
| 219 | 235 | .avatar-upload-preview { |
| 220 | - position: absolute; | |
| 221 | - top: 50%; | |
| 222 | - transform: translate(50%, -50%); | |
| 223 | - width: 180px; | |
| 224 | - height: 180px; | |
| 225 | - border-radius: 50%; | |
| 226 | - box-shadow: 0 0 4px #ccc; | |
| 227 | - overflow: hidden; | |
| 236 | + position: absolute; | |
| 237 | + top: 50%; | |
| 238 | + transform: translate(50%, -50%); | |
| 239 | + width: 180px; | |
| 240 | + height: 180px; | |
| 241 | + border-radius: 50%; | |
| 242 | + box-shadow: 0 0 4px #ccc; | |
| 243 | + overflow: hidden; | |
| 228 | 244 | } |
| 229 | 245 | |
| 230 | 246 | /* 拖拽列样式 */ |
| 231 | -.sortable-ghost{ | |
| 232 | - opacity: .8; | |
| 233 | - color: #fff!important; | |
| 234 | - background: #42b983!important; | |
| 247 | +.sortable-ghost { | |
| 248 | + opacity: .8; | |
| 249 | + color: #fff !important; | |
| 250 | + background: #42b983 !important; | |
| 235 | 251 | } |
| 236 | 252 | |
| 237 | 253 | .top-right-btn { |
| 238 | - position: relative; | |
| 239 | - float: right; | |
| 240 | -} | |
| 241 | 254 | \ No newline at end of file |
| 255 | + position: relative; | |
| 256 | + float: right; | |
| 257 | +} | |
| 258 | + | |
| 259 | +//vue-preview 全局样式开始 | |
| 260 | +[itemscope="itemscope"] figure { | |
| 261 | + float:left; | |
| 262 | + margin: 0 10px 0 0; | |
| 263 | + width: 100px; | |
| 264 | + height: 100px; | |
| 265 | +} | |
| 266 | + | |
| 267 | +[itemscope="itemscope"] figure img { | |
| 268 | + width: 100%; | |
| 269 | + height: 100%; | |
| 270 | +} | |
| 271 | + | |
| 272 | +//vue-preview 全局样式结束 | ... | ... |
trash-ui/src/layout/index.vue
| 1 | 1 | <template> |
| 2 | - <app-main /> | |
| 2 | + <div :class="classObj" class="app-wrapper"> | |
| 3 | + <sidebar class="sidebar-container"/> | |
| 4 | + <div :class="{hasTagsView:needTagsView}" class="main-container"> | |
| 5 | + <tags-view v-if="needTagsView"/> | |
| 6 | + <app-main/> | |
| 7 | + | |
| 8 | + </div> | |
| 9 | + </div> | |
| 3 | 10 | </template> |
| 4 | 11 | |
| 5 | 12 | <script> |
| 6 | 13 | import RightPanel from '@/components/RightPanel' |
| 7 | -import { AppMain, Navbar, Settings, Sidebar, TagsView } from './components' | |
| 14 | +import {AppMain, Navbar, Settings, Sidebar, TagsView} from './components' | |
| 8 | 15 | import ResizeMixin from './mixin/ResizeHandler' |
| 9 | -import { mapState } from 'vuex' | |
| 16 | +import {mapState} from 'vuex' | |
| 10 | 17 | |
| 11 | 18 | export default { |
| 12 | 19 | name: 'Layout', |
| ... | ... | @@ -38,52 +45,63 @@ export default { |
| 38 | 45 | }, |
| 39 | 46 | methods: { |
| 40 | 47 | handleClickOutside() { |
| 41 | - this.$store.dispatch('app/closeSideBar', { withoutAnimation: false }) | |
| 48 | + this.$store.dispatch('app/closeSideBar', {withoutAnimation: false}) | |
| 42 | 49 | } |
| 43 | 50 | } |
| 44 | 51 | } |
| 45 | 52 | </script> |
| 46 | 53 | |
| 47 | 54 | <style lang="scss" scoped> |
| 48 | - @import "~@/assets/styles/mixin.scss"; | |
| 49 | - @import "~@/assets/styles/variables.scss"; | |
| 50 | - | |
| 51 | - .app-wrapper { | |
| 52 | - @include clearfix; | |
| 53 | - position: relative; | |
| 54 | - height: 100%; | |
| 55 | - width: 100%; | |
| 56 | - | |
| 57 | - &.mobile.openSidebar { | |
| 58 | - position: fixed; | |
| 59 | - top: 0; | |
| 60 | - } | |
| 61 | - } | |
| 55 | +@import "~@/assets/styles/mixin.scss"; | |
| 56 | +@import "~@/assets/styles/variables.scss"; | |
| 62 | 57 | |
| 63 | - .drawer-bg { | |
| 64 | - background: #000; | |
| 65 | - opacity: 0.3; | |
| 66 | - width: 100%; | |
| 67 | - top: 0; | |
| 68 | - height: 100%; | |
| 69 | - position: absolute; | |
| 70 | - z-index: 999; | |
| 71 | - } | |
| 58 | +.app-wrapper { | |
| 59 | + @include clearfix; | |
| 60 | + position: relative; | |
| 61 | + height: 100%; | |
| 62 | + width: 100%; | |
| 72 | 63 | |
| 73 | - .fixed-header { | |
| 64 | + &.mobile.openSidebar { | |
| 74 | 65 | position: fixed; |
| 75 | 66 | top: 0; |
| 76 | - right: 0; | |
| 77 | - z-index: 9; | |
| 78 | - width: calc(100% - #{$sideBarWidth}); | |
| 79 | - transition: width 0.28s; | |
| 80 | 67 | } |
| 68 | +} | |
| 81 | 69 | |
| 82 | - .hideSidebar .fixed-header { | |
| 83 | - width: calc(100% - 54px) | |
| 84 | - } | |
| 70 | +.drawer-bg { | |
| 71 | + background: #000; | |
| 72 | + opacity: 0.3; | |
| 73 | + width: 100%; | |
| 74 | + top: 0; | |
| 75 | + height: 100%; | |
| 76 | + position: absolute; | |
| 77 | + z-index: 999; | |
| 78 | +} | |
| 85 | 79 | |
| 86 | - .mobile .fixed-header { | |
| 87 | - width: 100%; | |
| 88 | - } | |
| 80 | +.fixed-header { | |
| 81 | + position: fixed; | |
| 82 | + top: 0; | |
| 83 | + right: 0; | |
| 84 | + z-index: 9; | |
| 85 | + width: calc(100% - #{$sideBarWidth}); | |
| 86 | + transition: width 0.28s; | |
| 87 | +} | |
| 88 | + | |
| 89 | +.hideSidebar .fixed-header { | |
| 90 | + width: calc(100% - 54px) | |
| 91 | +} | |
| 92 | + | |
| 93 | +.mobile .fixed-header { | |
| 94 | + width: 100%; | |
| 95 | +} | |
| 96 | + | |
| 97 | +.preview figure { | |
| 98 | + float: left; | |
| 99 | + width: 30%; | |
| 100 | + height:calc(30vw - 0px); | |
| 101 | + margin: 1.5%; | |
| 102 | +} | |
| 103 | + | |
| 104 | +.preview figure img { | |
| 105 | + width: 400px; | |
| 106 | +} | |
| 89 | 107 | </style> | ... | ... |
trash-ui/src/layout/index4.vue renamed to trash-ui/src/layout/index1.vue
trash-ui/src/main.js
| ... | ... | @@ -22,6 +22,8 @@ import { parseTime, resetForm, addDateRange, selectDictLabel, selectDictLabels, |
| 22 | 22 | import Pagination from "@/components/Pagination"; |
| 23 | 23 | //自定义表格工具扩展 |
| 24 | 24 | import RightToolbar from "@/components/RightToolbar" |
| 25 | +//缩略图插件 | |
| 26 | +import VuePreview from "vue-preview"; | |
| 25 | 27 | |
| 26 | 28 | // 全局方法挂载 |
| 27 | 29 | Vue.prototype.getDicts = getDicts |
| ... | ... | @@ -54,6 +56,8 @@ Vue.component('Pagination', Pagination) |
| 54 | 56 | Vue.component('RightToolbar', RightToolbar) |
| 55 | 57 | |
| 56 | 58 | Vue.use(permission) |
| 59 | +//缩略图插件 | |
| 60 | +Vue.use(VuePreview) | |
| 57 | 61 | |
| 58 | 62 | /** |
| 59 | 63 | * If you don't want to use mock-server | ... | ... |
trash-ui/src/views/business/threestep/index.vue
| ... | ... | @@ -179,7 +179,6 @@ |
| 179 | 179 | <el-col :span="12"> |
| 180 | 180 | <el-form-item label="联系电话" prop="phone"> |
| 181 | 181 | <el-input v-model="form.phone" :maxlength="11" show-word-limit /> |
| 182 | - </el-select> | |
| 183 | 182 | </el-form-item> |
| 184 | 183 | </el-col> |
| 185 | 184 | </el-row> |
| ... | ... | @@ -191,21 +190,25 @@ |
| 191 | 190 | <el-row type="flex" justify="center" style="margin-top: 20px;" v-if="form.type != null"> |
| 192 | 191 | <el-col :span="6"> |
| 193 | 192 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(0)">过水槽照片</a> |
| 193 | + <vue-preview :slides="slides[0]"></vue-preview> | |
| 194 | 194 | <el-input v-model="form.img0" type="hidden"></el-input> |
| 195 | 195 | <p v-for="img,index in form.img0">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(0,img)" style="color:red"> x</a></p> |
| 196 | 196 | </el-col> |
| 197 | 197 | <el-col :span="6"> |
| 198 | 198 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(1)">洗车平台照片</a> |
| 199 | + <vue-preview :slides="slides[1]"></vue-preview> | |
| 199 | 200 | <el-input v-model="form.img1" type="hidden"></el-input> |
| 200 | 201 | <p v-for="img,index in form.img1">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(1,img)" style="color:red"> x</a></p> |
| 201 | 202 | </el-col> |
| 202 | 203 | <el-col :span="6"> |
| 203 | 204 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(2)">出入口照片</a> |
| 205 | + <vue-preview :slides="slides[2]"></vue-preview> | |
| 204 | 206 | <el-input v-model="form.img2" type="hidden"></el-input> |
| 205 | 207 | <p v-for="img,index in form.img2">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(2,img)" style="color:red"> x</a></p> |
| 206 | 208 | </el-col> |
| 207 | 209 | <el-col :span="6"> |
| 208 | 210 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(3)">沉淀池照片</a> |
| 211 | + <vue-preview :slides="slides[3]"></vue-preview> | |
| 209 | 212 | <el-input v-model="form.img3" type="hidden"></el-input> |
| 210 | 213 | <p v-for="img,index in form.img3">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(3,img)" style="color:red"> x</a></p> |
| 211 | 214 | </el-col> |
| ... | ... | @@ -213,21 +216,25 @@ |
| 213 | 216 | <el-row type="flex" justify="center" v-if="form.type != null"> |
| 214 | 217 | <el-col :span="6"> |
| 215 | 218 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(4)">硬质路面照片</a> |
| 219 | + <vue-preview :slides="slides[4]"></vue-preview> | |
| 216 | 220 | <el-input v-model="form.img4" type="hidden"></el-input> |
| 217 | 221 | <p v-for="img,index in form.img4">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(4,img)" style="color:red"> x</a></p> |
| 218 | 222 | </el-col> |
| 219 | 223 | <el-col :span="6"> |
| 220 | 224 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(5)">{{form.type==0?"摄像头视频截图1":"洗车设施照片"}}</a> |
| 225 | + <vue-preview :slides="slides[5]"></vue-preview> | |
| 221 | 226 | <el-input v-model="form.img5" type="hidden"></el-input> |
| 222 | 227 | <p v-for="img,index in form.img5">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(5,img)" style="color:red"> x</a></p> |
| 223 | 228 | </el-col> |
| 224 | 229 | <el-col :span="6"> |
| 225 | 230 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(6)">{{form.type==0?"摄像头视频截图2":"雾炮机"}}</a> |
| 231 | + <vue-preview :slides="slides[6]"></vue-preview> | |
| 226 | 232 | <el-input v-model="form.img6" type="hidden"></el-input> |
| 227 | 233 | <p v-for="img,index in form.img6">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(6,img)" style="color:red"> x</a></p> |
| 228 | 234 | </el-col> |
| 229 | 235 | <el-col :span="6"> |
| 230 | 236 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(7)">{{form.type==0?"摄像头视频截图3":"裸露黄土覆盖照片"}}</a> |
| 237 | + <vue-preview :slides="slides[7]"></vue-preview> | |
| 231 | 238 | <el-input v-model="form.img7" type="hidden"></el-input> |
| 232 | 239 | <p v-for="img,index in form.img7">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(7,img)" style="color:red"> x</a></p> |
| 233 | 240 | </el-col> |
| ... | ... | @@ -235,31 +242,33 @@ |
| 235 | 242 | <el-row type="flex" justify="center" v-if="form.type != null"> |
| 236 | 243 | <el-col :span="5"> |
| 237 | 244 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(8)">其他1</a> |
| 245 | + <vue-preview :slides="slides[8]"></vue-preview> | |
| 238 | 246 | <el-input v-model="form.img8" type="hidden"></el-input> |
| 239 | 247 | <p v-for="img,index in form.img8">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(8,img)" style="color:red"> x</a></p> |
| 240 | 248 | </el-col> |
| 241 | 249 | <el-col :span="5"> |
| 242 | 250 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(9)">其他2</a> |
| 251 | + <vue-preview :slides="slides[9]"></vue-preview> | |
| 243 | 252 | <el-input v-model="form.img9" type="hidden"></el-input> |
| 244 | 253 | <p v-for="img,index in form.img9">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(9,img)" style="color:red"> x</a></p> |
| 245 | 254 | </el-col> |
| 246 | 255 | <el-col :span="5"> |
| 247 | 256 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(10)">其他3</a> |
| 257 | + <vue-preview :slides="slides[10]"></vue-preview> | |
| 248 | 258 | <el-input v-model="form.img10" type="hidden"></el-input> |
| 249 | - <p v-for="img,index in form.img10">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(10,img)" style="color:red"> x</a> | |
| 250 | - </p> | |
| 259 | + <p v-for="img,index in form.img10">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(10,img)" style="color:red"> x</a></p> | |
| 251 | 260 | </el-col> |
| 252 | 261 | <el-col :span="5"> |
| 253 | 262 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(11)">其他4</a> |
| 263 | + <vue-preview :slides="slides[11]"></vue-preview> | |
| 254 | 264 | <el-input v-model="form.img11" type="hidden"></el-input> |
| 255 | - <p v-for="img,index in form.img11">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(11,img)" style="color:red"> x</a> | |
| 256 | - </p> | |
| 265 | + <p v-for="img,index in form.img11">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(11,img)" style="color:red"> x</a></p> | |
| 257 | 266 | </el-col> |
| 258 | 267 | <el-col :span="4"> |
| 259 | 268 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(12)">其他5</a> |
| 269 | + <vue-preview :slides="slides[12]"></vue-preview> | |
| 260 | 270 | <el-input v-model="form.img12" type="hidden"></el-input> |
| 261 | - <p v-for="img,index in form.img12">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(12,img)" style="color:red"> x</a> | |
| 262 | - </p> | |
| 271 | + <p v-for="img,index in form.img12">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(12,img)" style="color:red"> x</a></p> | |
| 263 | 272 | </el-col> |
| 264 | 273 | </el-row> |
| 265 | 274 | ... | ... |
trash-ui/src/views/business/threestep/threestepInfo.vue
| ... | ... | @@ -52,7 +52,6 @@ |
| 52 | 52 | <el-col :span="12"> |
| 53 | 53 | <el-form-item label="运输车辆" prop="companyTrucks"> |
| 54 | 54 | <el-input type="textarea" v-model="infoData.companyTrucks" disabled /> |
| 55 | - </el-select> | |
| 56 | 55 | </el-form-item> |
| 57 | 56 | </el-col> |
| 58 | 57 | </el-row> |
| ... | ... | @@ -73,130 +72,117 @@ |
| 73 | 72 | <el-col :span="4"> |
| 74 | 73 | 过水槽照片 |
| 75 | 74 | </el-col> |
| 76 | - <el-col :span="20"> | |
| 77 | - <el-row v-for="img,index in infoData.img0.split(',')" style="margin-bottom:10px;"> | |
| 78 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 79 | - </el-row> | |
| 75 | + <el-col :span="4" v-for="img,index in infoData.img0.split(',')" style="margin-bottom:10px;"> | |
| 76 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 77 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 80 | 78 | </el-col> |
| 81 | 79 | </el-row> |
| 82 | 80 | <el-row v-if="infoData.img1" > |
| 83 | 81 | <el-col :span="4"> |
| 84 | 82 | 洗车平台照片 |
| 85 | 83 | </el-col> |
| 86 | - <el-col :span="20"> | |
| 87 | - <el-row v-for="img,index in infoData.img1.split(',')" style="margin-bottom:10px;"> | |
| 88 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 89 | - </el-row> | |
| 84 | + <el-col :span="4" v-for="img,index in infoData.img1.split(',')" style="margin-bottom:10px;"> | |
| 85 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 86 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 90 | 87 | </el-col> |
| 91 | 88 | </el-row> |
| 92 | 89 | <el-row v-if="infoData.img2" > |
| 93 | 90 | <el-col :span="4"> |
| 94 | 91 | 出入口照片 |
| 95 | 92 | </el-col> |
| 96 | - <el-col :span="20"> | |
| 97 | - <el-row v-for="img,index in infoData.img2.split(',')" style="margin-bottom:10px;"> | |
| 98 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 99 | - </el-row> | |
| 93 | + <el-col :span="4" v-for="img,index in infoData.img2.split(',')" style="margin-bottom:10px;"> | |
| 94 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 95 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 100 | 96 | </el-col> |
| 101 | 97 | </el-row> |
| 102 | 98 | <el-row v-if="infoData.img3" > |
| 103 | 99 | <el-col :span="4"> |
| 104 | 100 | 沉淀池照片 |
| 105 | 101 | </el-col> |
| 106 | - <el-col :span="20"> | |
| 107 | - <el-row v-for="img,index in infoData.img3.split(',')" style="margin-bottom:10px;"> | |
| 108 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 109 | - </el-row> | |
| 102 | + <el-col :span="4" v-for="img,index in infoData.img3.split(',')" style="margin-bottom:10px;"> | |
| 103 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 104 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 110 | 105 | </el-col> |
| 111 | 106 | </el-row> |
| 112 | 107 | <el-row v-if="infoData.img4" > |
| 113 | 108 | <el-col :span="4"> |
| 114 | 109 | 硬质路面照片 |
| 115 | 110 | </el-col> |
| 116 | - <el-col :span="20"> | |
| 117 | - <el-row v-for="img,index in infoData.img4.split(',')" style="margin-bottom:10px;"> | |
| 118 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 119 | - </el-row> | |
| 111 | + <el-col :span="4" v-for="img,index in infoData.img4.split(',')" style="margin-bottom:10px;"> | |
| 112 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 113 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 120 | 114 | </el-col> |
| 121 | 115 | </el-row> |
| 122 | 116 | <el-row v-if="infoData.img5" > |
| 123 | 117 | <el-col :span="4"> |
| 124 | 118 | {{infoData.type==0?"摄像头视频截图1":"洗车设施照片"}} |
| 125 | 119 | </el-col> |
| 126 | - <el-col :span="20"> | |
| 127 | - <el-row v-for="img,index in infoData.img5.split(',')" style="margin-bottom:10px;"> | |
| 128 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 129 | - </el-row> | |
| 120 | + <el-col :span="4" v-for="img,index in infoData.img5.split(',')" style="margin-bottom:10px;"> | |
| 121 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 122 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 130 | 123 | </el-col> |
| 131 | 124 | </el-row> |
| 132 | 125 | <el-row v-if="infoData.img6" > |
| 133 | 126 | <el-col :span="4"> |
| 134 | 127 | {{infoData.type==0?"摄像头视频截图2":"雾炮机"}} |
| 135 | 128 | </el-col> |
| 136 | - <el-col :span="20"> | |
| 137 | - <el-row v-for="img,index in infoData.img6.split(',')" style="margin-bottom:10px;"> | |
| 138 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 139 | - </el-row> | |
| 129 | + <el-col :span="4" v-for="img,index in infoData.img6.split(',')" style="margin-bottom:10px;"> | |
| 130 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 131 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 140 | 132 | </el-col> |
| 141 | 133 | </el-row> |
| 142 | 134 | <el-row v-if="infoData.img7" > |
| 143 | 135 | <el-col :span="4"> |
| 144 | 136 | {{infoData.type==0?"摄像头视频截图3":"裸露黄土覆盖照片"}} |
| 145 | 137 | </el-col> |
| 146 | - <el-col :span="20"> | |
| 147 | - <el-row v-for="img,index in infoData.img7.split(',')" style="margin-bottom:10px;"> | |
| 148 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 149 | - </el-row> | |
| 138 | + <el-col :span="4" v-for="img,index in infoData.img7.split(',')" style="margin-bottom:10px;"> | |
| 139 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 140 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 150 | 141 | </el-col> |
| 151 | 142 | </el-row> |
| 152 | 143 | <el-row v-if="infoData.img8" > |
| 153 | 144 | <el-col :span="4"> |
| 154 | 145 | 其他1 |
| 155 | 146 | </el-col> |
| 156 | - <el-col :span="20"> | |
| 157 | - <el-row v-for="img,index in infoData.img8.split(',')" style="margin-bottom:10px;"> | |
| 158 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 159 | - </el-row> | |
| 160 | - </el-col> | |
| 147 | + <el-col :span="4" v-for="img,index in infoData.img8.split(',')" style="margin-bottom:10px;"> | |
| 148 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 149 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 150 | + </el-col> | |
| 161 | 151 | </el-row> |
| 162 | 152 | <el-row v-if="infoData.img9" > |
| 163 | 153 | <el-col :span="4"> |
| 164 | 154 | 其他2 |
| 165 | 155 | </el-col> |
| 166 | - <el-col :span="20"> | |
| 167 | - <el-row v-for="img,index in infoData.img9.split(',')" style="margin-bottom:10px;"> | |
| 168 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 169 | - </el-row> | |
| 156 | + <el-col :span="4" v-for="img,index in infoData.img9.split(',')" style="margin-bottom:10px;"> | |
| 157 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 158 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 170 | 159 | </el-col> |
| 171 | 160 | </el-row> |
| 172 | 161 | <el-row v-if="infoData.img10" > |
| 173 | 162 | <el-col :span="4"> |
| 174 | 163 | 其他3 |
| 175 | 164 | </el-col> |
| 176 | - <el-col :span="20"> | |
| 177 | - <el-row v-for="img,index in infoData.img10.split(',')" style="margin-bottom:10px;"> | |
| 178 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 179 | - </el-row> | |
| 165 | + <el-col :span="4" v-for="img,index in infoData.img10.split(',')" style="margin-bottom:10px;"> | |
| 166 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 167 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 180 | 168 | </el-col> |
| 181 | 169 | </el-row> |
| 182 | 170 | <el-row v-if="infoData.img11" > |
| 183 | 171 | <el-col :span="4"> |
| 184 | 172 | 其他4 |
| 185 | 173 | </el-col> |
| 186 | - <el-col :span="20"> | |
| 187 | - <el-row v-for="img,index in infoData.img11.split(',')" style="margin-bottom:10px;"> | |
| 188 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 189 | - </el-row> | |
| 174 | + <el-col :span="4" v-for="img,index in infoData.img11.split(',')" style="margin-bottom:10px;"> | |
| 175 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 176 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 190 | 177 | </el-col> |
| 191 | 178 | </el-row> |
| 192 | 179 | <el-row v-if="infoData.img12" > |
| 193 | 180 | <el-col :span="4"> |
| 194 | 181 | 其他5 |
| 195 | 182 | </el-col> |
| 196 | - <el-col :span="20"> | |
| 197 | - <el-row v-for="img,index in infoData.img12.split(',')" style="margin-bottom:10px;"> | |
| 198 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 199 | - </el-row> | |
| 183 | + <el-col :span="4" v-for="img,index in infoData.img12.split(',')" style="margin-bottom:10px;"> | |
| 184 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 185 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 200 | 186 | </el-col> |
| 201 | 187 | </el-row> |
| 202 | 188 | |
| ... | ... | @@ -236,130 +222,117 @@ |
| 236 | 222 | <el-col :span="4"> |
| 237 | 223 | 履职情况照片 |
| 238 | 224 | </el-col> |
| 239 | - <el-col :span="20"> | |
| 240 | - <el-row v-for="img,index in infoData.sub_img0.split(',')" style="margin-bottom:10px;"> | |
| 241 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 242 | - </el-row> | |
| 225 | + <el-col :span="4" v-for="img,index in infoData.sub_img0.split(',')" style="margin-bottom:10px;"> | |
| 226 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 227 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 243 | 228 | </el-col> |
| 244 | 229 | </el-row> |
| 245 | 230 | <el-row v-if="infoData.sub_img1" > |
| 246 | 231 | <el-col :span="4"> |
| 247 | 232 | 水枪水嘴照片 |
| 248 | 233 | </el-col> |
| 249 | - <el-col :span="20"> | |
| 250 | - <el-row v-for="img,index in infoData.sub_img1.split(',')" style="margin-bottom:10px;"> | |
| 251 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 252 | - </el-row> | |
| 234 | + <el-col :span="4" v-for="img,index in infoData.sub_img1.split(',')" style="margin-bottom:10px;"> | |
| 235 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 236 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 253 | 237 | </el-col> |
| 254 | 238 | </el-row> |
| 255 | 239 | <el-row v-if="infoData.sub_img2" > |
| 256 | 240 | <el-col :span="4"> |
| 257 | 241 | 照明照片 |
| 258 | 242 | </el-col> |
| 259 | - <el-col :span="20"> | |
| 260 | - <el-row v-for="img,index in infoData.sub_img2.split(',')" style="margin-bottom:10px;"> | |
| 261 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 262 | - </el-row> | |
| 243 | + <el-col :span="4" v-for="img,index in infoData.sub_img2.split(',')" style="margin-bottom:10px;"> | |
| 244 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 245 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 263 | 246 | </el-col> |
| 264 | 247 | </el-row> |
| 265 | 248 | <el-row v-if="infoData.sub_img3" > |
| 266 | 249 | <el-col :span="4"> |
| 267 | 250 | 视频监控照片 |
| 268 | 251 | </el-col> |
| 269 | - <el-col :span="20"> | |
| 270 | - <el-row v-for="img,index in infoData.sub_img3.split(',')" style="margin-bottom:10px;"> | |
| 271 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 272 | - </el-row> | |
| 252 | + <el-col :span="4" v-for="img,index in infoData.sub_img3.split(',')" style="margin-bottom:10px;"> | |
| 253 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 254 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 273 | 255 | </el-col> |
| 274 | 256 | </el-row> |
| 275 | 257 | <el-row v-if="infoData.sub_img4" > |
| 276 | 258 | <el-col :span="4"> |
| 277 | 259 | 洗车机照片 |
| 278 | 260 | </el-col> |
| 279 | - <el-col :span="20"> | |
| 280 | - <el-row v-for="img,index in infoData.sub_img4.split(',')" style="margin-bottom:10px;"> | |
| 281 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 282 | - </el-row> | |
| 261 | + <el-col :span="4" v-for="img,index in infoData.sub_img4.split(',')" style="margin-bottom:10px;"> | |
| 262 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 263 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 283 | 264 | </el-col> |
| 284 | 265 | </el-row> |
| 285 | 266 | <el-row v-if="infoData.sub_img5" > |
| 286 | 267 | <el-col :span="4"> |
| 287 | 268 | {{infoData.type==0?"摄像头视频截图1":"洗车设施照片"}} |
| 288 | 269 | </el-col> |
| 289 | - <el-col :span="20"> | |
| 290 | - <el-row v-for="img,index in infoData.sub_img5.split(',')" style="margin-bottom:10px;"> | |
| 291 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 292 | - </el-row> | |
| 270 | + <el-col :span="4" v-for="img,index in infoData.sub_img5.split(',')" style="margin-bottom:10px;"> | |
| 271 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 272 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 293 | 273 | </el-col> |
| 294 | 274 | </el-row> |
| 295 | 275 | <el-row v-if="infoData.sub_img6" > |
| 296 | 276 | <el-col :span="4"> |
| 297 | 277 | {{infoData.type==0?"摄像头视频截图2":"雾炮机"}} |
| 298 | 278 | </el-col> |
| 299 | - <el-col :span="20"> | |
| 300 | - <el-row v-for="img,index in infoData.sub_img6.split(',')" style="margin-bottom:10px;"> | |
| 301 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 302 | - </el-row> | |
| 279 | + <el-col :span="4" v-for="img,index in infoData.sub_img6.split(',')" style="margin-bottom:10px;"> | |
| 280 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 281 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 303 | 282 | </el-col> |
| 304 | 283 | </el-row> |
| 305 | 284 | <el-row v-if="infoData.sub_img7" > |
| 306 | 285 | <el-col :span="4"> |
| 307 | 286 | {{infoData.type==0?"摄像头视频截图3":"裸露黄土覆盖照片"}} |
| 308 | 287 | </el-col> |
| 309 | - <el-col :span="20"> | |
| 310 | - <el-row v-for="img,index in infoData.sub_img7.split(',')" style="margin-bottom:10px;"> | |
| 311 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 312 | - </el-row> | |
| 288 | + <el-col :span="4" v-for="img,index in infoData.sub_img7.split(',')" style="margin-bottom:10px;"> | |
| 289 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 290 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 313 | 291 | </el-col> |
| 314 | 292 | </el-row> |
| 315 | 293 | <el-row v-if="infoData.sub_img8" > |
| 316 | 294 | <el-col :span="4"> |
| 317 | 295 | 其他1 |
| 318 | 296 | </el-col> |
| 319 | - <el-col :span="20"> | |
| 320 | - <el-row v-for="img,index in infoData.sub_img8.split(',')" style="margin-bottom:10px;"> | |
| 321 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 322 | - </el-row> | |
| 323 | - </el-col> | |
| 297 | + <el-col :span="4" v-for="img,index in infoData.sub_img8.split(',')" style="margin-bottom:10px;"> | |
| 298 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 299 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 300 | + </el-col> | |
| 324 | 301 | </el-row> |
| 325 | 302 | <el-row v-if="infoData.sub_img9" > |
| 326 | 303 | <el-col :span="4"> |
| 327 | 304 | 其他2 |
| 328 | 305 | </el-col> |
| 329 | - <el-col :span="20"> | |
| 330 | - <el-row v-for="img,index in infoData.sub_img9.split(',')" style="margin-bottom:10px;"> | |
| 331 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 332 | - </el-row> | |
| 306 | + <el-col :span="4" v-for="img,index in infoData.sub_img9.split(',')" style="margin-bottom:10px;"> | |
| 307 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 308 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 333 | 309 | </el-col> |
| 334 | 310 | </el-row> |
| 335 | 311 | <el-row v-if="infoData.sub_img10" > |
| 336 | 312 | <el-col :span="4"> |
| 337 | 313 | 其他3 |
| 338 | 314 | </el-col> |
| 339 | - <el-col :span="20"> | |
| 340 | - <el-row v-for="img,index in infoData.sub_img10.split(',')" style="margin-bottom:10px;"> | |
| 341 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 342 | - </el-row> | |
| 315 | + <el-col :span="4" v-for="img,index in infoData.sub_img10.split(',')" style="margin-bottom:10px;"> | |
| 316 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 317 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 343 | 318 | </el-col> |
| 344 | 319 | </el-row> |
| 345 | 320 | <el-row v-if="infoData.sub_img11" > |
| 346 | 321 | <el-col :span="4"> |
| 347 | 322 | 其他4 |
| 348 | 323 | </el-col> |
| 349 | - <el-col :span="20"> | |
| 350 | - <el-row v-for="img,index in infoData.sub_img11.split(',')" style="margin-bottom:10px;"> | |
| 351 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 352 | - </el-row> | |
| 324 | + <el-col :span="4" v-for="img,index in infoData.sub_img11.split(',')" style="margin-bottom:10px;"> | |
| 325 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 326 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 353 | 327 | </el-col> |
| 354 | 328 | </el-row> |
| 355 | 329 | <el-row v-if="infoData.sub_img12" > |
| 356 | 330 | <el-col :span="4"> |
| 357 | 331 | 其他5 |
| 358 | 332 | </el-col> |
| 359 | - <el-col :span="20"> | |
| 360 | - <el-row v-for="img,index in infoData.sub_img12.split(',')" style="margin-bottom:10px;"> | |
| 361 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 362 | - </el-row> | |
| 333 | + <el-col :span="4" v-for="img,index in infoData.sub_img12.split(',')" style="margin-bottom:10px;"> | |
| 334 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 335 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 363 | 336 | </el-col> |
| 364 | 337 | </el-row> |
| 365 | 338 | |
| ... | ... | @@ -388,34 +361,31 @@ |
| 388 | 361 | <el-col :span="4"> |
| 389 | 362 | 附件1 |
| 390 | 363 | </el-col> |
| 391 | - <el-col :span="20"> | |
| 392 | - <el-row v-for="img,index in infoData.attchItem1.split(',')" style="margin-bottom:10px;"> | |
| 393 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 394 | - </el-row> | |
| 364 | + <el-col :span="4" v-for="img,index in infoData.attchItem1.split(',')" style="margin-bottom:10px;"> | |
| 365 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 366 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 395 | 367 | </el-col> |
| 396 | 368 | </el-row> |
| 397 | 369 | <el-row v-if="infoData.attchItem2" > |
| 398 | 370 | <el-col :span="4"> |
| 399 | 371 | 附件2 |
| 400 | 372 | </el-col> |
| 401 | - <el-col :span="20"> | |
| 402 | - <el-row v-for="img,index in infoData.attchItem2.split(',')" style="margin-bottom:10px;"> | |
| 403 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 404 | - </el-row> | |
| 373 | + <el-col :span="4" v-for="img,index in infoData.attchItem2.split(',')" style="margin-bottom:10px;"> | |
| 374 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 375 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 405 | 376 | </el-col> |
| 406 | 377 | </el-row> |
| 407 | 378 | <el-row v-if="infoData.attchItem3" > |
| 408 | 379 | <el-col :span="4"> |
| 409 | 380 | 附件3 |
| 410 | 381 | </el-col> |
| 411 | - <el-col :span="20"> | |
| 412 | - <el-row v-for="img,index in infoData.attchItem3.split(',')" style="margin-bottom:10px;"> | |
| 413 | - <a @click="downloadFile(img);" style="color: blue;">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 414 | - </el-row> | |
| 382 | + <el-col :span="4" v-for="img,index in infoData.attchItem3.split(',')" style="margin-bottom:10px;"> | |
| 383 | + <vue-preview :slides="slides1(img)" v-if="img.indexOf('.jpg') > -1"></vue-preview> | |
| 384 | + <a @click="downloadFile(img);" style="color: blue;" v-if="img.indexOf('.jpg') == -1">{{img.split("/")[img.split("/").length -1]}}</a> | |
| 415 | 385 | </el-col> |
| 416 | 386 | </el-row> |
| 417 | 387 | </el-form> |
| 418 | - | |
| 388 | + | |
| 419 | 389 | <el-dialog title="" :visible.sync="showPic" append-to-body width="400px"> |
| 420 | 390 | <img :src="picImage" width="100%" height="400px" /> |
| 421 | 391 | </el-dialog> | ... | ... |
trash-ui/src/views/casefile/violationCaseFile/index.vue
| ... | ... | @@ -210,6 +210,9 @@ |
| 210 | 210 | <el-radio label="运输企业">运输企业</el-radio> |
| 211 | 211 | </el-radio-group> |
| 212 | 212 | </el-form-item> |
| 213 | + <el-form-item> | |
| 214 | + <vue-preview :slides="slide1"></vue-preview> | |
| 215 | + </el-form-item> | |
| 213 | 216 | <el-form-item prop="fileEntityList" label="附件"> |
| 214 | 217 | <el-upload |
| 215 | 218 | ref="upload" | ... | ... |
trash-ui/src/views/casefile/violationCaseFile/violationCaseFileInfo.vue
| ... | ... | @@ -119,6 +119,7 @@ |
| 119 | 119 | </el-table-column> |
| 120 | 120 | </el-table> |
| 121 | 121 | <el-dialog title="查看附件" :visible.sync="open" append-to-body> |
| 122 | + <vue-preview :slides="slide1"></vue-preview> | |
| 122 | 123 | <el-table :data="fileEntityList"> |
| 123 | 124 | <el-table-column property="name" label="附件名称" header-align="center" align="center"></el-table-column> |
| 124 | 125 | <el-table-column label="操作" class-name="small-padding fixed-width" header-align="center" align="center"> |
| ... | ... | @@ -141,9 +142,6 @@ |
| 141 | 142 | <el-dialog title="预览" :visible.sync="openImg" append-to-body v-if="entryType==0"> |
| 142 | 143 | <img :src="img" width="100%" height="750px" /> |
| 143 | 144 | </el-dialog> |
| 144 | - <el-dialog title="" :visible.sync="showPic" append-to-body width="400px"> | |
| 145 | - <img :src="picImage" width="100%" height="400px"/> | |
| 146 | - </el-dialog> | |
| 147 | 145 | </el-form> |
| 148 | 146 | </template> |
| 149 | 147 | |
| ... | ... | @@ -174,7 +172,7 @@ export default { |
| 174 | 172 | img:null, |
| 175 | 173 | showPic: null, |
| 176 | 174 | picImage: null, |
| 177 | - | |
| 175 | + slide1: [] | |
| 178 | 176 | } |
| 179 | 177 | }, |
| 180 | 178 | created() { |
| ... | ... | @@ -197,6 +195,16 @@ export default { |
| 197 | 195 | this.form = response.data.violationCaseFile; |
| 198 | 196 | let files = JSON.stringify(response.data.uploadFiles); |
| 199 | 197 | this.fileEntityList = JSON.parse(files.replaceAll("filePath", "url").replaceAll("fileName", "name")); |
| 198 | + this.fileEntityList.map(item => { | |
| 199 | + if(item.url.indexOf(".jpg") > -1 || item.url.indexOf(".png") > -1 || item.url.indexOf(".jpeg") > -1 || item.url.indexOf(".jpg") > -1){ | |
| 200 | + this.slide1.push({ | |
| 201 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 202 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 203 | + w: 1920, | |
| 204 | + h: 1080 | |
| 205 | + }); | |
| 206 | + } | |
| 207 | + }) | |
| 200 | 208 | }); |
| 201 | 209 | |
| 202 | 210 | |
| ... | ... | @@ -209,17 +217,6 @@ export default { |
| 209 | 217 | let name = row.name; |
| 210 | 218 | let url = row.url; |
| 211 | 219 | const a = document.createElement('a') |
| 212 | - if (url.indexOf(".jpg") > -1 || url.indexOf(".png") > -1 || url.indexOf(".jpeg") > -1 || url.indexOf(".jpg") > -1) { | |
| 213 | - const fileType = url.substring(url.lastIndexOf('.') + 1).toLowerCase(); | |
| 214 | - getBase64({"path": url}).then(res => { | |
| 215 | - if (res) { | |
| 216 | - this.picImage = "data:image/" + fileType + ";base64," + res; | |
| 217 | - this.showPic = true; | |
| 218 | - } | |
| 219 | - }); | |
| 220 | - | |
| 221 | - return; | |
| 222 | - } | |
| 223 | 220 | a.setAttribute('download', name) |
| 224 | 221 | a.setAttribute('target', '_blank') |
| 225 | 222 | a.setAttribute('href', process.env.VUE_APP_BASE_API + url); | ... | ... |
trash-ui/src/views/casefile/violationWarningInformation/index.vue
| ... | ... | @@ -195,6 +195,9 @@ |
| 195 | 195 | <el-radio label="运输企业">运输企业</el-radio> |
| 196 | 196 | </el-radio-group> |
| 197 | 197 | </el-form-item> |
| 198 | + <el-form-item> | |
| 199 | + <vue-preview :slides="slide1"></vue-preview> | |
| 200 | + </el-form-item> | |
| 198 | 201 | <el-form-item prop="fileEntityList" label="附件"> |
| 199 | 202 | <el-upload |
| 200 | 203 | ref="upload" |
| ... | ... | @@ -246,4 +249,5 @@ |
| 246 | 249 | </div> |
| 247 | 250 | </template> |
| 248 | 251 | |
| 249 | -<script src="../../../api/warningInfo"></script> | |
| 252 | +<script src="../../../api/warningInfo"> | |
| 253 | +</script> | ... | ... |
trash-ui/src/views/casefile/violationWarningInformation/violationWarningInformationInfo.vue
| ... | ... | @@ -118,6 +118,7 @@ |
| 118 | 118 | </el-table-column> |
| 119 | 119 | </el-table> |
| 120 | 120 | <el-dialog title="查看附件" :visible.sync="open" append-to-body> |
| 121 | + <vue-preview :slides="slide1"></vue-preview> | |
| 121 | 122 | <el-table :data="fileEntityList"> |
| 122 | 123 | <el-table-column property="name" label="附件名称" header-align="center" align="center"></el-table-column> |
| 123 | 124 | <el-table-column label="操作" class-name="small-padding fixed-width" header-align="center" align="center"> |
| ... | ... | @@ -140,9 +141,6 @@ |
| 140 | 141 | <el-dialog title="预览" :visible.sync="openImg" append-to-body v-if="entryType==0"> |
| 141 | 142 | <img :src="img" width="100%" height="750px" /> |
| 142 | 143 | </el-dialog> |
| 143 | - <el-dialog title="" :visible.sync="showPic" append-to-body width="400px"> | |
| 144 | - <img :src="picImage" width="100%" height="400px"/> | |
| 145 | - </el-dialog> | |
| 146 | 144 | </el-form> |
| 147 | 145 | </template> |
| 148 | 146 | |
| ... | ... | @@ -173,6 +171,7 @@ export default { |
| 173 | 171 | img:null, |
| 174 | 172 | showPic: null, |
| 175 | 173 | picImage: null, |
| 174 | + slide1: [] | |
| 176 | 175 | } |
| 177 | 176 | }, |
| 178 | 177 | created() { |
| ... | ... | @@ -191,6 +190,16 @@ export default { |
| 191 | 190 | this.form = response.data.violationWarningInformation; |
| 192 | 191 | let files = JSON.stringify(response.data.uploadFiles); |
| 193 | 192 | this.fileEntityList = JSON.parse(files.replaceAll("filePath", "url").replaceAll("fileName", "name")); |
| 193 | + this.fileEntityList.map(item => { | |
| 194 | + if(item.url.indexOf(".jpg") > -1 || item.url.indexOf(".png") > -1 || item.url.indexOf(".jpeg") > -1 || item.url.indexOf(".jpg") > -1){ | |
| 195 | + this.slide1.push({ | |
| 196 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 197 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 198 | + w: 1920, | |
| 199 | + h: 1080 | |
| 200 | + }); | |
| 201 | + } | |
| 202 | + }) | |
| 194 | 203 | }); |
| 195 | 204 | listReplyApprovalProcess({tableName:"violation_warning" + ":" + this.idInfo}).then(response => { |
| 196 | 205 | this.replyApprovalProcessList = response.rows; |
| ... | ... | @@ -201,17 +210,6 @@ export default { |
| 201 | 210 | let name = row.name; |
| 202 | 211 | let url = row.url; |
| 203 | 212 | const a = document.createElement('a') |
| 204 | - if (url.indexOf(".jpg") > -1 || url.indexOf(".png") > -1 || url.indexOf(".jpeg") > -1 || url.indexOf(".jpg") > -1) { | |
| 205 | - const fileType = url.substring(url.lastIndexOf('.') + 1).toLowerCase(); | |
| 206 | - getBase64({"path": url}).then(res => { | |
| 207 | - if (res) { | |
| 208 | - this.picImage = "data:image/" + fileType + ";base64," + res; | |
| 209 | - this.showPic = true; | |
| 210 | - } | |
| 211 | - }); | |
| 212 | - | |
| 213 | - return; | |
| 214 | - } | |
| 215 | 213 | a.setAttribute('download', name) |
| 216 | 214 | a.setAttribute('target', '_blank') |
| 217 | 215 | a.setAttribute('href', process.env.VUE_APP_BASE_API + url); | ... | ... |
trash-ui/src/views/h5/leaveApplication/leaveApplicationInfo.vue
| ... | ... | @@ -44,6 +44,9 @@ |
| 44 | 44 | <el-form-item label="请假事由"> |
| 45 | 45 | <el-input v-model="form.content" type="textarea" :rows="4" :disabled="true"/> |
| 46 | 46 | </el-form-item> |
| 47 | + <el-form-item> | |
| 48 | + <vue-preview :slides="slide1"></vue-preview> | |
| 49 | + </el-form-item> | |
| 47 | 50 | <el-table :data="fileEntityList"> |
| 48 | 51 | <el-table-column property="name" label="附件名称" header-align="center" align="center"></el-table-column> |
| 49 | 52 | <el-table-column label="操作" class-name="small-padding fixed-width" header-align="center" align="center"> |
| ... | ... | @@ -60,10 +63,6 @@ |
| 60 | 63 | </el-table-column> |
| 61 | 64 | </el-table> |
| 62 | 65 | </el-form> |
| 63 | - | |
| 64 | - <el-dialog title="" :visible.sync="showPic" append-to-body width="400px"> | |
| 65 | - <img :src="picImage" width="100%" height="400px"/> | |
| 66 | - </el-dialog> | |
| 67 | 66 | </div> |
| 68 | 67 | </template> |
| 69 | 68 | |
| ... | ... | @@ -89,6 +88,7 @@ export default { |
| 89 | 88 | fileEntityList: [], |
| 90 | 89 | showPic: null, |
| 91 | 90 | picImage: null, |
| 91 | + slide1: [] | |
| 92 | 92 | } |
| 93 | 93 | }, |
| 94 | 94 | created() { |
| ... | ... | @@ -100,6 +100,16 @@ export default { |
| 100 | 100 | this.form = response.data.leaveApplication; |
| 101 | 101 | let files = JSON.stringify(response.data.uploadFiles); |
| 102 | 102 | this.fileEntityList = JSON.parse(files.replaceAll("filePath", "url").replaceAll("fileName", "name")); |
| 103 | + this.fileEntityList.map(item => { | |
| 104 | + if(item.url.indexOf(".jpg") > -1 || item.url.indexOf(".png") > -1 || item.url.indexOf(".jpeg") > -1 || item.url.indexOf(".jpg") > -1){ | |
| 105 | + this.slide1.push({ | |
| 106 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 107 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 108 | + w: 1920, | |
| 109 | + h: 1080 | |
| 110 | + }); | |
| 111 | + } | |
| 112 | + }) | |
| 103 | 113 | }); |
| 104 | 114 | }, |
| 105 | 115 | /** 文件下载 */ |
| ... | ... | @@ -107,18 +117,6 @@ export default { |
| 107 | 117 | let name = row.name; |
| 108 | 118 | let url = row.url; |
| 109 | 119 | const a = document.createElement('a') |
| 110 | - if (url.indexOf(".jpg") > -1 || url.indexOf(".png") > -1 || url.indexOf(".jpeg") > -1 || url.indexOf(".jpg") > -1) { | |
| 111 | - const fileType = url.substring(url.lastIndexOf('.') + 1).toLowerCase(); | |
| 112 | - getBase64({"path": url}).then(res => { | |
| 113 | - if (res) { | |
| 114 | - this.picImage = "data:image/" + fileType + ";base64," + res; | |
| 115 | - this.showPic = true; | |
| 116 | - } | |
| 117 | - }); | |
| 118 | - | |
| 119 | - return; | |
| 120 | - } | |
| 121 | - | |
| 122 | 120 | a.setAttribute('download', name) |
| 123 | 121 | a.setAttribute('target', '_blank') |
| 124 | 122 | a.setAttribute('href', process.env.VUE_APP_BASE_API + url); | ... | ... |
trash-ui/src/views/h5/threestep/index.vue
| ... | ... | @@ -136,7 +136,6 @@ |
| 136 | 136 | |
| 137 | 137 | <el-form-item label="联系电话" prop="phone" v-if="form.type!=null"> |
| 138 | 138 | <el-input v-model="form.phone" :maxlength="11" show-word-limit /> |
| 139 | - </el-select> | |
| 140 | 139 | </el-form-item> |
| 141 | 140 | |
| 142 | 141 | 上传附件:<a style="color:blue;font-size: 12px;" @click="picSample=true">示意图</a> |
| ... | ... | @@ -144,11 +143,13 @@ |
| 144 | 143 | <el-row type="flex" justify="center" style="margin-top: 20px;" v-if="form.type != null"> |
| 145 | 144 | <el-col :span="12"> |
| 146 | 145 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(0)">过水槽照片</a> |
| 146 | + <vue-preview :slides="slides[0]"></vue-preview> | |
| 147 | 147 | <el-input v-model="form.img0" type="hidden"></el-input> |
| 148 | - <p v-for="img,index in form.img0">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(0,img)" style="color:red"> x</a></p> | |
| 148 | + <p v-for="img,index in form.img0">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(0,img)" style="color:red"> x</a></p> | |
| 149 | 149 | </el-col> |
| 150 | 150 | <el-col :span="12"> |
| 151 | 151 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(1)">洗车平台照片</a> |
| 152 | + <vue-preview :slides="slides[1]"></vue-preview> | |
| 152 | 153 | <el-input v-model="form.img1" type="hidden"></el-input> |
| 153 | 154 | <p v-for="img,index in form.img1">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(1,img)" style="color:red"> x</a></p> |
| 154 | 155 | </el-col> |
| ... | ... | @@ -156,11 +157,13 @@ |
| 156 | 157 | <el-row type="flex" justify="center" style="margin-top: 20px;" v-if="form.type != null"> |
| 157 | 158 | <el-col :span="12"> |
| 158 | 159 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(2)">出入口照片</a> |
| 160 | + <vue-preview :slides="slides[2]"></vue-preview> | |
| 159 | 161 | <el-input v-model="form.img2" type="hidden"></el-input> |
| 160 | 162 | <p v-for="img,index in form.img2">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(2,img)" style="color:red"> x</a></p> |
| 161 | 163 | </el-col> |
| 162 | 164 | <el-col :span="12"> |
| 163 | 165 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(3)">沉淀池照片</a> |
| 166 | + <vue-preview :slides="slides[3]"></vue-preview> | |
| 164 | 167 | <el-input v-model="form.img3" type="hidden"></el-input> |
| 165 | 168 | <p v-for="img,index in form.img3">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(3,img)" style="color:red"> x</a></p> |
| 166 | 169 | </el-col> |
| ... | ... | @@ -168,11 +171,13 @@ |
| 168 | 171 | <el-row type="flex" justify="center" v-if="form.type != null"> |
| 169 | 172 | <el-col :span="12"> |
| 170 | 173 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(4)">硬质路面照片</a> |
| 174 | + <vue-preview :slides="slides[4]"></vue-preview> | |
| 171 | 175 | <el-input v-model="form.img4" type="hidden"></el-input> |
| 172 | 176 | <p v-for="img,index in form.img4">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(4,img)" style="color:red"> x</a></p> |
| 173 | 177 | </el-col> |
| 174 | 178 | <el-col :span="12"> |
| 175 | 179 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(5)">{{form.type==0?"摄像头视频截图1":"洗车设施照片"}}</a> |
| 180 | + <vue-preview :slides="slides[5]"></vue-preview> | |
| 176 | 181 | <el-input v-model="form.img5" type="hidden"></el-input> |
| 177 | 182 | <p v-for="img,index in form.img5">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(5,img)" style="color:red"> x</a></p> |
| 178 | 183 | </el-col> |
| ... | ... | @@ -180,11 +185,13 @@ |
| 180 | 185 | <el-row type="flex" justify="center" style="margin-top: 20px;" v-if="form.type != null"> |
| 181 | 186 | <el-col :span="12"> |
| 182 | 187 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(6)">{{form.type==0?"摄像头视频截图2":"雾炮机"}}</a> |
| 188 | + <vue-preview :slides="slides[6]"></vue-preview> | |
| 183 | 189 | <el-input v-model="form.img6" type="hidden"></el-input> |
| 184 | 190 | <p v-for="img,index in form.img6">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(6,img)" style="color:red"> x</a></p> |
| 185 | 191 | </el-col> |
| 186 | 192 | <el-col :span="12"> |
| 187 | 193 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(7)">{{form.type==0?"摄像头视频截图3":"裸露黄土覆盖照片"}}</a> |
| 194 | + <vue-preview :slides="slides[7]"></vue-preview> | |
| 188 | 195 | <el-input v-model="form.img7" type="hidden"></el-input> |
| 189 | 196 | <p v-for="img,index in form.img7">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(7,img)" style="color:red"> x</a></p> |
| 190 | 197 | </el-col> |
| ... | ... | @@ -192,11 +199,13 @@ |
| 192 | 199 | <el-row type="flex" justify="center" v-if="form.type != null"> |
| 193 | 200 | <el-col :span="12"> |
| 194 | 201 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(8)">其他1</a> |
| 202 | + <vue-preview :slides="slides[8]"></vue-preview> | |
| 195 | 203 | <el-input v-model="form.img8" type="hidden"></el-input> |
| 196 | 204 | <p v-for="img,index in form.img8">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(8,img)" style="color:red"> x</a></p> |
| 197 | 205 | </el-col> |
| 198 | 206 | <el-col :span="12"> |
| 199 | 207 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(9)">其他2</a> |
| 208 | + <vue-preview :slides="slides[9]"></vue-preview> | |
| 200 | 209 | <el-input v-model="form.img9" type="hidden"></el-input> |
| 201 | 210 | <p v-for="img,index in form.img9">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(9,img)" style="color:red"> x</a></p> |
| 202 | 211 | </el-col> |
| ... | ... | @@ -204,23 +213,23 @@ |
| 204 | 213 | <el-row type="flex" justify="center" style="margin-top: 20px;" v-if="form.type != null"> |
| 205 | 214 | <el-col :span="12"> |
| 206 | 215 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(10)">其他3</a> |
| 216 | + <vue-preview :slides="slides[10]"></vue-preview> | |
| 207 | 217 | <el-input v-model="form.img10" type="hidden"></el-input> |
| 208 | - <p v-for="img,index in form.img10">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(10,img)" style="color:red"> x</a> | |
| 209 | - </p> | |
| 218 | + <p v-for="img,index in form.img10">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(10,img)" style="color:red"> x</a></p> | |
| 210 | 219 | </el-col> |
| 211 | 220 | <el-col :span="12"> |
| 212 | 221 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(11)">其他4</a> |
| 222 | + <vue-preview :slides="slides[11]"></vue-preview> | |
| 213 | 223 | <el-input v-model="form.img11" type="hidden"></el-input> |
| 214 | - <p v-for="img,index in form.img11">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(11,img)" style="color:red"> x</a> | |
| 215 | - </p> | |
| 224 | + <p v-for="img,index in form.img11">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(11,img)" style="color:red"> x</a></p> | |
| 216 | 225 | </el-col> |
| 217 | 226 | </el-row> |
| 218 | 227 | <el-row type="flex" justify="center" style="margin-top: 20px;" v-if="form.type != null"> |
| 219 | 228 | <el-col :span="12"> |
| 220 | 229 | <a style="color:blue;font-size: 12px;" @click="showFileUpload(12)">其他5</a> |
| 230 | + <vue-preview :slides="slides[12]"></vue-preview> | |
| 221 | 231 | <el-input v-model="form.img12" type="hidden"></el-input> |
| 222 | - <p v-for="img,index in form.img12">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(12,img)" style="color:red"> x</a> | |
| 223 | - </p> | |
| 232 | + <p v-for="img,index in form.img12">{{img.split("/")[img.split("/").length -1]}}<a @click="removeImage(12,img)" style="color:red"> x</a></p> | |
| 224 | 233 | </el-col> |
| 225 | 234 | </el-row> |
| 226 | 235 | |
| ... | ... | @@ -303,10 +312,10 @@ |
| 303 | 312 | .card_title{ |
| 304 | 313 | word-break: break-all; |
| 305 | 314 | } |
| 306 | - | |
| 315 | + | |
| 307 | 316 | .el-select__tags{ |
| 308 | 317 | max-height: 200px; |
| 309 | 318 | overflow: auto; |
| 310 | 319 | } |
| 311 | - | |
| 320 | + | |
| 312 | 321 | </style> | ... | ... |
trash-ui/src/views/office/conference/conferenceInfo.vue
| ... | ... | @@ -39,6 +39,9 @@ |
| 39 | 39 | </el-form-item> |
| 40 | 40 | </el-col> |
| 41 | 41 | </el-row> |
| 42 | + <el-form-item label="附件缩略图"> | |
| 43 | + <vue-preview :slides="slide1"></vue-preview> | |
| 44 | + </el-form-item> | |
| 42 | 45 | <el-row> |
| 43 | 46 | <el-table :data="fileEntityList"> |
| 44 | 47 | <el-table-column property="name" label="附件名称" header-align="center" align="center"></el-table-column> |
| ... | ... | @@ -76,7 +79,8 @@ export default { |
| 76 | 79 | data() { |
| 77 | 80 | return { |
| 78 | 81 | form: {}, |
| 79 | - fileEntityList:[] | |
| 82 | + fileEntityList:[], | |
| 83 | + slide1:[] | |
| 80 | 84 | } |
| 81 | 85 | }, |
| 82 | 86 | created() { |
| ... | ... | @@ -88,6 +92,16 @@ export default { |
| 88 | 92 | this.form = response.data.conference; |
| 89 | 93 | let files = JSON.stringify(response.data.uploadFiles); |
| 90 | 94 | this.fileEntityList = JSON.parse(files.replaceAll("filePath", "url").replaceAll("fileName", "name")) |
| 95 | + this.fileEntityList.map(item => { | |
| 96 | + if(item.url.indexOf(".jpg") > -1 || item.url.indexOf(".png") > -1 || item.url.indexOf(".jpeg") > -1 || item.url.indexOf(".jpg") > -1){ | |
| 97 | + this.slide1.push({ | |
| 98 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 99 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 100 | + w: 1920, | |
| 101 | + h: 1080 | |
| 102 | + }); | |
| 103 | + } | |
| 104 | + }) | |
| 91 | 105 | }); |
| 92 | 106 | }, |
| 93 | 107 | /** 文件下载 */ | ... | ... |
trash-ui/src/views/office/conference/index.vue
| ... | ... | @@ -2,7 +2,7 @@ |
| 2 | 2 | <div class="app-container"> |
| 3 | 3 | <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px"> |
| 4 | 4 | <el-form-item label="会议时间" prop="conferenceTime"> |
| 5 | - <el-date-picker size="small" style="width: 200px" | |
| 5 | + <el-date-picker size="small" style="width: 200px" | |
| 6 | 6 | v-model="queryParams.conferenceTime" |
| 7 | 7 | type="date" |
| 8 | 8 | value-format="yyyy-MM-dd" |
| ... | ... | @@ -35,28 +35,28 @@ |
| 35 | 35 | >新增 |
| 36 | 36 | </el-button> |
| 37 | 37 | </el-col> |
| 38 | -<!-- <el-col :span="1.5">--> | |
| 39 | -<!-- <el-button--> | |
| 40 | -<!-- type="success"--> | |
| 41 | -<!-- icon="el-icon-edit"--> | |
| 42 | -<!-- size="mini"--> | |
| 43 | -<!-- :disabled="single"--> | |
| 44 | -<!-- @click="handleUpdate"--> | |
| 45 | -<!-- v-hasPermi="['office:conference:edit']"--> | |
| 46 | -<!-- >修改--> | |
| 47 | -<!-- </el-button>--> | |
| 48 | -<!-- </el-col>--> | |
| 49 | -<!-- <el-col :span="1.5">--> | |
| 50 | -<!-- <el-button--> | |
| 51 | -<!-- type="danger"--> | |
| 52 | -<!-- icon="el-icon-delete"--> | |
| 53 | -<!-- size="mini"--> | |
| 54 | -<!-- :disabled="multiple"--> | |
| 55 | -<!-- @click="handleDelete"--> | |
| 56 | -<!-- v-hasPermi="['office:conference:remove']"--> | |
| 57 | -<!-- >删除--> | |
| 58 | -<!-- </el-button>--> | |
| 59 | -<!-- </el-col>--> | |
| 38 | + <!-- <el-col :span="1.5">--> | |
| 39 | + <!-- <el-button--> | |
| 40 | + <!-- type="success"--> | |
| 41 | + <!-- icon="el-icon-edit"--> | |
| 42 | + <!-- size="mini"--> | |
| 43 | + <!-- :disabled="single"--> | |
| 44 | + <!-- @click="handleUpdate"--> | |
| 45 | + <!-- v-hasPermi="['office:conference:edit']"--> | |
| 46 | + <!-- >修改--> | |
| 47 | + <!-- </el-button>--> | |
| 48 | + <!-- </el-col>--> | |
| 49 | + <!-- <el-col :span="1.5">--> | |
| 50 | + <!-- <el-button--> | |
| 51 | + <!-- type="danger"--> | |
| 52 | + <!-- icon="el-icon-delete"--> | |
| 53 | + <!-- size="mini"--> | |
| 54 | + <!-- :disabled="multiple"--> | |
| 55 | + <!-- @click="handleDelete"--> | |
| 56 | + <!-- v-hasPermi="['office:conference:remove']"--> | |
| 57 | + <!-- >删除--> | |
| 58 | + <!-- </el-button>--> | |
| 59 | + <!-- </el-col>--> | |
| 60 | 60 | <el-col :span="1.5"> |
| 61 | 61 | <el-button |
| 62 | 62 | type="warning" |
| ... | ... | @@ -79,7 +79,7 @@ |
| 79 | 79 | <el-table-column label="发起部门" align="center" prop="deptName"/> |
| 80 | 80 | <el-table-column label="审批状态" align="center"> |
| 81 | 81 | <template slot-scope="scope"> |
| 82 | - <span>{{parseStatus(scope.row.status)}}</span> | |
| 82 | + <span>{{ parseStatus(scope.row.status) }}</span> | |
| 83 | 83 | </template> |
| 84 | 84 | </el-table-column> |
| 85 | 85 | <el-table-column label="操作" align="center" class-name="small-padding fixed-width"> |
| ... | ... | @@ -101,14 +101,14 @@ |
| 101 | 101 | v-hasPermi="['office:conference:edit']" |
| 102 | 102 | >修改 |
| 103 | 103 | </el-button> |
| 104 | -<!-- <el-button--> | |
| 105 | -<!-- size="mini"--> | |
| 106 | -<!-- type="text"--> | |
| 107 | -<!-- icon="el-icon-delete"--> | |
| 108 | -<!-- @click="handleDelete(scope.row)"--> | |
| 109 | -<!-- v-hasPermi="['office:conference:remove']"--> | |
| 110 | -<!-- >删除--> | |
| 111 | -<!-- </el-button>--> | |
| 104 | + <!-- <el-button--> | |
| 105 | + <!-- size="mini"--> | |
| 106 | + <!-- type="text"--> | |
| 107 | + <!-- icon="el-icon-delete"--> | |
| 108 | + <!-- @click="handleDelete(scope.row)"--> | |
| 109 | + <!-- v-hasPermi="['office:conference:remove']"--> | |
| 110 | + <!-- >删除--> | |
| 111 | + <!-- </el-button>--> | |
| 112 | 112 | </template> |
| 113 | 113 | </el-table-column> |
| 114 | 114 | </el-table> |
| ... | ... | @@ -127,7 +127,7 @@ |
| 127 | 127 | <el-row :gutter="2"> |
| 128 | 128 | <el-col :span="11"> |
| 129 | 129 | <el-form-item label="会议时间" prop="conferenceTime"> |
| 130 | - <el-date-picker size="small" style="width: 100%" | |
| 130 | + <el-date-picker size="small" style="width: 100%" | |
| 131 | 131 | v-model="form.conferenceTime" |
| 132 | 132 | type="datetime" |
| 133 | 133 | value-format="yyyy-MM-dd HH:mm:ss" |
| ... | ... | @@ -162,6 +162,9 @@ |
| 162 | 162 | </el-form-item> |
| 163 | 163 | </el-col> |
| 164 | 164 | </el-row> |
| 165 | + <el-form-item> | |
| 166 | + <vue-preview :slides="slide1"></vue-preview> | |
| 167 | + </el-form-item> | |
| 165 | 168 | <el-row :gutter="2"> |
| 166 | 169 | <el-col :span="11"> |
| 167 | 170 | <el-form-item prop="fileEntityList" label="附件"> |
| ... | ... | @@ -233,7 +236,7 @@ import {getDict} from "@/api/dict"; |
| 233 | 236 | |
| 234 | 237 | export default { |
| 235 | 238 | name: "Conference", |
| 236 | - components: {Editor,conferenceInfo}, | |
| 239 | + components: {Editor, conferenceInfo}, | |
| 237 | 240 | data() { |
| 238 | 241 | return { |
| 239 | 242 | // 遮罩层 |
| ... | ... | @@ -268,7 +271,7 @@ export default { |
| 268 | 271 | }, |
| 269 | 272 | // 表单参数 |
| 270 | 273 | form: { |
| 271 | - notify:["1"] | |
| 274 | + notify: ["1"] | |
| 272 | 275 | }, |
| 273 | 276 | // 表单校验 |
| 274 | 277 | rules: { |
| ... | ... | @@ -286,14 +289,43 @@ export default { |
| 286 | 289 | ], |
| 287 | 290 | }, |
| 288 | 291 | fileEntityList: [], |
| 289 | - openInfo:false, | |
| 290 | - idInfo:null, | |
| 291 | - depts:[] | |
| 292 | + openInfo: false, | |
| 293 | + idInfo: null, | |
| 294 | + depts: [], | |
| 295 | + slide1: [] | |
| 292 | 296 | }; |
| 293 | 297 | }, |
| 298 | + watch: { | |
| 299 | + fileEntityList(value) { | |
| 300 | + this.slide1 = [] | |
| 301 | + if (this.fileEntityList.length != 0) { | |
| 302 | + this.fileEntityList.map(item => { | |
| 303 | + if (item.name.indexOf(".jpg") > -1 || item.name.indexOf(".png") > -1 || item.name.indexOf(".jpeg") > -1 || item.name.indexOf(".jpg") > -1) { | |
| 304 | + if(item.raw!=null){ | |
| 305 | + this.slide1.push({ | |
| 306 | + src: URL.createObjectURL(item.raw), | |
| 307 | + msrc: URL.createObjectURL(item.raw), | |
| 308 | + alt: item.uid, | |
| 309 | + w: 1920, | |
| 310 | + h: 1080 | |
| 311 | + }); | |
| 312 | + }else{ | |
| 313 | + this.slide1.push({ | |
| 314 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 315 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 316 | + w: 1920, | |
| 317 | + h: 1080 | |
| 318 | + }); | |
| 319 | + } | |
| 320 | + } | |
| 321 | + }) | |
| 322 | + } | |
| 323 | + | |
| 324 | + } | |
| 325 | + }, | |
| 294 | 326 | created() { |
| 295 | - let dep = {type:"CSUserDepartmentType"}; | |
| 296 | - getDict(dep).then(res=>{ | |
| 327 | + let dep = {type: "CSUserDepartmentType"}; | |
| 328 | + getDict(dep).then(res => { | |
| 297 | 329 | this.depts = res.result; |
| 298 | 330 | }); |
| 299 | 331 | this.getList(); |
| ... | ... | @@ -350,9 +382,9 @@ export default { |
| 350 | 382 | this.multiple = !selection.length |
| 351 | 383 | }, |
| 352 | 384 | /** 查看按钮操作 */ |
| 353 | - handleInfo(row){ | |
| 385 | + handleInfo(row) { | |
| 354 | 386 | this.reset(); |
| 355 | - this.idInfo = row.id+""; | |
| 387 | + this.idInfo = row.id + ""; | |
| 356 | 388 | this.title = "会议管理详情"; |
| 357 | 389 | this.openInfo = true; |
| 358 | 390 | }, |
| ... | ... | @@ -385,7 +417,7 @@ export default { |
| 385 | 417 | formData.append('fileList', null); |
| 386 | 418 | //将新增的文件放入formData |
| 387 | 419 | this.fileEntityList.forEach(item => { |
| 388 | - if(item.id==null){ | |
| 420 | + if (item.id == null) { | |
| 389 | 421 | formData.append('fileList', item.raw) |
| 390 | 422 | } |
| 391 | 423 | }) |
| ... | ... | @@ -394,7 +426,7 @@ export default { |
| 394 | 426 | formData.append("uploadFilesList", null); |
| 395 | 427 | this.fileEntityList.forEach(item => { |
| 396 | 428 | delete item.params; |
| 397 | - if(item != "null" && item != null){ | |
| 429 | + if (item != "null" && item != null) { | |
| 398 | 430 | formData.append('uploadFilesList', JSON.stringify(item).replaceAll("url", "filePath").replaceAll("name", "fileName")); |
| 399 | 431 | } |
| 400 | 432 | }) |
| ... | ... | @@ -498,6 +530,7 @@ export default { |
| 498 | 530 | // 删除文件 |
| 499 | 531 | handleDeleteFile(index) { |
| 500 | 532 | this.fileEntityList.splice(index, 1); |
| 533 | + this.slide1.splice(index, 1); | |
| 501 | 534 | }, |
| 502 | 535 | /** 文件下载 */ |
| 503 | 536 | downloadFA(row) { | ... | ... |
trash-ui/src/views/office/handle/handleInfo.vue
| ... | ... | @@ -89,6 +89,9 @@ |
| 89 | 89 | v-if="form.type==0 && businessKey=='yuelanxuexi1'"> |
| 90 | 90 | <el-input v-model="form.userNamesDone" :disabled="true"/> |
| 91 | 91 | </el-form-item> |
| 92 | + <el-form-item> | |
| 93 | + <vue-preview :slides="slide1"></vue-preview> | |
| 94 | + </el-form-item> | |
| 92 | 95 | <el-row> |
| 93 | 96 | <el-table :data="fileEntityList"> |
| 94 | 97 | <el-table-column property="name" label="附件名称" header-align="center" align="center"></el-table-column> |
| ... | ... | @@ -159,7 +162,8 @@ export default { |
| 159 | 162 | "code": 6, |
| 160 | 163 | "name": "治理部" |
| 161 | 164 | }, |
| 162 | - ] | |
| 165 | + ], | |
| 166 | + slide1:[] | |
| 163 | 167 | } |
| 164 | 168 | }, |
| 165 | 169 | created() { |
| ... | ... | @@ -169,10 +173,18 @@ export default { |
| 169 | 173 | init() { |
| 170 | 174 | getHandle(this.idInfo).then(response => { |
| 171 | 175 | this.form = response.data.handleAffairs; |
| 172 | - console.log(this.form) | |
| 173 | - console.log(this.businessKey) | |
| 174 | 176 | let files = JSON.stringify(response.data.uploadFiles); |
| 175 | 177 | this.fileEntityList = JSON.parse(files.replaceAll("filePath", "url").replaceAll("fileName", "name")); |
| 178 | + this.fileEntityList.map(item => { | |
| 179 | + if(item.url.indexOf(".jpg") > -1 || item.url.indexOf(".png") > -1 || item.url.indexOf(".jpeg") > -1 || item.url.indexOf(".jpg") > -1){ | |
| 180 | + this.slide1.push({ | |
| 181 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 182 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 183 | + w: 1920, | |
| 184 | + h: 1080 | |
| 185 | + }); | |
| 186 | + } | |
| 187 | + }) | |
| 176 | 188 | }); |
| 177 | 189 | listReplyApprovalProcess({tableName: 'handle_affairs', tableId: this.idInfo}).then(response => { |
| 178 | 190 | if(response.rows.length>0){ | ... | ... |
trash-ui/src/views/office/handle/index.vue
| ... | ... | @@ -207,13 +207,9 @@ |
| 207 | 207 | <el-form-item label="诉求" prop="appeal" v-if="form.type==2 || form.type==3|| form.type==4"> |
| 208 | 208 | <el-input v-model="form.appeal" type="textarea" placeholder="请输入内容" :rows="6"/> |
| 209 | 209 | </el-form-item> |
| 210 | - <!-- 意见处 --> | |
| 211 | -<!-- <el-form-item label="办理意见" prop="opinion">--> | |
| 212 | -<!-- <el-input v-model="form.opinion" placeholder="请输入办理意见" />--> | |
| 213 | -<!-- </el-form-item>--> | |
| 214 | -<!-- <el-form-item label="相关部门意见" prop="deptOpinion">--> | |
| 215 | -<!-- <el-input v-model="form.deptOpinion" placeholder="请输入相关部门意见" />--> | |
| 216 | -<!-- </el-form-item>--> | |
| 210 | + <el-form-item> | |
| 211 | + <vue-preview :slides="slide1"></vue-preview> | |
| 212 | + </el-form-item> | |
| 217 | 213 | <el-row> |
| 218 | 214 | <el-col> |
| 219 | 215 | <el-form-item prop="fileEntityList" label="附件"> |
| ... | ... | @@ -336,8 +332,37 @@ export default { |
| 336 | 332 | openInfo: false, |
| 337 | 333 | businessKey:null, |
| 338 | 334 | depts:[], |
| 335 | + slide1: [] | |
| 339 | 336 | }; |
| 340 | 337 | }, |
| 338 | + watch: { | |
| 339 | + fileEntityList(value) { | |
| 340 | + this.slide1 = [] | |
| 341 | + if (this.fileEntityList.length != 0) { | |
| 342 | + this.fileEntityList.map(item => { | |
| 343 | + if (item.name.indexOf(".jpg") > -1 || item.name.indexOf(".png") > -1 || item.name.indexOf(".jpeg") > -1 || item.name.indexOf(".jpg") > -1) { | |
| 344 | + if(item.raw!=null){ | |
| 345 | + this.slide1.push({ | |
| 346 | + src: URL.createObjectURL(item.raw), | |
| 347 | + msrc: URL.createObjectURL(item.raw), | |
| 348 | + alt: item.uid, | |
| 349 | + w: 1920, | |
| 350 | + h: 1080 | |
| 351 | + }); | |
| 352 | + }else{ | |
| 353 | + this.slide1.push({ | |
| 354 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 355 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 356 | + w: 1920, | |
| 357 | + h: 1080 | |
| 358 | + }); | |
| 359 | + } | |
| 360 | + } | |
| 361 | + }) | |
| 362 | + } | |
| 363 | + | |
| 364 | + } | |
| 365 | + }, | |
| 341 | 366 | created() { |
| 342 | 367 | let dep = {type:"CSUserDepartmentType"}; |
| 343 | 368 | getDict(dep).then(res=>{ |
| ... | ... | @@ -547,6 +572,7 @@ export default { |
| 547 | 572 | // 删除文件 |
| 548 | 573 | handleDeleteFile(index) { |
| 549 | 574 | this.fileEntityList.splice(index, 1); |
| 575 | + this.slide1.splice(index, 1); | |
| 550 | 576 | }, |
| 551 | 577 | /** 文件下载 */ |
| 552 | 578 | downloadFA(row) { | ... | ... |
trash-ui/src/views/office/leaveApplication/index.vue
| ... | ... | @@ -185,6 +185,9 @@ |
| 185 | 185 | <el-form-item label="请假事由"> |
| 186 | 186 | <el-input v-model="form.content" type="textarea" :rows="4"/> |
| 187 | 187 | </el-form-item> |
| 188 | + <el-form-item> | |
| 189 | + <vue-preview :slides="slide1"></vue-preview> | |
| 190 | + </el-form-item> | |
| 188 | 191 | <el-form-item prop="fileEntityList" label="附件"> |
| 189 | 192 | <el-upload |
| 190 | 193 | ref="upload" | ... | ... |
trash-ui/src/views/office/leaveApplication/leaveApplicationInfo.vue
| ... | ... | @@ -44,6 +44,9 @@ |
| 44 | 44 | <el-form-item label="请假事由"> |
| 45 | 45 | <el-input v-model="form.content" type="textarea" :rows="4" :disabled="true"/> |
| 46 | 46 | </el-form-item> |
| 47 | + <el-form-item> | |
| 48 | + <vue-preview :slides="slide1"></vue-preview> | |
| 49 | + </el-form-item> | |
| 47 | 50 | <el-table :data="fileEntityList"> |
| 48 | 51 | <el-table-column property="name" label="附件名称" header-align="center" align="center"></el-table-column> |
| 49 | 52 | <el-table-column label="操作" class-name="small-padding fixed-width" header-align="center" align="center"> |
| ... | ... | @@ -60,9 +63,6 @@ |
| 60 | 63 | </el-table-column> |
| 61 | 64 | </el-table> |
| 62 | 65 | </el-form> |
| 63 | - <el-dialog title="" :visible.sync="showPic" append-to-body width="400px"> | |
| 64 | - <img :src="picImage" width="100%" height="400px"/> | |
| 65 | - </el-dialog> | |
| 66 | 66 | </div> |
| 67 | 67 | </template> |
| 68 | 68 | |
| ... | ... | @@ -88,6 +88,7 @@ export default { |
| 88 | 88 | fileEntityList: [], |
| 89 | 89 | showPic: null, |
| 90 | 90 | picImage: null, |
| 91 | + slide1:[] | |
| 91 | 92 | } |
| 92 | 93 | }, |
| 93 | 94 | created() { |
| ... | ... | @@ -99,6 +100,16 @@ export default { |
| 99 | 100 | this.form = response.data.leaveApplication; |
| 100 | 101 | let files = JSON.stringify(response.data.uploadFiles); |
| 101 | 102 | this.fileEntityList = JSON.parse(files.replaceAll("filePath", "url").replaceAll("fileName", "name")); |
| 103 | + this.fileEntityList.map(item => { | |
| 104 | + if(item.url.indexOf(".jpg") > -1 || item.url.indexOf(".png") > -1 || item.url.indexOf(".jpeg") > -1 || item.url.indexOf(".jpg") > -1){ | |
| 105 | + this.slide1.push({ | |
| 106 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 107 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 108 | + w: 1920, | |
| 109 | + h: 1080 | |
| 110 | + }); | |
| 111 | + } | |
| 112 | + }) | |
| 102 | 113 | }); |
| 103 | 114 | }, |
| 104 | 115 | /** 文件下载 */ |
| ... | ... | @@ -106,17 +117,6 @@ export default { |
| 106 | 117 | let name = row.name; |
| 107 | 118 | let url = row.url; |
| 108 | 119 | const a = document.createElement('a') |
| 109 | - if (url.indexOf(".jpg") > -1 || url.indexOf(".png") > -1 || url.indexOf(".jpeg") > -1 || url.indexOf(".jpg") > -1) { | |
| 110 | - const fileType = url.substring(url.lastIndexOf('.') + 1).toLowerCase(); | |
| 111 | - getBase64({"path": url}).then(res => { | |
| 112 | - if (res) { | |
| 113 | - this.picImage = "data:image/" + fileType + ";base64," + res; | |
| 114 | - this.showPic = true; | |
| 115 | - } | |
| 116 | - }); | |
| 117 | - | |
| 118 | - return; | |
| 119 | - } | |
| 120 | 120 | a.setAttribute('download', name) |
| 121 | 121 | a.setAttribute('target', '_blank') |
| 122 | 122 | a.setAttribute('href', process.env.VUE_APP_BASE_API + url); | ... | ... |
trash-ui/src/views/office/management/contractInfo.vue
| ... | ... | @@ -88,6 +88,9 @@ |
| 88 | 88 | </el-form-item> |
| 89 | 89 | </el-col> |
| 90 | 90 | </el-row> |
| 91 | + <el-form-item> | |
| 92 | + <vue-preview :slides="slide1"></vue-preview> | |
| 93 | + </el-form-item> | |
| 91 | 94 | <el-row> |
| 92 | 95 | <el-table :data="fileEntityList"> |
| 93 | 96 | <el-table-column property="name" label="附件名称" header-align="center" align="center"></el-table-column> |
| ... | ... | @@ -123,7 +126,8 @@ export default { |
| 123 | 126 | data() { |
| 124 | 127 | return { |
| 125 | 128 | form: {}, |
| 126 | - fileEntityList:[] | |
| 129 | + fileEntityList:[], | |
| 130 | + slide1:[] | |
| 127 | 131 | } |
| 128 | 132 | }, |
| 129 | 133 | created() { |
| ... | ... | @@ -135,6 +139,16 @@ export default { |
| 135 | 139 | this.form = response.data.contractManagement; |
| 136 | 140 | let files = JSON.stringify(response.data.uploadFiles); |
| 137 | 141 | this.fileEntityList = JSON.parse(files.replaceAll("filePath", "url").replaceAll("fileName", "name")) |
| 142 | + this.fileEntityList.map(item => { | |
| 143 | + if(item.url.indexOf(".jpg") > -1 || item.url.indexOf(".png") > -1 || item.url.indexOf(".jpeg") > -1 || item.url.indexOf(".jpg") > -1){ | |
| 144 | + this.slide1.push({ | |
| 145 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 146 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 147 | + w: 1920, | |
| 148 | + h: 1080 | |
| 149 | + }); | |
| 150 | + } | |
| 151 | + }) | |
| 138 | 152 | }); |
| 139 | 153 | }, |
| 140 | 154 | /** 文件下载 */ | ... | ... |
trash-ui/src/views/office/management/index.vue
| ... | ... | @@ -212,6 +212,9 @@ |
| 212 | 212 | </el-form-item> |
| 213 | 213 | </el-col> |
| 214 | 214 | </el-row> |
| 215 | + <el-form-item> | |
| 216 | + <vue-preview :slides="slide1"></vue-preview> | |
| 217 | + </el-form-item> | |
| 215 | 218 | <el-row> |
| 216 | 219 | <el-col :span="11"> |
| 217 | 220 | <el-form-item prop="fileEntityList" label="附件"> |
| ... | ... | @@ -357,9 +360,38 @@ export default { |
| 357 | 360 | fileEntityList: [], |
| 358 | 361 | openInfo: false, |
| 359 | 362 | idInfo:null, |
| 360 | - depts:[] | |
| 363 | + depts:[], | |
| 364 | + slide1: [] | |
| 361 | 365 | }; |
| 362 | 366 | }, |
| 367 | + watch: { | |
| 368 | + fileEntityList(value) { | |
| 369 | + this.slide1 = [] | |
| 370 | + if (this.fileEntityList.length != 0) { | |
| 371 | + this.fileEntityList.map(item => { | |
| 372 | + if (item.name.indexOf(".jpg") > -1 || item.name.indexOf(".png") > -1 || item.name.indexOf(".jpeg") > -1 || item.name.indexOf(".jpg") > -1) { | |
| 373 | + if(item.raw!=null){ | |
| 374 | + this.slide1.push({ | |
| 375 | + src: URL.createObjectURL(item.raw), | |
| 376 | + msrc: URL.createObjectURL(item.raw), | |
| 377 | + alt: item.uid, | |
| 378 | + w: 1920, | |
| 379 | + h: 1080 | |
| 380 | + }); | |
| 381 | + }else{ | |
| 382 | + this.slide1.push({ | |
| 383 | + src: process.env.VUE_APP_BASE_API + item.url, | |
| 384 | + msrc: process.env.VUE_APP_BASE_API + item.url, | |
| 385 | + w: 1920, | |
| 386 | + h: 1080 | |
| 387 | + }); | |
| 388 | + } | |
| 389 | + } | |
| 390 | + }) | |
| 391 | + } | |
| 392 | + | |
| 393 | + } | |
| 394 | + }, | |
| 363 | 395 | created() { |
| 364 | 396 | let dep = {type:"CSUserDepartmentType"}; |
| 365 | 397 | |
| ... | ... | @@ -576,6 +608,7 @@ export default { |
| 576 | 608 | // 删除文件 |
| 577 | 609 | handleDeleteFile(index) { |
| 578 | 610 | this.fileEntityList.splice(index, 1); |
| 611 | + this.slide1.splice(index, 1); | |
| 579 | 612 | }, |
| 580 | 613 | /** 文件下载 */ |
| 581 | 614 | downloadFA(row) { | ... | ... |