|  | @@ -44,8 +44,8 @@
 | 
	
		
			
				|  |  |                <el-form ref="temp" :rules="temp.rules" :model="temp" label-position="right" label-width="110px" style="width: 100%;margin:0 auto">
 | 
	
		
			
				|  |  |                  <el-row>
 | 
	
		
			
				|  |  |                    <el-col :span="24">
 | 
	
		
			
				|  |  | -                    <el-form-item label="消息名称:" prop="message">
 | 
	
		
			
				|  |  | -                      <span>{{temp.message}}</span>
 | 
	
		
			
				|  |  | +                    <el-form-item label="消息名称:" prop="messageName">
 | 
	
		
			
				|  |  | +                      <span>{{temp.messageName}}</span>
 | 
	
		
			
				|  |  |                      </el-form-item>
 | 
	
		
			
				|  |  |                    </el-col>
 | 
	
		
			
				|  |  |                  </el-row>
 | 
	
	
		
			
				|  | @@ -249,47 +249,70 @@
 | 
	
		
			
				|  |  |                <el-row>
 | 
	
		
			
				|  |  |                  <el-col :span="24">
 | 
	
		
			
				|  |  |                    <el-form-item label="发送方式:" prop="sendingMethod">
 | 
	
		
			
				|  |  | -                    <el-select v-model="temp.sendingMethod" style="width: 100%;" placeholder="发送方式">
 | 
	
		
			
				|  |  | +                    <el-select disabled v-model="temp.sendingMethod" style="width: 100%;" placeholder="发送方式">
 | 
	
		
			
				|  |  |                        <el-option v-for="item in modeList" :key="item.id" :label="item.name" :value="item.id" />
 | 
	
		
			
				|  |  |                      </el-select>
 | 
	
		
			
				|  |  |                    </el-form-item>
 | 
	
		
			
				|  |  |                  </el-col>
 | 
	
		
			
				|  |  |                </el-row>
 | 
	
		
			
				|  |  | +              <div v-if="temp.sendingMethod == '1'">
 | 
	
		
			
				|  |  | +                <el-row :gutter="5">
 | 
	
		
			
				|  |  | +                  <el-col :span="18">
 | 
	
		
			
				|  |  | +                    <el-form-item label="发送机制">
 | 
	
		
			
				|  |  | +                      <el-select disabled v-model="temp.sendingMechanism" style="width: 100%;" placeholder="发送机制">
 | 
	
		
			
				|  |  | +                        <el-option v-for="item in mechanismList" :key="item.id" :label="item.name" :value="item.id" />
 | 
	
		
			
				|  |  | +                      </el-select>
 | 
	
		
			
				|  |  | +                    </el-form-item>
 | 
	
		
			
				|  |  | +                  </el-col>
 | 
	
		
			
				|  |  | +                  <el-col :span="6" v-if="temp.sendingMechanism == '2'">
 | 
	
		
			
				|  |  | +                      <el-input disabled ref="numberCycles" v-model="temp.numberCycles" style="width: 100%;" placeholder="循环次数" type="text" />
 | 
	
		
			
				|  |  | +                  </el-col>
 | 
	
		
			
				|  |  | +                </el-row>
 | 
	
		
			
				|  |  | +                <el-row v-if="temp.sendingMechanism !== '1' && temp.sendingMechanism !== ''">
 | 
	
		
			
				|  |  | +                  <el-col :span="24">
 | 
	
		
			
				|  |  | +                    <el-form-item label="间隔周期:">
 | 
	
		
			
				|  |  | +                      <el-input disabled ref="intervalPeriod1" v-model="temp.intervalPeriod1" style="width: 33%;margin-right:1%" placeholder="天" type="text" />
 | 
	
		
			
				|  |  | +                      <el-input disabled ref="intervalPeriod2" v-model="temp.intervalPeriod2" style="width: 33%;margin-right:1%" placeholder="小时" type="text" />
 | 
	
		
			
				|  |  | +                      <el-input disabled ref="intervalPeriod3" v-model="temp.intervalPeriod3" style="width: 32%;" placeholder="分钟" type="text" />
 | 
	
		
			
				|  |  | +                    </el-form-item>
 | 
	
		
			
				|  |  | +                  </el-col>
 | 
	
		
			
				|  |  | +                </el-row>
 | 
	
		
			
				|  |  | +              </div>
 | 
	
		
			
				|  |  |                <div v-if="temp.sendingMethod == '2'">
 | 
	
		
			
				|  |  |                  <el-row>
 | 
	
		
			
				|  |  |                    <el-col :span="24">
 | 
	
		
			
				|  |  |                      <el-form-item label="延时:">
 | 
	
		
			
				|  |  | -                      <el-input ref="delayed1" v-model="temp.delayed1" style="width: 33%;margin-right:1%" placeholder="天" type="text" />
 | 
	
		
			
				|  |  | -                      <el-input ref="delayed2" v-model="temp.delayed2" style="width: 33%;margin-right:1%" placeholder="小时" type="text" />
 | 
	
		
			
				|  |  | -                      <el-input ref="delayed3" v-model="temp.delayed3" style="width: 32%;" placeholder="分钟" type="text" />
 | 
	
		
			
				|  |  | +                      <el-input disabled ref="delayed1" v-model="temp.delayed1" style="width: 33%;margin-right:1%" placeholder="天" type="text" />
 | 
	
		
			
				|  |  | +                      <el-input disabled ref="delayed2" v-model="temp.delayed2" style="width: 33%;margin-right:1%" placeholder="小时" type="text" />
 | 
	
		
			
				|  |  | +                      <el-input disabled ref="delayed3" v-model="temp.delayed3" style="width: 32%;" placeholder="分钟" type="text" />
 | 
	
		
			
				|  |  |                      </el-form-item>
 | 
	
		
			
				|  |  |                    </el-col>
 | 
	
		
			
				|  |  |                  </el-row>
 | 
	
		
			
				|  |  |                  <el-row>
 | 
	
		
			
				|  |  |                    <el-col :span="24">
 | 
	
		
			
				|  |  |                      <el-form-item label="发送时间">
 | 
	
		
			
				|  |  | -                       <el-time-select placeholder="发送时间" style="width: 100%;" v-model="temp.sendTime" :picker-options="{ start: '00:00', step: '00:15', end: '23:59' }" />
 | 
	
		
			
				|  |  | +                       <el-time-select disabled placeholder="发送时间" :clearable="false" style="width: 100%;" v-model="temp.sendTime" :picker-options="{ start: '00:00', step: '00:15', end: '23:59' }" />
 | 
	
		
			
				|  |  |                      </el-form-item>
 | 
	
		
			
				|  |  |                    </el-col>
 | 
	
		
			
				|  |  |                  </el-row>
 | 
	
		
			
				|  |  |                  <el-row :gutter="5">
 | 
	
		
			
				|  |  |                    <el-col :span="18">
 | 
	
		
			
				|  |  |                      <el-form-item label="发送机制">
 | 
	
		
			
				|  |  | -                      <el-select v-model="temp.sendingMechanism" style="width: 100%;" placeholder="发送机制">
 | 
	
		
			
				|  |  | +                      <el-select disabled v-model="temp.sendingMechanism" style="width: 100%;" placeholder="发送机制">
 | 
	
		
			
				|  |  |                          <el-option v-for="item in mechanismList" :key="item.id" :label="item.name" :value="item.id" />
 | 
	
		
			
				|  |  |                        </el-select>
 | 
	
		
			
				|  |  |                      </el-form-item>
 | 
	
		
			
				|  |  |                    </el-col>
 | 
	
		
			
				|  |  |                    <el-col :span="6" v-if="temp.sendingMechanism == '2'">
 | 
	
		
			
				|  |  | -                      <el-input ref="numberCycles" v-model="temp.numberCycles" style="width: 100%;" placeholder="循环次数" type="text" />
 | 
	
		
			
				|  |  | +                      <el-input disabled ref="numberCycles" v-model="temp.numberCycles" style="width: 100%;" placeholder="循环次数" type="text" />
 | 
	
		
			
				|  |  |                    </el-col>
 | 
	
		
			
				|  |  |                  </el-row>
 | 
	
		
			
				|  |  |                  <el-row v-if="temp.sendingMechanism !== '1' && temp.sendingMechanism !== ''">
 | 
	
		
			
				|  |  |                    <el-col :span="24">
 | 
	
		
			
				|  |  |                      <el-form-item label="间隔周期:">
 | 
	
		
			
				|  |  | -                      <el-input ref="intervalPeriod1" v-model="temp.intervalPeriod1" style="width: 33%;margin-right:1%" placeholder="天" type="text" />
 | 
	
		
			
				|  |  | -                      <el-input ref="intervalPeriod2" v-model="temp.intervalPeriod2" style="width: 33%;margin-right:1%" placeholder="小时" type="text" />
 | 
	
		
			
				|  |  | -                      <el-input ref="intervalPeriod3" v-model="temp.intervalPeriod3" style="width: 32%;" placeholder="分钟" type="text" />
 | 
	
		
			
				|  |  | +                      <el-input disabled ref="intervalPeriod1" v-model="temp.intervalPeriod1" style="width: 33%;margin-right:1%" placeholder="天" type="text" />
 | 
	
		
			
				|  |  | +                      <el-input disabled ref="intervalPeriod2" v-model="temp.intervalPeriod2" style="width: 33%;margin-right:1%" placeholder="小时" type="text" />
 | 
	
		
			
				|  |  | +                      <el-input disabled ref="intervalPeriod3" v-model="temp.intervalPeriod3" style="width: 32%;" placeholder="分钟" type="text" />
 | 
	
		
			
				|  |  |                      </el-form-item>
 | 
	
		
			
				|  |  |                    </el-col>
 | 
	
		
			
				|  |  |                  </el-row>
 | 
	
	
		
			
				|  | @@ -305,18 +328,18 @@
 | 
	
		
			
				|  |  |                  <el-row :gutter="5">
 | 
	
		
			
				|  |  |                    <el-col :span="18">
 | 
	
		
			
				|  |  |                      <el-form-item label="周期类型">
 | 
	
		
			
				|  |  | -                      <el-select v-model="temp.cycleType" style="width: 100%;" placeholder="周期类型">
 | 
	
		
			
				|  |  | +                      <el-select disabled v-model="temp.cycleType" style="width: 100%;" placeholder="周期类型">
 | 
	
		
			
				|  |  |                          <el-option v-for="item in cycleTypeList" :key="item.id" :label="item.name" :value="item.id" />
 | 
	
		
			
				|  |  |                        </el-select>
 | 
	
		
			
				|  |  |                      </el-form-item>
 | 
	
		
			
				|  |  |                    </el-col>
 | 
	
		
			
				|  |  |                    <el-col :span="6" v-if="temp.cycleType == '2'">
 | 
	
		
			
				|  |  | -                    <el-select v-model="temp.week" style="width: 100%;" placeholder="每周">
 | 
	
		
			
				|  |  | +                    <el-select disabled v-model="temp.week" style="width: 100%;" placeholder="每周">
 | 
	
		
			
				|  |  |                        <el-option v-for="item in weekList" :key="item.id" :label="item.name" :value="item.id" />
 | 
	
		
			
				|  |  |                      </el-select>
 | 
	
		
			
				|  |  |                    </el-col>
 | 
	
		
			
				|  |  |                    <el-col :span="6" v-if="temp.cycleType == 3">
 | 
	
		
			
				|  |  | -                    <el-select v-model="temp.month" style="width: 100%;" placeholder="每月">
 | 
	
		
			
				|  |  | +                    <el-select disabled v-model="temp.month" style="width: 100%;" placeholder="每月">
 | 
	
		
			
				|  |  |                        <el-option v-for="item in monthList" :key="item.id" :label="item.name" :value="item.id" />
 | 
	
		
			
				|  |  |                      </el-select>
 | 
	
		
			
				|  |  |                    </el-col>
 | 
	
	
		
			
				|  | @@ -324,7 +347,7 @@
 | 
	
		
			
				|  |  |                  <el-row>
 | 
	
		
			
				|  |  |                    <el-col :span="24">
 | 
	
		
			
				|  |  |                      <el-form-item label="发送时间">
 | 
	
		
			
				|  |  | -                       <el-time-select placeholder="发送时间" style="width: 100%;" v-model="temp.sendTime" :picker-options="{ start: '00:00', step: '00:15', end: '23:59' }" />
 | 
	
		
			
				|  |  | +                       <el-time-select disabled placeholder="发送时间" :clearable="false" style="width: 100%;" v-model="temp.sendTime" :picker-options="{ start: '00:00', step: '00:15', end: '23:59' }" />
 | 
	
		
			
				|  |  |                      </el-form-item>
 | 
	
		
			
				|  |  |                    </el-col>
 | 
	
		
			
				|  |  |                  </el-row>
 | 
	
	
		
			
				|  | @@ -332,7 +355,7 @@
 | 
	
		
			
				|  |  |              </el-form>
 | 
	
		
			
				|  |  |          </div>
 | 
	
		
			
				|  |  |          <div slot="footer" class="dialog-footer" style="right:30px;position:absolute;bottom: 40px;">
 | 
	
		
			
				|  |  | -          <el-button class="cancelClose" @click="see.dialogFormVisible = false;getList(); ">取消</el-button>
 | 
	
		
			
				|  |  | +          <el-button class="cancelClose1" @click="see.dialogFormVisible = false;getList(); ">取消</el-button>
 | 
	
		
			
				|  |  |          </div>
 | 
	
		
			
				|  |  |        </div>
 | 
	
		
			
				|  |  |      </el-dialog>
 | 
	
	
		
			
				|  | @@ -467,7 +490,7 @@
 | 
	
		
			
				|  |  |        this.monthList = []
 | 
	
		
			
				|  |  |        for(let i=1;i<=31;i++){
 | 
	
		
			
				|  |  |          let obj = {}
 | 
	
		
			
				|  |  | -        obj.id = i
 | 
	
		
			
				|  |  | +        obj.id = String(i)
 | 
	
		
			
				|  |  |          obj.name = i+'日'
 | 
	
		
			
				|  |  |          this.monthList.push(obj)
 | 
	
		
			
				|  |  |        }
 | 
	
	
		
			
				|  | @@ -503,10 +526,12 @@
 | 
	
		
			
				|  |  |          this.setUp.dialogFormVisible = true
 | 
	
		
			
				|  |  |          this.activeName = 'first'
 | 
	
		
			
				|  |  |          this.setUp.temp = Object.assign({}, row)
 | 
	
		
			
				|  |  | -        this.temp.messageName = row.data.message //消息名称
 | 
	
		
			
				|  |  | +        this.temp.messageName = row.message //消息名称
 | 
	
		
			
				|  |  |          this.temp.triggerCondition = row.trigger //触发条件
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  | +        this.temp.sendTime = row.data.push_time //发送时间
 | 
	
		
			
				|  |  | +        this.selectList1 = []
 | 
	
		
			
				|  |  | +        this.selectList2 = row.user.split(',')
 | 
	
		
			
				|  |  | +        console.log(this.selectList2,'this.selectList211')
 | 
	
		
			
				|  |  |          // 立即
 | 
	
		
			
				|  |  |          this.temp.sendingMethod = String(row.data.remind_type) //发送方式
 | 
	
		
			
				|  |  |          if(this.temp.sendingMethod == '1'){
 | 
	
	
		
			
				|  | @@ -514,12 +539,26 @@
 | 
	
		
			
				|  |  |            if(this.temp.sendingMechanism == '2'){
 | 
	
		
			
				|  |  |              this.temp.numberCycles = row.data.push_limit //循环次数
 | 
	
		
			
				|  |  |              if(this.temp.sendingMechanism !== '1' && this.temp.sendingMechanism !== ''){
 | 
	
		
			
				|  |  | -              this.formatMinutes(row.data.interval_time) //间隔周期
 | 
	
		
			
				|  |  | +              //间隔周期
 | 
	
		
			
				|  |  | +              var minutes = row.data.interval_time
 | 
	
		
			
				|  |  | +              var day = parseInt(Math.floor(minutes / 1440));
 | 
	
		
			
				|  |  | +              var hour = day > 0 ? Math.floor((minutes - day * 1440) / 60) : Math.floor(minutes / 60);
 | 
	
		
			
				|  |  | +              var minute = hour > 0 ? Math.floor(minutes - day * 1440 - hour * 60) : minutes;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod1 = day;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod2 = hour;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod3 = minute;
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  |            }
 | 
	
		
			
				|  |  |            if(this.temp.sendingMechanism == '3'){
 | 
	
		
			
				|  |  |              if(this.temp.sendingMechanism !== '1' && this.temp.sendingMechanism !== ''){
 | 
	
		
			
				|  |  | -              this.formatMinutes(row.data.interval_time) //间隔周期
 | 
	
		
			
				|  |  | +              //间隔周期
 | 
	
		
			
				|  |  | +              var minutes = row.data.interval_time
 | 
	
		
			
				|  |  | +              var day = parseInt(Math.floor(minutes / 1440));
 | 
	
		
			
				|  |  | +              var hour = day > 0 ? Math.floor((minutes - day * 1440) / 60) : Math.floor(minutes / 60);
 | 
	
		
			
				|  |  | +              var minute = hour > 0 ? Math.floor(minutes - day * 1440 - hour * 60) : minutes;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod1 = day;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod2 = hour;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod3 = minute;
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  |            }
 | 
	
		
			
				|  |  |          }
 | 
	
	
		
			
				|  | @@ -527,19 +566,39 @@
 | 
	
		
			
				|  |  |          if(this.temp.sendingMethod == '2'){
 | 
	
		
			
				|  |  |            this.temp.sendingMethod = String(row.data.remind_type) //发送方式
 | 
	
		
			
				|  |  |            if(this.temp.sendingMethod == '2'){
 | 
	
		
			
				|  |  | -            this.formatMinutes(row.data.interval_time) //延时
 | 
	
		
			
				|  |  | +            //延时
 | 
	
		
			
				|  |  | +            var minutes = row.data.delay_time
 | 
	
		
			
				|  |  | +            var day = parseInt(Math.floor(minutes / 1440));
 | 
	
		
			
				|  |  | +            var hour = day > 0 ? Math.floor((minutes - day * 1440) / 60) : Math.floor(minutes / 60);
 | 
	
		
			
				|  |  | +            var minute = hour > 0 ? Math.floor(minutes - day * 1440 - hour * 60) : minutes;
 | 
	
		
			
				|  |  | +            this.temp.delayed1 = day;
 | 
	
		
			
				|  |  | +            this.temp.delayed2 = hour;
 | 
	
		
			
				|  |  | +            this.temp.delayed3 = minute;
 | 
	
		
			
				|  |  |            }
 | 
	
		
			
				|  |  |            this.temp.sendTime = row.data.push_time //发送时间
 | 
	
		
			
				|  |  | -          this.temp.push_limit = String(row.data.push_time) //发送机制
 | 
	
		
			
				|  |  | -          if(this.temp.push_limit == '2'){
 | 
	
		
			
				|  |  | +          this.temp.sendingMechanism = String(row.data.cycle_type) //发送机制
 | 
	
		
			
				|  |  | +          if(this.temp.sendingMechanism == '2'){
 | 
	
		
			
				|  |  |              this.temp.numberCycles = row.data.push_limit //循环次数
 | 
	
		
			
				|  |  |              if(this.temp.sendingMechanism !== '1' && this.temp.sendingMechanism !== ''){
 | 
	
		
			
				|  |  | -              this.formatMinutes(row.data.interval_time) //间隔周期
 | 
	
		
			
				|  |  | +              //间隔周期
 | 
	
		
			
				|  |  | +              var minutes = row.data.interval_time
 | 
	
		
			
				|  |  | +              var day = parseInt(Math.floor(minutes / 1440));
 | 
	
		
			
				|  |  | +              var hour = day > 0 ? Math.floor((minutes - day * 1440) / 60) : Math.floor(minutes / 60);
 | 
	
		
			
				|  |  | +              var minute = hour > 0 ? Math.floor(minutes - day * 1440 - hour * 60) : minutes;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod1 = day;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod2 = hour;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod3 = minute;
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  |            }
 | 
	
		
			
				|  |  | -          if(this.temp.push_limit == '3'){
 | 
	
		
			
				|  |  | +          if(this.temp.sendingMechanism == '3'){
 | 
	
		
			
				|  |  |              if(this.temp.sendingMechanism !== '1' && this.temp.sendingMechanism !== ''){
 | 
	
		
			
				|  |  | -              this.formatMinutes(row.data.interval_time) //间隔周期
 | 
	
		
			
				|  |  | +              var minutes = row.data.interval_time
 | 
	
		
			
				|  |  | +              var day = parseInt(Math.floor(minutes / 1440));
 | 
	
		
			
				|  |  | +              var hour = day > 0 ? Math.floor((minutes - day * 1440) / 60) : Math.floor(minutes / 60);
 | 
	
		
			
				|  |  | +              var minute = hour > 0 ? Math.floor(minutes - day * 1440 - hour * 60) : minutes;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod1 = day;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod2 = hour;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod3 = minute;
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  |            }
 | 
	
		
			
				|  |  |          }
 | 
	
	
		
			
				|  | @@ -547,40 +606,102 @@
 | 
	
		
			
				|  |  |          if(this.temp.sendingMethod == '3'){
 | 
	
		
			
				|  |  |            this.temp.cycleType = String(row.data.date_type)  //周期类型
 | 
	
		
			
				|  |  |            if(this.temp.cycleType == '2'){
 | 
	
		
			
				|  |  | -            this.temp.week = row.data.push_date
 | 
	
		
			
				|  |  | +            this.temp.week = String(row.data.push_date)
 | 
	
		
			
				|  |  |            }
 | 
	
		
			
				|  |  |            if(this.temp.cycleType == '3'){
 | 
	
		
			
				|  |  | -            this.temp.month = row.data.push_date
 | 
	
		
			
				|  |  | +            this.temp.month = String(row.data.push_date)
 | 
	
		
			
				|  |  |            }
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |          this.getList1()
 | 
	
		
			
				|  |  |        },
 | 
	
		
			
				|  |  | -      formatMinutes(minutes) {
 | 
	
		
			
				|  |  | -        var day = parseInt(Math.floor(minutes / 1440));
 | 
	
		
			
				|  |  | -        var hour = day > 0 ? Math.floor((minutes - day * 1440) / 60) : Math.floor(minutes / 60);
 | 
	
		
			
				|  |  | -        var minute = hour > 0 ? Math.floor(minutes - day * 1440 - hour * 60) : minutes;
 | 
	
		
			
				|  |  | +      handleSee(row){
 | 
	
		
			
				|  |  | +        this.see.dialogStatus = 'see'
 | 
	
		
			
				|  |  | +        this.see.dialogFormVisible = true
 | 
	
		
			
				|  |  | +        this.setUp.temp = Object.assign({}, row)
 | 
	
		
			
				|  |  | +        this.temp.messageName = row.message //消息名称
 | 
	
		
			
				|  |  | +        this.temp.triggerCondition = row.trigger //触发条件
 | 
	
		
			
				|  |  | +        this.temp.sendTime = row.data.push_time //发送时间
 | 
	
		
			
				|  |  | +        // 立即
 | 
	
		
			
				|  |  | +        this.temp.sendingMethod = String(row.data.remind_type) //发送方式
 | 
	
		
			
				|  |  | +        if(this.temp.sendingMethod == '1'){
 | 
	
		
			
				|  |  | +          this.temp.sendingMechanism = String(row.data.cycle_type) //发送机制
 | 
	
		
			
				|  |  | +          if(this.temp.sendingMechanism == '2'){
 | 
	
		
			
				|  |  | +            this.temp.numberCycles = row.data.push_limit //循环次数
 | 
	
		
			
				|  |  | +            if(this.temp.sendingMechanism !== '1' && this.temp.sendingMechanism !== ''){
 | 
	
		
			
				|  |  | +              //间隔周期
 | 
	
		
			
				|  |  | +              var minutes = row.data.interval_time
 | 
	
		
			
				|  |  | +              var day = parseInt(Math.floor(minutes / 1440));
 | 
	
		
			
				|  |  | +              var hour = day > 0 ? Math.floor((minutes - day * 1440) / 60) : Math.floor(minutes / 60);
 | 
	
		
			
				|  |  | +              var minute = hour > 0 ? Math.floor(minutes - day * 1440 - hour * 60) : minutes;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod1 = day;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod2 = hour;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod3 = minute;
 | 
	
		
			
				|  |  | +            }
 | 
	
		
			
				|  |  | +          }
 | 
	
		
			
				|  |  | +          if(this.temp.sendingMechanism == '3'){
 | 
	
		
			
				|  |  | +            if(this.temp.sendingMechanism !== '1' && this.temp.sendingMechanism !== ''){
 | 
	
		
			
				|  |  | +              //间隔周期
 | 
	
		
			
				|  |  | +              var minutes = row.data.interval_time
 | 
	
		
			
				|  |  | +              var day = parseInt(Math.floor(minutes / 1440));
 | 
	
		
			
				|  |  | +              var hour = day > 0 ? Math.floor((minutes - day * 1440) / 60) : Math.floor(minutes / 60);
 | 
	
		
			
				|  |  | +              var minute = hour > 0 ? Math.floor(minutes - day * 1440 - hour * 60) : minutes;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod1 = day;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod2 = hour;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod3 = minute;
 | 
	
		
			
				|  |  | +            }
 | 
	
		
			
				|  |  | +          }
 | 
	
		
			
				|  |  | +        }
 | 
	
		
			
				|  |  | +        // 延时
 | 
	
		
			
				|  |  |          if(this.temp.sendingMethod == '2'){
 | 
	
		
			
				|  |  | -          this.temp.delayed1 = day;
 | 
	
		
			
				|  |  | -          this.temp.delayed2 = hour;
 | 
	
		
			
				|  |  | -          this.temp.delayed3 = minute;
 | 
	
		
			
				|  |  | -          return this.temp.delayed1;
 | 
	
		
			
				|  |  | -          return this.temp.delayed2;
 | 
	
		
			
				|  |  | -          return this.temp.delayed3;
 | 
	
		
			
				|  |  | +          this.temp.sendingMethod = String(row.data.remind_type) //发送方式
 | 
	
		
			
				|  |  | +          if(this.temp.sendingMethod == '2'){
 | 
	
		
			
				|  |  | +            //延时
 | 
	
		
			
				|  |  | +            var minutes = row.data.delay_time
 | 
	
		
			
				|  |  | +            var day = parseInt(Math.floor(minutes / 1440));
 | 
	
		
			
				|  |  | +            var hour = day > 0 ? Math.floor((minutes - day * 1440) / 60) : Math.floor(minutes / 60);
 | 
	
		
			
				|  |  | +            var minute = hour > 0 ? Math.floor(minutes - day * 1440 - hour * 60) : minutes;
 | 
	
		
			
				|  |  | +            this.temp.delayed1 = day;
 | 
	
		
			
				|  |  | +            this.temp.delayed2 = hour;
 | 
	
		
			
				|  |  | +            this.temp.delayed3 = minute;
 | 
	
		
			
				|  |  | +          }
 | 
	
		
			
				|  |  | +          this.temp.sendTime = row.data.push_time //发送时间
 | 
	
		
			
				|  |  | +          this.temp.sendingMechanism = String(row.data.cycle_type) //发送机制
 | 
	
		
			
				|  |  | +          if(this.temp.sendingMechanism == '2'){
 | 
	
		
			
				|  |  | +            this.temp.numberCycles = row.data.push_limit //循环次数
 | 
	
		
			
				|  |  | +            if(this.temp.sendingMechanism !== '1' && this.temp.sendingMechanism !== ''){
 | 
	
		
			
				|  |  | +              //间隔周期
 | 
	
		
			
				|  |  | +              var minutes = row.data.interval_time
 | 
	
		
			
				|  |  | +              var day = parseInt(Math.floor(minutes / 1440));
 | 
	
		
			
				|  |  | +              var hour = day > 0 ? Math.floor((minutes - day * 1440) / 60) : Math.floor(minutes / 60);
 | 
	
		
			
				|  |  | +              var minute = hour > 0 ? Math.floor(minutes - day * 1440 - hour * 60) : minutes;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod1 = day;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod2 = hour;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod3 = minute;
 | 
	
		
			
				|  |  | +            }
 | 
	
		
			
				|  |  | +          }
 | 
	
		
			
				|  |  | +          if(this.temp.sendingMechanism == '3'){
 | 
	
		
			
				|  |  | +            if(this.temp.sendingMechanism !== '1' && this.temp.sendingMechanism !== ''){
 | 
	
		
			
				|  |  | +              var minutes = row.data.interval_time
 | 
	
		
			
				|  |  | +              var day = parseInt(Math.floor(minutes / 1440));
 | 
	
		
			
				|  |  | +              var hour = day > 0 ? Math.floor((minutes - day * 1440) / 60) : Math.floor(minutes / 60);
 | 
	
		
			
				|  |  | +              var minute = hour > 0 ? Math.floor(minutes - day * 1440 - hour * 60) : minutes;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod1 = day;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod2 = hour;
 | 
	
		
			
				|  |  | +              this.temp.intervalPeriod3 = minute;
 | 
	
		
			
				|  |  | +            }
 | 
	
		
			
				|  |  | +          }
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  | -        if(this.temp.sendingMechanism !== '1' && this.temp.sendingMechanism !== ''){
 | 
	
		
			
				|  |  | -          this.temp.intervalPeriod1 = day;
 | 
	
		
			
				|  |  | -          this.temp.intervalPeriod2 = hour;
 | 
	
		
			
				|  |  | -          this.temp.intervalPeriod3 = minute;
 | 
	
		
			
				|  |  | -          return this.temp.intervalPeriod1;
 | 
	
		
			
				|  |  | -          return this.temp.intervalPeriod2;
 | 
	
		
			
				|  |  | -          return this.temp.intervalPeriod3;
 | 
	
		
			
				|  |  | +        // 指定周期
 | 
	
		
			
				|  |  | +        if(this.temp.sendingMethod == '3'){
 | 
	
		
			
				|  |  | +          this.temp.cycleType = String(row.data.date_type)  //周期类型
 | 
	
		
			
				|  |  | +          if(this.temp.cycleType == '2'){
 | 
	
		
			
				|  |  | +            this.temp.week = String(row.data.push_date)
 | 
	
		
			
				|  |  | +          }
 | 
	
		
			
				|  |  | +          if(this.temp.cycleType == '3'){
 | 
	
		
			
				|  |  | +            this.temp.month = String(row.data.push_date)
 | 
	
		
			
				|  |  | +          }
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |        },
 | 
	
		
			
				|  |  | -      handleSee(){
 | 
	
		
			
				|  |  | -        this.see.dialogStatus = 'see'
 | 
	
		
			
				|  |  | -        this.see.dialogFormVisible = true
 | 
	
		
			
				|  |  | -        this.see.temp = Object.assign({}, row)
 | 
	
		
			
				|  |  | -      },
 | 
	
		
			
				|  |  |        handleClick(item){
 | 
	
		
			
				|  |  |          if(item == 'first'){
 | 
	
		
			
				|  |  |            this.getList1()
 | 
	
	
		
			
				|  | @@ -616,8 +737,7 @@
 | 
	
		
			
				|  |  |            if (response.data.list !== null) {
 | 
	
		
			
				|  |  |              this.setUp.list1 = response.data.list
 | 
	
		
			
				|  |  |              if(this.selectList1.length== 0){
 | 
	
		
			
				|  |  | -              this.setUp.data2.parammaps.roleid = response.data.list[0]['id']
 | 
	
		
			
				|  |  | -              this.selectList1.push(response.data.list[0]['id'])
 | 
	
		
			
				|  |  | +              this.setUp.data2.parammaps.roleid = ''
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  |              this.selectList1.forEach(key => {
 | 
	
		
			
				|  |  |                this.setUp.list1.forEach(row => {
 | 
	
	
		
			
				|  | @@ -643,11 +763,14 @@
 | 
	
		
			
				|  |  |          postJson(url,this.setUp.data2).then(response => {
 | 
	
		
			
				|  |  |            if (response.data.list !== null) {
 | 
	
		
			
				|  |  |              this.setUp.list2 = response.data.list
 | 
	
		
			
				|  |  | -            this.selectList2 = []
 | 
	
		
			
				|  |  | -            response.data.list.forEach(key => {
 | 
	
		
			
				|  |  | -              this.selectList2.push(key.username)
 | 
	
		
			
				|  |  | -            })
 | 
	
		
			
				|  |  | +            if(this.selectList1.length !== 0){
 | 
	
		
			
				|  |  | +              this.selectList2 = []
 | 
	
		
			
				|  |  | +              response.data.list.forEach(key => {
 | 
	
		
			
				|  |  | +                this.selectList2.push(key.username)
 | 
	
		
			
				|  |  | +              })
 | 
	
		
			
				|  |  | +            }
 | 
	
		
			
				|  |  |              this.selectList2.forEach(key => {
 | 
	
		
			
				|  |  | +              console.log(key,'key')
 | 
	
		
			
				|  |  |                this.setUp.list2.forEach(row => {
 | 
	
		
			
				|  |  |                  if (row.username == key) {
 | 
	
		
			
				|  |  |                    this.$nextTick(() => {
 | 
	
	
		
			
				|  | @@ -721,8 +844,8 @@
 | 
	
		
			
				|  |  |          // 发送方式-立即
 | 
	
		
			
				|  |  |          if(this.temp.sendingMethod == '1'){
 | 
	
		
			
				|  |  |            data.sys_name = 'tmrWatch'
 | 
	
		
			
				|  |  | -          data.pasture_id = this.setUp.temp.pastureid
 | 
	
		
			
				|  |  | -          data.service_id = this.setUp.temp.service_id
 | 
	
		
			
				|  |  | +          data.pastureid = this.setUp.temp.pastureid
 | 
	
		
			
				|  |  | +          // data.service_id = this.setUp.temp.service_id
 | 
	
		
			
				|  |  |            data.type_name = this.temp.messageName
 | 
	
		
			
				|  |  |            data.template_id = 'BtkN1rWKOJtKP0C64lGxIrPzLRFsYFas-4gupX2-pFo'
 | 
	
		
			
				|  |  |            data.id = this.setUp.temp.id
 | 
	
	
		
			
				|  | @@ -740,7 +863,7 @@
 | 
	
		
			
				|  |  |          // 发送方式-延时
 | 
	
		
			
				|  |  |          if(this.temp.sendingMethod == '2'){
 | 
	
		
			
				|  |  |            data.id = this.setUp.temp.id
 | 
	
		
			
				|  |  | -          data.user = this.setUp.temp.user
 | 
	
		
			
				|  |  | +          data.user = this.selectList2
 | 
	
		
			
				|  |  |            data.sys_name = 'tmrWatch'
 | 
	
		
			
				|  |  |            data.type_name = this.temp.messageName
 | 
	
		
			
				|  |  |            data.template_id = 'BtkN1rWKOJtKP0C64lGxIrPzLRFsYFas-4gupX2-pFo'
 | 
	
	
		
			
				|  | @@ -760,7 +883,7 @@
 | 
	
		
			
				|  |  |          // 发送方式-指定周期
 | 
	
		
			
				|  |  |          if(this.temp.sendingMethod == '3'){
 | 
	
		
			
				|  |  |            data.id = this.setUp.temp.id
 | 
	
		
			
				|  |  | -          data.user = this.setUp.temp.user
 | 
	
		
			
				|  |  | +          data.user = this.selectList2
 | 
	
		
			
				|  |  |            data.sys_name = 'tmrWatch'
 | 
	
		
			
				|  |  |            data.type_name = this.temp.messageName
 | 
	
		
			
				|  |  |            data.template_id = 'BtkN1rWKOJtKP0C64lGxIrPzLRFsYFas-4gupX2-pFo'
 | 
	
	
		
			
				|  | @@ -779,8 +902,10 @@
 | 
	
		
			
				|  |  |            if(response.code == 200){
 | 
	
		
			
				|  |  |              console.log('成功')
 | 
	
		
			
				|  |  |              this.$notify({ title: '成功', message: '保存成功', type: 'success', duration: 2000 })
 | 
	
		
			
				|  |  | +            this.setUp.dialogFormVisible = false
 | 
	
		
			
				|  |  | +            this.getList()
 | 
	
		
			
				|  |  |            }else{
 | 
	
		
			
				|  |  | -            this.$notify({ title: '成功', message: response.message, type: 'success', duration: 2000 })
 | 
	
		
			
				|  |  | +            this.$notify({ title: '失败', message: response.message, type: 'warning', duration: 2000 })
 | 
	
		
			
				|  |  |              console.log('失败')
 | 
	
		
			
				|  |  |            }
 | 
	
		
			
				|  |  |          })
 |