瀏覽代碼

提交代码-渠道号可提测

朱鑫波 3 年之前
父節點
當前提交
4d936aeb51

+ 9 - 0
src/main.js

@@ -110,6 +110,15 @@ Vue.prototype.doMian = "http://139.186.31.213:8804/jeecg-boot";
 Vue.prototype.postFormAction = postFormAction;
 Vue.prototype.postFormAction = postFormAction;
 Vue.prototype.postDataAction = postAction;
 Vue.prototype.postDataAction = postAction;
 Vue.prototype.getAction = getAction;
 Vue.prototype.getAction = getAction;
+
+Vue.prototype.cancel = function () {
+  let cancelArr = window.axiosCancel
+  cancelArr = cancelArr || [] //判断空值
+  cancelArr.forEach((ele, index) => {
+    ele.cancel('取消了请求') // 在失败函数中返回这里自定义的错误信息
+    delete window.axiosCancel[index]
+  })
+}
 new Vue({
 new Vue({
   router,
   router,
   store,
   store,

+ 75 - 68
src/utils/request.js

@@ -6,86 +6,87 @@
 import Vue from 'vue';
 import Vue from 'vue';
 import axios from 'axios';
 import axios from 'axios';
 import store from '@/store';
 import store from '@/store';
-import {VueAxios} from './axios';
-import {Modal, notification} from 'ant-design-vue';
-import {ACCESS_TOKEN} from '@/store/mutation-types';
+import { VueAxios } from './axios';
+import { Modal, notification } from 'ant-design-vue';
+import { ACCESS_TOKEN } from '@/store/mutation-types';
 const key = '1';
 const key = '1';
 // 创建 axios 实例
 // 创建 axios 实例
 
 
+window.axiosCancel = []
 if (process.env.NODE_ENV === 'development') {
 if (process.env.NODE_ENV === 'development') {
-    axios.defaults.baseURL = '/jeecg-boot';
+	axios.defaults.baseURL = '/jeecg-boot';
 }
 }
 else if (process.env.NODE_ENV === 'debug') {
 else if (process.env.NODE_ENV === 'debug') {
 }
 }
 else if (process.env.NODE_ENV === 'production') {
 else if (process.env.NODE_ENV === 'production') {
 	// axios.defaults.baseURL = 'http://apipre.tjyourong.com.cn/jeecg-boot'; // 预生产
 	// axios.defaults.baseURL = 'http://apipre.tjyourong.com.cn/jeecg-boot'; // 预生产
-    // axios.defaults.baseURL = 'http://gateway.tjyourong.com.cn/jeecg-boot';//测试
+	// axios.defaults.baseURL = 'http://gateway.tjyourong.com.cn/jeecg-boot';//测试
 	axios.defaults.baseURL = 'http://api.tjyourong.com.cn/jeecg-boot'; // 生产环境
 	axios.defaults.baseURL = 'http://api.tjyourong.com.cn/jeecg-boot'; // 生产环境
 }
 }
 const service = axios.create({
 const service = axios.create({
 	// baseURL: '/jeecg-boot', // api base_url
 	// baseURL: '/jeecg-boot', // api base_url
-    timeout: 6000000 // 请求超时时间
+	timeout: 6000000 // 请求超时时间
 });
 });
 
 
 
 
 
 
 
 
 const err = (error) => {
 const err = (error) => {
-    if (error.esponse) {
+	if (error.esponse) {
 		let data = error.response.data
 		let data = error.response.data
 		const token = Vue.ls.get(ACCESS_TOKEN)
 		const token = Vue.ls.get(ACCESS_TOKEN)
 		// console.log("------异常响应------", token)
 		// console.log("------异常响应------", token)
 		// console.log("------异常响应------", error.response.status)
 		// console.log("------异常响应------", error.response.status)
 		switch (error.response.status) {
 		switch (error.response.status) {
-		case 403:
-			notification.error({key,message: '系统提示', description: '拒绝访问', duration: 4})
-			break
-		case 500:
-			//notification.error({ message: '系统提示', description:'Token失效,请重新登录!',duration: 4})
-			if (token && data.message == "Token失效,请重新登录") {
-			// update-begin- --- author:scott ------ date:20190225 ---- for:Token失效采用弹框模式,不直接跳转----
-			// store.dispatch('Logout').then(() => {
-			//     window.location.reload()
-			// })
-			Modal.error({
-				title: '登录已过期',
-				content: '很抱歉,登录已过期,请重新登录',
-				okText: '重新登录',
-				mask: false,
-				onOk: () => {
-				store.dispatch('Logout').then(() => {
-					Vue.ls.remove(ACCESS_TOKEN)
-					window.location.reload()
-				})
+			case 403:
+				notification.error({ key, message: '系统提示', description: '拒绝访问', duration: 4 })
+				break
+			case 500:
+				//notification.error({ message: '系统提示', description:'Token失效,请重新登录!',duration: 4})
+				if (token && data.message == "Token失效,请重新登录") {
+					// update-begin- --- author:scott ------ date:20190225 ---- for:Token失效采用弹框模式,不直接跳转----
+					// store.dispatch('Logout').then(() => {
+					//     window.location.reload()
+					// })
+					Modal.error({
+						title: '登录已过期',
+						content: '很抱歉,登录已过期,请重新登录',
+						okText: '重新登录',
+						mask: false,
+						onOk: () => {
+							store.dispatch('Logout').then(() => {
+								Vue.ls.remove(ACCESS_TOKEN)
+								window.location.reload()
+							})
+						}
+					})
+					// update-end- --- author:scott ------ date:20190225 ---- for:Token失效采用弹框模式,不直接跳转----
+				}
+				break
+			case 404:
+				notification.error({ key, message: '系统提示', description: '很抱歉,资源未找到!', duration: 4 })
+				break
+			case 504:
+				notification.error({ key, message: '系统提示', description: '网络超时' })
+				break
+			case 401:
+				notification.error({ key, message: '系统提示', description: '未授权,请重新登录', duration: 4 })
+				if (token) {
+					store.dispatch('Logout').then(() => {
+						setTimeout(() => {
+							window.location.reload()
+						}, 1500)
+					})
 				}
 				}
-			})
-			// update-end- --- author:scott ------ date:20190225 ---- for:Token失效采用弹框模式,不直接跳转----
-			}
-			break
-		case 404:
-			notification.error({key,message: '系统提示', description: '很抱歉,资源未找到!', duration: 4})
-			break
-		case 504:
-			notification.error({key,message: '系统提示', description: '网络超时'})
-			break
-		case 401:
-			notification.error({key,message: '系统提示', description: '未授权,请重新登录', duration: 4})
-			if (token) {
-			store.dispatch('Logout').then(() => {
-				setTimeout(() => {
-				window.location.reload()
-				}, 1500)
-			})
-			}
-			break
-		default:
-			notification.error({
-			key,
-			message: '系统提示',
-			description: data.message,
-			duration: 4
-			})
-			break
+				break
+			default:
+				notification.error({
+					key,
+					message: '系统提示',
+					description: data.message,
+					duration: 4
+				})
+				break
 		}
 		}
 	}
 	}
 	return Promise.reject(error)
 	return Promise.reject(error)
@@ -94,30 +95,36 @@ const err = (error) => {
 // request interceptor
 // request interceptor
 service.interceptors.request.use(config => {
 service.interceptors.request.use(config => {
 	const token = Vue.ls.get(ACCESS_TOKEN);
 	const token = Vue.ls.get(ACCESS_TOKEN);
-    if (token) {
+	if (token) {
 		config.headers['X-Access-Token'] = token; // 让每个请求携带自定义 token 请根据实际情况自行修改
 		config.headers['X-Access-Token'] = token; // 让每个请求携带自定义 token 请根据实际情况自行修改
-    }
-    if (config.method === 'get') {
+	}
+	if (config.method === 'get') {
 		config.params = {
 		config.params = {
 			_t: Date.parse(new Date()) / 1000,
 			_t: Date.parse(new Date()) / 1000,
 			...config.params
 			...config.params
 		};
 		};
-    }
+	}
+	config.cancelToken = new axios.CancelToken(cancel => {
+		window.axiosCancel.push({
+			cancel
+		})
+	})
+
 	return config;
 	return config;
 }, (error) => {
 }, (error) => {
-  	return Promise.reject(error);
+	return Promise.reject(error);
 });
 });
 
 
 // response interceptor
 // response interceptor
 service.interceptors.response.use((response) => {
 service.interceptors.response.use((response) => {
-    return response.data;
+	return response.data;
 }, (error) => {
 }, (error) => {
-    notification.error({
-        key,
-        message: '系统提示',
-        description: '网络超时,请刷新页面'
-    });
-    return;
+	notification.error({
+		key,
+		message: '系统提示',
+		description: '网络超时,请刷新页面'
+	});
+	return;
 });
 });
 
 
 const installer = {
 const installer = {
@@ -128,6 +135,6 @@ const installer = {
 };
 };
 
 
 export {
 export {
-    installer as VueAxios,
+	installer as VueAxios,
 	service as axios
 	service as axios
 };
 };

文件差異過大導致無法顯示
+ 1076 - 0
src/views/modules/autoLaunch/channelManage/channelDetailList.vue


+ 88 - 14
src/views/modules/autoLaunch/channelManage/components/creatApplication.vue

@@ -38,7 +38,14 @@
                                     rules: [{ required: true, validator: handleConfirmValue }]
                                     rules: [{ required: true, validator: handleConfirmValue }]
                                 }
                                 }
                             ]"
                             ]"
+                            id="url"
                         />
                         />
+                        <a-tag
+                            color="#2db7f5"
+                            @click="getChangeAll('渠道号', 'form', 'url')"
+                            v-if="createTypeData && createTypeData.createType == '1'"
+                            >+渠道号</a-tag
+                        >
                     </a-form-item>
                     </a-form-item>
 
 
                     <a-form-item
                     <a-form-item
@@ -105,7 +112,14 @@
                                 }
                                 }
                             ]"
                             ]"
                             placeholder="请填写应用标记,必填且不可重复,如快手-5.6.1.66"
                             placeholder="请填写应用标记,必填且不可重复,如快手-5.6.1.66"
+                            id="appVersion"
                         />
                         />
+                        <a-tag
+                            color="#2db7f5"
+                            @click="getChangeAll('渠道号', 'form', 'appVersion')"
+                            v-if="createTypeData && createTypeData.createType == '1'"
+                            >+渠道号</a-tag
+                        >
                     </a-form-item>
                     </a-form-item>
                     <a-form-item
                     <a-form-item
                         label="隐私政策链接"
                         label="隐私政策链接"
@@ -187,10 +201,81 @@ export default {
             // uploadAction: '/kuaishouAppPackage/importAppExcel',
             // uploadAction: '/kuaishouAppPackage/importAppExcel',
             tokenHeader: { 'X-Access-Token': Vue.ls.get(ACCESS_TOKEN) },
             tokenHeader: { 'X-Access-Token': Vue.ls.get(ACCESS_TOKEN) },
             okCreated: false,
             okCreated: false,
-            dataFile: null
+            dataFile: null,
+            createTypeData: null
         }
         }
     },
     },
     methods: {
     methods: {
+        getChangeAll(type, form, field) {
+            var node = document.getElementById(field)
+            var v = '-{{' + type + '}}-'
+            if (document.selection) {
+                //IE
+                node.focus()
+                var sel = document.selection.createRange()
+                sel.text = v
+                sel.select()
+                if (field == 'channelName') {
+                    this[form].setFieldsValue({ channelName: sel.text })
+                } else if (field == 'channelCode') {
+                    this[form].setFieldsValue({ channelCode: sel.text })
+                } else if (field == 'url') {
+                    this[form].setFieldsValue({ url: sel.text })
+                } else if (field == 'clickTrackUrl') {
+                    this[form].setFieldsValue({ clickTrackUrl: sel.text })
+                } else if (field == 'actionbarClickUrl') {
+                    this[form].setFieldsValue({ actionbarClickUrl: sel.text })
+                } else if (field == 'appVersion') {
+                    this[form].setFieldsValue({ appVersion: sel.text })
+                }
+            } else if (node.selectionStart || node.selectionStart == '0') {
+                //MOZILLA/GOOGLE
+                var startPos = node.selectionStart
+                var endPos = node.selectionEnd
+                var restoreTop = node.scrollTop
+                node.value = node.value.substring(0, startPos) + v + node.value.substring(endPos, node.value.length)
+                if (restoreTop > 0) {
+                    node.scrollTop = restoreTop
+                }
+                if (field == 'channelName') {
+                    this[form].setFieldsValue({ channelName: node.value })
+                } else if (field == 'channelCode') {
+                    this[form].setFieldsValue({ channelCode: node.value })
+                } else if (field == 'url') {
+                    this[form].setFieldsValue({ url: node.value })
+                } else if (field == 'clickTrackUrl') {
+                    this[form].setFieldsValue({ clickTrackUrl: node.value })
+                } else if (field == 'actionbarClickUrl') {
+                    this[form].setFieldsValue({ actionbarClickUrl: node.value })
+                } else if (field == 'appVersion') {
+                    this[form].setFieldsValue({ appVersion: node.value })
+                }
+                node.focus()
+                node.selectionStart = startPos + v.length
+                node.selectionEnd = startPos + v.length
+                // this.channelName = node.value
+            } else {
+                //OTHER
+                node.value += v
+                // console.log(node.value)
+                if (field == 'channelName') {
+                    this[form].setFieldsValue({ channelName: node.value })
+                } else if (field == 'channelCode') {
+                    this[form].setFieldsValue({ channelCode: node.value })
+                } else if (field == 'url') {
+                    this[form].setFieldsValue({ url: node.value })
+                } else if (field == 'clickTrackUrl') {
+                    this[form].setFieldsValue({ clickTrackUrl: node.value })
+                } else if (field == 'actionbarClickUrl') {
+                    this[form].setFieldsValue({ actionbarClickUrl: node.value })
+                } else if (field == 'appVersion') {
+                    this[form].setFieldsValue({ appVersion: node.value })
+                }
+
+                node.focus()
+                // this.channelName = node.value
+            }
+        },
         overUpload(file) {},
         overUpload(file) {},
         downLoadFile() {
         downLoadFile() {
             downFile('/kuaishouAppPackage/exportAppTemplate').then(res => {
             downFile('/kuaishouAppPackage/exportAppTemplate').then(res => {
@@ -314,19 +399,6 @@ export default {
                     that.personNameDisabled = false
                     that.personNameDisabled = false
                     that.personResourceDisabled = false
                     that.personResourceDisabled = false
                     resolve()
                     resolve()
-                    //   } else if (result.code === 201) {
-                    //     that.$message.error(result.message)
-                    //     that.personForm.name = result.result.orientationName
-                    //     that.personForm.resource = result.result.type
-                    //     that.personNameDisabled = true
-                    //     that.personResourceDisabled = true
-                    //     reject()
-                    //   }
-                    // })
-                    // .catch((error) => {
-                    //   console.log(error, 'eeee')
-                    //   reject()
-                    // })
                 })
                 })
             })
             })
         },
         },
@@ -406,6 +478,7 @@ export default {
                         params = { ...values }
                         params = { ...values }
                         params.appIconUrl = this.fileUrl
                         params.appIconUrl = this.fileUrl
                         this.$emit('getDataList', params)
                         this.$emit('getDataList', params)
+                        this.handleCancel()
                         // postAction(this.url.insertTemplateUrl, params).then(res => {
                         // postAction(this.url.insertTemplateUrl, params).then(res => {
                         //     this.confirmLoading = false
                         //     this.confirmLoading = false
                         //     if (res.success) {
                         //     if (res.success) {
@@ -426,6 +499,7 @@ export default {
         onChange(value) {}
         onChange(value) {}
     },
     },
     created: function() {
     created: function() {
+        this.createTypeData = JSON.parse(localStorage.getItem('createTypeData'))
         let params = {}
         let params = {}
         params.pageSize = '1000'
         params.pageSize = '1000'
         params.mediaId = '2'
         params.mediaId = '2'

+ 93 - 21
src/views/modules/autoLaunch/channelManage/createChannel.vue

@@ -217,7 +217,7 @@ li.chouzhen.first:before {
                     <a-col :sm="24" style="margin-bottom: 20px; z-index: 10" id="container">
                     <a-col :sm="24" style="margin-bottom: 20px; z-index: 10" id="container">
                         <a-card class="search-box step-jump">
                         <a-card class="search-box step-jump">
                             <a-form layout="horizontal" v-bind="formItemLayout" :form="formProject">
                             <a-form layout="horizontal" v-bind="formItemLayout" :form="formProject">
-                                <a-row :gutter="16">
+                                <a-row :gutter="16" v-if="createTypeData && !!!createTypeData.accountId">
                                     <a-col :span="16">
                                     <a-col :span="16">
                                         <a-form-item label="使用范围">
                                         <a-form-item label="使用范围">
                                             <a-radio-group
                                             <a-radio-group
@@ -241,7 +241,11 @@ li.chouzhen.first:before {
                                     v-if="getFormData('usageRange') == 2 || getFormData('usageRange') == undefined"
                                     v-if="getFormData('usageRange') == 2 || getFormData('usageRange') == undefined"
                                 >
                                 >
                                     <a-col :span="16">
                                     <a-col :span="16">
-                                        <a-form-item label="选择项目">
+                                        <a-form-item
+                                            :label="
+                                                createTypeData && !!!createTypeData.accountId ? '选择项目' : '账户ID'
+                                            "
+                                        >
                                             <Treeselect
                                             <Treeselect
                                                 style="width:600px"
                                                 style="width:600px"
                                                 v-decorator="[
                                                 v-decorator="[
@@ -250,7 +254,9 @@ li.chouzhen.first:before {
                                                         rules: [{ required: true, message: '项目必选' }]
                                                         rules: [{ required: true, message: '项目必选' }]
                                                     }
                                                     }
                                                 ]"
                                                 ]"
+                                                v-if="createTypeData && !!!createTypeData.accountId"
                                             />
                                             />
+                                            <span v-else>{{ createTypeData.accountId }}</span>
                                         </a-form-item>
                                         </a-form-item>
                                     </a-col>
                                     </a-col>
                                 </a-row>
                                 </a-row>
@@ -344,11 +350,14 @@ li.chouzhen.first:before {
                                                 id="channelCode"
                                                 id="channelCode"
                                             />
                                             />
                                         </a-form-item>
                                         </a-form-item>
-                                        <a-form-item v-bind="tailFormItemLayout">
+                                        <a-form-item
+                                            v-bind="tailFormItemLayout"
+                                            v-if="createTypeData && createTypeData.createType == '1'"
+                                        >
                                             <a-tag
                                             <a-tag
                                                 color="#2db7f5"
                                                 color="#2db7f5"
-                                                @click="getChangeAll('渠道号', 'formProject', 'channelCode')"
-                                                >+渠道号</a-tag
+                                                @click="getChangeAll('号', 'formProject', 'channelCode')"
+                                                >+号</a-tag
                                             >
                                             >
                                         </a-form-item>
                                         </a-form-item>
                                     </a-col>
                                     </a-col>
@@ -365,7 +374,10 @@ li.chouzhen.first:before {
                                                 id="channelName"
                                                 id="channelName"
                                             />
                                             />
                                         </a-form-item>
                                         </a-form-item>
-                                        <a-form-item v-bind="tailFormItemLayout">
+                                        <a-form-item
+                                            v-bind="tailFormItemLayout"
+                                            v-if="createTypeData && createTypeData.createType == '1'"
+                                        >
                                             <a-tag
                                             <a-tag
                                                 color="#2db7f5"
                                                 color="#2db7f5"
                                                 @click="getChangeAll('渠道号', 'formProject', 'channelName')"
                                                 @click="getChangeAll('渠道号', 'formProject', 'channelName')"
@@ -394,17 +406,22 @@ li.chouzhen.first:before {
                                         <a-form-item label="调起链接">
                                         <a-form-item label="调起链接">
                                             <a-input
                                             <a-input
                                                 v-decorator="[
                                                 v-decorator="[
-                                                    'url',
+                                                    'schemaUri',
                                                     {
                                                     {
                                                         rules: [{ validator: handleConfirmValueOkUndefind }]
                                                         rules: [{ validator: handleConfirmValueOkUndefind }]
                                                     }
                                                     }
                                                 ]"
                                                 ]"
                                                 allow-clear
                                                 allow-clear
-                                                id="url"
+                                                id="schemaUri"
                                             />
                                             />
                                         </a-form-item>
                                         </a-form-item>
-                                        <a-form-item v-bind="tailFormItemLayout">
-                                            <a-tag color="#2db7f5" @click="getChangeAll('渠道号', 'formProject', 'url')"
+                                        <a-form-item
+                                            v-bind="tailFormItemLayout"
+                                            v-if="createTypeData && createTypeData.createType == '1'"
+                                        >
+                                            <a-tag
+                                                color="#2db7f5"
+                                                @click="getChangeAll('渠道号', 'formProject', 'schemaUri')"
                                                 >+渠道号</a-tag
                                                 >+渠道号</a-tag
                                             >
                                             >
                                         </a-form-item>
                                         </a-form-item>
@@ -427,7 +444,10 @@ li.chouzhen.first:before {
                                                 id="clickTrackUrl"
                                                 id="clickTrackUrl"
                                             />
                                             />
                                         </a-form-item>
                                         </a-form-item>
-                                        <a-form-item v-bind="tailFormItemLayout">
+                                        <a-form-item
+                                            v-bind="tailFormItemLayout"
+                                            v-if="createTypeData && createTypeData.createType == '1'"
+                                        >
                                             <a-tag
                                             <a-tag
                                                 color="#2db7f5"
                                                 color="#2db7f5"
                                                 @click="getChangeAll('渠道号', 'formProject', 'clickTrackUrl')"
                                                 @click="getChangeAll('渠道号', 'formProject', 'clickTrackUrl')"
@@ -456,7 +476,10 @@ li.chouzhen.first:before {
                                                 id="actionbarClickUrl"
                                                 id="actionbarClickUrl"
                                             />
                                             />
                                         </a-form-item>
                                         </a-form-item>
-                                        <a-form-item v-bind="tailFormItemLayout">
+                                        <a-form-item
+                                            v-bind="tailFormItemLayout"
+                                            v-if="createTypeData && createTypeData.createType == '1'"
+                                        >
                                             <a-tag
                                             <a-tag
                                                 color="#2db7f5"
                                                 color="#2db7f5"
                                                 @click="getChangeAll('渠道号', 'formProject', 'actionbarClickUrl')"
                                                 @click="getChangeAll('渠道号', 'formProject', 'actionbarClickUrl')"
@@ -550,6 +573,12 @@ li.chouzhen.first:before {
                     </a-col>
                     </a-col>
                 </a-row>
                 </a-row>
             </div>
             </div>
+            <div style="width:100%;display:flex;    justify-content: flex-end;">
+                <a-button type="default" style="margin-right: 15px" @click="goBack">返回</a-button>
+                <a-button type="primary" style="margin-right: 15px" @click="saveHandler" :loading="saveLoading"
+                    >确定</a-button
+                >
+            </div>
         </a-spin>
         </a-spin>
         <creatApplication ref="application" @getDataList="getDataAll" />
         <creatApplication ref="application" @getDataList="getDataAll" />
     </div>
     </div>
@@ -563,7 +592,7 @@ import pick from 'lodash.pick'
 import { mixin } from '@/utils/mixin.js'
 import { mixin } from '@/utils/mixin.js'
 import Treeselect from './components/treeSelectProject.vue'
 import Treeselect from './components/treeSelectProject.vue'
 import treeSelectAccount from './components/treeSelectAccount.vue'
 import treeSelectAccount from './components/treeSelectAccount.vue'
-
+import { mapGetters } from 'vuex'
 import moment from 'moment'
 import moment from 'moment'
 import selectCheckAll from '@/components/formComponents/toutiaoTime'
 import selectCheckAll from '@/components/formComponents/toutiaoTime'
 import checkBoxGroup from '@/components/formComponents/checkBoxGroup'
 import checkBoxGroup from '@/components/formComponents/checkBoxGroup'
@@ -571,6 +600,7 @@ import uploadFile from '@/components/uploadFileMd5Push.vue'
 import { stopOtherVideo, closeAllVideoFun } from '@/utils/videoControl' // 停止除当前外的其他视频播放,及停止所有视频播放的方法
 import { stopOtherVideo, closeAllVideoFun } from '@/utils/videoControl' // 停止除当前外的其他视频播放,及停止所有视频播放的方法
 import selectTable from '@/views/modules/Statistics/components/selectPagination.vue'
 import selectTable from '@/views/modules/Statistics/components/selectPagination.vue'
 import creatApplication from './components/creatApplication.vue'
 import creatApplication from './components/creatApplication.vue'
+import { getAction, postAction, downFile, downFilePost } from '@/api/manage'
 // import EditableCell from './editablCell'
 // import EditableCell from './editablCell'
 // import lookPreviewVue from './lookPreview.vue'
 // import lookPreviewVue from './lookPreview.vue'
 function tqFun(qcArr1) {
 function tqFun(qcArr1) {
@@ -635,6 +665,7 @@ export default {
         return {
         return {
             projectId: null,
             projectId: null,
             spinning: false,
             spinning: false,
+            saveLoading: false,
             accountIds: [],
             accountIds: [],
             fansStarOptions: [],
             fansStarOptions: [],
             fansStarType: 0,
             fansStarType: 0,
@@ -648,6 +679,7 @@ export default {
             activeKey: '',
             activeKey: '',
             loading: false,
             loading: false,
             formProject: this.$form.createForm(this), //选择项目表单
             formProject: this.$form.createForm(this), //选择项目表单
+            newAppFormData: null,
             formItemLayout: {
             formItemLayout: {
                 labelCol: { span: 6 },
                 labelCol: { span: 6 },
                 wrapperCol: { span: 16 }
                 wrapperCol: { span: 16 }
@@ -659,13 +691,15 @@ export default {
                         offset: 6
                         offset: 6
                     }
                     }
                 }
                 }
-            }
+            },
+            createTypeData: { createType: '1', accountId: null }
         }
         }
     },
     },
     computed: {},
     computed: {},
     watch: {},
     watch: {},
     mounted() {
     mounted() {
         this.$nextTick(function() {
         this.$nextTick(function() {
+            this.createTypeData = JSON.parse(localStorage.getItem('createTypeData'))
             window.addEventListener('scroll', this.onScroll)
             window.addEventListener('scroll', this.onScroll)
             const that = this
             const that = this
             window.onresize = () => {
             window.onresize = () => {
@@ -679,7 +713,10 @@ export default {
     filters: {},
     filters: {},
     methods: {
     methods: {
         moment,
         moment,
-        getDataAll(form) {},
+        ...mapGetters(['userInfo']),
+        getDataAll(form) {
+            this.newAppFormData = form
+        },
         addNewApp() {
         addNewApp() {
             this.$refs.application.showApplication()
             this.$refs.application.showApplication()
         },
         },
@@ -696,8 +733,8 @@ export default {
                     this[form].setFieldsValue({ channelName: sel.text })
                     this[form].setFieldsValue({ channelName: sel.text })
                 } else if (field == 'channelCode') {
                 } else if (field == 'channelCode') {
                     this[form].setFieldsValue({ channelCode: sel.text })
                     this[form].setFieldsValue({ channelCode: sel.text })
-                } else if (field == 'url') {
-                    this[form].setFieldsValue({ url: sel.text })
+                } else if (field == 'schemaUri') {
+                    this[form].setFieldsValue({ schemaUri: sel.text })
                 } else if (field == 'clickTrackUrl') {
                 } else if (field == 'clickTrackUrl') {
                     this[form].setFieldsValue({ clickTrackUrl: sel.text })
                     this[form].setFieldsValue({ clickTrackUrl: sel.text })
                 } else if (field == 'actionbarClickUrl') {
                 } else if (field == 'actionbarClickUrl') {
@@ -716,8 +753,8 @@ export default {
                     this[form].setFieldsValue({ channelName: node.value })
                     this[form].setFieldsValue({ channelName: node.value })
                 } else if (field == 'channelCode') {
                 } else if (field == 'channelCode') {
                     this[form].setFieldsValue({ channelCode: node.value })
                     this[form].setFieldsValue({ channelCode: node.value })
-                } else if (field == 'url') {
-                    this[form].setFieldsValue({ url: sel.text })
+                } else if (field == 'schemaUri') {
+                    this[form].setFieldsValue({ schemaUri: sel.text })
                 } else if (field == 'clickTrackUrl') {
                 } else if (field == 'clickTrackUrl') {
                     this[form].setFieldsValue({ clickTrackUrl: sel.text })
                     this[form].setFieldsValue({ clickTrackUrl: sel.text })
                 } else if (field == 'actionbarClickUrl') {
                 } else if (field == 'actionbarClickUrl') {
@@ -735,8 +772,8 @@ export default {
                     this[form].setFieldsValue({ channelName: node.value })
                     this[form].setFieldsValue({ channelName: node.value })
                 } else if (field == 'channelCode') {
                 } else if (field == 'channelCode') {
                     this[form].setFieldsValue({ channelCode: node.value })
                     this[form].setFieldsValue({ channelCode: node.value })
-                } else if (field == 'url') {
-                    this[form].setFieldsValue({ url: sel.text })
+                } else if (field == 'schemaUri') {
+                    this[form].setFieldsValue({ schemaUri: sel.text })
                 } else if (field == 'clickTrackUrl') {
                 } else if (field == 'clickTrackUrl') {
                     this[form].setFieldsValue({ clickTrackUrl: sel.text })
                     this[form].setFieldsValue({ clickTrackUrl: sel.text })
                 } else if (field == 'actionbarClickUrl') {
                 } else if (field == 'actionbarClickUrl') {
@@ -769,6 +806,41 @@ export default {
                 callback()
                 callback()
             }
             }
         },
         },
+        goBack() {
+            this.$router.replace('/autoLaunch/channelManage')
+            this.$bus.$emit('remove', '/autoLaunch/createChannel')
+        },
+        saveHandler() {
+            this.formProject.validateFields((err, values) => {
+                if (!err) {
+                    if (!!this.newAppFormData) {
+                        this.saveLoading = true
+                        var params = { ...values, ...this.newAppFormData }
+                        params.userId = this.userInfo().id
+                        params.createType = this.createTypeData.createType
+                        if (this.createTypeData && !!this.createTypeData.accountId) {
+                            params.projectId = null
+                            params.accountId = this.createTypeData.accountId
+                        }
+                        let url =
+                            this.createTypeData.createType == '1'
+                                ? '/channel/systemBatchCreation'
+                                : '/channel/customizedCreate'
+                        postAction(url, params).then(res => {
+                            this.saveLoading = false
+                            if (res.success) {
+                                this.$router.replace('/autoLaunch/channelManage')
+                                this.$bus.$emit('remove', '/autoLaunch/createChannel')
+                            } else {
+                                this.$message.error(res.message)
+                            }
+                        })
+                    } else {
+                        this.$message.error('未创建新的应用')
+                    }
+                }
+            })
+        },
         numberMaxCheck() {
         numberMaxCheck() {
             // if (value == '' || value == null) {
             // if (value == '' || value == null) {
             //     callback('请输入最高出价')
             //     callback('请输入最高出价')

+ 209 - 16
src/views/modules/autoLaunch/channelManage/index.vue

@@ -178,9 +178,9 @@
                         ref="accountTable"
                         ref="accountTable"
                     >
                     >
                         <span slot="action" slot-scope="text, records">
                         <span slot="action" slot-scope="text, records">
-                            <a>添加渠道号</a>
+                            <a @click="addNewChannelElse(records)">添加渠道号</a>
                             <a-divider type="vertical" />
                             <a-divider type="vertical" />
-                            <a>查看详情</a>
+                            <a @click="toDetailList(records)">查看详情</a>
                         </span>
                         </span>
                     </a-table>
                     </a-table>
                     <a-pagination
                     <a-pagination
@@ -236,21 +236,94 @@
                 </div>
                 </div>
             </a-radio-group>
             </a-radio-group>
         </a-modal>
         </a-modal>
+
+        <a-modal
+            title="下载模板"
+            :width="800"
+            ref="modal"
+            :visible="visibleDownLoad"
+            @ok="handleOkImport"
+            @cancel="
+                visibleDownLoad = false
+                productIdDownLoad = ''
+                projectIdDownLoad = ''
+                fileUrl = ''
+                cancel()
+            "
+            okText="提交"
+            :confirmLoading="downLoading"
+        >
+            <selectTable :projectId.sync="productIdDownLoad" ref="selectTableDownLoad"></selectTable>
+            <selectTableProject
+                :projectId.sync="projectIdDownLoad"
+                :productId="productIdDownLoad"
+                ref="selectTableProjectDownLoad"
+            ></selectTableProject>
+            <a-button type="primary" icon="plus" @click="handleOkDownLoad" style="margin-left:85px;margin-bottom:15px"
+                >导出渠道号模板</a-button
+            >
+            <a-form :form="formDownLoad">
+                <a-form-item
+                    label="上传图标"
+                    :labelCol="{ xs: { span: 24 }, sm: { span: 5 } }"
+                    :wrapperCol="{ xs: { span: 24 }, sm: { span: 19 } }"
+                    v-if="visibleDownLoad"
+                    class="require-class"
+                >
+                    <uploadFile
+                        v-if="visibleDownLoad"
+                        :value.sync="fileUrl"
+                        :multiple="false"
+                        :fileCount="1"
+                        uploadType="image"
+                        @overUpload="overUpload"
+                        :size="100"
+                    ></uploadFile>
+                    <p class="upload-txt-rules">文件格式:支持上传png/jpg/jpeg图片,尺寸450*450,小于100kb</p>
+                </a-form-item>
+                <a-form-item
+                    label="上传文件"
+                    v-if="visibleDownLoad"
+                    :labelCol="{ xs: { span: 24 }, sm: { span: 5 } }"
+                    :wrapperCol="{ xs: { span: 24 }, sm: { span: 16 } }"
+                    class="require-class fileUpload"
+                    id="fileUpload"
+                >
+                    <a-upload
+                        name="file"
+                        :multiple="false"
+                        :headers="tokenHeader"
+                        :file-list="fileList"
+                        :showUploadList="false"
+                        :beforeUpload="beforeUpload"
+                        @change="handleChange"
+                        style="margin-right: 20px"
+                    >
+                        <a-button :disabled="fileUrl == ''">
+                            <a-icon type="upload" />
+                            {{ loadDisabled ? '上传中,请稍后' : '文件上传' }}
+                        </a-button>
+                    </a-upload>
+                </a-form-item>
+            </a-form>
+        </a-modal>
     </div>
     </div>
 </template>
 </template>
 
 
 <script>
 <script>
-import { TreeSelect } from 'ant-design-vue'
-const SHOW_PARENT = TreeSelect.SHOW_PARENT
 import ARow from 'ant-design-vue/es/grid/Row'
 import ARow from 'ant-design-vue/es/grid/Row'
 import ACol from 'ant-design-vue/es/grid/Col'
 import ACol from 'ant-design-vue/es/grid/Col'
 import moment from 'moment'
 import moment from 'moment'
-import { getKsAccountReport, getKsDetail, getReportList } from '@api/video.js'
 import { getAction, postAction, downFile, downFilePost } from '@/api/manage'
 import { getAction, postAction, downFile, downFilePost } from '@/api/manage'
 import selectTable from '@/views/modules/material/comment/selectTable.vue'
 import selectTable from '@/views/modules/material/comment/selectTable.vue'
 import selectTableProject from '@/views/modules/Statistics/components/selectPagination.vue'
 import selectTableProject from '@/views/modules/Statistics/components/selectPagination.vue'
 import qs from 'qs'
 import qs from 'qs'
-
+import { mapGetters } from 'vuex'
+import uploadFile from './components/uploadFile.vue'
+import Vue from 'vue'
+import { ACCESS_TOKEN } from '@/store/mutation-types'
+import $ from 'jquery'
+const fileSuffix = ['xlsx', 'xls', 'zip']
 let TTcolumns = [
 let TTcolumns = [
     {
     {
         title: '产品名称',
         title: '产品名称',
@@ -303,20 +376,31 @@ export default {
         ACol,
         ACol,
         ARow,
         ARow,
         selectTable,
         selectTable,
-        selectTableProject
+        selectTableProject,
+        uploadFile
     },
     },
 
 
     data() {
     data() {
         return {
         return {
+            tokenHeader: { 'X-Access-Token': Vue.ls.get(ACCESS_TOKEN) },
+            fileList: [],
+            dataFile: null,
+            loadDisabled: false,
             productId: '',
             productId: '',
             projectId: '',
             projectId: '',
             accountId: '',
             accountId: '',
             visibleChannel: false,
             visibleChannel: false,
+            visibleDownLoad: false,
+            downLoading: false,
+            fileUrl: '',
+            projectIdDownLoad: '',
+            productIdDownLoad: '',
             channelType: 'a',
             channelType: 'a',
-            createType:1,
+            createType: 1,
             indexAll: 0,
             indexAll: 0,
             spinning: false,
             spinning: false,
             form: this.$form.createForm(this),
             form: this.$form.createForm(this),
+            formDownLoad: this.$form.createForm(this),
             exportloading: false,
             exportloading: false,
             dateRange: [moment().subtract(1, 'weeks'), moment()],
             dateRange: [moment().subtract(1, 'weeks'), moment()],
             noImg: require('@/assets/noImg.png'),
             noImg: require('@/assets/noImg.png'),
@@ -359,7 +443,6 @@ export default {
             //treeselect的参数
             //treeselect的参数
             treeValue: [],
             treeValue: [],
             treeData: [],
             treeData: [],
-            SHOW_PARENT,
 
 
             type: 3,
             type: 3,
 
 
@@ -394,13 +477,48 @@ export default {
     },
     },
     methods: {
     methods: {
         moment,
         moment,
-        newCreat(id) {
-            if (id) {
-                window.open('/creat-config?id=' + id, '_blank')
-            } else {
-                window.open('/creat-config', '_blank')
+        overUpload(file) {},
+        handleChange() {
+            this.loadDisabled = false
+            this.$message.success('文件导入成功')
+        },
+        beforeUpload(file) {
+            // this.cosUpload(file)
+            // if (process.env.NODE_ENV == 'development') {
+            //   this.uploadAction = `/jeecg-boot/kuaishouAppPackage/importAppExcel?projectId=${this.projectId}&platform=${
+            //     this.appType == 'ios' ? +this.platform + 2 : +this.platform
+            //   }&imageUrl=${this.fileUrl}`
+            // } else if (process.env.NODE_ENV == 'debug') {
+            // } else if (process.env.NODE_ENV == 'production') {
+            //   this.uploadAction = `${this.axios.defaults.baseURL}/kuaishouAppPackage/importAppExcel?projectId=${
+            //     this.projectId
+            //   }&platform=${this.appType == 'ios' ? +this.platform + 2 : +this.platform}&imageUrl=${this.fileUrl}`
+            // }
+            // this.dataFile = file
+            this.dataFile = $('.fileUpload')
+                .eq(0)
+                .find('input')[0].files[0]
+            this.loadDisabled = true
+            const size = (Number(file.size) / (1024 * 1024)).toFixed(2)
+            const fileName = file.name
+            const fileStrArr = fileName.split('.')
+            const suffix = fileStrArr[fileStrArr.length - 1]
+
+            let result = fileSuffix.some(item => {
+                return item === suffix
+            })
+
+            if (!result) {
+                this.$message.error('不支持该文件类型')
+                this.loadDisabled = false
+                return false
             }
             }
         },
         },
+        ...mapGetters(['userInfo']),
+        toDetailList(item) {
+            localStorage.setItem('channelInfoAccountId', item.accountId)
+            this.$router.push({ path: '/autoLaunch/channelDetailList' })
+        },
 
 
         cpaBidValid(rule, value, callback) {
         cpaBidValid(rule, value, callback) {
             let z = /-/g
             let z = /-/g
@@ -420,10 +538,79 @@ export default {
                 callback()
                 callback()
             }
             }
         },
         },
+        addNewChannelElse(item) {
+            this.createType = item.createType
+            var createTypeData = { createType: this.createType, accountId: item.accountId }
+            localStorage.setItem('createTypeData', JSON.stringify(createTypeData))
+            this.$router.push({ path: '/autoLaunch/createChannel' })
+        },
         handleOk() {
         handleOk() {
             if (this.channelType == 'a') {
             if (this.channelType == 'a') {
-                this.createType = 1
+                this.createType = '1'
+                var createTypeData = { createType: this.createType, accountId: null }
+                localStorage.setItem('createTypeData', JSON.stringify(createTypeData))
                 this.$router.push({ path: '/autoLaunch/createChannel' })
                 this.$router.push({ path: '/autoLaunch/createChannel' })
+            } else if (this.channelType == 'b') {
+                this.createType = '2'
+                this.visibleDownLoad = true
+                this.handleCancel()
+            } else if (this.channelType == 'c') {
+                this.createType = '3'
+                var createTypeData = { createType: this.createType, accountId: null }
+                localStorage.setItem('createTypeData', JSON.stringify(createTypeData))
+                this.$router.push({ path: '/autoLaunch/createChannel' })
+            }
+        },
+        handleOkImport() {
+            if (!!this.fileUrl) {
+                this.downLoading = true
+                let params = {}
+                if (this.dataFile) {
+                    let formData = new FormData()
+                    formData.append('file', this.dataFile)
+                    formData.append('imageUrl', this.fileUrl)
+
+                    postAction('/channel/importChannelExcel', formData).then(res => {
+                        this.downLoading = false
+                        if (res.code === 200) {
+                            this.$message.success('创建成功')
+                            this.visibleDownLoad = false
+                            this.productIdDownLoad = ''
+                            this.projectIdDownLoad = ''
+                            this.fileUrl = ''
+                            this.handleResetForm()
+                        } else {
+                            this.$message.error(res.message)
+                        }
+                    })
+                } else {
+                    this.$message.error('请上传文件')
+                }
+
+                return
+            }
+        },
+        handleOkDownLoad() {
+            if (!!this.projectIdDownLoad && !!this.productIdDownLoad) {
+                let params = {}
+                params.productId = this.productIdDownLoad
+                params.projectId = this.projectIdDownLoad
+                params.userId = this.userInfo().id
+                downFile('/channel/exportChannelTemplate', params).then(res => {
+                    let blob = new Blob([res], {
+                        type: 'application/vnd.openxmlformats-officedocument.spre1adsheetml.sheet'
+                    })
+                    let downloadElement = document.createElement('a')
+                    let href = window.URL.createObjectURL(blob) //创建下载的链接
+                    downloadElement.href = href
+                    downloadElement.download = '渠道号模板.xlsx' //下载后文件名
+                    document.body.appendChild(downloadElement)
+                    downloadElement.click() //点击下载
+                    document.body.removeChild(downloadElement) //下载完成移除元素
+                    window.URL.revokeObjectURL(href) //释放掉blob对象
+                })
+            } else {
+                this.$message.error('请选择产品和项目')
             }
             }
         },
         },
         handleCancel() {
         handleCancel() {
@@ -471,7 +658,7 @@ export default {
                     this.dataLoading = false
                     this.dataLoading = false
                     if (result.code === 200) {
                     if (result.code === 200) {
                         this.dataSource = result.result.list || []
                         this.dataSource = result.result.list || []
-                        this.ipagination.total = result.pageInfo.total || 0
+                        this.ipagination.total = result.result.total || 0
                         // result.result.total
                         // result.result.total
                     } else {
                     } else {
                         this.$message.error(result.message)
                         this.$message.error(result.message)
@@ -542,6 +729,12 @@ export default {
                 this.$refs.selectTableProject.keyValue = ''
                 this.$refs.selectTableProject.keyValue = ''
                 this.$refs.selectTableProject.getData(n)
                 this.$refs.selectTableProject.getData(n)
             }
             }
+        },
+        productIdDownLoad: function(n, o) {
+            if (n != '') {
+                this.$refs.selectTableProjectDownLoad.keyValue = ''
+                this.$refs.selectTableProjectDownLoad.getData(n)
+            }
         }
         }
     },
     },
     computed: {
     computed: {

+ 923 - 0
src/views/modules/autoLaunch/channelManage/itemList.vue

@@ -0,0 +1,923 @@
+<style lang="scss" scoped>
+.search-bar {
+    display: flex;
+    align-items: center;
+}
+.search-box p {
+    display: inline-block;
+    border: 1px solid #f2f2f2;
+    border-radius: 5px;
+    margin-right: 10px;
+    padding: 5px 10px;
+    cursor: pointer;
+}
+</style>
+<style scoped>
+.showNumBox {
+    margin: 10px 0;
+}
+.showNumBox .ant-card-body {
+    display: flex;
+    justify-content: center;
+}
+.showNumBox p,
+.showNumBox span {
+    text-align: center;
+    line-height: 40px;
+    font-size: 30px;
+    font-weight: 600;
+    color: red;
+    margin: 0;
+}
+.search-box .ant-card-body {
+    padding: 5px 15px;
+}
+.showNumBox .ant-card-body .styleElse {
+    line-height: 60px;
+    height: 40px;
+    font-size: 16px;
+    font-weight: 400;
+    margin-left: 10px;
+}
+.ant-modal-wrap .yincang .ant-modal-content .ant-modal-footer {
+    display: none !important;
+}
+.yincang .ant-col-6 p {
+    text-align: left;
+    color: red;
+    font-size: 16px;
+    font-weight: 500;
+}
+.ant-table-thead div {
+    font-weight: 700;
+}
+.tool-tip {
+    position: absolute;
+    top: 65px;
+    right: 10px;
+}
+</style>
+<style lang="less" scoped>
+.ant-card-head .ant-tabs-bar {
+    padding: 0;
+}
+.search-box .ant-card-body {
+    padding: 5px 15px;
+}
+.search-box {
+    padding: 15px 10px;
+}
+.search-box p {
+    display: inline-block;
+    border: 1px solid #f2f2f2;
+    border-radius: 5px;
+    margin-right: 10px;
+    padding: 5px 10px;
+    cursor: pointer;
+}
+.statistics .ant-col-6 .ant-card-body .styleElse {
+    line-height: 60px;
+    height: 40px;
+    font-size: 16px;
+    font-weight: 400;
+    margin-left: 10px;
+}
+.ant-modal-wrap .yincang .ant-modal-content .ant-modal-footer {
+    display: none !important;
+}
+.yincang .ant-col-6 p {
+    text-align: left;
+    color: red;
+    font-size: 16px;
+    font-weight: 500;
+}
+.ant-table-thead div {
+    font-weight: 700;
+}
+.tool-tip {
+    position: absolute;
+    top: 65px;
+    right: 10px;
+}
+.statistics {
+    .ant-card-bordered {
+        border: none;
+    }
+    .ant-card-head .ant-tabs {
+        clear: both;
+        margin-bottom: -13px;
+        color: rgba(0, 0, 0, 0.65);
+        font-weight: normal;
+        font-size: 14px;
+    }
+    .duibi {
+        position: absolute;
+        right: 24px;
+        top: 15px;
+    }
+    p {
+        margin-bottom: 0;
+    }
+}
+</style>
+
+<style lang="less" scoped>
+@import 'channelManage';
+</style>
+<template>
+    <div class="channelManage config-project">
+        <a-card>
+            <div class="table-page-search-wrapper">
+                <a-form layout="inline" :form="form" hide-required-mark :selfUpdate="true" @submit="handleQueryList">
+                    <a-row :gutter="24">
+                        <!-- <a-col :md="8" :sm="8" :xxl="6">
+                            <selectTable :projectId.sync="productId" ref="selectTable"></selectTable>
+                        </a-col> -->
+
+                        <a-col :md="8" :sm="8" :xxl="6">
+                            <selectTableProject
+                                :projectId.sync="projectId"
+                                :productId="productId"
+                                ref="selectTableProject"
+                            ></selectTableProject>
+                        </a-col>
+                        <!--  -->
+                        <a-col :md="8" :sm="8" :xxl="6">
+                            <a-form-item label="素材关键字">
+                                <a-input placeholder="请输入素材关键字" v-decorator="['keyword']"></a-input>
+                            </a-form-item>
+                        </a-col>
+                        <a-col :md="8" :sm="8" :xxl="6">
+                            <a-form-item label="单品名称">
+                                <a-input placeholder="请输入单品名称" v-decorator="['itemName']"></a-input>
+                            </a-form-item>
+                        </a-col>
+                        <a-col :md="8" :sm="8" :xxl="6">
+                            <span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
+                                <a-button type="primary" icon="search" @click="handleQueryList">查询</a-button>
+                                <a-button type="primary" @click="handleResetForm" icon="reload" class="middle-button"
+                                    >重置</a-button
+                                >
+                                <a-button type="primary" @click="visibleAddItem = true">添加单品</a-button>
+                                <a-button type="primary" @click="visibleDownLoad = true" class="middle-button"
+                                    >批量导入单品</a-button
+                                >
+                            </span>
+                        </a-col>
+                    </a-row>
+                </a-form>
+            </div>
+        </a-card>
+
+        <a-row style="margin-bottom:15px;margin-top:12px">
+            <a-col :span="24">
+                <div class="tableBody" style="min-height:200px;padding-bottom: 50px">
+                    <a-table
+                        :columns="columns"
+                        :dataSource="dataSource"
+                        :pagination="false"
+                        :loading="dataLoading"
+                        bordered
+                        @change="tableChange"
+                        size="middle"
+                        style="word-break: break-all;font-size:16px;font-weight:600"
+                        id="outTable"
+                        ref="accountTable"
+                    >
+                        <span slot="state" slot-scope="text, record">
+                            <a-switch :checked="text" @change="handleSwitchChang($event, record)" />
+                        </span>
+                        <span slot="action" slot-scope="text, record">
+                            <a-popover
+                                v-model="record.visible"
+                                trigger="click"
+                                placement="topLeft"
+                                @visibleChange="visibleChange"
+                            >
+                                <span slot="title">关键词</span>
+                                <template slot="content" style="width:300px;">
+                                    <div style="margin:5px">
+                                        <span
+                                            ><a-input
+                                                v-model="keyWord"
+                                                size="small"
+                                                style="margin-right:20px;width:120px"
+                                        /></span>
+                                    </div>
+
+                                    <div>
+                                        <a-button
+                                            type="default"
+                                            @click="bidChangeCancel(record)"
+                                            size="small"
+                                            style="margin-right:10px"
+                                            >取消</a-button
+                                        >
+                                        <a-button type="primary" @click="bidChangeOk(record)" size="small" class="ok"
+                                            >修改</a-button
+                                        >
+                                    </div>
+                                </template>
+                                <a
+                                    @click="
+                                        () => {
+                                            record.visible = true
+                                        }
+                                    "
+                                    >编辑素材关键词</a
+                                >
+                            </a-popover>
+                        </span>
+                    </a-table>
+                    <a-pagination
+                        size="small"
+                        :showTotal="ipagination.showTotal"
+                        style="float: right;margin-top:10px"
+                        v-if="dataSource.length > 0"
+                        showQuickJumper
+                        :pageSize.sync="ipagination.pageSize"
+                        :total="ipagination.total"
+                        v-model="ipagination.current"
+                        @change="getDataSource"
+                    />
+                </div>
+            </a-col>
+        </a-row>
+
+        <a-modal
+            title="下载模板"
+            :width="800"
+            ref="modal"
+            :visible="visibleDownLoad"
+            @ok="handleOkImport"
+            @cancel="
+                visibleDownLoad = false
+                projectIdDownLoad = ''
+                cancel()
+            "
+            okText="提交"
+            :confirmLoading="downLoading"
+        >
+            <selectTableProject
+                :projectId.sync="projectIdDownLoad"
+                ref="selectTableProjectDownLoad"
+            ></selectTableProject>
+            <a-button type="primary" icon="plus" @click="handleOkDownLoad" style="margin-left:85px;margin-bottom:15px"
+                >导出单品模板</a-button
+            >
+            <a-form :form="formDownLoad">
+                <a-form-item
+                    label="上传文件"
+                    v-if="visibleDownLoad"
+                    :labelCol="{ xs: { span: 24 }, sm: { span: 5 } }"
+                    :wrapperCol="{ xs: { span: 24 }, sm: { span: 16 } }"
+                    class="require-class fileUpload"
+                    id="fileUpload"
+                >
+                    <a-upload
+                        name="file"
+                        :multiple="false"
+                        :headers="tokenHeader"
+                        :file-list="fileList"
+                        :showUploadList="false"
+                        :beforeUpload="beforeUpload"
+                        @change="handleChange"
+                        style="margin-right: 20px"
+                    >
+                        <a-button>
+                            <a-icon type="upload" />
+                            {{ loadDisabled ? '上传中,请稍后' : '文件上传' }}
+                        </a-button>
+                    </a-upload>
+                </a-form-item>
+            </a-form>
+        </a-modal>
+
+        <a-modal
+            title="添加单品"
+            :width="800"
+            ref="modal"
+            :visible="visibleAddItem"
+            @cancel="visibleAddItem = false"
+            @ok="handleOk"
+            :confirmLoading="confirmLoading"
+        >
+            <a-button type="primary" @click="addOneItem" style="margin-bottom:10px">添加单品信息</a-button>
+            <a-form-model ref="ruleForm" :model="addItemForm" v-bind="formItemLayout">
+                <a-collapse accordion v-model="activeKey" ref="collapse">
+                    <template v-for="(item, index) in addItemForm.items">
+                        <a-collapse-panel
+                            :header="item.itemName"
+                            style="background: #f9f9fa;border-radius: 4px;margin-bottom:15px;overflow: hidden;border: 1px solid #d9d9d9;"
+                        >
+                            <span slot="extra">
+                                <a-popconfirm :title="`确定删除吗?`" @confirm="deleteRule($event, item, index)">
+                                    <a-icon type="delete" @click="deleteIcon($event)" />
+                                </a-popconfirm>
+                            </span>
+                            <a-form-model-item
+                                label="项目"
+                                ref="projectId"
+                                :prop="'items.' + index + '.projectId'"
+                                :rules="[{ required: true, message: '请选择项目', trigger: 'blur' }]"
+                            >
+                                <!-- <a-input v-model="item.projectId" placeholder="请输入规则名称" /> -->
+                                <Treeselect v-model="item.projectId" style="width:100%" />
+                            </a-form-model-item>
+                            <a-form-model-item
+                                label="素材关键字"
+                                ref="keyword"
+                                :prop="'items.' + index + '.keyword'"
+                                :rules="[
+                                    { required: true, message: '请填写素材关键字', trigger: 'blur' },
+                                    { min: 1, message: '长度不得小于1', trigger: 'blur' }
+                                ]"
+                            >
+                                <a-input v-model="item.keyword" placeholder="请输入素材关键字" />
+                            </a-form-model-item>
+                            <a-form-model-item
+                                label="单品名称"
+                                ref="itemName"
+                                :prop="'items.' + index + '.itemName'"
+                                :rules="[
+                                    { required: true, message: '请填写单品名称', trigger: 'blur' },
+                                    { min: 1, message: '长度不得小于1', trigger: 'blur' }
+                                ]"
+                            >
+                                <a-input v-model="item.itemName" placeholder="请输入单品名称" />
+                            </a-form-model-item>
+                        </a-collapse-panel>
+                    </template>
+                </a-collapse>
+            </a-form-model>
+        </a-modal>
+    </div>
+</template>
+
+<script>
+import ARow from 'ant-design-vue/es/grid/Row'
+import ACol from 'ant-design-vue/es/grid/Col'
+import moment from 'moment'
+import { getAction, postAction, downFile, downFilePost } from '@/api/manage'
+import selectTable from '@/views/modules/material/comment/selectTable.vue'
+import selectTableProject from '@/views/modules/Statistics/components/selectPagination.vue'
+import Treeselect from './components/treeSelectProject.vue'
+import qs from 'qs'
+import { mapGetters } from 'vuex'
+import uploadFile from './components/uploadFile.vue'
+import Vue from 'vue'
+import { ACCESS_TOKEN } from '@/store/mutation-types'
+import $ from 'jquery'
+const fileSuffix = ['xlsx', 'xls', 'zip']
+let TTcolumns = [
+    {
+        title: '开关',
+        dataIndex: 'state',
+        scopedSlots: { customRender: 'state' },
+        align: 'center',
+        key: 'state'
+    },
+    {
+        title: '项目名称',
+        dataIndex: 'project_name',
+        scopedSlots: { customRender: 'project_name' },
+        align: 'center',
+        key: 'project_name'
+    },
+
+    {
+        title: '单品名称',
+        dataIndex: 'item_name',
+        scopedSlots: { customRender: 'item_name' },
+        align: 'center',
+        key: 'item_name'
+    },
+    {
+        title: '素材关键字',
+        dataIndex: 'keyword',
+        scopedSlots: { customRender: 'keyword' },
+        align: 'center',
+        key: 'keyword'
+    },
+    {
+        title: '操作',
+        dataIndex: 'action',
+        scopedSlots: { customRender: 'action' },
+        align: 'center',
+        key: 'action'
+    }
+]
+
+export default {
+    components: {
+        ACol,
+        ARow,
+        selectTable,
+        selectTableProject,
+        uploadFile,
+        Treeselect
+    },
+
+    data() {
+        return {
+            visibleAddItem: false,
+            confirmLoading: false,
+            activeKey: '0',
+            addItemForm: {
+                items: [{ projectId: '', keyWord: '', itemName: '默认名称-单品1' }]
+            },
+            formItemLayout: {
+                labelCol: { span: 4 },
+                wrapperCol: { span: 20 }
+            },
+            tokenHeader: { 'X-Access-Token': Vue.ls.get(ACCESS_TOKEN) },
+            fileList: [],
+            dataFile: null,
+            loadDisabled: false,
+            productId: '',
+            projectId: '',
+            accountId: '',
+            visibleChannel: false,
+            visibleDownLoad: false,
+            downLoading: false,
+            fileUrl: '',
+            projectIdDownLoad: '',
+            channelType: 'a',
+            createType: 1,
+            indexAll: 0,
+            spinning: false,
+            form: this.$form.createForm(this),
+            formDownLoad: this.$form.createForm(this),
+            exportloading: false,
+            dateRange: [moment().subtract(1, 'weeks'), moment()],
+            noImg: require('@/assets/noImg.png'),
+            validationRules: {
+                bid: [
+                    {
+                        required: true,
+                        message: '出价信息必须填写'
+                        // validator: this.validateBid,
+                    }
+                ]
+            },
+            ipagination: {
+                current: 1,
+                pageSize: 10,
+                //   pageSizeOptions: ['10', '20', '30'],
+                showTotal: (total, range) => {
+                    return range[0] + '-' + range[1] + ' 共' + total + '条'
+                },
+                showQuickJumper: true,
+                showSizeChanger: true,
+                pageSizeOptions: ['10', '30', '50'],
+                total: 0,
+                onChange: (current, pageSize) => {
+                    // 切换分页时的回调,
+                    // 当在页面定义change事件时,切记要把此处的事件清除,因为这两个事件重叠了,可能到时候会导致一些莫名的bug
+                    this.ipagination.current = current
+                    this.ipagination.pageSize = pageSize
+                }
+            },
+            value: 'valid',
+            KSaccountList: [],
+            TTaccountList: [],
+
+            KSdesignList: [],
+            TTdesignList: [],
+
+            operateDisabled: false,
+            duration: 1000,
+            //treeselect的参数
+            treeValue: [],
+            treeData: [],
+
+            type: 3,
+
+            operate: '',
+            designList: [],
+
+            tabKey: 1,
+
+            loading: false,
+            columns: [...TTcolumns],
+            dataSource: [],
+
+            tableTab: 1,
+
+            newPlan: 0,
+            effectPlan: 0,
+
+            openOptions: false,
+
+            target: 'createTime',
+            order: 'descend',
+            dataLoading: false,
+            url: '/channelItem/queryChannelItemList',
+            modifyPriceVisible: false,
+            modifyPriceLoading: false,
+            modifyPriceDetail: null,
+            accountVisible: false,
+            againLoading: false,
+            accountProjectDetail: null,
+            accountProjectList: [],
+            keyWord: undefined
+        }
+    },
+    methods: {
+        moment,
+        visibleChange() {
+            this.keyWord = undefined
+        },
+        bidChangeCancel(record) {
+            record.visible = false
+            this.keyWord = undefined
+        },
+        bidChangeOk(record) {
+            record.visible = false
+            const paramsData = {
+                id: record.id,
+                keyword: this.keyWord
+            }
+            getAction('/channelItem/updateChannelItems', paramsData)
+                .then(result => {
+                    if (result.code === 200) {
+                        record.visible = false
+                        this.keyWord = undefined
+                        const paramsData = this.form.getFieldsValue()
+                        this.handleGetTableList(paramsData)
+                    } else {
+                        this.$message.error(result.message)
+                    }
+                })
+                .catch(error => {
+                    console.log(error, 'eeee')
+                })
+        },
+        handleSwitchChang(checked, data) {
+            const paramsData = {
+                id: data.id,
+                state: checked ? 1 : 0
+            }
+            getAction('/channelItem/updateChannelItems', paramsData)
+                .then(result => {
+                    if (result.code === 200) {
+                        const paramsData = this.form.getFieldsValue()
+                        this.handleGetTableList(paramsData)
+                    } else {
+                        this.$message.error(result.message)
+                    }
+                })
+                .catch(error => {
+                    console.log(error, 'eeee')
+                })
+        },
+        overUpload(file) {},
+        handleChange() {
+            this.loadDisabled = false
+            this.$message.success('文件导入成功')
+        },
+        beforeUpload(file) {
+            // this.cosUpload(file)
+            // if (process.env.NODE_ENV == 'development') {
+            //   this.uploadAction = `/jeecg-boot/kuaishouAppPackage/importAppExcel?projectId=${this.projectId}&platform=${
+            //     this.appType == 'ios' ? +this.platform + 2 : +this.platform
+            //   }&imageUrl=${this.fileUrl}`
+            // } else if (process.env.NODE_ENV == 'debug') {
+            // } else if (process.env.NODE_ENV == 'production') {
+            //   this.uploadAction = `${this.axios.defaults.baseURL}/kuaishouAppPackage/importAppExcel?projectId=${
+            //     this.projectId
+            //   }&platform=${this.appType == 'ios' ? +this.platform + 2 : +this.platform}&imageUrl=${this.fileUrl}`
+            // }
+            // this.dataFile = file
+            this.dataFile = $('.fileUpload')
+                .eq(0)
+                .find('input')[0].files[0]
+            this.loadDisabled = true
+            const size = (Number(file.size) / (1024 * 1024)).toFixed(2)
+            const fileName = file.name
+            const fileStrArr = fileName.split('.')
+            const suffix = fileStrArr[fileStrArr.length - 1]
+
+            let result = fileSuffix.some(item => {
+                return item === suffix
+            })
+
+            if (!result) {
+                this.$message.error('不支持该文件类型')
+                this.loadDisabled = false
+                return false
+            }
+        },
+        ...mapGetters(['userInfo']),
+        toDetailList(item) {},
+
+        cpaBidValid(rule, value, callback) {
+            let z = /-/g
+            let a = /\//g
+            let d = /\./g
+            if (value === '' || value === undefined) {
+                callback('出价必须填写')
+            } else if (value.startsWith('.') || value.endsWith('.')) {
+                callback('请填写正确出价')
+            } else if (value.startsWith('-') || value.endsWith('-')) {
+                callback('请填写正确出价')
+            } else if (value.match(a) && value.match(z)) {
+                callback('不允许出现除"-"和"/"之外的所有字符,并且二者不可同时出现')
+            } else if (value.match(/[^0-9+-\/]/g)) {
+                callback('请填写正确出价')
+            } else {
+                callback()
+            }
+        },
+        addOneItem() {
+            this.addItemForm.items.push({
+                projectId: '',
+                keyWord: '',
+                itemName: '默认名称-单品' + (this.addItemForm.items.length + 1)
+            })
+        },
+        handleOk() {
+            this.$refs.ruleForm.validate(valid => {
+                if (valid) {
+                    this.confirmLoading = true
+                    postAction('/channelItem/addChannelItem', this.addItemForm.items).then(res => {
+                        this.confirmLoading = false
+                        if (res.success) {
+                            this.visibleAddItem = false
+                            this.addItemForm.items = [{ projectId: '', keyWord: '', itemName: '默认名称-单品1' }]
+                        } else {
+                            this.$message.error(res.message)
+                        }
+                    })
+                }
+            })
+        },
+        handleOkImport() {
+            this.downLoading = true
+            let params = {}
+            if (this.dataFile) {
+                let formData = new FormData()
+                formData.append('file', this.dataFile)
+
+                postAction('/channelItem/importItemExcel', formData).then(res => {
+                    this.downLoading = false
+                    if (res.code === 200) {
+                        this.$message.success('创建成功')
+                        this.visibleDownLoad = false
+                        this.projectIdDownLoad = ''
+                        this.handleResetForm()
+                        
+                    } else {
+                        this.$message.error(res.message)
+                    }
+                })
+            } else {
+                this.$message.error('请上传文件')
+            }
+
+            return
+        },
+        handleOkDownLoad() {
+            if (!!this.projectIdDownLoad) {
+                let params = {}
+                params.projectId = this.projectIdDownLoad
+                params.userId = this.userInfo().id
+                downFile('/channelItem/exportItemTemplate', params).then(res => {
+                    let blob = new Blob([res], {
+                        type: 'application/vnd.openxmlformats-officedocument.spre1adsheetml.sheet'
+                    })
+                    let downloadElement = document.createElement('a')
+                    let href = window.URL.createObjectURL(blob) //创建下载的链接
+                    downloadElement.href = href
+                    downloadElement.download = '单品模板.xlsx' //下载后文件名
+                    document.body.appendChild(downloadElement)
+                    downloadElement.click() //点击下载
+                    document.body.removeChild(downloadElement) //下载完成移除元素
+                    window.URL.revokeObjectURL(href) //释放掉blob对象
+                })
+            } else {
+                this.$message.error('请选择项目')
+            }
+        },
+        handleCancel() {
+            this.visibleChannel = false
+        },
+        addNewChannel() {
+            this.visibleChannel = true
+        },
+        getDataSource(current, pageSize) {
+            // 切换分页时的回调,
+            // 当在页面定义change事件时,切记要把此处的事件清除,因为这两个事件重叠了,可能到时候会导致一些莫名的bug
+            this.ipagination.current = current
+            this.ipagination.pageSize = pageSize
+            const paramsData = this.form.getFieldsValue()
+            this.handleGetTableList(paramsData)
+        },
+        handleQueryList(event) {
+            this.ipagination.current = 1
+            event.preventDefault()
+            const paramsData = this.form.getFieldsValue()
+            this.handleGetTableList(paramsData)
+        },
+        handleResetForm() {
+            this.ipagination.current = 1
+            this.form.resetFields()
+            this.$refs.selectTable.keyValue = ''
+            this.$refs.selectTable.getData()
+            this.$refs.selectTableProject.keyValue = ''
+            this.$refs.selectTableProject.getData()
+            const paramsData = this.form.getFieldsValue()
+            this.handleGetTableList(paramsData)
+        },
+        handleGetTableList(data) {
+            let paramsData = {
+                projectId: this.projectId,
+                keyword: data.keyword,
+                itemName: data.itemName,
+                pageNo: this.ipagination.current,
+                pageSize: this.ipagination.pageSize
+            }
+            this.dataSource = []
+            this.dataLoading = true
+            this.getAction(this.url, paramsData)
+                .then(result => {
+                    this.dataLoading = false
+                    if (result.code === 200) {
+                        this.dataSource =
+                            result.result.list.map(item => {
+                                return {
+                                    ...item,
+                                    visible: false
+                                }
+                            }) || []
+                        this.ipagination.total = result.result.total || 0
+                        // result.result.total
+                    } else {
+                        this.$message.error(result.message)
+                    }
+                })
+                .catch(error => {
+                    this.dataLoading = false
+                    console.log(error, 'eeee')
+                })
+        },
+        getAccountNoProject() {
+            this.projectId = undefined
+            const paramsData = this.form.getFieldsValue()
+            this.handleGetTableList(paramsData)
+        },
+        disabledDate(current) {
+            // Can not select days before today and today
+            return current && current > moment().endOf('day')
+        },
+        dateChange(date, dateString) {
+            // console.log(date,dateString)
+        },
+
+        filterOption(input, option) {
+            // console.log(input, option)
+            return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
+        },
+        operateChange(value) {
+            console.log(value)
+            if (value) {
+                this.accountDisabled = true
+                this.accountId = ''
+            } else {
+                this.accountDisabled = false
+            }
+        },
+
+        tableChange(pagination, filters, sorter, { currentDataSource }) {
+            this.ipagination.current = pagination.current
+            this.ipagination.pageSize = pagination.pageSize
+            if (sorter.order) {
+                this.order = sorter.order ? sorter.order : 'descend'
+                this.target = sorter.columnKey
+                const paramsData = this.form.getFieldsValue()
+                this.handleGetTableList({
+                    ...paramsData,
+                    target: sorter.columnKey,
+                    order: sorter.order ? sorter.order : 'descend'
+                })
+            }
+        },
+
+        // 获取所有运营
+        getAllOperator(key) {
+            let url = '/sys/user/getAllUserListV1'
+            this.designList = []
+
+            getAction(url, {}).then(res => {
+                if (res.success) {
+                    this.designList = res.result
+                }
+            })
+        }
+    },
+    watch: {
+        productId: function(n, o) {
+            if (n != '') {
+                this.$refs.selectTableProject.keyValue = ''
+                this.$refs.selectTableProject.getData(n)
+            }
+        },
+    },
+    computed: {
+        newDate() {
+            var myDate = new Date()
+            myDate.getYear() //获取当前年份(2位)
+            var n = myDate.getFullYear() //获取完整的年份(4位,1970-????)
+            var m = myDate.getMonth() //获取当前月份(0-11,0代表1月)
+            var d = myDate.getDate() //获取当前日(1-31)
+            var day = myDate.getHours()
+            return day
+        }
+    },
+    mounted() {
+        const paramsData = this.form.getFieldsValue()
+        this.handleGetTableList(paramsData)
+        this.getAllOperator()
+    },
+    activated: function() {},
+
+    filters: {
+        toPercentage(val) {
+            if (typeof val != 'string') {
+                return (val * 100).toFixed(2) + '%'
+            } else {
+                return val
+            }
+        },
+        //保留两位小数并且变成货币格式
+        decimalsHandle(val) {
+            if (val && typeof val != 'string') {
+                if (val >= 0) {
+                    val = parseFloat(val).toFixed(2)
+                    let numberStr = val.toString()
+                    let str = numberStr.split('.')
+
+                    let str0 = str[0].split('').reverse()
+                    for (let i = 0; i < str0.length; i++) {
+                        if ((i + 1) % 4 === 0) {
+                            str0.splice(i, 0, ',')
+                        }
+                    }
+                    str0.reverse()
+                    let handleResult = ''
+                    for (let j = 0; j < str0.length; j++) {
+                        handleResult += str0[j]
+                    }
+
+                    return handleResult + '.' + str[1]
+                } else {
+                    val = parseFloat(val).toFixed(2)
+                    let numberStr = val.toString()
+                    let str = numberStr.split('.')
+
+                    let str0 = str[0]
+                        .substr(1)
+                        .split('')
+                        .reverse()
+                    for (let i = 0; i < str0.length; i++) {
+                        if ((i + 1) % 4 === 0) {
+                            str0.splice(i, 0, ',')
+                        }
+                    }
+                    str0.reverse()
+                    let handleResult = ''
+                    for (let j = 0; j < str0.length; j++) {
+                        handleResult += str0[j]
+                    }
+
+                    return '-' + handleResult + '.' + str[1]
+                }
+            } else if (typeof val == 'string') {
+                return val
+            } else {
+                return 0
+            }
+        },
+        //变成货币格式
+        formatCurrency(val) {
+            if (val) {
+                let numberStr = val.toString()
+                let str = numberStr.split('').reverse()
+                for (let i = 0; i < str.length; i++) {
+                    if ((i + 1) % 4 === 0) {
+                        str.splice(i, 0, ',')
+                    }
+                }
+                str.reverse()
+                let handleResult = ''
+                for (let j = 0; j < str.length; j++) {
+                    handleResult += str[j]
+                }
+                return handleResult
+            } else {
+                return '-'
+            }
+        }
+    }
+}
+</script>

+ 2 - 2
vue.config.js

@@ -105,10 +105,10 @@ module.exports = {
         // target: 'http://192.168.1.43:8088', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.1.43:8088', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.1.43:8806', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.1.43:8806', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.0.252:8098', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.0.252:8098', //请求本地 需要jeecg-boot后台项目  毕洁泉
-        target: 'http://192.168.1.219:7701', //请求本地 需要jeecg-boot后台项目  赵西安
+        // target: 'http://192.168.1.219:7701', //请求本地 需要jeecg-boot后台项目  赵西安
         // target: 'http://192.168.1.193:8080', //请求本地 需要jeecg-boot后台项目  李煜一
         // target: 'http://192.168.1.193:8080', //请求本地 需要jeecg-boot后台项目  李煜一
         // target: 'http://192.168.1.193:31012', //请求本地 需要jeecg-boot后台项目  李煜一
         // target: 'http://192.168.1.193:31012', //请求本地 需要jeecg-boot后台项目  李煜一
-        // target: 'http://api.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目
+        target: 'http://api.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目
         // target: 'https://trac.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目
         // target: 'https://trac.tjyourong.com.cn', //请求本地 需要jeecg-boot后台项目
         // target: 'http://39.106.184.70:8088/', //请求本地 需要jeecg-boot后台项目
         // target: 'http://39.106.184.70:8088/', //请求本地 需要jeecg-boot后台项目
         //  target: 'http://adsp.tjyourong.com.cn/', //请求本地 需要jeecg-boot后台项目
         //  target: 'http://adsp.tjyourong.com.cn/', //请求本地 需要jeecg-boot后台项目