瀏覽代碼

'自动投放'

魏志佳 4 年之前
父節點
當前提交
b9a0b2f17d

+ 130 - 56
src/components/formComponents/Cascader.vue

@@ -9,6 +9,9 @@
     .el-input__inner{
         height: 32px  !important;
     }
+    .el-cascader__tags {
+        top: 64%;
+    }
 }
 
 </style>
@@ -29,7 +32,7 @@
       >
     </a-checkbox-group> -->
 
-    <!-- :show-all-levels="false" -->
+    <!-- :show-all-levels="false"  :clearCheckedNodes='clearCheckedNodes'-->
         <el-cascader
         v-model='selectedVal'
         :disabled="disabled"        
@@ -38,7 +41,7 @@
         collapse-tags
         
         ></el-cascader>
-        {{selectedVal}}
+        <!-- {{selectedVal}} -->
   </div>
 </template>
 
@@ -83,6 +86,13 @@ export default {
         return []
       },
     },
+    cascaderValue: {
+      // v-model绑定值
+      type: [Number, Array, String],
+      default() {
+        return []
+      },
+    },
     label: {
       // label 绑定值
       type: [Array, String],
@@ -108,13 +118,15 @@ export default {
   data() {
     return {
         // selectOption: [],
+        totalData:[],
+        selectedVal:[],
         props: {
             multiple: true ,
             // checkStrictly: true ,
             emitPath:false,
             lazy: this.isLazy,
-            lazyLoad (node, resolve) {
-                console.log(node,resolve)
+            lazyLoad :(node, resolve) =>{
+                // console.log(node,resolve)
                 const { level } = node;
                
                 // const nodes = Array.from({ length: level + 1 })
@@ -127,18 +139,41 @@ export default {
                 if(node.root){
                     params.level=1;
                 }else{
-                    params.parent=node.root?0:node.data.regionId
+                    params.parent=node.root?0:node.value
                 }
+                
                 getAction('/kuaishou/batch/getRegion',params).then(res=>{
-                    console.log(res)
+                    // console.log(res)
+                    
                     const nodes =res.result.map(item => ({
-                        value: item.id,
+                        value: item.regionId,
                         label: item.name,
                         level:item.level,
-                        parent:item.parent,
-                        regionId:item.regionId,
-                        leaf: item.level >= 3
+                        parent:item.parent,                        
+                        leaf: item.level >= 2
                     }));
+                    if(!node.root&&node.level==1){
+                      if(this.totalData.length){
+                        let dataArr=[];
+                        dataArr=this.totalData.filter(item=>{
+                            return item.value==node.value
+                        });
+                        if(!dataArr.length){
+                          this.totalData.push({
+                            label:node.label,
+                            value:node.value,
+                            children:res.result.length
+                          })
+                        }
+                      }else{
+                        this.totalData.push({
+                          label:node.label,
+                          value:node.value,
+                          children:res.result.length
+                        })
+                      }
+                    }
+                    // console.log(this.totalData)
                     // 通过调用resolve将子节点数据返回,通知组件数据加载完成
                     resolve(nodes);
                 })
@@ -149,40 +184,55 @@ export default {
     }
   },
   watch: {
-    options(val) {
-      if (isArray(val)) {
-        this.selectOption.splice(0, this.selectOption.length)
-        this.selectOption.push(...val)
-      }
-    },
+    
     selectedVal(n, o) {
-      if (this.radioStyle && !this.allValue) {
-        if (n.length == 0) {
-          this.selectedVal = o
-        }
+      console.log(n,o)
+      if(n.length){
+          var retrunData = []
+          
+          if(n.length){
+             retrunData=JSON.parse(JSON.stringify(n))
+            this.totalData.forEach(element => {
+                let arr=[];
+                arr=n.filter(item=>{
+                  let number=(item+'').substr(0,2)
+                  // console.log(number)
+                  return element.value==number
+                })
+                if(arr.length==element.children ){
+                  
+                  retrunData=retrunData.filter(ele=>{
+                    return element.value!=(ele+'').substr(0,2)
+                  })
+                  console.log(retrunData)
+                  // this.selectedVal=[];
+                  retrunData=[
+                    ...retrunData,
+                    element.value,
+                    
+                  ]
+                }
+                
+              
+            });
+          }
+          console.log('retrunData',retrunData)
+          // this.$emit('input', val)
+          // this.$emit('change', val)
+          this.$emit('update:cascaderValue',retrunData)
+          // this.consoleFun('VALUE: ', val, 'LABEL:', label)
+      
+      }else{
+        this.$emit('update:cascaderValue',n)
       }
+      
+      
     },
   },
-  computed: {
-    selectedVal: {
-      get: function () {
-        return this.value
-      },
-      set: function (val) {
-        this.selectChange(val)
-      },
-    },
-  },
+  // 
   mounted() {
     this.$nextTick(() => {
-      if (this.code && this.options.length == 0) {
-        // 如果code值不为空且options.lengt==0, 则去请求字典项
-        this.getOptions()
-      } else {
-        // 否则直接获取外部传入的options
-        this.selectOption.splice(0, this.selectOption.length)
-        this.selectOption.push(...this.options)
-      }
+      
     })
   },
   methods: {
@@ -213,26 +263,46 @@ export default {
       })
     },
     selectChange(val) {
-      // 选择事件
-     
+      
         // 多选
         var retrunData = []
-        // let label = this.selectOption.filter((v) => val.findIndex((item) => item == v.value) > -1).map((v) => v.label)
-        // if (this.allValue) {
-        //   if (val.findIndex((item) => item == 'unlimited') == 0) {
-        //     retrunData = val.slice(-1)
-        //   } else if (val.findIndex((item) => item == 'unlimited') == val.length - 1) {
-        //     retrunData = ['unlimited']
-        //   } else {
-        //     retrunData = val
-        //   }
-        // } else {
-        //   retrunData = val
-        // }
-
-        this.$emit('input', val)
-        this.$emit('update:label', val)
-        this.$emit('change', val)
+        
+        console.log(val)
+        
+        if(val.length){
+          this.totalData.forEach(element => {
+              let arr=[];
+              arr=val.filter(item=>{
+                let number=(item+'').substr(0,2)
+                // console.log(number)
+                return element.value==number
+              })
+              if(arr.length==element.children ){
+                let otherArr=[]
+                otherArr=this.selectedVal.filter(ele=>{
+                  return element.value!=(ele+'').substr(0,2)
+                })
+                console.log(otherArr)
+                // this.selectedVal=[];
+                retrunData=[
+                  ...retrunData,
+                  element.value,
+                  ...otherArr,
+                ]
+                
+              }else{
+                retrunData=[
+                  ...retrunData,
+                  ...arr
+                ]
+              }
+             
+          });
+        }
+        console.log('retrunData',retrunData)
+        // this.$emit('input', val)
+        // this.$emit('change', val)
+        this.$emit('update:cascaderValue',retrunData)
         // this.consoleFun('VALUE: ', val, 'LABEL:', label)
       
     },
@@ -246,6 +316,10 @@ export default {
         console.log(...args)
       }
     },
+
+    // clearCheckedNodes(){
+
+    // },
   },
 }
 </script>

+ 258 - 290
src/components/formComponents/toutiaoTime.vue

@@ -3,154 +3,129 @@
     <table class="time_table table" v-on:mouseleave="mouseleave">
       <thead>
         <tr>
-          <th rowspan="2" style="width:120px">日期/时间(时)</th>
+          <th rowspan="2" style="width:120px">日期/时间</th>
         </tr>
         <tr>
-          <th class="unselectable" colspan="2" v-for="(num, index) in numData" :key="index" style="width:50px">{{ num }}
-          </th>
+          <th class="unselectable" v-for="(num, index) in numData" :key="index" style="width:30px">{{ num }}</th>
         </tr>
       </thead>
       <tbody>
         <tr v-for="(options, index) in timeData" :key="index">
           <th scope="row">{{ options.date }}</th>
-          <td v-for="(timeItem, key) in options.time" :key="key" style="width:15px"
+          <td
+            v-for="(timeItem, key) in options.time"
+            :key="key"
             :class="[{ active_select: timeItem.isSelected, active_select_move: timeItem.show }]"
-            v-on:mousedown="mousedown(index, key)" v-on:mouseover="mouseover(index, key)"
-            v-on:mouseup="mouseup(index, key)" @click="showOne(index, key)"></td>
+            v-on:mousedown="mousedown(index, key)"
+            v-on:mouseover="mouseover(index, key)"
+            v-on:mouseup="mouseup(index, key)"
+            @click="showOne(index, key)"
+          ></td>
         </tr>
       </tbody>
     </table>
+    <!-- <div style="height:200px;overflow:auto">
+      <span v-for="(item, index) of dataString" :key="index">
+        <a-tag v-if="item" closable :afterClose="() => handleClose(index)">
+          {{ setItemDate(index) }}
+        </a-tag>
+      </span>
+    </div> -->
   </div>
 </template>
 <script>
-  var arr = []
-  for (let i = 0; i < 48; i++) {
-    arr.push(i / 2)
-  }
-  export default {
-    name: 'calendar-table',
-    props: {
-      scheduleTime: {
-        type: String,
-        default () {
-          var str = ''
-          for (let i = 0; i < 7 * 48; i++) {
-            str += '0'
-          }
-          return str
-        }
+export default {
+  name: 'calendar-table',
+  props: {
+    scheduleTime: {
+      type: String,
+      default() {
+        return '000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
       }
-    },
-    data() {
-      return {
-        show: false,
-        numData: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, ],
-        // [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, ],
-        dateTime: ['周一', '周二', '周三', '周四', '周五', '周六', '周日'],
-        timeData: [{
-            date: '周一',
-            time: []
-          },
-          {
-            date: '周二',
-            time: []
-          },
-          {
-            date: '周三',
-            time: []
-          },
-          {
-            date: '周四',
-            time: []
-          },
-          {
-            date: '周五',
-            time: []
-          },
-          {
-            date: '周六',
-            time: []
-          },
-          {
-            date: '周日',
-            time: []
-          }
-        ],
-        selectFlag: false,
-        max: {
-          x: 0,
-          y: 0
+    }
+  },
+  data() {
+    return {
+      show: false,
+      numData: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23],
+      dateTime: ['周一', '周二', '周三', '周四', '周五', '周六', '周日'],
+      timeData: [
+        {
+          date: '周一',
+          time: []
+        },
+        {
+          date: '周二',
+          time: []
+        },
+        {
+          date: '周三',
+          time: []
+        },
+        {
+          date: '周四',
+          time: []
         },
-        dataString: ''
+        {
+          date: '周五',
+          time: []
+        },
+        {
+          date: '周六',
+          time: []
+        },
+        {
+          date: '周日',
+          time: []
+        }
+      ],
+      selectFlag: false,
+      max: {
+        x: 0,
+        y: 0
+      },
+      dataString: ''
+    }
+  },
+  methods: {
+    // handleClose(item) {
+    //   var index = Math.floor(item / 24)
+    //   var key = item % 7
+    //   if (this.timeData[index].time[key].value == false) {
+    //     if (this.timeData[index].time[key].isSelected) {
+    //       this.timeData[index].time[key].isSelected = false
+    //     } else {
+    //       this.$set(this.timeData[index].time[key], 'isSelected', true)
+    //     }
+    //   }
+    // },
+    showOne(index, key) {
+      //   this.timeData[index].time[key].isSelected = !this.timeData[index].time[key].isSelected
+    },
+    mousedown: function(index, key) {
+      this.selectStart = []
+      this.selectFlag = true
+      if (this.timeData[index].time[key].value == false) {
+        if (this.timeData[index].time[key].isSelected) {
+          this.timeData[index].time[key].isSelected = false
+        } else {
+          this.$set(this.timeData[index].time[key], 'isSelected', true)
+        }
       }
+      this.selectStart.push({
+        index: index,
+        key: key
+      })
     },
-    methods: {
-      // handleClose(item) {
-      //   var index = Math.floor(item / 24)
-      //   var key = item % 7
-      //   if (this.timeData[index].time[key].value == false) {
-      //     if (this.timeData[index].time[key].isSelected) {
-      //       this.timeData[index].time[key].isSelected = false
-      //     } else {
-      //       this.$set(this.timeData[index].time[key], 'isSelected', true)
-      //     }
-      //   }
-      // },
-      showOne(index, key) {
-        //   this.timeData[index].time[key].isSelected = !this.timeData[index].time[key].isSelected
-      },
-      mousedown: function (index, key) {
-        this.selectStart = []
-        this.selectFlag = true
-        if (this.timeData[index].time[key].value == false) {
-          if (this.timeData[index].time[key].isSelected) {
-            this.timeData[index].time[key].isSelected = false
-          } else {
-            this.$set(this.timeData[index].time[key], 'isSelected', true)
-          }
+    mouseover: function(index, key) {
+      // x 垂直方向  y 水平方向
+      if (this.selectFlag) {
+        if (index >= this.max.x) {
+          this.max.x = index
         }
-        this.selectStart.push({
-          index: index,
-          key: key
-        })
-      },
-      mouseover: function (index, key) {
-        // x 垂直方向  y 水平方向
-        if (this.selectFlag) {
-          if (index >= this.max.x) {
-            this.max.x = index
-          }
-          if (key >= this.max.y) {
-            this.max.y = key
-          }
-          var start = {
-            x: this.selectStart[0].index,
-            y: this.selectStart[0].key
-          }
-          var end = {
-            x: index,
-            y: key
-          }
-          for (var i = end.x; i <= this.max.x; i++) {
-            for (var j = end.y; j <= this.max.y; j++) {
-              this.$set(this.timeData[i].time[j], 'isSelected', false)
-            }
-          }
-          /* 渲染选中的区域 */
-          // for (var i = start.x; i <= end.x; i++) {
-          //   for (var j = start.y; j <= end.y; j++) {
-          //     // this.$set(this.timeData[i].time[j], 'isSelected', true)
-          //     this.$set(this.timeData[i].time[j], 'show', true)
-          //   }
-          // }
-          for (var i = start.x; i <= end.x; i++) {
-            for (var j = start.y; j <= end.y; j++) {
-              this.$set(this.timeData[i].time[j], 'isSelected', true)
-            }
-          }
+        if (key >= this.max.y) {
+          this.max.y = key
         }
-      },
-      mouseup: function (index, key) {
         var start = {
           x: this.selectStart[0].index,
           y: this.selectStart[0].key
@@ -159,186 +134,179 @@
           x: index,
           y: key
         }
+        for (var i = end.x; i <= this.max.x; i++) {
+          for (var j = end.y; j <= this.max.y; j++) {
+            this.$set(this.timeData[i].time[j], 'isSelected', false)
+          }
+        }
         /* 渲染选中的区域 */
-        var data = []
-        var arr = []
-        //   for (let i = 0; i < this.timeData.length; i++) {
-        //     for (let j = 0; j < this.timeData[i].time.length; j++) {
-        //       this.timeData[i].time[j].show = false
-        //     }
+        // for (var i = start.x; i <= end.x; i++) {
+        //   for (var j = start.y; j <= end.y; j++) {
+        //     // this.$set(this.timeData[i].time[j], 'isSelected', true)
+        //     this.$set(this.timeData[i].time[j], 'show', true)
         //   }
-        arr = data.concat(
-          this.timeData[0].time,
-          this.timeData[1].time,
-          this.timeData[2].time,
-          this.timeData[3].time,
-          this.timeData[4].time,
-          this.timeData[5].time,
-          this.timeData[6].time
-        )
-        this.dataString = arr.map(item => {
-          if (item.isSelected) {
-            return 1
-          } else {
-            return 0
+        // }
+        for (var i = start.x; i <= end.x; i++) {
+          for (var j = start.y; j <= end.y; j++) {
+            this.$set(this.timeData[i].time[j], 'isSelected', true)
           }
-        })
-        this.$emit('update:scheduleTime', this.dataString.join(''))
-        this.selectFlag = false
-        this.max = {
-          x: 0,
-          y: 0
         }
-      },
-      mouseleave: function () {
-        this.selectFlag = false
-      },
-      setItemDate(sum) {
-        let i = sum
+      }
+    },
+    mouseup: function(index, key) {
+      var start = {
+        x: this.selectStart[0].index,
+        y: this.selectStart[0].key
+      }
+      var end = {
+        x: index,
+        y: key
+      }
+      /* 渲染选中的区域 */
+      var data = []
+      var arr = []
+      //   for (let i = 0; i < this.timeData.length; i++) {
+      //     for (let j = 0; j < this.timeData[i].time.length; j++) {
+      //       this.timeData[i].time[j].show = false
+      //     }
+      //   }
+      arr = data.concat(
+        this.timeData[0].time,
+        this.timeData[1].time,
+        this.timeData[2].time,
+        this.timeData[3].time,
+        this.timeData[4].time,
+        this.timeData[5].time,
+        this.timeData[6].time
+      )
+      this.dataString = arr.map(item => {
+        if (item.isSelected) {
+          return 1
+        } else {
+          return 0
+        }
+      })
+      console.log(this.dataString.join(''))
+      this.$emit('update:scheduleTime', this.dataString.join(''))
+      this.selectFlag = false
+      this.max = {
+        x: 0,
+        y: 0
+      }
+    },
+    mouseleave: function() {
+      this.selectFlag = false
+    },
+    setItemDate(sum) {
+      let i = sum
+      if (i < 24) {
+        return '周一' + i + ':00~' + (i + 1) + ':00'
+      } else if (i < 48 && i >= 24) {
+        return '周二' + (i - 24) + ':00~' + (i - 23) + ':00'
+      } else if (i < 72 && i >= 48) {
+        return '周三' + (i - 48) + ':00~' + (i - 47) + ':00'
+      } else if (i < 96 && i >= 72) {
+        return '周四' + (i - 72) + ':00~' + (i - 71) + ':00'
+      } else if (i < 120 && i >= 96) {
+        return '周五' + (i - 96) + ':00~' + (i - 95) + ':00'
+      } else if (i < 144 && i >= 120) {
+        return '周六' + (i - 120) + ':00~' + (i - 119) + ':00'
+      } else {
+        return '周日' + (i - 144) + ':00~' + (i - 143) + ':00'
+      }
+    },
+    init() {
+      var str = this.scheduleTime
+      var arr = str.split('')
+      this.timeData = [
+        {
+          date: '周一',
+          time: []
+        },
+        {
+          date: '周二',
+          time: []
+        },
+        {
+          date: '周三',
+          time: []
+        },
+        {
+          date: '周四',
+          time: []
+        },
+        {
+          date: '周五',
+          time: []
+        },
+        {
+          date: '周六',
+          time: []
+        },
+        {
+          date: '周日',
+          time: []
+        }
+      ]
+      for (let i = 0; i < arr.length; i++) {
         if (i < 24) {
-          return '周一' + i + ':00~' + (i + 1) + ':00'
+          this.timeData[0].time.push({ isSelected: arr[i] == 1 ? true : false, move: false, value: false })
         } else if (i < 48 && i >= 24) {
-          return '周二' + (i - 24) + ':00~' + (i - 23) + ':00'
+          this.timeData[1].time.push({ isSelected: arr[i] == 1 ? true : false, move: false, value: false })
         } else if (i < 72 && i >= 48) {
-          return '周三' + (i - 48) + ':00~' + (i - 47) + ':00'
+          this.timeData[2].time.push({ isSelected: arr[i] == 1 ? true : false, move: false, value: false })
         } else if (i < 96 && i >= 72) {
-          return '周四' + (i - 72) + ':00~' + (i - 71) + ':00'
+          this.timeData[3].time.push({ isSelected: arr[i] == 1 ? true : false, move: false, value: false })
         } else if (i < 120 && i >= 96) {
-          return '周五' + (i - 96) + ':00~' + (i - 95) + ':00'
+          this.timeData[4].time.push({ isSelected: arr[i] == 1 ? true : false, move: false, value: false })
         } else if (i < 144 && i >= 120) {
-          return '周六' + (i - 120) + ':00~' + (i - 119) + ':00'
+          this.timeData[5].time.push({ isSelected: arr[i] == 1 ? true : false, move: false, value: false })
         } else {
-          return '周日' + (i - 144) + ':00~' + (i - 143) + ':00'
-        }
-      },
-      init() {
-        var str = this.scheduleTime
-        var arr = str.split('')
-        this.timeData = [{
-            date: '周一',
-            time: []
-          },
-          {
-            date: '周二',
-            time: []
-          },
-          {
-            date: '周三',
-            time: []
-          },
-          {
-            date: '周四',
-            time: []
-          },
-          {
-            date: '周五',
-            time: []
-          },
-          {
-            date: '周六',
-            time: []
-          },
-          {
-            date: '周日',
-            time: []
-          }
-        ]
-        for (let i = 0; i < arr.length; i++) {
-          if (i < 48) {
-            this.timeData[0].time.push({
-              isSelected: arr[i] == 1 ? true : false,
-              move: false,
-              value: false
-            })
-          } else if (i < 96 && i >= 48) {
-            this.timeData[1].time.push({
-              isSelected: arr[i] == 1 ? true : false,
-              move: false,
-              value: false
-            })
-          } else if (i < 144 && i >= 96) {
-            this.timeData[2].time.push({
-              isSelected: arr[i] == 1 ? true : false,
-              move: false,
-              value: false
-            })
-          } else if (i < 192 && i >= 144) {
-            this.timeData[3].time.push({
-              isSelected: arr[i] == 1 ? true : false,
-              move: false,
-              value: false
-            })
-          } else if (i < 240 && i >= 192) {
-            this.timeData[4].time.push({
-              isSelected: arr[i] == 1 ? true : false,
-              move: false,
-              value: false
-            })
-          } else if (i < 288 && i >= 240) {
-            this.timeData[5].time.push({
-              isSelected: arr[i] == 1 ? true : false,
-              move: false,
-              value: false
-            })
-          } else {
-            this.timeData[6].time.push({
-              isSelected: arr[i] == 1 ? true : false,
-              move: false,
-              value: false
-            })
-          }
+          this.timeData[6].time.push({ isSelected: arr[i] == 1 ? true : false, move: false, value: false })
         }
       }
-    },
-    watch: {
-      scheduleTime: {
-        immediate: true, // immediate选项可以开启首次赋值监听
-        handler(newVal, oldVal) {
-          console.log(newVal,'-----', oldVal);
-          if(newVal==''||newVal==null||newVal==undefined){
+    }
+  },
+  watch: {
+    scheduleTime: {
+      immediate: true, // immediate选项可以开启首次赋值监听
+      handler(newVal, oldVal) {
+        if(newVal == '' || newVal == null || newVal == undefined){
+            // this.scheduleTime=oldVal
             this.$emit('update:scheduleTime', oldVal)
-            
-            this.init()
-          }else{
-            this.init()
-          }
-          
         }
+        this.init()
       }
     }
   }
+}
 </script>
 
 <style lang="scss" scoped>
-  .time_table {
-    border: 1px solid #ccc;
-    border-collapse: collapse;
-  }
-
-  .time_table th,
-  .time_table td {
-    border: 1px solid #ccc;
-    text-align: center;
-  }
-
-  .time_table .unselectable {
-    width: 5px !important;
-    height: 30px;
-  }
-
-  .active_select {
-    background: cornflowerblue;
-  }
-
-  .active_select_move {
-    background: aqua;
-  }
-
-  * {
-    -webkit-touch-callout: none !important;
-    -webkit-user-select: none !important;
-    -moz-user-select: none !important;
-    -ms-user-select: none !important;
-    user-select: none !important;
-  }
-</style>
+.time_table {
+  border: 1px solid #ccc;
+  border-collapse: collapse;
+}
+.time_table th,
+.time_table td {
+  border: 1px solid #ccc;
+  text-align: center;
+}
+.time_table .unselectable {
+  //   width: 30px !important;
+  height: 20px;
+}
+.active_select {
+  background: cornflowerblue;
+}
+.active_select_move {
+  background: aqua;
+}
+* {
+  -webkit-touch-callout: none !important;
+  -webkit-user-select: none !important;
+  -moz-user-select: none !important;
+  -ms-user-select: none !important;
+  user-select: none !important;
+}
+</style>

+ 645 - 0
src/views/modules/autoLaunch/createStrategy.vue

@@ -0,0 +1,645 @@
+<template>
+  <div class="newPlan">
+    <a-form :form="form">
+         <!-- 投放范围 -->
+        <div class="moduler">
+            <div class="moduler-title">请选择策略创建场景</div>
+            <div class="ad-range">
+            <div class="row-item">
+                <div class="hint-item"></div>
+                <div class="label-item">
+                <div class="text-item">创建场景</div>
+                <div class="required-item"></div>
+                </div>
+                <div class="input-item">
+                <a-form-item>
+                    <a-radio-group v-decorator="['scenes', { initialValue:'2' }]">
+                    <a-radio-button value="1">素材+出价</a-radio-button>
+                    <a-radio-button value="2">素材+定向</a-radio-button>
+                    <a-radio-button value="3">时间+出价</a-radio-button>
+                    </a-radio-group>
+                </a-form-item>
+                </div>
+            </div>        
+            </div>
+        </div>
+
+        <div class="moduler">
+            <div class="moduler-title">选择账户</div>
+            <div>
+            <div class="row-item">
+                <div class="hint-item"></div>
+                <div class="label-item">
+                <div class="text-item">账户</div>
+                <div class="required-item"></div>
+                </div>
+                <div class="input-item">
+                    <a-tree-select
+                        v-model="accountId"
+                        show-search
+                        style="width: 600px;height:30px"
+                        :dropdownMatchSelectWidth='true'
+                        :dropdown-style="{ maxHeight: '400px', overflow: 'auto' }"              
+                        tree-checkable
+                        searchPlaceholder='请输入账户关键字搜索'
+                        :show-checked-strategy="SHOW_PARENT"
+                        placeholder="请选择项目和账户或搜索账户关键字"
+                        treeNodeFilterProp="title"
+                        :allowClear="true"
+                        @change="treeChange"
+                        @search="treeSearch"
+                        @select="treeSelect"                        
+                        :maxTagCount='1'    
+                        :tree-data="treeData"
+                        :filterOption='filterOption'
+                    >
+                
+                    </a-tree-select>
+                </div>
+            </div>
+            </div>
+        </div>
+     
+        <!-- 推广目的 -->
+        <div class="moduler">
+            <div class="moduler-title">请选择营销目标</div>
+            
+            <div class="row-item">
+                <div class="hint-item">
+                </div>
+                <div class="label-item">
+                <div class="text-item"></div>
+                <div class="required-item"></div>
+                </div>
+                <div class="input-item">
+                    <a-form-item >
+                        <a-radio-group   v-decorator="['marketingGoal',{initialValue:'1' }]" @change="marketingGoalChange">
+                            <a-radio-button value="1">提升应用安装</a-radio-button>
+                            <a-radio-button value="2">获取电商下单</a-radio-button>                                   
+                            <a-radio-button value="3">推广品牌活动</a-radio-button>                                   
+                            <a-radio-button value="4">收集销售线索</a-radio-button>                                   
+                            <a-radio-button value="5">提高应用活跃</a-radio-button>                                   
+                        </a-radio-group>
+                    </a-form-item>
+                </div>
+            </div>        
+           
+        </div>
+    
+        <!-- 基础信息 -->
+        <div class="moduler">
+            <div class="moduler-title">请设置基本信息</div>
+            
+            <div class="row-item">
+            <div class="hint-item"> </div>
+            <div class="label-item">
+              <div class="text-item">策略名称</div>
+              <div class="required-item"></div>
+            </div>
+            <div class="input-item">
+              <a-form-item>                
+                <a-input v-model="strategyName"  allow-clear />
+               </a-form-item>
+            </div>
+          </div>  
+            
+        </div>
+    
+      <div class="moduler">
+        <div class="opt">
+          <a-button type="default" style="margin-right:15px" @click="goBack">取消</a-button>
+         
+          <a-button type="primary" @click="goNext"  :loading="goNextloading">下一步</a-button>
+        </div>
+      </div>
+    </a-form>
+    <div class="infoModal">
+         <a-modal v-model="visible" title="提示"  @ok="handleOk" :keyboard='false' :maskClosable='false'>
+            <ul>
+              <li v-for="(item,index) in errorInfo" :key="index">
+                  <span>账户{{LHKaccountInfo[index].title}}:</span>{{item.message || '投放项目创建成功'}}
+              </li>
+            </ul>
+            <template slot="footer">
+              <a-button key="back" @click="handleCancel">
+                返回本页
+              </a-button>
+              <a-button key="submit" type="primary"  @click="handleOk">
+                下一步
+              </a-button>
+            </template>
+          </a-modal>
+    </div>
+  </div>
+</template>
+
+<script>
+import moment from 'moment'
+import { getAction, postAction, downFile, downFilePost } from '@/api/manage'
+
+import { TreeSelect } from 'ant-design-vue';
+import qs from 'qs'
+const SHOW_PARENT = TreeSelect.SHOW_PARENT;
+// import selectCheckAll from './toutiaoTime'
+
+var str = ""
+for (let i = 0; i < 7*48; i++) {
+ str+='0'
+  
+}
+export default {
+  components: {
+    // selectCheckAll,
+    // newDirectedPackage,
+  },
+  data() {
+    return {
+        LHKaccountInfo:{},
+        treeValue: [],
+        treeData: [],
+        SHOW_PARENT,
+        accountId:[],
+        strategyName: '',
+        form: this.$form.createForm(this),
+
+        goNextloading:false,
+        goPlanShowloading:false,
+        
+        
+        dateRange: [moment(), moment()],
+
+        visible:false,
+        errorInfo:[],
+       
+        validationRules: {
+            url: [   
+            {          
+                required: true,
+                validator: this.validateURL,
+            },
+            ],
+            strategyName:[{
+            required: true,
+            validator: this.validateName,
+            }],
+            bid:[{
+            required: true,
+            message:'出价信息必须填写',
+            // validator: this.validateBid,
+            }],
+            roi:[{
+            required: true,
+            message:'ROI系数必须填写',
+            // validator: this.validateBid,
+            }],
+        },
+        
+    }
+  },
+  watch: {
+    
+  },
+  methods: {
+    // //项目改变后的事件
+    treeChange(val) {
+      // console.log(this.treeData)
+      console.log(val)
+      this.accountId = [];
+      //选择一个后禁用其他
+      if(val.length==1){
+          if(val[0]*1){
+            let selectindex=0
+              this.treeData.forEach((ele,index)=>{                   
+                  if(ele.children){
+                     ele.children.map((item,ind)=>{
+                            if(item.value==val[0]){
+                                selectindex=index;
+                            }
+                      })
+                  }                   
+              });
+              // console.log(selectindex)
+              if(selectindex ||selectindex==0){
+                this.treeData.forEach((ele,index)=>{
+                    if(index!=selectindex){
+                         ele.disableCheckbox = true;
+                         if(ele.children){
+                              ele.children.map((item,ind)=>{
+                                   item.disableCheckbox = true;
+                              })
+                         }
+                    }
+                })
+              }
+              
+          }else{
+            //  console.log(1)
+              this.treeData.forEach((ele,index)=>{
+                    if(ele.value!=val[0]){
+                         ele.disableCheckbox = true;
+                         
+                         if(ele.children){
+                              ele.children.forEach((item,ind)=>{
+                                   item.disableCheckbox = true;
+                              })
+                         }
+                    }
+                    
+              })
+          }
+          // console.log(this.mediaId)
+          
+      }
+
+        if(val.length==0){
+            this.treeData.forEach((ele,index)=>{              
+                    ele.disableCheckbox = false;
+                    
+                    if(ele.children){
+                        ele.children.forEach((item,ind)=>{
+                            item.disableCheckbox = false;
+                        })
+                    }
+                
+            });
+            
+        }
+      if(val){
+        val.forEach((ele,index)=>{
+          if(ele*1){
+              this.accountId.push(ele)
+          }else{              
+              let projectArr=this.treeData.filter((item)=>{
+                  return item.value==ele
+              });
+              // console.log(projectArr)
+              projectArr[0].children.forEach((element)=>{
+                 this.accountId.push(element.value)
+              })
+          }
+
+
+        })       
+      }
+      
+     console.log(this.accountId);
+      let LHKaccountInfo=[]
+      this.accountId.forEach(item=>{
+          this.treeData.forEach(element=>{
+            element.children.forEach(ele=>{
+              if(item==ele.value){
+                LHKaccountInfo.push(ele)
+              }
+            })
+          })
+      })
+
+      sessionStorage.setItem('LHKaccountInfo',JSON.stringify(LHKaccountInfo))
+    },
+    treeSearch(){
+    },
+    treeSelect(){
+    },
+    
+    filterOption(input, option){
+      console.log(input, option)
+      return (
+          option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
+        );
+    },
+ 
+
+    //请求项目和账户内容
+    accountHttp(){
+        this.treeData=[];
+        this.accountId=[];
+        getAction('/ctop/projectMember/getProjectAccountByUserId?mediaType=1', {}).then(res => {
+        if(res.success){
+                // console.log(res);
+                if(res.result){
+                    res.result.forEach((element,index) => {
+                    if(element){                  
+                        this.treeData.push({});                    
+                        this.treeData[index].title=element.project.projectName +'_('+ element.project.advertiserName +')';
+                        this.treeData[index].value='project'+element.project.projectId;
+                        this.treeData[index].key=element.project.projectId;
+                        this.treeData[index].mediaId=element.project.mediaId;
+                        this.treeData[index].children=[];
+                                            
+                        if(element.account.length){
+                        element.account.forEach((ele,i)=>{
+                            this.treeData[index].children.push({});
+                            this.treeData[index].children[i].title=ele.userName+'_'+ele.authName+'_'+element.project.projectName;
+                            this.treeData[index].children[i].value=ele.accountId;
+                            this.treeData[index].children[i].key=ele.accountId;
+                        })
+                            
+                        }                           
+                    }      
+                    });
+                    // console.log(this.treeData)
+                    
+                }
+        }
+        })
+    },
+
+    
+    handleOk(e) {
+        this.visible=false;
+        this.$router.replace({path:'/LaunchHousekeeper/setProjectConvert'})
+        
+        
+    },
+    handleCancel(e) {
+        this.visible = false;
+    },
+    
+   
+    //获取表单的某一个属性值
+    getFormData(className) {
+      return this.form.getFieldValue(className)
+    },
+    dateChange(date, dateString) {
+      // console.log(date,dateString)
+      this.form.getFieldDecorator('startTime')
+      this.form.getFieldDecorator('endTime')
+      this.form.setFieldsValue({
+        startTime: date[0].format('YYYY-MM-DD HH:mm'),
+        endTime:  date[1].format('YYYY-MM-DD HH:mm'),
+      })
+    },
+    
+    //推广目的改变
+    marketingGoalChange(e){
+        console.log(e.target)
+        this.marketingGoalHandle(e.target.value)
+    },
+    
+    // 验证网址
+    IsURL(res) {
+      //   var strRegex = /^([hH][tT]{2}[pP]:\/\/|[hH][tT]{2}[pP][sS]:\/\/|www\.)(([A-Za-z0-9-~]+)\.)+([A-Za-z0-9-~\/])+$/
+      var strRegex = /^([hH][tT]{2}[pP]:\/\/|[hH][tT]{2}[pP][sS]:\/\/)(([A-Za-z0-9-~]+)\.)+([A-Za-z0-9-~\/])+(.+[A-Za-z0-9-~\/])+$/
+      var re = new RegExp(strRegex)
+      // console.log(re.test(res))
+      if (re.test(res)) {
+        return true
+      } else {
+        return false
+      }
+    },
+    validateURL(rule, value, callback) {
+      // console.log(rule, value, callback);
+
+      if (this.IsURL(value)) {
+        callback()
+      } else if (value && !this.IsURL(value)) {
+        callback('链接地址无法访问,请正确输入')
+      } else {
+          callback('链接必须填写')
+      }
+    },
+    validateName(rule, value, callback){
+      // console.log(rule, value, callback);
+
+        if (value) {
+          callback()
+        } else {
+              callback('应用包名称必须填写')
+        }
+    },
+    validateBid(rule, value, callback){
+      // console.log(rule, value, callback);
+        if (value) {
+          callback()
+        } else {
+            callback('出价必须填写')
+        }
+    },
+
+   
+    
+    goBack() {
+        this.$router.replace('/modules/LaunchHousekeeper/LaunchHousekeeperList')
+        this.$bus.$emit('remove', '/LaunchHousekeeper/newProject')
+    },
+    
+    // 保存并新建创意
+    goNext() {
+        this.$nextTick(()=>{
+            if (this.strategyName) {
+            let LHKaccountInfo=sessionStorage.getItem('LHKaccountInfo');
+                if(LHKaccountInfo){
+                    this.LHKaccountInfo=JSON.parse(LHKaccountInfo)
+                }
+                this.form.validateFields((err, values) => {
+                if (!err) {
+
+                console.log('Received values of form: ', values)
+                // console.log(this.strategyNames)
+                this.goNextloading=true;
+                values.accountId = this.accountId
+                values.strategyName=this.strategyName
+                postAction('/adlab/Project/create', {                
+                    ...values,
+                }).then((res) => {
+                    console.log(res)
+                    if (res.success) {
+                    this.goNextloading=false;
+                    
+                        if(res.result){
+                            this.errorInfo=res.result;
+                            this.visible=true;
+
+                            let projectInfo=[]
+                            res.result.forEach(item=>{
+                                if(item.code==0){
+                                projectInfo.push(item)
+                                }
+                            })
+
+                            sessionStorage.setItem('projectInfo',JSON.stringify(projectInfo))
+                        }
+                    
+                    } else {
+                    this.goNextloading=false;
+                    this.$message.error('网络开小差了,等会再试试')
+                    }
+                })
+                }else{
+                this.$message.error('请正确填写必填项目')
+                }
+            })
+                }else{
+                    this.$message.error('请输入策略名称')
+                }
+        })
+        
+        },
+        
+
+        
+    },
+    marketingGoalHandle(val){
+        let str='';
+        switch (val) {
+            case '1':
+                str='应用安装'
+                break;
+            case '2':
+                str='电商下单'
+                break;
+            case '3':
+                str='推广品牌'
+                break;
+            case '4':
+                str='营销线上'
+                break;
+            case '5':
+                str='应用活跃'
+                break;
+        
+            default:
+                str='转化错误'
+                break;
+        }
+        return str
+    },
+  mounted() {
+    this.accountHttp()
+    // this.$bus.$emit('remove', '/modules/BatchCreate/newGroup')
+    let strategyNamepart=this.marketingGoalHandle(this.getFormData('marketingGoal'));
+    
+    
+    this.strategyName ='[策略]'+ strategyNamepart + moment().format('MM_DD_hh:mm') ;
+
+    
+  },
+}
+</script>
+<style lang="scss">
+.newPlan{
+  .ant-btn-danger {
+    background-color: #ff4d4f !important; 
+  }
+}
+
+
+.ant-tooltip-inner,
+.ant-tooltip,
+.ant-tooltip-arrow::before {
+  background-color: #fff;
+  color: #333;
+}
+.ant-tooltip-inner {
+  span {
+    display: block;
+  }
+}
+.ant-tooltip {
+  max-width: 450px;
+}
+.newPlan {
+  .ant-radio-button-wrapper {
+    min-width: 80px;
+    text-align: center;
+  }
+  .ant-form-item {
+    -webkit-box-sizing: border-box;
+    box-sizing: border-box;
+    margin: 0;
+    padding: 0;
+    color: rgba(0, 0, 0, 0.65);
+    font-size: 14px;
+    font-variant: tabular-nums;
+    line-height: 1.5;
+    list-style: none;
+    -webkit-font-feature-settings: 'tnum';
+    font-feature-settings: 'tnum';
+    vertical-align: top;
+  }
+  .directedBody {
+    .ant-form-item {
+      margin-bottom: 20px;
+    }
+  }
+}
+</style>
+<style lang="scss" scoped>
+.newPlan {
+  font-family: PingFangSC-Regular, tahoma, arial, 'Hiragino Sans GB', 'Microsoft yahei', sans-serif;
+  color: #333;
+  ul,
+  li {
+    margin: 0;
+    padding: 0;
+  }
+  .moduler {
+    background: #fff;
+    margin-bottom: 16px;
+    position: relative;
+    padding: 32px 24px 48px 32px;
+    border-radius: 4px;
+    box-shadow: 0px 1px 6px 0px rgba(0, 0, 0, 0.05);
+    .moduler-title {
+      display: flex;
+      align-items: center;
+      font-size: 22px;
+      margin-bottom: 20px;
+    }
+    .row-item {
+      display: flex;
+      justify-content: flex-start;
+      align-items: center;
+      margin-bottom: 32px;
+    }
+    .row-item:last-of-type {
+      margin-bottom: 0;
+    }
+    .row-item .hint-item {
+      width: 24px;
+      min-width: 24px;
+      align-self: flex-start;
+      line-height: 20px;
+      height: 20px;
+      margin-top: 9px;
+    }
+    .row-item .label-item {
+      position: relative;
+      align-items: flex-start;
+      align-self: flex-start;
+      line-height: 20px;
+      height: 20px;
+      margin-top: 10px;
+      width: 80px;
+      min-width: 80px;
+      .text-item {
+        font-size: 14px;
+        width: 60px;
+      }
+    }
+    .row-item .required-item {
+      width: 4px;
+      height: 4px;
+      border-radius: 2px;
+      background: #f45858;
+      position: absolute;
+      right: 10px;
+      top: 50%;
+      transform: translateY(-50%);
+    }
+    .row-item .input-item {
+      min-width: 480px;
+      position: relative;
+      // height: 35px;
+      .tip {
+        font-size: 12px;
+        color: tomato;
+      }
+    }
+  }
+  .opt {
+    text-align: right;
+  }
+}
+</style>

+ 237 - 0
src/views/modules/autoLaunch/radioCheck.vue

@@ -0,0 +1,237 @@
+<template>
+    <div class="radioCheck" >
+        
+            <label :class="{'item':true,'selection': selectValue.indexOf(item.value)>-1,'bgcolor':item.disabled}" v-for="(item,index) in checkArr" :key="index">
+                
+                <span>
+                    <input type="checkbox" :value="item.value"  class="checkbox-button-input" @click="radioCheckChange($event,item)">
+                </span>
+                <span>{{item.title}}</span>
+                
+            </label>
+            <!-- <label :class="{'item':true,'selection': selectValue.indexOf(item.value)>-1}" v-for="(item,index) in checkArr" :key="index" :disabled='item.disabled'>               
+                <span>
+                    <input type="checkbox" :value="item.value"  class="checkbox-button-input" @click="radioCheckChange">
+                </span>
+                <span>{{item.title}}</span>               
+            </label>        -->
+    </div>
+</template>
+
+<script>
+export default {
+    data() {
+        return {
+            selectValue:[''],
+            currentSelect:'',
+        }
+    },
+   
+    props:['checkArr','selectArr'],
+    watch:{
+        checkArr:{
+            handler(n,o){
+                // console.log(n,o)
+                this.selectValue=[];
+                let i=0;
+                this.checkArr.forEach((item,index)=>{
+                    // console.log(item)
+                    if(item.disabled==false){
+                        i++;
+                        this.selectValue[0]=item.value;
+                        // console.log(this.selectValue)
+                    }else if(item.disabled==undefined){
+                        if(item.checked){
+                            this.selectValue.push(item.value)
+                        }
+                        
+                    }
+                })
+                if(this.selectValue.length==0){
+                    this.selectValue=[''];
+                }
+                if(i==3){
+                    this.selectValue[0]='';
+                }
+                // console.log(this.selectValue)
+                this.$emit('getSonValue',this.selectValue)
+            },
+            deep:true,
+            // immediate: true
+
+        },
+        
+    },
+    methods: {
+        //单选多选的事件
+        radioCheckChange(e,item){
+            console.log(e.target,item,!item.disabled);
+            
+            this.currentSelect=e.target.value;
+            if(!item.disabled){
+
+                if(e.target.value=='' || this.selectValue.length==0 ){
+                    this.selectValue=[''];
+                }else{
+                    if(this.selectValue.indexOf('')>-1){
+                        let i=this.selectValue.indexOf('');
+                        this.selectValue.splice(0,1)
+                    }
+                    
+                    if(this.selectValue.indexOf(e.target.value)==-1){
+                        this.selectValue.push(e.target.value)
+                    }else if(this.selectValue.indexOf(e.target.value)>-1){
+                        this.selectValue=this.selectValue.filter((item)=>{
+                            return item!=e.target.value
+                        })  
+                    }
+
+                    if(this.selectValue.length==0){
+                        this.selectValue=[''];
+                    }
+                    
+                }
+            // console.log(this.currentSelect,this.selectValue);
+            }
+            this.$emit('getSonValue',this.selectValue)
+        },
+    },
+    mounted() {
+        // this.selectValue=[]
+        // console.log(this.checkArr)
+        this.checkArr.forEach((item,index)=>{
+            
+            if(item.disabled&&item.disabled!=undefined){
+                this.selectValue[0]=item.value
+            }else{
+                this.selectValue=['']
+            }
+        })
+        this.$emit('getSonValue',this.selectValue)
+    },
+}
+</script>
+
+<style lang="scss" scoped>
+.radioCheck{        
+    border-radius: 5px;
+    height: 32px;
+    padding: 0;
+    margin: 0;
+    border: none;
+    background: transparent;
+    .btn{
+        background: transparent;
+        padding: 0;
+        margin: 0;
+        border: none;
+    }
+    .item{
+        min-width: 80px;
+        padding: 0px 15px;
+        text-align: center;
+        display: inline-block;
+        border: 1px solid #ccc;
+        border-left: 0;
+        height: 32px;
+        line-height: 32px;
+        cursor: pointer;
+        .checkbox-button-input{
+            width: 0;
+            height: 0;
+            opacity: 0;
+        }
+
+    }
+    .bgcolor{
+        color:rgba(0, 0, 0, 0.25);
+        background-color: #f5f5f5;
+        border-color: #d9d9d9;
+        cursor: not-allowed;
+    }
+    .item::after{
+        content: "";
+        position: absolute;
+        right: 1px;
+        top: -2px;
+        width: 0;
+        height: 0;
+        border-top: 6px solid transparent;
+        border-bottom: 6px solid transparent;
+        border-left: 6px solid;
+        border-left-color: #e0e0e0;
+        -webkit-transform: rotate(-45deg);
+        -ms-transform: rotate(-45deg);
+        transform: rotate(-45deg);
+        border-radius: 2px;
+    }
+    .item:hover{
+        color: #1890ff;
+    }
+    .selection{
+        color: #1890ff;
+        background: #fff;
+        border-color: #1890ff;
+    }
+    .item.selection:hover{
+        // color: #1890ff;
+        color: #40a9ff;
+        background: #fff;
+        border-color: #40a9ff;
+    }
+    .item.selection:after{
+        border-left: 6px solid #1890ff;
+    }
+    .item:hover::after{
+        // border-color: #40a9ff;
+        border-left: 6px solid #40a9ff;
+    }
+    .bgcolor:hover{
+        color:rgba(0, 0, 0, 0.25);
+        background-color: #f5f5f5;
+        border-color: #d9d9d9;
+        cursor: not-allowed;
+    }
+    .bgcolor:hover::after{
+        // border-color: #40a9ff;
+        border-left: 6px solid #e0e0e0;
+    }
+    .bgcolor.selection:after{
+        border-left: 6px solid #e0e0e0;
+    }
+    .bgcolor.selection{
+        color:rgba(0, 0, 0, 0.25);
+        background-color: #f5f5f5;
+        border-color: #d9d9d9;
+        cursor: not-allowed;
+    }
+    .bgcolor.selection:hover{
+        // color: #1890ff;
+        color:rgba(0, 0, 0, 0.25);
+        background-color: #f5f5f5;
+        border-color: #d9d9d9;
+        cursor: not-allowed;
+    }
+    .bgcolor.selection:after{
+        border-left: 6px solid #e0e0e0;
+    }
+}
+.radioCheck .item:first-child {
+    border-radius: 5px 0 0 5px;
+    border-left: 1px solid #ccc;
+}
+.radioCheck .item.selection:first-child {
+    border-radius: 5px 0 0 5px;
+    border-left: 1px solid #1890ff;
+}
+.radioCheck .item.selection:nth-child(2) {
+    
+    border-left: 1px solid #1890ff;
+}
+.radioCheck .item:first-child:after{
+    border-left: 0;
+}
+.radioCheck .item:last-child {
+    border-radius: 0px 5px 5px 0px;
+}
+</style>

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


+ 5 - 3
src/views/modules/earlyWarningRules/ruleModule.vue

@@ -132,16 +132,17 @@
                       >
 
                       </scheduleTime>
-
+                        <!--  v-model="value.threshold" -->
                        <region
                         :disabled="!editShow"
+                        :cascaderValue.sync='value.threshold'
                         style="width: 100%;height:32px"
                         :isLazy='true'
-                        v-model="value.threshold"
+                       
                         v-else-if="value.modelType == 'region'"
                       >
                       </region>
-
+                      <!-- {{value.threshold}} -->
                       {{ value.dataUnit }}
                     </a-form-model-item>
                   </div>
@@ -261,6 +262,7 @@
                                       :maxTagCount="3"
                                     >
                                     </a-select>
+                                    
                                   </a-form-model-item>
                                 </div>
                               </div>

+ 2 - 2
vue.config.js

@@ -68,7 +68,7 @@ module.exports = {
     open : true,
     proxy: {
       '/jeecg-boot': {
-         target: 'http://192.168.1.8:8080', //请求本地 需要jeecg-boot后台项目  蒙蒙
+        //  target: 'http://192.168.1.8:8080', //请求本地 需要jeecg-boot后台项目  蒙蒙
         // target: 'http://192.168.0.59:8088', //请求本地 需要jeecg-boot后台项目  英豪
         // target: 'http://192.168.1.188:8088', //请求本地 需要jeecg-boot后台项目  英豪
         // target: 'http://192.168.2.115:8080', //请求本地 需要jeecg-boot后台项目  祚云
@@ -77,7 +77,7 @@ module.exports = {
         // target: 'http://192.168.1.43:8888', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.0.252:8098', //请求本地 需要jeecg-boot后台项目  毕洁泉
         // target: 'http://192.168.1.219:8080', //请求本地 需要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: 'http://39.106.184.70:8088/', //请求本地 需要jeecg-boot后台项目
         //  target: 'http://adsp.tjyourong.com.cn/', //请求本地 需要jeecg-boot后台项目