jwyu 3 жил өмнө
parent
commit
a65193434d

+ 19 - 1
pages-approve/seal/edit.vue

@@ -131,11 +131,14 @@
 				</van-search>
 				</van-search>
 				<view class="search-result">
 				<view class="search-result">
 					<view class="result-custome-box" v-if="searchContractList.length===0">
 					<view class="result-custome-box" v-if="searchContractList.length===0">
+						<van-empty description="暂无数据" :image="require('@/static/empty.png')" v-if="!searchCustomeStatus"/>
+						<view v-else>
 						<view class="result-item flex" v-for="item in searchCustomeList" :key="item" @click="getContract(item)">
 						<view class="result-item flex" v-for="item in searchCustomeList" :key="item" @click="getContract(item)">
 							<image src="../static/search-icon.png" mode="aspectFill" class="search-icon"></image>
 							<image src="../static/search-icon.png" mode="aspectFill" class="search-icon"></image>
 							<view class="con van-ellipsis">{{item}}</view>
 							<view class="con van-ellipsis">{{item}}</view>
 							<image src="../static/click-icon.png" mode="aspectFill" class="click-icon"></image>
 							<image src="../static/click-icon.png" mode="aspectFill" class="click-icon"></image>
 						</view>
 						</view>
+						</view>
 					</view>
 					</view>
 					<view class="result-contract-box" v-else>
 					<view class="result-contract-box" v-else>
 						<view class="result-contract-item" v-for="item in searchContractList" :key="item.ContractId" @click="handleChooseContract(item)">
 						<view class="result-contract-item" v-for="item in searchContractList" :key="item.ContractId" @click="handleChooseContract(item)">
@@ -161,6 +164,14 @@
 		components:{
 		components:{
 			steps
 			steps
 		},
 		},
+		watch:{
+			showCustome(){
+				this.searchCustomeVal=''
+				this.searchCustomeStatus=true 
+				this.searchCustomeList=[]
+				this.searchContractList=[]
+			}
+		},
 		data() {
 		data() {
 			return {
 			return {
 				SealId:0,
 				SealId:0,
@@ -200,6 +211,7 @@
 				radioVal:'系统合同',
 				radioVal:'系统合同',
 				
 				
 				searchCustomeVal:'',//搜索客户输入数据
 				searchCustomeVal:'',//搜索客户输入数据
+				searchCustomeStatus:true,//搜索客户 是否有结果
 				searchCustomeList:[],//搜索到的客户名称列表
 				searchCustomeList:[],//搜索到的客户名称列表
 				searchContractList:[],//选择搜索中的客户后合同列表数据
 				searchContractList:[],//选择搜索中的客户后合同列表数据
 			}
 			}
@@ -317,6 +329,11 @@
 				const res=await apiSearchCustome({Keyword:this.searchCustomeVal})
 				const res=await apiSearchCustome({Keyword:this.searchCustomeVal})
 				if(res.code===200){
 				if(res.code===200){
 					this.searchCustomeList=res.data
 					this.searchCustomeList=res.data
+					if(res.data.length===0){
+						this.searchCustomeStatus=false
+					}else{
+						this.searchCustomeStatus=true
+					}
 				}
 				}
 			},
 			},
 			
 			
@@ -343,7 +360,8 @@
 				this.ServiceType=e.ContractType
 				this.ServiceType=e.ContractType
 				this.UseCompanyName=e.CompanyName
 				this.UseCompanyName=e.CompanyName
 				this.ContractId=e.ContractId
 				this.ContractId=e.ContractId
-				this.ContractfileUrl=e.FileUrl
+				// this.ContractfileUrl=e.FileUrl
+				this.handleFile(e.FileUrl)
 				// 关闭搜索弹窗
 				// 关闭搜索弹窗
 				this.showCustome=false
 				this.showCustome=false
 				this.searchCustomeVal=''
 				this.searchCustomeVal=''