| 
					
				 | 
			
			
				@@ -8,7 +8,7 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 </template> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 <script> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 	import Clipboard from 'clipboard'; // 引入Clipboard 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-	import {getTemplate,callback,youkuClickCallback, iqiyiClickCallback} from '../../api/api.js' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+	import {getTemplateByNo,getTemplateById,callback,youkuClickCallback, iqiyiClickCallback} from '../../api/api.js' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 	import {clicks} from '../../common/common.js' 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 		 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 		 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -22,7 +22,8 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				vid: '', 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				click_id: '', 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				aid: '', 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				no: '', 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				id: null, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				no: null, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				type: 0, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				show: false, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				name: '', 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -40,21 +41,9 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			window.vueInstance = this;  // 将 Vue 实例暴露到全局 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 		}, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 		onLoad(option) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-			if(option.type == null || option.type == "" || option.type == undefined){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				uni.showToast({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-					icon:'none', 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-					title: '推广链接错误', 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				}); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				return; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-			} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-			if(option.accountId == null || option.accountId == "" || option.accountId == undefined){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				uni.showToast({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-					icon:'none', 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-					title: '推广链接错误', 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				}); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				return; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-			} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-			if(option.id == null || option.id == "" || option.id == undefined){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			this.no = option.no; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			this.id = option.tid; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			if((this.id == null || this.id == "" || this.id == undefined) && (this.no == null || this.no == "" || this.no == undefined)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				uni.showToast({ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 					icon:'none', 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 					title: '推广链接错误', 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -82,11 +71,18 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				this.impress_id = option.impress_id; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 				this.sign = option.sign; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-			getTemplate(option.id).then(e => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				this.data = e.data; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				this.site = e.site; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-				this.json = JSON.parse(e.data.json) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-			}) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			if(this.id){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				getTemplateById(this.id).then(e => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					this.data = e.data; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					this.site = e.site; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					this.json = JSON.parse(e.data.json) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				}) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			}else if(this.no){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				getTemplateByNo(this.no).then(e => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					this.data = e.data; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+					this.json = JSON.parse(e.data.json) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+				}) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+			} 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			// callback({vid: this.vid}).then(e => { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			// 	console.info(e) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 			// }) 
			 |