zhongtianhaoyuan před 2 roky
rodič
revize
b708e5003f
1 změnil soubory, kde provedl 62 přidání a 6 odebrání
  1. 62 6
      pages/universalityAudit/look.vue

+ 62 - 6
pages/universalityAudit/look.vue

@@ -91,6 +91,11 @@
 								<view v-if='item.auditMind' class="right-content">
 									{{item.auditMind}}
 								</view>
+								<view class="flex audit_img">
+									<view v-for="(items,indexs) in item.fileUrl" class="url_css">
+										<image :src="items" mode="aspectFill" class="url_img" @click="auditFile(items)"></image>
+									</view>
+								</view>
 							</view>
 							<view v-if='item.commonStaffs1' class="right">
 								<u-icon @click='showcontent(item)' :name="item.showflow?'arrow-up':'arrow-down'" size="28">
@@ -137,6 +142,21 @@
 			
 		},
 		methods: {
+			auditFile(src) {
+				uni.downloadFile({
+					url: src,
+					success: function(res) {
+						var filePath = res.tempFilePath;
+						uni.openDocument({
+							filePath: filePath,
+							showMenu: true,
+							success: function(res) {
+								console.log('打开文档成功');
+							}
+						});
+					}
+				});
+			},
 			getList(){
 				var that =this
 				this.$api.doRequest('get', '/generalAuditInfo/getGeneralAuditInfo', {
@@ -232,8 +252,14 @@
 										.getTime()
 										response.data.data[i].updateDate = this.$u.timeFormat(
 											time, 'mm.dd hh:MM')
-										response.data.data[i].auditMind = response.data.data[i]
-											.workflowHistoricTasks[len].auditMind
+										// response.data.data[i].auditMind = response.data.data[i]
+										// 	.workflowHistoricTasks[len].auditMind
+										if (response.data.data[i].workflowHistoricTasks[len].auditMind && response.data.data[i].workflowHistoricTasks[len].auditMind.indexOf("##") !=-1) {
+											response.data.data[i].auditMind = response.data.data[i].workflowHistoricTasks[len].auditMind.split("##")[0]
+											response.data.data[i].fileUrl = response.data.data[i].workflowHistoricTasks[len].auditMind.split("##")[1].split(",")
+										}else{
+											response.data.data[i].auditMind = response.data.data[i].workflowHistoricTasks[len].auditMind
+										}
 									} else {
 										this.$set(response.data.data[i], 'status', 'question')
 										// response.data.data[i].status='question'
@@ -304,7 +330,7 @@
 	
 			.left {
 				display: flex;
-				align-items: center;
+				// align-items: center;
 	
 				.item1 {
 					position: relative;
@@ -321,11 +347,21 @@
 					}
 	
 					.status {
-						position: absolute;
+						// position: absolute;
+						// border-radius: 50%;
+						// padding: 0px 2px;
+						// right: -3px;
+						// bottom: -3px;
+						// background: #fff;
+						text-align: center;
+						position: relative;
+						width: 18px;
+						height: 18px;
 						border-radius: 50%;
 						padding: 0px 2px;
-						right: -3px;
-						bottom: -3px;
+						margin: auto;
+						margin-right: -5px;
+						top: -16px;
 						background: #fff;
 					}
 	
@@ -426,6 +462,26 @@
 		.audit {
 			margin-top: 20rpx;
 		}
+		.audit_img {
+			flex-wrap: wrap;
+			// margin: 0 10rpx;
+			margin-left: 20rpx;
+		
+			.url_css {
+				border: 1px solid #999999;
+				border-radius: 10px;
+				margin-top: 10px;
+				margin-right: 4px;
+				overflow: hidden;
+				width: 73px;
+				height: 73px;
+				.url_img {
+					width: 73px;
+					height: 73px;
+					// border-radius: 10px;
+				}
+			}
+		}
 	}
 .u-form {
 		margin: 20rpx;