|  | @@ -7,7 +7,7 @@
 | 
											
												
													
														|  |        <el-button v-if="isRoleEdit" class="success" icon="el-icon-plus" style="float: left;" @click="handleCreate2">设置允许误差时间</el-button>
 |  |        <el-button v-if="isRoleEdit" class="success" icon="el-icon-plus" style="float: left;" @click="handleCreate2">设置允许误差时间</el-button>
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |        
 |  |        
 | 
											
												
													
														|  | -      <el-button v-if="isRoleEdit" class="success" icon="el-icon-open" style="float: left;" @click="handleTakeEffect">启用</el-button>
 |  | 
 | 
											
												
													
														|  | 
 |  | +     <el-button v-if="isRoleEdit" class="success" icon="el-icon-open" style="float: left;" @click="handleTakeEffect">启用</el-button>
 | 
											
												
													
														|  |        <el-button v-if="isRoleEdit" class="danger" icon="el-icon-turn-off" style="float: left;" @click="handleDisable">禁用</el-button>
 |  |        <el-button v-if="isRoleEdit" class="danger" icon="el-icon-turn-off" style="float: left;" @click="handleDisable">禁用</el-button>
 | 
											
												
													
														|  |        <el-button v-if="isRoleEdit" class="success" style="float: left;" @click="handleCheck">校验</el-button>
 |  |        <el-button v-if="isRoleEdit" class="success" style="float: left;" @click="handleCheck">校验</el-button>
 | 
											
												
													
														|  |   
 |  |   
 | 
											
										
											
												
													
														|  | @@ -93,36 +93,84 @@
 | 
											
												
													
														|  |        </template>
 |  |        </template>
 | 
											
												
													
														|  |        <div class="app-add">
 |  |        <div class="app-add">
 | 
											
												
													
														|  |          <el-form ref="temp" :rules="create1.rules" :model="create1.temp" label-position="right" label-width="155px" style="width: 100%;margin:0 auto 50px">
 |  |          <el-form ref="temp" :rules="create1.rules" :model="create1.temp" label-position="right" label-width="155px" style="width: 100%;margin:0 auto 50px">
 | 
											
												
													
														|  | -       
 |  | 
 | 
											
												
													
														|  | -           
 |  | 
 | 
											
												
													
														|  | 
 |  | +        
 | 
											
												
													
														|  |            <el-row>
 |  |            <el-row>
 | 
											
												
													
														|  |                <el-col :span="6">
 |  |                <el-col :span="6">
 | 
											
												
													
														|  |                  <el-form-item label="设置时间:" prop="useinbarid">
 |  |                  <el-form-item label="设置时间:" prop="useinbarid">
 | 
											
												
													
														|  |                     <el-time-picker
 |  |                     <el-time-picker
 | 
											
												
													
														|  | -                    v-model="value1"
 |  | 
 | 
											
												
													
														|  | -                    :picker-options="{
 |  | 
 | 
											
												
													
														|  | -                      selectableRange: '00:00:00 - 23:59:59'
 |  | 
 | 
											
												
													
														|  | -                    }"
 |  | 
 | 
											
												
													
														|  | 
 |  | +                    v-model="timevalue1"
 | 
											
												
													
														|  | 
 |  | +                    :picker-options="{ selectableRange: '00:00:00 - 23:59:59' }"
 | 
											
												
													
														|  |                       value-format="HH:mm"
 |  |                       value-format="HH:mm"
 | 
											
												
													
														|  | -    format="HH:mm"
 |  | 
 | 
											
												
													
														|  | 
 |  | +                     @change="change_time1" format="HH:mm"
 | 
											
												
													
														|  |                      placeholder="任意时间点">
 |  |                      placeholder="任意时间点">
 | 
											
												
													
														|  |                    </el-time-picker>
 |  |                    </el-time-picker>
 | 
											
												
													
														|  |                  </el-form-item>
 |  |                  </el-form-item>
 | 
											
												
													
														|  |                </el-col>
 |  |                </el-col>
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |            </el-row>
 |  |            </el-row>
 | 
											
												
													
														|  | 
 |  | +           <el-row>
 | 
											
												
													
														|  | 
 |  | +               <el-tag v-for="tag in timetags1" :key="tag.name" closable @close="tag_close1(tag)" type="success">{{tag}}</el-tag>
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  | - 
 |  | 
 | 
											
												
													
														|  | -  
 |  | 
 | 
											
												
													
														|  | 
 |  | +            </el-row>
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  | -       
 |  | 
 | 
											
												
													
														|  | 
 |  | +        
 | 
											
												
													
														|  |          </el-form>
 |  |          </el-form>
 | 
											
												
													
														|  |          <div slot="footer" class="dialog-footer">
 |  |          <div slot="footer" class="dialog-footer">
 | 
											
												
													
														|  |            <el-button class="cancelClose" @click="create1.dialogFormVisible = false;getList()">关闭</el-button>
 |  |            <el-button class="cancelClose" @click="create1.dialogFormVisible = false;getList()">关闭</el-button>
 | 
											
												
													
														|  | -          <el-button class="save"  @click="handleCreate">确认</el-button>
 |  | 
 | 
											
												
													
														|  | 
 |  | +          <el-button class="save"  @click="handleCreate1">确认</el-button>
 | 
											
												
													
														|  | 
 |  | +        </div>
 | 
											
												
													
														|  | 
 |  | +      </div>
 | 
											
												
													
														|  | 
 |  | +    </el-dialog>
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    <el-dialog :fullscreen="dialogFull" :visible.sync="create2.dialogFormVisible" :close-on-click-modal="false" width="50%">
 | 
											
												
													
														|  | 
 |  | +      <template slot="title">
 | 
											
												
													
														|  | 
 |  | +        <div class="avue-crud__dialog__header">
 | 
											
												
													
														|  | 
 |  | +          <span class="el-dialog__title">
 | 
											
												
													
														|  | 
 |  | +            <span style="display:inline-block;width:3px;height:20px;margin-right:5px; float: left;margin-top:2px" />
 | 
											
												
													
														|  | 
 |  | +            允许误差时间
 | 
											
												
													
														|  | 
 |  | +          </span>
 | 
											
												
													
														|  | 
 |  | +          <div class="avue-crud__dialog__menu" @click="dialogFull? dialogFull=false: dialogFull=true">
 | 
											
												
													
														|  | 
 |  | +            <svg-icon v-if="dialogFull" icon-class="exit-fullscreen" />
 | 
											
												
													
														|  | 
 |  | +            <svg-icon v-else icon-class="fullscreen" />
 | 
											
												
													
														|  | 
 |  | +          </div>
 | 
											
												
													
														|  | 
 |  | +        </div>
 | 
											
												
													
														|  | 
 |  | +      </template>
 | 
											
												
													
														|  | 
 |  | +      <div class="app-add">
 | 
											
												
													
														|  | 
 |  | +        <el-form ref="temp" :rules="create2.rules" :model="create2.temp" label-position="right" label-width="155px" style="width: 100%;margin:0 auto 50px">
 | 
											
												
													
														|  | 
 |  | +        
 | 
											
												
													
														|  | 
 |  | +          <el-row>
 | 
											
												
													
														|  | 
 |  | +              <el-col :span="6">
 | 
											
												
													
														|  | 
 |  | +              <el-form-item label="允许误差时间(分钟):" prop="time">
 | 
											
												
													
														|  | 
 |  | +                <el-input ref="time" v-model="create2.temp.time" class="filter-item" placeholder="请输入" type="text" />
 | 
											
												
													
														|  | 
 |  | +              </el-form-item>
 | 
											
												
													
														|  | 
 |  | +            </el-col>
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +          </el-row>
 | 
											
												
													
														|  | 
 |  | +           
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +        
 | 
											
												
													
														|  | 
 |  | +        </el-form>
 | 
											
												
													
														|  | 
 |  | +        <div slot="footer" class="dialog-footer">
 | 
											
												
													
														|  | 
 |  | +          <el-button class="cancelClose" @click="create2.dialogFormVisible = false;getList()">关闭</el-button>
 | 
											
												
													
														|  | 
 |  | +          <el-button class="save"  @click="handleCreate2">确认</el-button>
 | 
											
												
													
														|  |          </div>
 |  |          </div>
 | 
											
												
													
														|  |        </div>
 |  |        </div>
 | 
											
												
													
														|  |      </el-dialog>
 |  |      </el-dialog>
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +   <!-- 校验 -->
 | 
											
												
													
														|  | 
 |  | +    <el-dialog title="提示" :destroy-on-close="true" :visible.sync="check.dialogFormVisible" :close-on-click-modal="false" width="30%">
 | 
											
												
													
														|  | 
 |  | +      <div class="check">
 | 
											
												
													
														|  | 
 |  | +        <p v-if="check.temp.isDistribution == '0'">当前有栏舍未分配,建议及时进行分配,未分配栏舍如下:</p>
 | 
											
												
													
														|  | 
 |  | +        <p v-else>已分配完:当前栏舍已分配完善</p>
 | 
											
												
													
														|  | 
 |  | +        {{ check.temp.bnames }}
 | 
											
												
													
														|  | 
 |  | +      </div>
 | 
											
												
													
														|  | 
 |  | +      <div slot="footer" class="dialog-footer" style="bottom: 10px;">
 | 
											
												
													
														|  | 
 |  | +        <el-button class="save" @click="check.dialogFormVisible=false;">确认</el-button>
 | 
											
												
													
														|  | 
 |  | +      </div>
 | 
											
												
													
														|  | 
 |  | +    </el-dialog>
 | 
											
												
													
														|  | 
 |  | +    
 | 
											
												
													
														|  |   
 |  |   
 | 
											
												
													
														|  |      
 |  |      
 | 
											
												
													
														|  |    </div>
 |  |    </div>
 | 
											
										
											
												
													
														|  | @@ -166,97 +214,76 @@ export default {
 | 
											
												
													
														|  |          total: 0,
 |  |          total: 0,
 | 
											
												
													
														|  |          listLoading: true,
 |  |          listLoading: true,
 | 
											
												
													
														|  |          temp: {},
 |  |          temp: {},
 | 
											
												
													
														|  | -        rwList: [],
 |  | 
 | 
											
												
													
														|  | -        isPtsfname: false, // 补料配方/补料重量
 |  | 
 | 
											
												
													
														|  | -        getdataListParm2: {
 |  | 
 | 
											
												
													
														|  | -          name: 'getSysoptEnable',
 |  | 
 | 
											
												
													
														|  | -          page: 1,
 |  | 
 | 
											
												
													
														|  | -          offset: 1,
 |  | 
 | 
											
												
													
														|  | -          pagecount: 1,
 |  | 
 | 
											
												
													
														|  | -          returntype: 'Map',
 |  | 
 | 
											
												
													
														|  | -          parammaps: {
 |  | 
 | 
											
												
													
														|  | -            pastureid: Cookies.get('pastureid'),
 |  | 
 | 
											
												
													
														|  | -            inforname: 'isEnableSupplyFeed'
 |  | 
 | 
											
												
													
														|  | -          }
 |  | 
 | 
											
												
													
														|  | -        },
 |  | 
 | 
											
												
													
														|  | -        
 |  | 
 | 
											
												
													
														|  | -        getdataListParm3: {
 |  | 
 | 
											
												
													
														|  | -          name: 'getSysoptEnable1',
 |  | 
 | 
											
												
													
														|  | 
 |  | +  
 | 
											
												
													
														|  | 
 |  | + 
 | 
											
												
													
														|  | 
 |  | +      },
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +      create1: {
 | 
											
												
													
														|  | 
 |  | +        dialogFormVisible: false,
 | 
											
												
													
														|  | 
 |  | +        dialogStatus: '',
 | 
											
												
													
														|  | 
 |  | +        temp: { pastureid: Cookies.get('pastureid'), fname: ''},
 | 
											
												
													
														|  | 
 |  | +        rules: {
 | 
											
												
													
														|  | 
 |  | +          // fname: [{ type: 'string', required: true, message: '必填', trigger: 'blur' }],
 | 
											
												
													
														|  | 
 |  | +          // fclassid: [{ type: 'string', required: true, message: '必填', trigger: 'blur' }],
 | 
											
												
													
														|  | 
 |  | +          // feedcode: [{ type: 'string', required: true, message: '必填', trigger: 'blur' }]
 | 
											
												
													
														|  | 
 |  | +        }
 | 
											
												
													
														|  | 
 |  | +      },
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +      create2: {
 | 
											
												
													
														|  | 
 |  | +        dialogFormVisible: false,
 | 
											
												
													
														|  | 
 |  | +        dialogStatus: '',
 | 
											
												
													
														|  | 
 |  | +        temp: { pastureid: Cookies.get('pastureid'), time: ''},
 | 
											
												
													
														|  | 
 |  | +        rules: {
 | 
											
												
													
														|  | 
 |  | +          // fname: [{ type: 'string', required: true, message: '必填', trigger: 'blur' }],
 | 
											
												
													
														|  | 
 |  | +          // fclassid: [{ type: 'string', required: true, message: '必填', trigger: 'blur' }],
 | 
											
												
													
														|  | 
 |  | +          // feedcode: [{ type: 'string', required: true, message: '必填', trigger: 'blur' }]
 | 
											
												
													
														|  | 
 |  | +        }
 | 
											
												
													
														|  | 
 |  | +      },
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +      check: {
 | 
											
												
													
														|  | 
 |  | +        dialogFormVisible: false,
 | 
											
												
													
														|  | 
 |  | +        dialogStatus: '',
 | 
											
												
													
														|  | 
 |  | +        getCheckParm: {
 | 
											
												
													
														|  | 
 |  | +          name: 'checkRemainplan',
 | 
											
												
													
														|  |            page: 1,
 |  |            page: 1,
 | 
											
												
													
														|  |            offset: 1,
 |  |            offset: 1,
 | 
											
												
													
														|  | -          pagecount: 1,
 |  | 
 | 
											
												
													
														|  | 
 |  | +          pagecount: 10,
 | 
											
												
													
														|  |            returntype: 'Map',
 |  |            returntype: 'Map',
 | 
											
												
													
														|  |            parammaps: {
 |  |            parammaps: {
 | 
											
												
													
														|  | -            pastureid: Cookies.get('pastureid'),
 |  | 
 | 
											
												
													
														|  | -            inforname: 'times'
 |  | 
 | 
											
												
													
														|  | 
 |  | +            pastureid: Cookies.get('pastureid')
 | 
											
												
													
														|  |            }
 |  |            }
 | 
											
												
													
														|  |          },
 |  |          },
 | 
											
												
													
														|  | -        RWLength: '' // 班次长度
 |  | 
 | 
											
												
													
														|  | 
 |  | +        temp: {
 | 
											
												
													
														|  | 
 |  | +          bnames: '',
 | 
											
												
													
														|  | 
 |  | +          isDistribution: ''
 | 
											
												
													
														|  | 
 |  | +        }
 | 
											
												
													
														|  |        },
 |  |        },
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  | -      value1: new Date(2016, 9, 10, 18, 40),
 |  | 
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +      timevalue1: new Date(2022, 9, 10, 18, 40),
 | 
											
												
													
														|  | 
 |  | +      timetags1: [],
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  |        dialogFull: false,
 |  |        dialogFull: false,
 | 
											
												
													
														|  |        isRoleEdit: [],
 |  |        isRoleEdit: [],
 | 
											
												
													
														|  |        headerList: [],
 |  |        headerList: [],
 | 
											
												
													
														|  |        pickerMinDate: '',
 |  |        pickerMinDate: '',
 | 
											
												
													
														|  | -      pickerOptions: {
 |  | 
 | 
											
												
													
														|  | -        onPick: ({ maxDate, minDate }) => {
 |  | 
 | 
											
												
													
														|  | -          this.pickerMinDate = minDate.getTime()
 |  | 
 | 
											
												
													
														|  | -          if (maxDate) {
 |  | 
 | 
											
												
													
														|  | -            this.pickerMinDate = ''
 |  | 
 | 
											
												
													
														|  | -          }
 |  | 
 | 
											
												
													
														|  | -        },
 |  | 
 | 
											
												
													
														|  | -        // 限制不能选择今天之后的日期
 |  | 
 | 
											
												
													
														|  | -        disabledDate: (time) => {
 |  | 
 | 
											
												
													
														|  | -          if (this.pickerMinDate !== '') {
 |  | 
 | 
											
												
													
														|  | -            const one = 31 * 24 * 3600 * 1000
 |  | 
 | 
											
												
													
														|  | -            const minTime = this.pickerMinDate - one
 |  | 
 | 
											
												
													
														|  | -            let maxTime = this.pickerMinDate + one
 |  | 
 | 
											
												
													
														|  | -            if (maxTime > new Date()) {
 |  | 
 | 
											
												
													
														|  | -              maxTime = new Date()
 |  | 
 | 
											
												
													
														|  | -            }
 |  | 
 | 
											
												
													
														|  | -            return time.getTime() < minTime - 8.64e7 || time.getTime() > maxTime - 8.64e7
 |  | 
 | 
											
												
													
														|  | -          }
 |  | 
 | 
											
												
													
														|  | -          return time.getTime() > Date.now() - 8.64e7
 |  | 
 | 
											
												
													
														|  | -        }
 |  | 
 | 
											
												
													
														|  | -      },
 |  | 
 | 
											
												
													
														|  | -      requestParams: [
 |  | 
 | 
											
												
													
														|  | -        { name: 'getFTSWLSList', offset: 0, pagecount: 0, parammaps: { pastureid: Cookies.get('pastureid') }},
 |  | 
 | 
											
												
													
														|  | -        { name: 'getFTBLList', offset: 0, pagecount: 0, parammaps: { pastureid: Cookies.get('pastureid') }},
 |  | 
 | 
											
												
													
														|  | -        { name: 'getCowclassListEnable', offset: 0, pagecount: 0, parammaps: { pastureid: Cookies.get('pastureid') }},
 |  | 
 | 
											
												
													
														|  | -        { name: 'getBarListEnable', offset: 0, pagecount: 0, parammaps: { pastureid: Cookies.get('pastureid') }}
 |  | 
 | 
											
												
													
														|  | -      ],
 |  | 
 | 
											
												
													
														|  | -      getFeedTempletNameListParm: {
 |  | 
 | 
											
												
													
														|  | -        name: 'getFeedTempletName',
 |  | 
 | 
											
												
													
														|  | -        page: 1,
 |  | 
 | 
											
												
													
														|  | -        offset: 1,
 |  | 
 | 
											
												
													
														|  | -        // pagecount: parseInt(Cookies.get('pageCount')),
 |  | 
 | 
											
												
													
														|  | -        pagecount: '',
 |  | 
 | 
											
												
													
														|  | -        returntype: 'Map',
 |  | 
 | 
											
												
													
														|  | -        parammaps: {}
 |  | 
 | 
											
												
													
														|  | -      },
 |  | 
 | 
											
												
													
														|  | -      tnameList: [], // 配方名 称
 |  | 
 | 
											
												
													
														|  | -      recipeTemplateList: [], // 配方模板
 |  | 
 | 
											
												
													
														|  | -      feedingFormulaList: [], // 补料配方
 |  | 
 | 
											
												
													
														|  | -      livestockTypeList: [], // 类别
 |  | 
 | 
											
												
													
														|  | -      barList: [],
 |  | 
 | 
											
												
													
														|  | 
 |  | + 
 | 
											
												
													
														|  | 
 |  | +   
 | 
											
												
													
														|  |        rules: {
 |  |        rules: {
 | 
											
												
													
														|  |          cowclassid: [{ type: 'string', required: true, message: '必填', trigger: 'blur' }]
 |  |          cowclassid: [{ type: 'string', required: true, message: '必填', trigger: 'blur' }]
 | 
											
												
													
														|  |        },
 |  |        },
 | 
											
												
													
														|  |        
 |  |        
 | 
											
												
													
														|  |        selectList: [],
 |  |        selectList: [],
 | 
											
												
													
														|  |     
 |  |     
 | 
											
												
													
														|  | -     
 |  | 
 | 
											
												
													
														|  | -      textMap: {
 |  | 
 | 
											
												
													
														|  | -        Nutritional: '营养评估',
 |  | 
 | 
											
												
													
														|  | -        history: '历史记录'
 |  | 
 | 
											
												
													
														|  | -      },
 |  | 
 | 
											
												
													
														|  | -      focusWRow: {}, // 一班重量得到焦点暂存
 |  | 
 | 
											
												
													
														|  | -      focusWRow2: {}, // 2班重量得到焦点暂存
 |  | 
 | 
											
												
													
														|  | -      focusWRow3: {}, // 3班重量得到焦点暂存
 |  | 
 | 
											
												
													
														|  | -      focusWRow4: {}, // 4班重量得到焦点暂存
 |  | 
 | 
											
												
													
														|  | 
 |  | +   
 | 
											
												
													
														|  | 
 |  | +       
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |        requestParam: {},
 |  |        requestParam: {},
 | 
											
												
													
														|  |        download: {
 |  |        download: {
 | 
											
										
											
												
													
														|  | @@ -283,16 +310,7 @@ export default {
 | 
											
												
													
														|  |        oldRowList:{},
 |  |        oldRowList:{},
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  | -      create1: {
 |  | 
 | 
											
												
													
														|  | -        dialogFormVisible: false,
 |  | 
 | 
											
												
													
														|  | -        dialogStatus: '',
 |  | 
 | 
											
												
													
														|  | -        temp: { pastureid: Cookies.get('pastureid'), fname: '', fclassid: '', fclass: '', feedcode: '', source: '用户自定义', printgroupid: '1', printgroup: '无', unitweight: '', uprice: '', allowratio: '', autozone: '', autosecond: '0', autosecondname: '禁用', confirmstart: '0', confirmstartname: '禁用', enable: '1', trgaddress: '', backup1: '', backup2: '', backup3: '', sort: '' },
 |  | 
 | 
											
												
													
														|  | -        rules: {
 |  | 
 | 
											
												
													
														|  | -          // fname: [{ type: 'string', required: true, message: '必填', trigger: 'blur' }],
 |  | 
 | 
											
												
													
														|  | -          // fclassid: [{ type: 'string', required: true, message: '必填', trigger: 'blur' }],
 |  | 
 | 
											
												
													
														|  | -          // feedcode: [{ type: 'string', required: true, message: '必填', trigger: 'blur' }]
 |  | 
 | 
											
												
													
														|  | -        }
 |  | 
 | 
											
												
													
														|  | -      },
 |  | 
 | 
											
												
													
														|  | 
 |  | +      
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |  
 |  |  
 | 
											
										
											
												
													
														|  | @@ -314,6 +332,16 @@ export default {
 | 
											
												
													
														|  |        const isRoleEdit = checkButtons(JSON.parse(sessionStorage.getItem('buttons')), Edit)
 |  |        const isRoleEdit = checkButtons(JSON.parse(sessionStorage.getItem('buttons')), Edit)
 | 
											
												
													
														|  |        this.isRoleEdit = isRoleEdit
 |  |        this.isRoleEdit = isRoleEdit
 | 
											
												
													
														|  |      },
 |  |      },
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    getTimeList() {
 | 
											
												
													
														|  | 
 |  | +      GetDataByName(this.getTimeListParm).then(response => {
 | 
											
												
													
														|  | 
 |  | +        if (response.data.list !== null) {
 | 
											
												
													
														|  | 
 |  | +          this.timeList = response.data.list
 | 
											
												
													
														|  | 
 |  | +        } else {
 | 
											
												
													
														|  | 
 |  | +          this.timeList = []
 | 
											
												
													
														|  | 
 |  | +        }
 | 
											
												
													
														|  | 
 |  | +      })
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  |       
 |  |       
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |       // 新增
 |  |       // 新增
 | 
											
										
											
												
													
														|  | @@ -328,6 +356,17 @@ export default {
 | 
											
												
													
														|  |        this.create1.temp = { pastureid: Cookies.get('pastureid'), 'myId': (new Date()).valueOf(), 'Edit': true, 'NoEdit': false, 'isCreate': true, 'isUpdate': false, 'isUpdateSave': false, 'enable': 1, 'sort': "", 'ftid': '', 'ftname': '', 'tmrcode': '', 'tmrid': '', 'times': '', 'lppcode': '', 'lppid': '', 'rtime': '', barid: '', 'treatmethod': '', 'useinbar': '', 'useinbarid': '' }
 |  |        this.create1.temp = { pastureid: Cookies.get('pastureid'), 'myId': (new Date()).valueOf(), 'Edit': true, 'NoEdit': false, 'isCreate': true, 'isUpdate': false, 'isUpdateSave': false, 'enable': 1, 'sort': "", 'ftid': '', 'ftname': '', 'tmrcode': '', 'tmrid': '', 'times': '', 'lppcode': '', 'lppid': '', 'rtime': '', barid: '', 'treatmethod': '', 'useinbar': '', 'useinbarid': '' }
 | 
											
												
													
														|  |      },
 |  |      },
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  | 
 |  | +    handleCreate2() {
 | 
											
												
													
														|  | 
 |  | +      console.log('点击了新增')
 | 
											
												
													
														|  | 
 |  | +      this.resetTemp2()
 | 
											
												
													
														|  | 
 |  | +      this.dialogFull = false
 | 
											
												
													
														|  | 
 |  | +      this.create2.dialogStatus = 'create'
 | 
											
												
													
														|  | 
 |  | +      this.create2.dialogFormVisible = true
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  | 
 |  | +     resetTemp2() {
 | 
											
												
													
														|  | 
 |  | +      this.create2.temp = { pastureid: Cookies.get('pastureid'), 'myId': (new Date()).valueOf(), 'Edit': true, 'NoEdit': false, 'isCreate': true, 'isUpdate': false, 'isUpdateSave': false, 'enable': 1, 'sort': "", 'ftid': '', 'ftname': '', 'tmrcode': '', 'tmrid': '', 'times': '', 'lppcode': '', 'lppid': '', 'rtime': '', barid: '', 'treatmethod': '', 'useinbar': '', 'useinbarid': '' }
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |   
 |  |   
 | 
											
										
											
												
													
														|  | @@ -361,6 +400,119 @@ export default {
 | 
											
												
													
														|  |      handleSearch() {
 |  |      handleSearch() {
 | 
											
												
													
														|  |        this.getList()
 |  |        this.getList()
 | 
											
												
													
														|  |      },
 |  |      },
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    change_time1(tag){
 | 
											
												
													
														|  | 
 |  | +      console.log("tag", tag)
 | 
											
												
													
														|  | 
 |  | +        console.log("timetags1", this.timetags1)
 | 
											
												
													
														|  | 
 |  | +  
 | 
											
												
													
														|  | 
 |  | +     this.timetags1.push(tag)
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    tag_close1(tag){
 | 
											
												
													
														|  | 
 |  | +        console.log("tag", tag)
 | 
											
												
													
														|  | 
 |  | +        console.log("timetags1", this.timetags1)
 | 
											
												
													
														|  | 
 |  | +        this.timetags1.splice(this.timetags1.indexOf(tag), 1);
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    // 校验
 | 
											
												
													
														|  | 
 |  | +    handleCheck() {
 | 
											
												
													
														|  | 
 |  | +      console.log('点击了校验')
 | 
											
												
													
														|  | 
 |  | +      this.check.dialogStatus = 'check'
 | 
											
												
													
														|  | 
 |  | +      this.check.dialogFormVisible = true
 | 
											
												
													
														|  | 
 |  | +      this.getCheckList()
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  | 
 |  | +    getCheckList() {
 | 
											
												
													
														|  | 
 |  | +      GetDataByName(this.check.getCheckParm).then(response => {
 | 
											
												
													
														|  | 
 |  | +        if (response.data.list[0].bnames !== undefined) {
 | 
											
												
													
														|  | 
 |  | +          this.check.temp.isDistribution = 0
 | 
											
												
													
														|  | 
 |  | +          this.check.temp.bnames = response.data.list[0].bnames
 | 
											
												
													
														|  | 
 |  | +        } else {
 | 
											
												
													
														|  | 
 |  | +          this.check.temp = {}
 | 
											
												
													
														|  | 
 |  | +          this.check.temp.isDistribution = 1
 | 
											
												
													
														|  | 
 |  | +        }
 | 
											
												
													
														|  | 
 |  | +      })
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    handleTakeEffect() {
 | 
											
												
													
														|  | 
 |  | +      if (this.selectList.length == 0) {
 | 
											
												
													
														|  | 
 |  | +        this.$message({ type: 'error', message: '请选择车次信息', duration: 2000 })
 | 
											
												
													
														|  | 
 |  | +      } else {
 | 
											
												
													
														|  | 
 |  | +        MessageBox.confirm('当前选中' + this.selectList.length + '条信息,是否生效?', {
 | 
											
												
													
														|  | 
 |  | +          confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning'
 | 
											
												
													
														|  | 
 |  | +        }).then(() => {
 | 
											
												
													
														|  | 
 |  | +          for (let i = 0; i < this.selectList.length; i++) {
 | 
											
												
													
														|  | 
 |  | +            // this.$set(this.selectList[i], 'enable', '1')
 | 
											
												
													
														|  | 
 |  | +            this.selectList[i].enable = 1
 | 
											
												
													
														|  | 
 |  | +          }
 | 
											
												
													
														|  | 
 |  | +          console.log('生效', this.selectList)
 | 
											
												
													
														|  | 
 |  | +          this.requestParam.common = { 'returnmap': '0' }
 | 
											
												
													
														|  | 
 |  | +          this.requestParam.data = []
 | 
											
												
													
														|  | 
 |  | +          this.requestParam.data[0] = { 'name': 'insertSpotList', 'resultmaps': { 'list': this.selectList }}
 | 
											
												
													
														|  | 
 |  | +          this.requestParam.data[0].children = []
 | 
											
												
													
														|  | 
 |  | +          this.requestParam.data[0].children[0] = { 'name': 'updateRemainplanEnable', 'type': 'e', 'parammaps': {
 | 
											
												
													
														|  | 
 |  | +            enable: '@insertSpotList.enable',
 | 
											
												
													
														|  | 
 |  | +            id: '@insertSpotList.id',
 | 
											
												
													
														|  | 
 |  | +            pastureid: '@insertSpotList.pastureid'
 | 
											
												
													
														|  | 
 |  | +          }}
 | 
											
												
													
														|  | 
 |  | +          ExecDataByConfig(this.requestParam).then(response => {
 | 
											
												
													
														|  | 
 |  | +            console.log('生效保存发送参数', this.requestParam)
 | 
											
												
													
														|  | 
 |  | +            if (response.msg === 'fail') {
 | 
											
												
													
														|  | 
 |  | +              this.$notify({ title: '生效失败', message: response.data, type: 'warning', duration: 2000 })
 | 
											
												
													
														|  | 
 |  | +            } else {
 | 
											
												
													
														|  | 
 |  | +              this.$notify({ title: '', message: '生效成功', type: 'success', duration: 2000 })
 | 
											
												
													
														|  | 
 |  | +              this.getList()
 | 
											
												
													
														|  | 
 |  | +            }
 | 
											
												
													
														|  | 
 |  | +          })
 | 
											
												
													
														|  | 
 |  | +        })
 | 
											
												
													
														|  | 
 |  | +      }
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  | 
 |  | +    handleDisable() {
 | 
											
												
													
														|  | 
 |  | +      if (this.selectList.length == 0) {
 | 
											
												
													
														|  | 
 |  | +        this.$message({ type: 'error', message: '请选择车次信息', duration: 2000 })
 | 
											
												
													
														|  | 
 |  | +      } else {
 | 
											
												
													
														|  | 
 |  | +        MessageBox.confirm('当前选中' + this.selectList.length + '条信息,是否禁用?', {
 | 
											
												
													
														|  | 
 |  | +          confirmButtonText: '确认', cancelButtonText: '取消', type: 'warning'
 | 
											
												
													
														|  | 
 |  | +        }).then(() => {
 | 
											
												
													
														|  | 
 |  | +          for (let i = 0; i < this.selectList.length; i++) {
 | 
											
												
													
														|  | 
 |  | +            // this.$set(this.selectList[i], 'enable', '1')
 | 
											
												
													
														|  | 
 |  | +            this.selectList[i].enable = 0
 | 
											
												
													
														|  | 
 |  | +          }
 | 
											
												
													
														|  | 
 |  | +          console.log('禁用', this.selectList)
 | 
											
												
													
														|  | 
 |  | +          this.requestParam.common = { 'returnmap': '0' }
 | 
											
												
													
														|  | 
 |  | +          this.requestParam.data = []
 | 
											
												
													
														|  | 
 |  | +          this.requestParam.data[0] = { 'name': 'insertSpotList', 'resultmaps': { 'list': this.selectList }}
 | 
											
												
													
														|  | 
 |  | +          this.requestParam.data[0].children = []
 | 
											
												
													
														|  | 
 |  | +          this.requestParam.data[0].children[0] = { 'name': 'updateRemainplanEnable', 'type': 'e', 'parammaps': {
 | 
											
												
													
														|  | 
 |  | +            enable: '@insertSpotList.enable',
 | 
											
												
													
														|  | 
 |  | +            id: '@insertSpotList.id',
 | 
											
												
													
														|  | 
 |  | +            pastureid: '@insertSpotList.pastureid'
 | 
											
												
													
														|  | 
 |  | +          }}
 | 
											
												
													
														|  | 
 |  | +          ExecDataByConfig(this.requestParam).then(response => {
 | 
											
												
													
														|  | 
 |  | +            console.log('禁用保存发送参数', this.requestParam)
 | 
											
												
													
														|  | 
 |  | +            if (response.msg === 'fail') {
 | 
											
												
													
														|  | 
 |  | +              this.$notify({ title: '禁用失败', message: response.data, type: 'warning', duration: 2000 })
 | 
											
												
													
														|  | 
 |  | +            } else {
 | 
											
												
													
														|  | 
 |  | +              this.$notify({ title: '', message: '禁用成功', type: 'success', duration: 2000 })
 | 
											
												
													
														|  | 
 |  | +              this.getList()
 | 
											
												
													
														|  | 
 |  | +            }
 | 
											
												
													
														|  | 
 |  | +          })
 | 
											
												
													
														|  | 
 |  | +        })
 | 
											
												
													
														|  | 
 |  | +      }
 | 
											
												
													
														|  | 
 |  | +    },
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  |      renderHeader(h, { column, $index }) { // h即为cerateElement的简写,具体可看vue官方文档
 |  |      renderHeader(h, { column, $index }) { // h即为cerateElement的简写,具体可看vue官方文档
 | 
											
												
													
														|  |        return h(
 |  |        return h(
 | 
											
												
													
														|  |          'div',
 |  |          'div',
 | 
											
										
											
												
													
														|  | @@ -378,20 +530,7 @@ export default {
 | 
											
												
													
														|  |      headerClick(column, event) {
 |  |      headerClick(column, event) {
 | 
											
												
													
														|  |        console.log(column, event)
 |  |        console.log(column, event)
 | 
											
												
													
														|  |        this.headerList.push(event)
 |  |        this.headerList.push(event)
 | 
											
												
													
														|  | -      if (column.label == '第一班重量') {
 |  | 
 | 
											
												
													
														|  | -        for (let i = 0; i < this.table.list.length; i++) {
 |  | 
 | 
											
												
													
														|  | -          if (this.table.list[i].Edit == true) {
 |  | 
 | 
											
												
													
														|  | -            if (event.target.outerHTML == '<i class="el-icon-unlock" style="margin-left: 5px;"></i>') {
 |  | 
 | 
											
												
													
														|  | -              event.target.className = 'el-icon-lock'
 |  | 
 | 
											
												
													
														|  | -              this.$set(this.table.list[i], 'isOneWeight', true) // 锁住不可编辑
 |  | 
 | 
											
												
													
														|  | -            } else if (event.target.outerHTML == '<i class="el-icon-lock" style="margin-left: 5px;"></i>') {
 |  | 
 | 
											
												
													
														|  | -              event.target.className = 'el-icon-unlock'
 |  | 
 | 
											
												
													
														|  | -              this.$set(this.table.list[i], 'isOneWeight', false) // 解锁可编辑
 |  | 
 | 
											
												
													
														|  | -            }
 |  | 
 | 
											
												
													
														|  | -          }
 |  | 
 | 
											
												
													
														|  | -        }
 |  | 
 | 
											
												
													
														|  | -      } else if (column.label == '第二班重量') {
 |  | 
 | 
											
												
													
														|  | -        for (let i = 0; i < this.table.list.length; i++) {
 |  | 
 | 
											
												
													
														|  | 
 |  | +      for (let i = 0; i < this.table.list.length; i++) {
 | 
											
												
													
														|  |            if (this.table.list[i].Edit == true) {
 |  |            if (this.table.list[i].Edit == true) {
 | 
											
												
													
														|  |              if (event.target.outerHTML == '<i class="el-icon-unlock" style="margin-left: 5px;"></i>') {
 |  |              if (event.target.outerHTML == '<i class="el-icon-unlock" style="margin-left: 5px;"></i>') {
 | 
											
												
													
														|  |                event.target.className = 'el-icon-lock'
 |  |                event.target.className = 'el-icon-lock'
 | 
											
										
											
												
													
														|  | @@ -402,31 +541,6 @@ export default {
 | 
											
												
													
														|  |              }
 |  |              }
 | 
											
												
													
														|  |            }
 |  |            }
 | 
											
												
													
														|  |          }
 |  |          }
 | 
											
												
													
														|  | -      } else if (column.label == '第三班重量') {
 |  | 
 | 
											
												
													
														|  | -        for (let i = 0; i < this.table.list.length; i++) {
 |  | 
 | 
											
												
													
														|  | -          if (this.table.list[i].Edit == true) {
 |  | 
 | 
											
												
													
														|  | -            if (event.target.outerHTML == '<i class="el-icon-unlock" style="margin-left: 5px;"></i>') {
 |  | 
 | 
											
												
													
														|  | -              event.target.className = 'el-icon-lock'
 |  | 
 | 
											
												
													
														|  | -              this.$set(this.table.list[i], 'isThreeWeight', true) // 锁住不可编辑
 |  | 
 | 
											
												
													
														|  | -            } else if (event.target.outerHTML == '<i class="el-icon-lock" style="margin-left: 5px;"></i>') {
 |  | 
 | 
											
												
													
														|  | -              event.target.className = 'el-icon-unlock'
 |  | 
 | 
											
												
													
														|  | -              this.$set(this.table.list[i], 'isThreeWeight', false) // 解锁可编辑
 |  | 
 | 
											
												
													
														|  | -            }
 |  | 
 | 
											
												
													
														|  | -          }
 |  | 
 | 
											
												
													
														|  | -        }
 |  | 
 | 
											
												
													
														|  | -      } else if (column.label == '第四班重量') {
 |  | 
 | 
											
												
													
														|  | -        for (let i = 0; i < this.table.list.length; i++) {
 |  | 
 | 
											
												
													
														|  | -          if (this.table.list[i].Edit == true) {
 |  | 
 | 
											
												
													
														|  | -            if (event.target.outerHTML == '<i class="el-icon-unlock" style="margin-left: 5px;"></i>') {
 |  | 
 | 
											
												
													
														|  | -              event.target.className = 'el-icon-lock'
 |  | 
 | 
											
												
													
														|  | -              this.$set(this.table.list[i], 'isFourWeight', true) // 锁住不可编辑
 |  | 
 | 
											
												
													
														|  | -            } else if (event.target.outerHTML == '<i class="el-icon-lock" style="margin-left: 5px;"></i>') {
 |  | 
 | 
											
												
													
														|  | -              event.target.className = 'el-icon-unlock'
 |  | 
 | 
											
												
													
														|  | -              this.$set(this.table.list[i], 'isFourWeight', false) // 解锁可编辑
 |  | 
 | 
											
												
													
														|  | -            }
 |  | 
 | 
											
												
													
														|  | -          }
 |  | 
 | 
											
												
													
														|  | -        }
 |  | 
 | 
											
												
													
														|  | -      }
 |  | 
 | 
											
												
													
														|  |      },
 |  |      },
 | 
											
												
													
														|  |   
 |  |   
 | 
											
												
													
														|  |   
 |  |   
 | 
											
										
											
												
													
														|  | @@ -538,14 +652,7 @@ export default {
 | 
											
												
													
														|  |        
 |  |        
 | 
											
												
													
														|  |        console.log(row, '===========')
 |  |        console.log(row, '===========')
 | 
											
												
													
														|  |        this.table.temp.softccount = row.softccount
 |  |        this.table.temp.softccount = row.softccount
 | 
											
												
													
														|  | -      this.table.temp.r1 = Math.round(row.r1)
 |  | 
 | 
											
												
													
														|  | -      this.table.temp.r2 = Math.round(row.r2)
 |  | 
 | 
											
												
													
														|  | -      this.table.temp.r3 = Math.round(row.r3)
 |  | 
 | 
											
												
													
														|  | -      this.table.temp.r4 = Math.round(row.r4)
 |  | 
 | 
											
												
													
														|  | -      this.table.temp.w1 = row.w1
 |  | 
 | 
											
												
													
														|  | -      this.table.temp.w2 = row.w2
 |  | 
 | 
											
												
													
														|  | -      this.table.temp.w3 = row.w3
 |  | 
 | 
											
												
													
														|  | -      this.table.temp.w4 = row.w4
 |  | 
 | 
											
												
													
														|  | 
 |  | +   
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |        var obj = {}
 |  |        var obj = {}
 | 
											
												
													
														|  |        obj.pastureid = row.pastureid
 |  |        obj.pastureid = row.pastureid
 |