1
0
panhui 7 rokov pred
rodič
commit
131c2165bb

+ 8 - 14
src/main/vue/src/entries/admin.js

@@ -103,9 +103,6 @@ Vue.prototype.$http = {
             reject('url error');
             return;
         }
-        // if (!/^(http:\/\/)|(https:\/\/)/.test(params.url)) {
-        //     params.url = baseUrl + params.url;
-        // }
         let data = new FormData();
         if (params.data) {
             for (let key in params.data) {
@@ -249,22 +246,16 @@ Vue.prototype.JsonSort = function(list, jsonp, hasNot) {
                 return list.indexOf(a) - list.indexOf(b)
             }
         })
-
         var returnJson = {}
         needList.forEach(item => {
             returnJson[item] = jsonp[item]
 
         })
-
-        // console.log(needList)
-
-
-
         return returnJson
 
     }
     //获取牛只信息
-Vue.prototype.getCowInfo = function(cowID, type, isBack) {
+Vue.prototype.getCowInfo = function(cowID, type, isBack, returnFalse) {
 
     return new Promise((resolve, reject) => {
         if (cowID.length != 8) {
@@ -280,10 +271,13 @@ Vue.prototype.getCowInfo = function(cowID, type, isBack) {
                 if (isBack) {
                     resolve()
                 } else {
-                    this.$message({
-                        message: '当前牛只信息不存在',
-                        type: 'warning'
-                    });
+                    if (!returnFalse) {
+                        this.$message({
+                            message: '当前牛只信息不存在',
+                            type: 'warning'
+                        });
+                    }
+
                     reject(new Error())
                 }
 

+ 257 - 0
src/main/vue/src/pages/HandleApproach.vue

@@ -0,0 +1,257 @@
+<template>
+  <el-container style="flex-grow:1">
+    <el-main class="containMain">
+      <div class="contentTitle">进场登记</div>
+      <div :style="{height:(allHeight-140)+'px'}">
+        <el-form ref="form" :model="formData" label-width="80px" style="margin-top:20px;">
+          <el-form-item label label-width="0">
+            <el-input v-model="formData.cowID" prefix-icon="el-icon-search" style="width:300px" maxlength="8"></el-input>
+            <el-button type="primary" @click="getNowCow" style="width:90px;margin-left:12px">确认</el-button>
+          </el-form-item>
+          <div class="sub" v-if="formData.cowID.length==8">操作牛号:{{formData.cowID}}</div>
+          <el-form-item label="耳号">
+            <el-input v-model="formData.earNO" style="width:200px" maxlength="8" placeholder="请输入耳号"></el-input>
+          </el-form-item>
+          <el-form-item label="性别">
+            <el-select v-model="formData.sex" style="width:76px" placeholder="请选择性别">
+              <el-option v-for="item in sexList" :key="item.val" :label="item.title" :value="item.val"></el-option>
+            </el-select>
+          </el-form-item>
+          <el-form-item label="当前牧场">
+            <el-input v-model="formData.currFarm" disabled style="width:110px" maxlength="8" placeholder="请输入牧场"></el-input>
+          </el-form-item>
+          <el-form-item label="当前牛舍">
+            <el-select v-model="formData.currGroup" style="width:110px" placeholder="请选择">
+              <el-option v-for="item in cowShedList" :key="item['牛舍编号']" :label="item['牛舍编号']" :value="item['牛舍编号']"></el-option>
+            </el-select>
+          </el-form-item>
+          <el-form-item label="进场日期">
+            <el-date-picker v-model="formData.enterDate" style="width:200px" type="date" placeholder="选择进场日期"></el-date-picker>
+          </el-form-item>
+          <el-form-item label="当前胎次">
+            <el-input v-model="formData.currLact" style="width:110px" maxlength="2" placeholder="请输入当前胎次"></el-input>
+          </el-form-item>
+          <el-form-item label="出生日期">
+            <el-date-picker v-model="formData.birthday" style="width:200px" type="date" placeholder="选择出生日期"></el-date-picker>
+          </el-form-item>
+          <el-form-item label="初生重量">
+            <el-input v-model="formData.bornWeight" style="width:110px" maxlength="3" placeholder="请输入当前胎次"></el-input>
+          </el-form-item>
+          <div style="margin-top:80px">
+            <el-button @click="onSave" type="primary" style="width:98px;" size="mediu">确认保存</el-button>
+          </div>
+        </el-form>
+      </div>
+    </el-main>
+  </el-container>
+</template>
+<script>
+import formValidator from '../formValidator'
+import axios from 'axios'
+import { mapState } from 'vuex'
+export default {
+  created() {
+
+    // this.getHaleInfo('wsCow', 'getUserDict', ['LeftReason'], 'list').then((data) => {
+    //   this.allReason = data
+    //   this.formData.reason = data[0]['类别']
+    // })
+
+
+    //牛舍列表
+    this.getHaleInfo('wsCow', 'getAllGroupByFarmName', [
+      this.$store.state.farmName
+    ], 'list').then((data) => {
+      this.cowShedList = data
+    })
+  },
+  data() {
+    return {
+      cowShedList: [],
+      saving: false,
+      formData: {
+        cowID: this.$store.state.farmNO,
+        earNO: '',
+        sex: true,
+        currFarm: this.$store.state.farmName,
+        currGroup: "",
+        enterDate: this.getTime(Date.parse(new Date()), 'YYYY-MM-DD'),
+        currLact: 0,
+        birthday: "",
+        bornWeight: 30,
+        currCategory: "",
+        color: "",
+        groCode: "",//泌乳状态
+        repCode: "",//繁殖状态
+      },
+      rules: {
+        icon: [
+          { required: true, message: '请上传头像', trigger: 'blur' },
+        ],
+        username: [
+          { required: true, message: '请输入昵称', trigger: 'blur' },
+        ],
+        phone: [
+          { required: true, message: '请输入手机号', trigger: 'blur' },
+          {
+            validator: (rule, value, callback) => {
+              if (!value) {
+                callback(new Error('请输入手机号'));
+              } else if (/^1[3-9]\d{9}$/.test(value)) {
+                callback();
+              } else {
+                callback(new Error('请输入正确的手机号'));
+              }
+            }, trigger: 'blur'
+          }
+        ],
+        password: [
+          { required: true, message: '请输入密码', trigger: 'blur' },
+        ],
+        roleId: [
+          { required: true, message: '请选择角色', trigger: 'blur' },
+        ]
+      },
+      sexList: [{
+        title: '公牛',
+        val: false
+      }, {
+        title: '母牛',
+        val: true
+      }]
+    }
+  },
+  computed: {
+    ...mapState(['userInfo', 'allHeight']),
+    reasons() {
+      var list = []
+      this.allReason.forEach(item => {
+        if (list.indexOf(item['类别']) == -1) {
+          list.push(item['类别'])
+        }
+      })
+      return list
+    },
+
+  },
+  watch: {
+    'formData.cowID'() {
+      if (this.formData.cowID.length == 0) {
+        this.formData.cowID = this.$store.state.farmNO
+      }
+      if (this.formData.cowID.length != 8) {
+        return
+      }
+      this.getNowCow()
+    }
+  },
+  methods: {
+    onSave() {
+      if (!this.formData.cowID) {
+        this.$message({
+          message: '请录入离场牛只牛号',
+          type: 'warning'
+        });
+        return
+      }
+      this.formData.operators = this.userInfo.username
+      var list = []
+      Object.keys(this.formData).forEach(item => {
+        if (item == 'isActive') {
+          list.push(this.formData.isActive == '1' ? true : false)
+        }
+        else {
+          list.push(this.formData[item])
+        }
+
+      })
+      this.getHaleInfo('wsCow', 'addLeftInfo', list, 'json').then((data) => {
+        // console.log(data)
+        if (data.rtnCode == -1) {
+          this.$message({
+            message: data.rtnMessage,
+            type: 'warning'
+          });
+          this.formData.cowID = ''
+        }
+        else {
+          this.$message({
+            message: '离场信息录入成功',
+            type: 'warning'
+          });
+          this.formData.cowID = ''
+        }
+      })
+    },
+    submit() {
+      var data = JSON.parse(JSON.stringify(this.formData));
+      this.$http.post({
+        url: this.formData.id ? '/userInfo/update' : '/userInfo/save',
+        data: data
+      }).then(res => {
+        if (res.success) {
+          this.$message.success('成功');
+          this.$router.go(-1);
+        } else {
+          this.$message.warning('失败')
+        }
+      });
+    },
+    getNowCow() {
+
+      this.getCowInfo(this.formData.cowID, '', '', true).then((data) => {
+        this.$message({
+          message: '当前牛只信息已存在不能进场',
+          type: 'warning'
+        });
+        this.formData.cowID = ''
+      }).catch(() => {
+
+      })
+    }
+  }
+}
+</script>
+<style lang="less" scoped>
+.containMain {
+  background: rgba(255, 255, 255, 1);
+  border-radius: 4px;
+  padding: 15px;
+  // margin-right: 10px;
+  .contentTitle {
+    border-bottom: 1px solid #f2f4f5;
+  }
+  // min-width: 450px;
+
+  .sub {
+    font-size: 14px;
+    font-weight: 600;
+    color: rgba(102, 102, 102, 1);
+    line-height: 20px;
+    margin-bottom: 40px;
+    padding-left: 20px;
+  }
+}
+
+.contentTitle {
+  font-size: 16px;
+  font-weight: bold;
+  color: rgba(0, 0, 0, 1);
+  line-height: 22px;
+  letter-spacing: 1px;
+  padding-bottom: 14px;
+}
+
+.containAside {
+  padding: 0;
+  margin-left: 10px;
+  display: flex;
+  flex-direction: column;
+  .asideInfo {
+    flex-grow: 1;
+    background: rgba(255, 255, 255, 1);
+    border-radius: 4px;
+    padding: 15px;
+  }
+}
+</style>

+ 441 - 0
src/main/vue/src/pages/HandleBeestings.vue

@@ -0,0 +1,441 @@
+<template>
+  <el-container style="flex-grow:1">
+    <el-aside class="containAside" max-width="500px" width="26%" style=" margin-right: 10px;">
+      <div class="asideInfo">
+        <div class="contentTitle">
+          {{pageTitle}}
+          <!-- <span>{{list.length}}头奶牛</span> -->
+        </div>
+        <div class="selectContent">
+          <el-select v-model="cowshed" placeholder="请选择牛舍" style="width:230px">
+            <el-option v-for="item in cowShedList" :key="item" :label="item" :value="item"></el-option>
+          </el-select>
+          <!-- <el-button type="primary" plain @click="filitDayList=filitDay">筛选</el-button> -->
+        </div>
+        <div class="tableNum">{{filitList.length}}头奶牛</div>
+        <el-table class="handleTable" border :data="filitList" style="width: 100%" :height="(allHeight-224)+'px'" size="small" @row-click="rowClick">
+          <el-table-column prop="牛号" label="牛号" fixed="left" align="center"></el-table-column>
+          <el-table-column prop="当前牛舍" label="牛舍" align="center"></el-table-column>
+          <el-table-column prop="初乳饲喂量" label="初乳饲喂量" align="center" width="140"></el-table-column>
+          <el-table-column prop="初生重" label="初生重" align="center"></el-table-column>
+          <el-table-column prop="出生时间" label="出生时间" align="center"></el-table-column>
+        </el-table>
+      </div>
+    </el-aside>
+    <el-main class="containMain">
+      <div class="contentTitle">初乳饲喂信息登记</div>
+      <el-form ref="form" :model="formData" style="margin-top:20px;width:522px;" label-width="80px">
+        <el-form-item label label-width="0">
+          <!-- <el-input v-model="formData.cowID" prefix-icon="el-icon-search" style="width:300px" maxlength="8"></el-input>
+          <el-button type="primary" @click="getNowCow" style="width:90px;margin-left:12px">确认</el-button> -->
+          <el-autocomplete v-model="formData.cowID" prefix-icon="el-icon-search" style="width:300px" :fetch-suggestions="querySearchAsync" placeholder="请输入内容" @select="handleSelect"></el-autocomplete>
+        </el-form-item>
+        <div class="sub" v-if="tableData.length>0">操作牛号:{{chooseCowInfo['牛号']}}</div>
+
+        <div style="margin-top:80px">
+          <el-button @click="onSave" type="primary" style="width:98px;" size="mediu">提交</el-button>
+        </div>
+      </el-form>
+    </el-main>
+    <el-aside class="containAside" max-width="450px" width="25%" style=" margin-left: 10px;">
+      <div class="asideInfo">
+        <div class="contentTitle">牛只信息</div>
+        <el-table class="handleTable" border :data="tableData" style="width: 100%" :height="(allHeight-120)+'px'" size="small">
+          <el-table-column prop="key" label="参数"></el-table-column>
+          <el-table-column prop="value" label="当前牛只信信息"></el-table-column>
+        </el-table>
+      </div>
+    </el-aside>
+  </el-container>
+</template>
+<script>
+import formValidator from '../formValidator'
+import axios from 'axios'
+import { mapState } from 'vuex'
+export default {
+  created() {
+    //任务列表
+    this.getList(1)
+
+
+    //获取全部疾病
+    // this.getHaleInfo('wsCow', 'getUserDict', [
+    //     'HoofTreatment'
+    // ], 'list').then((data) => {
+    //     this.typeList = [{ 名称: '暂无蹄病' }]
+    //     this.typeList = this.typeList.concat(data)
+    //     this.formData.type = this.typeList[0]['名称']
+    // })
+
+  },
+  data() {
+    return {
+      saving: false,
+      formData: {
+        cowID: '',
+        type: '',
+        level: '0分:正常',
+        nursingDate: '',
+        nursing_FL: 1,
+        nursing_BL: 1,
+        nursing_FR: 1,
+        nursing_BR: 1
+      },
+      mateModes: [],
+      levelList: ['0分:正常', '1分:轻微破行', '2分:中度破行', '3分:破行', '4分:严重破行'],
+      bulls: [],
+      tableData: [],
+      list: [],
+      cowshed: '',
+      task: 2,
+      typeList: [],
+      taskList: [{
+        name: '干奶修蹄',
+        type: 1,
+        use: '请注射维生素E'
+      }
+        , {
+        name: '泌乳牛普修',
+        type: 2,
+        use: '请投喂博威钙'
+      }
+        , {
+        name: '青年牛修蹄',
+        type: 3,
+        use: '2-3胎次需要投服一粒博威钙,继续护理请点"是",结束护理请点"否"(注意:结束护理后,将不再提示护理操作)'
+      }],
+      chooseCowInfo: {}
+    }
+  },
+  computed: {
+    ...mapState(['userInfo', 'allHeight']),
+    pageTitle() {
+      return this.$route.meta.title
+    },
+    cowShedList() {
+      var list = ['全部牛舍']
+      this.list.forEach(item => {
+        if (list.indexOf(item['当前牛舍']) == -1) {
+          list.push(item['当前牛舍'])
+        }
+      })
+      return list
+    },
+    filitList() {
+      var list = []
+      if (this.cowshed) {
+        if (this.cowshed == '全部牛舍') {
+          list = this.list
+        }
+        else {
+          this.list.forEach(item => {
+            if (item['当前牛舍'] == this.cowshed) {
+              list.push(item)
+            }
+          })
+        }
+      }
+      return list
+    },
+    nowTaskJson() {
+      var jsonp = {}
+      if (this.task) {
+        this.taskList.forEach(item => {
+          if (this.task == item.type) {
+            jsonp = item
+          }
+        })
+      }
+
+      return jsonp
+    },
+    cowIDList(){
+        var list=[]
+        this.list.forEach(item=>{
+            list.push({
+                value:item['牛号']
+            })
+        })
+        return list
+    },
+  },
+  watch: {
+    task() {
+      this.cowshed = ''
+      this.formData.cowID = ''
+      this.getList(1)
+    },
+    // 'formData.cowID'() {
+    //   if (this.formData.cowID.length != 8) {
+    //     return
+    //   }
+    //   this.getNowCow()
+    // }
+  },
+  methods: {
+      handleSelect(choose){
+          var data={}
+          this.list.forEach(item=>{
+              if(item['牛号']==choose.value){
+data=item
+              }
+          })
+           this.getNowCow(data)
+      },
+      querySearchAsync(queryString, cb) {
+        var restaurants = this.cowIDList;
+        var results = queryString ? restaurants.filter(this.createStateFilter(queryString)) : restaurants;
+
+       
+      setTimeout(() => {
+          cb(results);
+        }, 3000 * Math.random());
+      },
+       createStateFilter(queryString) {
+        return (state) => {
+          return (state.value.toLowerCase().indexOf(queryString.toLowerCase()) === 0);
+        };
+      },
+    getList(type) {
+      this.getHaleInfo('wsCalving', 'getFeedingColosTask', [
+        this.$store.state.farmName
+      ], 'list').then((data) => {
+        this.list = data
+        if (this.list.length == 0) {
+          this.$alert('暂无需要处理的奶牛', '提示', {
+            confirmButtonText: '确定',
+            callback: action => {
+
+            }
+          });
+        }
+        else {
+          setTimeout(() => {
+            this.cowshed = this.cowShedList[1]
+          }, 500)
+        }
+
+      })
+    },
+    onSave() {
+      if (!this.formData.cowID) {
+        this.$message({
+          message: '请录入牛只牛号',
+          type: 'warning'
+        });
+        return
+      }
+
+
+      var jsonp = {}
+
+      this.getHaleInfo('wsCalving', 'addFeedingColosInfo', [
+       this.formData.cowID, this.chooseCowInfo['初乳饲喂量'], '', this.userInfo.username
+      ], 'json').then((data) => {
+        if (data.rtnCode == -1) {
+          // this.$message({
+          //     message: data.rtnMessage,
+          //     type: 'warning'
+          // });
+          this.$alert(data.rtnMessage, '提示', {
+            confirmButtonText: '确定',
+            callback: action => {
+              this.formData.cowID = ''
+            }
+          });
+        }
+        else {
+          this.$message({
+            message: '录入成功',
+            type: 'success'
+          });
+          this.formData.cowID = ''
+          this.getList()
+        }
+      })
+    },
+    saveFeed() {
+      var name = this.name.split('-')
+      this.getHaleInfo('wsVeterinary', 'addPCInfo', [
+        {
+          cowID: this.formData['牛号'],
+          careDate: Date.parse(new Date()),
+          calvingDate: Date.parse(new Date(this.formData['产犊日期'])),
+          bodyTemp: this.temperatureList.indexOf(this.bodyTemp),
+          diseaseDate: Date.parse(new Date(this.formData['提示日期'])),
+          diseaseCategory: name[0],
+          diseaseName: name[1],
+          isToHospital: this.isCheck
+        }
+      ], 'json').then((data) => {
+        console.log(data)
+        if (data.rtnCode == -1) {
+          this.$alert(data.rtnMessage, '提示', {
+            confirmButtonText: '确定',
+            callback: action => {
+              this.formData.cowID = ''
+            }
+          });
+        }
+        else {
+          this.$message({
+            message: '录入成功',
+            type: 'success'
+          });
+          this.formData.cowID = ''
+          this.getList()
+        }
+      })
+    },
+    badTreat() {
+      this.getHaleInfo('wsVeterinary', 'addPCFinishInfo', [
+        this.formData['牛号'], Date.parse(new Date(this.formData['产犊日期'])), '产犊', this.formData['产犊类型'], this.userInfo.username
+      ], 'json').then((data) => {
+        console.log(data)
+        if (data.rtnCode == -1) {
+          this.$alert(data.rtnMessage, '提示', {
+            confirmButtonText: '确定',
+            callback: action => {
+              this.formData.cowID = ''
+            }
+          });
+        }
+        else {
+          this.$message({
+            message: '录入成功',
+            type: 'success'
+          });
+          this.formData.cowID = ''
+          this.getList()
+        }
+      })
+    },
+    getNowCow(row) {
+          this.chooseCowInfo = row
+        var list = []
+        Object.keys(row).forEach(item => {
+          list.push({
+            key: item,
+            value: row[item]
+          })
+        })
+
+        this.tableData = list
+     
+
+
+    },
+    rowClick(row) {
+      this.formData.cowID = row['牛号']
+      this.getNowCow(row)
+    }
+  }
+}
+</script>
+<style lang="less" scoped>
+.containMain {
+  background: rgba(255, 255, 255, 1);
+  border-radius: 4px;
+  padding: 15px;
+  // margin-right: 10px;
+  .contentTitle {
+    border-bottom: 1px solid #f2f4f5;
+  }
+  // min-width: 450px;
+
+  .sub {
+    font-size: 14px;
+    font-weight: 600;
+    color: rgba(102, 102, 102, 1);
+    line-height: 20px;
+    margin-bottom: 40px;
+    padding-left: 20px;
+  }
+}
+
+.contentTitle {
+  font-size: 16px;
+  font-weight: bold;
+  color: rgba(0, 0, 0, 1);
+  line-height: 22px;
+  letter-spacing: 1px;
+  padding-bottom: 14px;
+  span {
+    font-size: 13px;
+    color: rgba(102, 102, 102, 1);
+    line-height: 18px;
+    margin-left: 10px;
+  }
+}
+.selectContent {
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+  padding: 20px 0;
+}
+
+.tableNum {
+  font-size: 13px;
+  font-weight: bold;
+  color: rgba(102, 102, 102, 1);
+  line-height: 18px;
+  padding-bottom: 15px;
+}
+.containAside {
+  padding: 0;
+
+  display: flex;
+  flex-direction: column;
+  .asideInfo {
+    flex-grow: 1;
+    background: rgba(255, 255, 255, 1);
+    border-radius: 4px;
+    padding: 15px;
+  }
+}
+
+.item {
+  .item-title {
+    font-size: 14px;
+    font-weight: bold;
+
+    color: rgba(0, 0, 0, 1);
+    line-height: 20px;
+    letter-spacing: 1px;
+  }
+
+  .text {
+    font-size: 13px;
+    color: rgba(0, 0, 0, 1);
+    line-height: 18px;
+    letter-spacing: 1px;
+    word-wrap: break-word;
+    padding: 10px 0 15px;
+  }
+}
+
+.HoofList {
+  display: flex;
+  width: 130px;
+  flex-wrap: wrap;
+  justify-content: space-between;
+  .hoof-item {
+    width: 60px;
+    height: 60px;
+    border-radius: 4px;
+    font-size: 13px;
+    font-weight: bold;
+    color: rgba(255, 255, 255, 1);
+    line-height: 18px;
+    text-align: center;
+    line-height: 60px;
+    background: rgb(0, 85, 128);
+    margin-bottom: 10px;
+    cursor: pointer;
+
+    &.active {
+      background: rgba(133, 195, 6, 1);
+    }
+  }
+}
+</style>

+ 0 - 365
src/main/vue/src/pages/HandleImmunopotency.1.vue

@@ -1,365 +0,0 @@
-<template>
-  <el-container style="flex-grow:1">
-    <el-aside class="containAside" max-width="500px" width="26%" style=" margin-right: 10px;">
-      <div class="asideInfo">
-        <div class="contentTitle">
-          {{task==1?'免疫任务':'免疫效价'}}
-          <!-- <span>{{list.length}}头奶牛</span> -->
-          <el-select v-model="task" placeholder="请选择" size="mini" style="float:right">
-            <el-option v-for="item in taskList" :key="item.type" :label="item.name" :value="item.type"></el-option>
-          </el-select>
-        </div>
-        <div class="selectContent">
-          <el-select v-model="taskNO" placeholder="请选择任务" style="width:230px">
-            <el-option v-for="item in taskNOList" :key="item['任务单编号']" :label="item['免疫检疫名称']" :value="item['任务单编号']"></el-option>
-          </el-select>
-
-          <el-select v-model="cowshed" v-if="taskNO" placeholder="请选择牛舍" style="width:230px">
-            <el-option v-for="item in cowshedList" :key="item['当前牛舍']" :label="item['当前牛舍']" :value="item['当前牛舍']"></el-option>
-          </el-select>
-        </div>
-        <div class="tableNum">{{list.length}}头奶牛</div>
-        <el-table class="handleTable" border :data="list" style="width: 100%" :height="(allHeight-220)+'px'" size="small" @row-click="rowClick">
-          <el-table-column prop="牛号" label="牛号" fixed="left" align="center"></el-table-column>
-          <el-table-column prop="当前牛舍" label="牛舍" align="center"></el-table-column>
-        </el-table>
-      </div>
-    </el-aside>
-    <el-main class="containMain">
-      <div class="contentTitle">配种信息登记</div>
-      <el-form ref="form" :model="formData" label-width="120px" style="margin-top:20px;width:522px">
-        <el-form-item label label-width="0">
-          <el-input v-model="formData.cowID" prefix-icon="el-icon-search" style="width:300px" maxlength="8"></el-input>
-          <el-button type="primary" @click="getNowCow" style="width:90px;margin-left:12px">确认</el-button>
-        </el-form-item>
-        <div class="sub" v-if="tableData.length>0">操作牛号:{{tableData[0].value}}</div>
-        <el-form-item label="是否进行操作">
-          <el-radio-group v-model="formData.isEdit">
-            <el-radio label="0">是</el-radio>
-            <el-radio label="1">否</el-radio>
-          </el-radio-group>
-        </el-form-item>
-
-        <div style="margin-top:80px">
-          <el-button @click="onSave" type="primary" style="width:98px;" size="mediu">确认保存</el-button>
-        </div>
-      </el-form>
-    </el-main>
-    <el-aside class="containAside" width="25%" max-width="450px" style=" margin-left: 10px;">
-      <div class="asideInfo">
-        <div class="contentTitle">牛只信息</div>
-        <el-table class="handleTable" border :data="tableData" style="width: 100%" :height="(allHeight-120)+'px'" size="small">
-          <el-table-column prop="key" label="参数"></el-table-column>
-          <el-table-column prop="value" label="当前牛只信信息"></el-table-column>
-        </el-table>
-      </div>
-    </el-aside>
-  </el-container>
-</template>
-<script>
-import formValidator from '../formValidator'
-import axios from 'axios'
-import { mapState } from 'vuex'
-export default {
-  created() {
-    //配种列表
-    this.getTask()
-
-
-  },
-  data() {
-    return {
-      saving: false,
-      formData: {
-        cowID: '',
-        isEdit: '0'
-      },
-      mateModes: [],
-      methods: ['人工观察', '计步器揭发', '同期发情'],
-      bulls: [],
-      tableData: [],
-      list: [],
-      editCowInfo: {},
-      reasonList: [],
-      taskList: [{
-        name: '免疫任务',
-        type: 1
-      }, {
-        name: '免疫效价',
-        type: 2
-      }],
-      task: 1,
-      taskNOList: [],
-      taskNO: '',
-      cowshedList: [],
-      cowshed: ''
-    }
-  },
-  computed: {
-    ...mapState(['userInfo', 'allHeight']),
-    pageTitle() {
-      return this.$route.meta.title
-    },
-    bullMsg() {
-      var jsonp = {}
-      if (this.formData.bull) {
-        this.bulls.forEach(item => {
-          if (item['牛号'] == this.formData.bull) {
-            jsonp = item
-          }
-        })
-      }
-
-      return jsonp
-
-
-    }
-  },
-  watch: {
-    'formData.reason'() {
-      setTimeout(() => {
-        this.formData.remark = this.remarks[0]
-      }, 100)
-    },
-    'formData.cowID'() {
-      if (this.formData.cowID.length != 8) {
-        return
-      }
-      this.getNowCow()
-    },
-    task() {
-      this.getTask()
-      this.taskNO=''
-      this.cowshed=''
-    },
-    taskNO() {
-      this.list = []
-      this.cowshed = ''
-      if (this.taskNO) {
-        this.getList('')
-      }
-
-    },
-    cowshed() {
-      if (this.cowshed) {
-        this.getList(this.cowshed)
-      }
-    }
-  },
-  methods: {
-    getList(cowshed) {
-      this.getHaleInfo('wsVeterinary', 'getIQTaskDetail', [
-        this.$store.state.farmName, this.task, this.taskNO, cowshed
-      ], 'list').then((data) => {
-        console.log(data)
-        if (!cowshed) {
-          this.cowshedList = data
-        }
-        else {
-          this.list = data
-        }
-
-
-      })
-    },
-    getTask() {
-      this.getHaleInfo('wsVeterinary', 'getIQTask', [
-        this.$store.state.farmName, this.task
-      ], 'list').then((data) => {
-        console.log(data)
-        this.taskNOList = data
-
-
-      })
-    },
-    onSave() {
-      if (!this.formData.cowID) {
-        this.$message({
-          message: '请录入牛只牛号',
-          type: 'warning'
-        });
-        return
-      }
-
-      
-      this.formData.operators = this.userInfo.username
-
-      this.getHaleInfo('wsVeterinary', 'updateIQInfo', [
-         this.formData.cowID, this.taskNO, this.task, '', '', this.userInfo.username
-      ], 'json').then((data) => {
-        console.log(data)
-        if (data.rtnCode == -1) {
-          // this.$message({
-          //     message: data.rtnMessage,
-          //     type: 'warning'
-          // });
-          this.$alert(data.rtnMessage, '提示', {
-            confirmButtonText: '确定',
-            callback: action => {
-              this.formData.cowID = ''
-            }
-          });
-        }
-        else {
-          this.$message({
-            message: '录入成功',
-            type: 'success'
-          });
-          this.formData.cowID = ''
-          this.getList(this.cowshed)
-        }
-      })
-    },
-    notMatch() {
-
-      if (!this.formData.reason) {
-        this.$message({
-          message: '请选择未配原因',
-          type: 'warning'
-        });
-        return
-      }
-
-      if (!this.formData.person) {
-        this.$message({
-          message: '请选择配种员',
-          type: 'warning'
-        });
-        return
-      }
-      this.getHaleInfo('wsBreeding', 'updateHeatingByNomate', [
-        this.formData.cowID, this.formData.reason, this.formData.person
-      ], 'json').then((data) => {
-        console.log(data)
-        if (data.rtnCode == -1) {
-          this.$alert(data.rtnMessage, '提示', {
-            confirmButtonText: '确定',
-            callback: action => {
-              this.formData.cowID = ''
-            }
-          });
-        }
-        else {
-          this.$message({
-            message: '录入成功',
-            type: 'success'
-          });
-          this.formData.cowID = ''
-          this.getList()
-        }
-      })
-    },
-    getNowCow(data) {
-
-
-      var list = []
-      data = this.JsonSort(['牛号', '任务单编号'], data)
-      Object.keys(data).forEach(item => {
-        list.push({
-          key: item,
-          value: data[item]
-        })
-      })
-
-      this.editCowInfo = data
-
-
-      this.tableData = list
-
-
-
-    },
-    rowClick(row) {
-      this.formData = {
-        cowID: row['牛号'],
-        isEdit: '0'
-      }
-
-      this.getNowCow(row)
-    }
-  }
-}
-</script>
-<style lang="less" scoped>
-.containMain {
-  background: rgba(255, 255, 255, 1);
-  border-radius: 4px;
-  padding: 15px;
-  // margin-right: 10px;
-  .contentTitle {
-    border-bottom: 1px solid #f2f4f5;
-  }
-  // min-width: 450px;
-
-  .sub {
-    font-size: 14px;
-    font-weight: 600;
-    color: rgba(102, 102, 102, 1);
-    line-height: 20px;
-    margin-bottom: 40px;
-    padding-left: 20px;
-  }
-}
-
-.tableNum {
-  font-size: 13px;
-  font-weight: bold;
-  color: rgba(102, 102, 102, 1);
-  line-height: 18px;
-  padding-bottom: 15px;
-}
-.selectContent {
-  display: flex;
-  align-items: center;
-  justify-content: space-between;
-  padding: 20px 0;
-}
-
-.contentTitle {
-  font-size: 16px;
-  font-weight: bold;
-  color: rgba(0, 0, 0, 1);
-  line-height: 22px;
-  letter-spacing: 1px;
-  padding-bottom: 14px;
-  span {
-    font-size: 13px;
-    color: rgba(102, 102, 102, 1);
-    line-height: 18px;
-    margin-left: 10px;
-  }
-}
-
-.containAside {
-  padding: 0;
-
-  display: flex;
-  flex-direction: column;
-  .asideInfo {
-    flex-grow: 1;
-    background: rgba(255, 255, 255, 1);
-    border-radius: 4px;
-    padding: 15px;
-  }
-}
-
-.item {
-  .item-title {
-    font-size: 14px;
-    font-weight: bold;
-
-    color: rgba(0, 0, 0, 1);
-    line-height: 20px;
-    letter-spacing: 1px;
-  }
-
-  .text {
-    font-size: 13px;
-    color: rgba(0, 0, 0, 1);
-    line-height: 18px;
-    letter-spacing: 1px;
-    word-wrap: break-word;
-    padding: 10px 0 15px;
-  }
-}
-</style>

+ 337 - 0
src/main/vue/src/pages/HandlePhoto.vue

@@ -0,0 +1,337 @@
+<template>
+  <el-container>
+    <el-main class="containMain">
+      <div class="contentTitle">{{pageTitle}}</div>
+      <el-form ref="form" :model="formData" label-width="80px" style="margin-top:20px;">
+        <el-form-item label label-width="0">
+          <el-autocomplete prefix-icon="el-icon-search" v-model="formData.cowID" :fetch-suggestions="queryCow" placeholder="请输入牛号" style="width:300px" clearable @select="getNowCow"></el-autocomplete>
+          <el-button type="primary" @click="getNowCow" style="width:90px;margin-left:12px">确认</el-button>
+        </el-form-item>
+        <div class="sub" v-if="tableData.length>0">操作牛号:{{tableData[0].value}}</div>
+        <div class="subStr">只能上传JPG / PNG文件,尺寸比例750x750px,且不超过500KB</div>
+        <div class="list">
+          <div class="item">
+            <el-upload action class="avatar-uploader" :show-file-list="false" :before-upload="beforeLeft">
+              <img v-if="formData.left" :src="formData.left" class="avatar">
+              <i v-else class="el-icon-plus avatar-uploader-icon"></i>
+            </el-upload>
+            <p>左侧照片</p>
+          </div>
+          <div class="item">
+            <el-upload action class="avatar-uploader" :show-file-list="false" :before-upload="beforeFront">
+              <img v-if="formData.front" :src="formData.front" class="avatar">
+              <i v-else class="el-icon-plus avatar-uploader-icon"></i>
+            </el-upload>
+            <p>正面照片</p>
+          </div>
+          <div class="item">
+            <el-upload action class="avatar-uploader" :show-file-list="false" :before-upload="beforeRight">
+              <img v-if="formData.right" :src="formData.right" class="avatar">
+              <i v-else class="el-icon-plus avatar-uploader-icon"></i>
+            </el-upload>
+            <p>右侧照片</p>
+          </div>
+        </div>
+
+        <div style="margin-top:80px">
+          <el-button @click="onSave" type="primary" style="width:98px;" size="mediu">提交信息</el-button>
+        </div>
+      </el-form>
+    </el-main>
+    <el-aside class="containAside" width="450px">
+      <div class="asideInfo">
+        <div class="contentTitle">牛只信息</div>
+        <el-table class="handleTable" border :data="tableData" style="width: 100%" :height="(allHeight-120)+'px'" size="small">
+          <el-table-column prop="key" label="参数"></el-table-column>
+          <el-table-column prop="value" label="当前牛只信信息"></el-table-column>
+        </el-table>
+      </div>
+    </el-aside>
+  </el-container>
+</template>
+<script>
+import formValidator from '../formValidator'
+import axios from 'axios'
+import { mapState } from 'vuex'
+export default {
+  created() {
+
+  },
+  data() {
+    return {
+      saving: false,
+      formData: {
+        cowID: '',
+        left: '',
+        front: '',
+        right: ''
+      },
+      tableData: []
+    }
+  },
+  computed: {
+    ...mapState(['userInfo', 'allHeight']),
+    pageTitle() {
+      return this.$route.meta.title
+    }
+  },
+  watch: {
+    'formData.cowID'() {
+
+      if (this.formData.cowID.length != 8) {
+        return
+      }
+      this.getNowCow()
+    }
+  },
+  methods: {
+    beforeLeft(flie) {
+      var reader = new FileReader();
+      reader.onload = (e) => {
+        this.formData.left = reader.result
+      }
+      reader.readAsDataURL(flie)
+
+      return false
+    },
+    beforeFront(flie) {
+      var reader = new FileReader();
+      reader.onload = (e) => {
+        this.formData.front = reader.result
+      }
+      reader.readAsDataURL(flie)
+
+      return false
+    },
+    beforeRight(flie) {
+      var reader = new FileReader();
+      reader.onload = (e) => {
+        this.formData.right = reader.result
+      }
+      reader.readAsDataURL(flie)
+
+      return false
+    },
+    onSave() {
+      if (this.formData.cowID.length != 8) {
+        this.$message({
+          message: '请录入牛只牛号',
+          type: 'warning'
+        });
+        return
+      }
+
+      if (!this.formData.left) {
+        this.$message({
+          message: '请录入牛只左侧照片',
+          type: 'warning'
+        });
+        return
+      }
+
+      if (!this.formData.front) {
+        this.$message({
+          message: '请录入牛只正面照片',
+          type: 'warning'
+        });
+        return
+      }
+      if (!this.formData.right) {
+        this.$message({
+          message: '请录入牛只右侧照片',
+          type: 'warning'
+        });
+        return
+      }
+
+      this.savePhoto(0)
+
+
+    },
+    savePhoto(index) {
+      if (index >= 3) {
+        this.$message({
+          message: '提交成功',
+          type: 'success'
+        });
+        return
+      }
+      var formData = new FormData()
+      formData.append('cowId', this.formData.cowID)
+      formData.append('operators', this.userInfo.username)
+      if (index == 0) {
+        formData.append('photo', this.formData.left)
+        formData.append('description', '牛只三面照L')
+      }
+      else if (index == 1) {
+        formData.append('photo', this.formData.front)
+        formData.append('description', '牛只三面照F')
+      }
+      else if (index == 2) {
+        formData.append('photo', this.formData.right)
+        formData.append('description', '牛只三面照R')
+      }
+
+
+      axios.post('http://118.178.226.110:8090/cowOut/addPhotoInfo', formData, {
+        withCredentials: false
+      }).then(res => {
+        if (res.data.success) {
+          this.savePhoto(index + 1)
+        }
+        else {
+          this.$message({
+            message: res.data.error,
+            type: 'warning'
+          });
+        }
+
+
+      })
+
+      setTimeout(() => {
+
+      }, 100)
+    },
+    getNowCow() {
+      this.getHaleInfo('wsVeterinary', 'getFeedMagnetByCowID', [this.formData.cowID], 'json').then((data) => {
+        // console.log(data)
+        data = this.JsonSort(['牛号', '当前牛舍', '繁殖状态', '泌乳状态', '投喂磁石日期', '投喂磁石人'], data)
+        var list = []
+        Object.keys(data).forEach(item => {
+          list.push({
+            key: item,
+            value: data[item]
+          })
+        })
+
+        // console.log(list)
+
+        this.tableData = list
+
+      }).catch(() => {
+        this.formData.cowID = ''
+      })
+    },
+
+  }
+}
+</script>
+<style lang="less" scoped>
+.containMain {
+  background: rgba(255, 255, 255, 1);
+  border-radius: 4px;
+  padding: 15px;
+  // margin-right: 10px;
+  .contentTitle {
+    border-bottom: 1px solid #f2f4f5;
+  }
+  // min-width: 450px;
+
+  .sub {
+    font-size: 14px;
+    font-weight: 600;
+    color: rgba(102, 102, 102, 1);
+    line-height: 20px;
+    margin-bottom: 40px;
+    padding-left: 20px;
+  }
+}
+
+.contentTitle {
+  font-size: 16px;
+  font-weight: bold;
+  color: rgba(0, 0, 0, 1);
+  line-height: 22px;
+  letter-spacing: 1px;
+  padding-bottom: 14px;
+}
+
+.containAside {
+  padding: 0;
+  margin-left: 10px;
+  display: flex;
+  flex-direction: column;
+  .asideInfo {
+    flex-grow: 1;
+    background: rgba(255, 255, 255, 1);
+    border-radius: 4px;
+    padding: 15px;
+  }
+}
+
+.subStr {
+  height: 14px;
+  font-size: 12px;
+  font-family: PingFangSC-Regular;
+  font-weight: 400;
+  color: rgba(144, 147, 153, 1);
+  line-height: 14px;
+  margin-top: 50px;
+  margin-left: 15px;
+}
+
+.list {
+  display: flex;
+  margin-top: 10px;
+  .item {
+    text-align: center;
+    margin-right: 20px;
+  }
+}
+
+.avatar-uploader-icon {
+  font-size: 28px;
+  color: #8c939d;
+  width: 178px;
+  height: 178px;
+  line-height: 178px;
+  text-align: center;
+  border: 1px dashed #d9d9d9;
+  border-radius: 6px;
+  cursor: pointer;
+  position: relative;
+  overflow: hidden;
+  background-color: #fbfdff;
+  &:hover {
+    border-color: #409eff;
+  }
+}
+
+.avatar {
+  width: 178px;
+  height: 178px;
+  display: block;
+  border: 1px dashed #d9d9d9;
+  border-radius: 6px;
+  cursor: pointer;
+  position: relative;
+  overflow: hidden;
+  &:hover {
+    border-color: #409eff;
+  }
+}
+
+.wrapper {
+  position: relative;
+}
+
+.single-upload .el-upload {
+  position: relative;
+}
+
+.loading {
+  position: absolute;
+  top: 0;
+  bottom: 0;
+  left: 0;
+  right: 0;
+  margin: auto;
+  display: flex;
+  align-items: center;
+  justify-content: center;
+  background: rgba(255, 255, 255, 0.6);
+  color: #333;
+  font-size: 24px;
+}
+</style>

+ 209 - 0
src/main/vue/src/pages/HandleTransition.vue

@@ -0,0 +1,209 @@
+<template>
+  <el-container style="flex-grow:1">
+    <el-main class="containMain">
+      <div class="contentTitle">离场登记</div>
+      <el-form ref="form" :model="formData" label-width="80px" style="margin-top:20px;">
+        <el-form-item label label-width="0">
+          <el-input v-model="formData.cowID" prefix-icon="el-icon-search" style="width:300px" maxlength="8"></el-input>
+          <el-button type="primary" @click="getNowCow" style="width:90px;margin-left:12px">确认</el-button>
+        </el-form-item>
+        <div class="sub" v-if="tableData.length>0">操作牛号:{{tableData[0].value}}</div>
+        <el-form-item label="目标牧场">
+          <el-select v-model="formData.currFarm" placeholder="请选择目标牧场">
+            <el-option v-for="item in farmList" :key="item['牧场编号']" :label="item['牧场名称']" :value="item['牧场编号']"></el-option>
+          </el-select>
+        </el-form-item>
+
+        <div style="margin-top:80px">
+          <el-button @click="onSave" type="primary" style="width:98px;" size="mediu">确认转场+</el-button>
+        </div>
+      </el-form>
+    </el-main>
+    <el-aside class="containAside" width="450px">
+      <div class="asideInfo">
+        <div class="contentTitle">牛只信息</div>
+        <el-table class="handleTable" border :data="tableData" style="width: 100%" :height="(allHeight-70)+'px'" size="small">
+          <el-table-column prop="key" label="参数"></el-table-column>
+          <el-table-column prop="value" label="当前牛只信信息"></el-table-column>
+        </el-table>
+      </div>
+    </el-aside>
+  </el-container>
+</template>
+<script>
+import formValidator from '../formValidator'
+import axios from 'axios'
+import { mapState } from 'vuex'
+export default {
+  created() {
+
+    this.getHaleInfo('wsCow', 'getAllFarm', [], 'list').then((data) => {
+      this.farmList = data
+    })
+
+
+  },
+  data() {
+    return {
+      saving: false,
+      formData: {
+        cowID: '',
+        currFarm: '',
+      },
+      tableData: [],
+      farmList: []
+    }
+  },
+  computed: {
+    ...mapState(['userInfo', 'allHeight']),
+
+  },
+  watch: {
+    'formData.cowID'() {
+      if (this.formData.cowID.length != 8) {
+        return
+      }
+      this.getNowCow()
+    }
+  },
+  methods: {
+    onSave() {
+      if (!this.formData.cowID) {
+        this.$message({
+          message: '请录入离场牛只牛号',
+          type: 'warning'
+        });
+        return
+      }
+      if (!this.formData.currFarm) {
+        this.$message({
+          message: '请选择目标牧场',
+          type: 'warning'
+        });
+        return
+      }
+
+      axios.get('http://116.62.160.108/mfMISWS/wsCow.asmx/UpdateCurrFarm', {
+        params: {
+          currFarm: this.formData.currFarm,
+          cowNO: this.formData.cowID
+        },
+        withCredentials: false
+      }).then(res => {
+        var cowList = []
+        var xml = this.getXml(res.data)
+        console.log(xml)
+        var rtnCode = xml.getElementsByTagName("rtnCode")[0]
+        if (rtnCode == -1) {
+          this.$message({
+            message: xml.getElementsByTagName("rtnMessage")[0],
+            type: 'warning'
+          });
+        }
+        else {
+          this.$message({
+            message: '转场信息录入成功',
+            type: 'success'
+          });
+          this.formData.cowID = ''
+        }
+       
+      })
+
+    },
+    submit() {
+      var data = JSON.parse(JSON.stringify(this.formData));
+      this.$http.post({
+        url: this.formData.id ? '/userInfo/update' : '/userInfo/save',
+        data: data
+      }).then(res => {
+        if (res.success) {
+          this.$message.success('成功');
+          this.$router.go(-1);
+        } else {
+          this.$message.warning('失败')
+        }
+      });
+    },
+    getNowCow() {
+
+      this.getCowInfo(this.formData.cowID).then((data) => {
+        // console.log(data)
+        if (data['是否在场'] == '否') {
+          this.$message({
+            message: '当前牛只并不在场',
+            type: 'warning'
+          });
+          this.formData.cowID = ''
+          return
+        }
+
+          if (data['当前牧场'] != this.$store.state.farmName) {
+          this.$message({
+            message: '牛只不属于你所在的牧场,无权转牛',
+            type: 'warning'
+          });
+          this.formData.cowID = ''
+          return
+        }
+        var list = []
+        Object.keys(data).forEach(item => {
+          list.push({
+            key: item,
+            value: data[item]
+          })
+        })
+
+        // console.log(list)
+
+        this.tableData = list
+      }).catch(() => {
+        this.formData.cowID = ''
+      })
+    }
+  }
+}
+</script>
+<style lang="less" scoped>
+.containMain {
+  background: rgba(255, 255, 255, 1);
+  border-radius: 4px;
+  padding: 15px;
+  // margin-right: 10px;
+  .contentTitle {
+    border-bottom: 1px solid #f2f4f5;
+  }
+  // min-width: 450px;
+
+  .sub {
+    font-size: 14px;
+    font-weight: 600;
+    color: rgba(102, 102, 102, 1);
+    line-height: 20px;
+    margin-bottom: 40px;
+    padding-left: 20px;
+  }
+}
+
+.contentTitle {
+  font-size: 16px;
+  font-weight: bold;
+  color: rgba(0, 0, 0, 1);
+  line-height: 22px;
+  letter-spacing: 1px;
+  padding-bottom: 14px;
+}
+
+.containAside {
+  padding: 0;
+  margin-left: 10px;
+  display: flex;
+  flex-direction: column;
+  .asideInfo {
+    flex-grow: 1;
+    background: rgba(255, 255, 255, 1);
+    border-radius: 4px;
+    padding: 15px;
+  }
+}
+</style>

+ 436 - 0
src/main/vue/src/pages/HandleWeaning.vue

@@ -0,0 +1,436 @@
+<template>
+  <el-container style="flex-grow:1">
+    <el-aside class="containAside" max-width="500px" width="26%" style=" margin-right: 10px;">
+      <div class="asideInfo">
+        <div class="contentTitle">
+          {{pageTitle}}
+          <!-- <span>{{list.length}}头奶牛</span> -->
+          <el-checkbox v-model="batch" style="float:right">批量</el-checkbox>
+        </div>
+        <div class="selectContent">
+          <el-select v-model="cowshed" placeholder="请选择牛舍" style="width:230px">
+            <el-option v-for="item in cowShedList" :key="item" :label="item" :value="item"></el-option>
+          </el-select>
+          <!-- <el-button type="primary" plain @click="filitDayList=filitDay">筛选</el-button> -->
+        </div>
+        <div class="tableNum">{{filitList.length}}头奶牛</div>
+        <el-table class="handleTable" border :data="filitList" style="width: 100%" :height="(allHeight-224)+'px'" size="small" @row-click="rowClick">
+          <el-table-column prop="牛号" label="牛号" fixed="left" align="center"></el-table-column>
+          <el-table-column prop="当前牛舍" label="牛舍" align="center"></el-table-column>
+          <el-table-column prop="出生日期" label="出生日期" align="center" width="140"></el-table-column>
+          <el-table-column prop="日龄" label="日龄" align="center"></el-table-column>
+        </el-table>
+      </div>
+    </el-aside>
+    <el-main class="containMain">
+      <div class="contentTitle">断奶信息登记</div>
+      <el-form ref="form" :model="formData" style="margin-top:20px;width:522px;" label-width="80px">
+        <el-form-item label label-width="0">
+          <!-- <el-input v-model="formData.cowID" prefix-icon="el-icon-search" style="width:300px" maxlength="8"></el-input>
+          <el-button type="primary" @click="getNowCow" style="width:90px;margin-left:12px">确认</el-button>-->
+          <el-autocomplete v-model="formData.cowID" prefix-icon="el-icon-search" style="width:300px" :fetch-suggestions="querySearchAsync" placeholder="请输入内容" @select="handleSelect"></el-autocomplete>
+        </el-form-item>
+        <div class="sub" v-if="tableData.length>0">操作牛号:{{chooseCowInfo['牛号']}}</div>
+
+        <div style="margin-top:80px">
+          <el-button @click="onSave" type="primary" style="width:98px;" size="mediu">断奶</el-button>
+          <el-button @click="later" type="warning" style="width:98px;" size="mediu">延迟断奶</el-button>
+        </div>
+      </el-form>
+    </el-main>
+    <el-aside class="containAside" max-width="450px" width="25%" style=" margin-left: 10px;">
+      <div class="asideInfo">
+        <div class="contentTitle">牛只信息</div>
+        <el-table class="handleTable" border :data="tableData" style="width: 100%" :height="(allHeight-120)+'px'" size="small">
+          <el-table-column prop="key" label="参数"></el-table-column>
+          <el-table-column prop="value" label="当前牛只信信息"></el-table-column>
+        </el-table>
+      </div>
+    </el-aside>
+
+    <el-dialog :title="formInline.cowID+'推迟断奶'" :visible.sync="handleClose" width="30%">
+      <el-form :inline="true" :model="formInline" class="demo-form-inline">
+        <el-form-item label="推迟断奶原因">
+          <el-select v-model="formInline.reason" placeholder="请选择">
+            <el-option v-for="item in reasons" :key="item" :label="item" :value="item"></el-option>
+          </el-select>
+        </el-form-item>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button @click="handleClose = false">取 消</el-button>
+        <el-button type="primary" @click="sureLater">确 定</el-button>
+      </span>
+    </el-dialog>
+  </el-container>
+</template>
+<script>
+import formValidator from '../formValidator'
+import axios from 'axios'
+import { mapState } from 'vuex'
+export default {
+  created() {
+    //任务列表
+    this.getList(1)
+
+
+    //获取全部疾病
+    // this.getHaleInfo('wsCow', 'getUserDict', [
+    //     'HoofTreatment'
+    // ], 'list').then((data) => {
+    //     this.typeList = [{ 名称: '暂无蹄病' }]
+    //     this.typeList = this.typeList.concat(data)
+    //     this.formData.type = this.typeList[0]['名称']
+    // })
+
+  },
+  data() {
+    return {
+      handleClose: false,
+      batch: false,
+      saving: false,
+      formData: {
+        cowID: '',
+
+      },
+      mateModes: [],
+      levelList: ['0分:正常', '1分:轻微破行', '2分:中度破行', '3分:破行', '4分:严重破行'],
+      bulls: [],
+      tableData: [],
+      list: [],
+      cowshed: '',
+      task: 2,
+      formInline: {
+        cowID: '',
+        reason: '发育不良'
+      },
+      reasons: ['发育不良', '病牛', '体质弱小', '采食量未达到1.5kG'],
+      typeList: [],
+      taskList: [{
+        name: '干奶修蹄',
+        type: 1,
+        use: '请注射维生素E'
+      }
+        , {
+        name: '泌乳牛普修',
+        type: 2,
+        use: '请投喂博威钙'
+      }
+        , {
+        name: '青年牛修蹄',
+        type: 3,
+        use: '2-3胎次需要投服一粒博威钙,继续护理请点"是",结束护理请点"否"(注意:结束护理后,将不再提示护理操作)'
+      }],
+      chooseCowInfo: {}
+    }
+  },
+  computed: {
+    ...mapState(['userInfo', 'allHeight']),
+    pageTitle() {
+      return this.$route.meta.title
+    },
+    cowShedList() {
+      var list = ['全部牛舍']
+      this.list.forEach(item => {
+        if (list.indexOf(item['当前牛舍']) == -1) {
+          list.push(item['当前牛舍'])
+        }
+      })
+      return list
+    },
+    filitList() {
+      var list = []
+      if (this.cowshed) {
+        if (this.cowshed == '全部牛舍') {
+          list = this.list
+        }
+        else {
+          this.list.forEach(item => {
+            if (item['当前牛舍'] == this.cowshed) {
+              list.push(item)
+            }
+          })
+        }
+      }
+      return list
+    },
+    nowTaskJson() {
+      var jsonp = {}
+      if (this.task) {
+        this.taskList.forEach(item => {
+          if (this.task == item.type) {
+            jsonp = item
+          }
+        })
+      }
+
+      return jsonp
+    },
+    cowIDList() {
+      var list = []
+      this.list.forEach(item => {
+        list.push({
+          value: item['牛号']
+        })
+      })
+      return list
+    },
+  },
+  watch: {
+    task() {
+      this.cowshed = ''
+      this.formData.cowID = ''
+      this.getList(1)
+    },
+    // 'formData.cowID'() {
+    //   if (this.formData.cowID.length != 8) {
+    //     return
+    //   }
+    //   this.getNowCow()
+    // }
+  },
+  methods: {
+    handleSelect(choose) {
+      var data = {}
+      this.list.forEach(item => {
+        if (item['牛号'] == choose.value) {
+          data = item
+        }
+      })
+      this.getNowCow(data)
+    },
+    querySearchAsync(queryString, cb) {
+      var restaurants = this.cowIDList;
+      var results = queryString ? restaurants.filter(this.createStateFilter(queryString)) : restaurants;
+
+
+      setTimeout(() => {
+        cb(results);
+      }, 3000 * Math.random());
+    },
+    createStateFilter(queryString) {
+      return (state) => {
+        return (state.value.toLowerCase().indexOf(queryString.toLowerCase()) === 0);
+      };
+    },
+    getList(type) {
+      this.getHaleInfo('wsCalving', 'getWeaningTask', [
+        this.$store.state.farmName
+      ], 'list').then((data) => {
+        this.list = data
+        if (this.list.length == 0 && type == 1) {
+          this.$alert('暂无需要处理的奶牛', '提示', {
+            confirmButtonText: '确定',
+            callback: action => {
+
+            }
+          });
+        }
+
+
+      })
+    },
+    later() {
+      if (!this.formData.cowID) {
+        this.$message({
+          message: '请录入牛只牛号',
+          type: 'warning'
+        });
+        return
+      }
+      this.formInline.cowID = JSON.parse(JSON.stringify(this.formData.cowID))
+      this.handleClose = true
+    },
+    onSave() {
+      if (!this.formData.cowID) {
+        this.$message({
+          message: '请录入牛只牛号',
+          type: 'warning'
+        });
+        return
+      }
+
+
+      var jsonp = {}
+
+      this.getHaleInfo('wsCalving', 'addWeaningInfo', [
+        this.formData.cowID, 0, '', '', this.userInfo.username
+      ], 'json').then((data) => {
+        if (data.rtnCode == -1) {
+          // this.$message({
+          //     message: data.rtnMessage,
+          //     type: 'warning'
+          // });
+          this.$alert(data.rtnMessage, '提示', {
+            confirmButtonText: '确定',
+            callback: action => {
+              this.formData.cowID = ''
+            }
+          });
+        }
+        else {
+          this.$message({
+            message: '录入成功',
+            type: 'success'
+          });
+          this.formData.cowID = ''
+          this.getList()
+        }
+      })
+    },
+    getNowCow(row) {
+      this.chooseCowInfo = row
+      var list = []
+      Object.keys(row).forEach(item => {
+        list.push({
+          key: item,
+          value: row[item]
+        })
+      })
+
+      this.tableData = list
+
+
+
+    },
+    rowClick(row) {
+      this.formData.cowID = row['牛号']
+      this.getNowCow(row)
+    },
+    sureLater() {
+      this.getHaleInfo('wsCalving', 'addWeaningInfo', [
+        this.formInline.cowID, 0, '', this.formInline.reason, this.userInfo.username
+      ], 'json').then((data) => {
+        if (data.rtnCode == -1) {
+          // this.$message({
+          //     message: data.rtnMessage,
+          //     type: 'warning'
+          // });
+          this.$alert(data.rtnMessage, '提示', {
+            confirmButtonText: '确定',
+            callback: action => {
+              this.formData.cowID = ''
+            }
+          });
+        }
+        else {
+          this.$message({
+            message: '录入成功',
+            type: 'success'
+          });
+          this.formData.cowID = ''
+          this.formInline.cowID = ''
+          this.handleClose = false
+          this.getList()
+        }
+      })
+    }
+  }
+}
+</script>
+<style lang="less" scoped>
+.containMain {
+  background: rgba(255, 255, 255, 1);
+  border-radius: 4px;
+  padding: 15px;
+  // margin-right: 10px;
+  .contentTitle {
+    border-bottom: 1px solid #f2f4f5;
+  }
+  // min-width: 450px;
+
+  .sub {
+    font-size: 14px;
+    font-weight: 600;
+    color: rgba(102, 102, 102, 1);
+    line-height: 20px;
+    margin-bottom: 40px;
+    padding-left: 20px;
+  }
+}
+
+.contentTitle {
+  font-size: 16px;
+  font-weight: bold;
+  color: rgba(0, 0, 0, 1);
+  line-height: 22px;
+  letter-spacing: 1px;
+  padding-bottom: 14px;
+  span {
+    font-size: 13px;
+    color: rgba(102, 102, 102, 1);
+    line-height: 18px;
+    margin-left: 10px;
+  }
+}
+.selectContent {
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+  padding: 20px 0;
+}
+
+.tableNum {
+  font-size: 13px;
+  font-weight: bold;
+  color: rgba(102, 102, 102, 1);
+  line-height: 18px;
+  padding-bottom: 15px;
+}
+.containAside {
+  padding: 0;
+
+  display: flex;
+  flex-direction: column;
+  .asideInfo {
+    flex-grow: 1;
+    background: rgba(255, 255, 255, 1);
+    border-radius: 4px;
+    padding: 15px;
+  }
+}
+
+.item {
+  .item-title {
+    font-size: 14px;
+    font-weight: bold;
+
+    color: rgba(0, 0, 0, 1);
+    line-height: 20px;
+    letter-spacing: 1px;
+  }
+
+  .text {
+    font-size: 13px;
+    color: rgba(0, 0, 0, 1);
+    line-height: 18px;
+    letter-spacing: 1px;
+    word-wrap: break-word;
+    padding: 10px 0 15px;
+  }
+}
+
+.HoofList {
+  display: flex;
+  width: 130px;
+  flex-wrap: wrap;
+  justify-content: space-between;
+  .hoof-item {
+    width: 60px;
+    height: 60px;
+    border-radius: 4px;
+    font-size: 13px;
+    font-weight: bold;
+    color: rgba(255, 255, 255, 1);
+    line-height: 18px;
+    text-align: center;
+    line-height: 60px;
+    background: rgb(0, 85, 128);
+    margin-bottom: 10px;
+    cursor: pointer;
+
+    &.active {
+      background: rgba(133, 195, 6, 1);
+    }
+  }
+}
+</style>

+ 619 - 579
src/main/vue/src/router/index.js

@@ -7,593 +7,633 @@ Vue.use(Router);
 
 const router = new Router({
     routes: [{
-        path: '/',
-        component: () =>
-            import('../pages/Admin'),
-        children: [{
             path: '/',
-            redirect: 'dashboard'
-        },
-        {
-            path: '/404',
-            name: '404',
-            component: () =>
-                import('../pages/404')
-        },
-        {
-            path: '/dashboard',
-            name: 'dashboard',
-            component: () =>
-                import('../pages/Dashboard')
-        },
-        {
-            path: '/users',
-            name: 'users',
-            component: () =>
-                import('../pages/Users')
-        },
-        {
-            path: '/user',
-            name: 'user',
-            component: () =>
-                import('../pages/User')
-        },
-        {
-            path: '/menus',
-            name: 'menus',
-            component: () =>
-                import('../pages/Menus')
-        },
-        {
-            path: '/roles',
-            name: 'roles',
-            component: () =>
-                import('../pages/Roles')
-        },
-        {
-            path: '/role',
-            name: 'role',
-            component: () =>
-                import('../pages/Role')
-        },
-        {
-            path: '/api',
-            name: 'api',
-            component: () =>
-                import('../pages/Api')
-        },
-        {
-            path: '/genCodes',
-            name: 'genCodes',
-            component: () =>
-                import('../pages/GenCodes')
-        },
-        {
-            path: '/genCode',
-            name: 'genCode',
-            component: () =>
-                import('../pages/GenCode')
-        },
-        {
-            path: '/permissions',
-            name: 'permissions',
-            component: () =>
-                import('../pages/Permissions')
-        },
-        {
-            path: '/permission',
-            name: 'permission',
-            component: () =>
-                import('../pages/Permission')
-        },
-        {
-            path: '/departs',
-            name: 'departs',
-            component: () =>
-                import('../pages/Departs')
-        },
-        {
-            path: '/lineChart',
-            name: 'lineChart',
-            component: () =>
-                import('../pages/LineChart')
-        },
-        {
-            path: '/barChart',
-            name: 'barChart',
-            component: () =>
-                import('../pages/BarChart')
-        },
-        {
-            path: '/polarAreaChart',
-            name: 'polarAreaChart',
-            component: () =>
-                import('../pages/PolarAreaChart')
-        },
-        {
-            path: '/pieChart',
-            name: 'pieChart',
-            component: () =>
-                import('../pages/PieChart')
-        },
-        {
-            path: '/radarChart',
-            name: 'radarChart',
-            component: () =>
-                import('../pages/RadarChart')
-        },
-        {
-            path: '/bubbleChart',
-            name: 'bubbleChart',
-            component: () =>
-                import('../pages/BubbleChart')
-        },
-        {
-            path: '/processModels',
-            name: 'processModels',
-            component: () =>
-                import('../pages/ProcessModels')
-        },
-        {
-            path: '/processDefinitions',
-            name: 'processDefinitions',
-            component: () =>
-                import('../pages/ProcessDefinitions')
-        },
-        {
-            path: '/myProcesses',
-            name: 'myProcesses',
-            component: () =>
-                import('../pages/MyProcesses')
-        },
-        {
-            path: '/myTasks',
-            name: 'myTasks',
-            component: () =>
-                import('../pages/MyTasks')
-        },
-        {
-            path: '/completeTaskDynamic',
-            name: 'CompleteTaskDynamic',
-            component: () =>
-                import('../pages/CompleteTaskDynamic')
-        },
-        {
-            path: '/tableShouyiYaopinxinxis',
-            name: 'tableShouyiYaopinxinxis',
-            component: () =>
-                import('../pages/TableShouyiYaopinxinxis')
-        },
-        {
-            path: '/tableShouyiYaopinxinxi',
-            name: 'tableShouyiYaopinxinxi',
-            component: () =>
-                import('../pages/TableShouyiYaopinxinxi')
-        },
-        {
-            path: '/testAaas',
-            name: 'testAaas',
-            component: () =>
-                import('../pages/TestAaas')
-        },
-        {
-            path: '/testAaa',
-            name: 'testAaa',
-            component: () =>
-                import('../pages/TestAaa')
-        },
-        {
-            path: '/testAaaLineChart',
-            name: 'testAaaLineChart',
-            component: () =>
-                import('../pages/TestAaaLineChart')
-        },
-        {
-            path: '/commonQuerys',
-            name: 'commonQuerys',
-            component: () =>
-                import('../pages/CommonQuerys')
-        },
-        {
-            path: '/commonQuery',
-            name: 'commonQuery',
-            component: () =>
-                import('../pages/CommonQuery')
-        },
-        {
-            path: '/commonIframe',
-            name: 'commonIframe',
-            component: () =>
-                import('../pages/CommonIframe')
-        },
-        {
-            path: '/queryConfigs',
-            name: 'queryConfigs',
-            component: () =>
-                import('../pages/QueryConfigs')
-        },
-        {
-            path: '/queryConfig',
-            name: 'queryConfig',
-            component: () =>
-                import('../pages/QueryConfig')
-        },
-        {
-            path: '/testBbbs',
-            name: 'testBbbs',
-            component: () =>
-                import('../pages/TestBbbs')
-        },
-        {
-            path: '/testBbb',
-            name: 'testBbb',
-            component: () =>
-                import('../pages/TestBbb')
-        },
-        {
-            path: '/testBbbCopys',
-            name: 'testBbbCopys',
-            component: () =>
-                import('../pages/TestBbbCopys')
-        },
-        {
-            path: '/testBbbCopy',
-            name: 'testBbbCopy',
-            component: () =>
-                import('../pages/TestBbbCopy')
-        },
-        {
-            path: '/dataSourceInfos',
-            name: 'dataSourceInfos',
-            component: () =>
-                import('../pages/DataSourceInfos')
-        },
-        {
-            path: '/dataSourceInfo',
-            name: 'dataSourceInfo',
-            component: () =>
-                import('../pages/DataSourceInfo')
-        },
-        {
-            path: '/testSqlserverAaas',
-            name: 'testSqlserverAaas',
-            component: () =>
-                import('../pages/TestSqlserverAaas')
-        },
-        {
-            path: '/TestSqlserverAaa',
-            name: 'TestSqlserverAaa',
-            component: () =>
-                import('../pages/TestSqlserverAaa')
-        },
-        {
-            path: '/deploySystem',
-            name: 'DeploySystem',
             component: () =>
-                import('../pages/DeploySystem')
-        },
-        {
-            path: '/testDeploy',
-            name: 'TestDeploy',
-            component: () =>
-                import('../pages/TestDeploy')
-        },
-        {
-            path: '/testDeploys',
-            name: 'TestDeploys',
-            component: () =>
-                import('../pages/TestDeploys')
-        },
-        {
-            path: '/testaaaone',
-            name: 'Testaaaone',
-            component: () =>
-                import('../pages/Testaaaone')
-        },
-        {
-            path: '/testaaaones',
-            name: 'Testaaaones',
-            component: () =>
-                import('../pages/Testaaaones')
-        },
-        {
-            path: '/testgit',
-            name: 'Testgit',
-            component: () =>
-                import('../pages/Testgit')
-        },
-        {
-            path: '/testgits',
-            name: 'Testgits',
-            component: () =>
-                import('../pages/Testgits')
-        },
-        {
-            path: '/testCaidan',
-            name: 'TestCaidan',
-            component: () =>
-                import('../pages/TestCaidan')
-        },
-        {
-            path: '/testCaidans',
-            name: 'TestCaidans',
-            component: () =>
-                import('../pages/TestCaidans')
-        },
-        {
-            path: '/tableNiuseRongliang',
-            name: 'TableNiuseRongliang',
-            component: () =>
-                import('../pages/TableNiuseRongliang')
-        },
-        {
-            path: '/tableNiuseRongliangs',
-            name: 'TableNiuseRongliangs',
-            component: () =>
-                import('../pages/TableNiuseRongliangs')
-        },
-        /**INSERT_LOCATION**/
+                import ('../pages/Admin'),
+            children: [{
+                    path: '/',
+                    redirect: 'dashboard'
+                },
+                {
+                    path: '/404',
+                    name: '404',
+                    component: () =>
+                        import ('../pages/404')
+                },
+                {
+                    path: '/dashboard',
+                    name: 'dashboard',
+                    component: () =>
+                        import ('../pages/Dashboard')
+                },
+                {
+                    path: '/users',
+                    name: 'users',
+                    component: () =>
+                        import ('../pages/Users')
+                },
+                {
+                    path: '/user',
+                    name: 'user',
+                    component: () =>
+                        import ('../pages/User')
+                },
+                {
+                    path: '/menus',
+                    name: 'menus',
+                    component: () =>
+                        import ('../pages/Menus')
+                },
+                {
+                    path: '/roles',
+                    name: 'roles',
+                    component: () =>
+                        import ('../pages/Roles')
+                },
+                {
+                    path: '/role',
+                    name: 'role',
+                    component: () =>
+                        import ('../pages/Role')
+                },
+                {
+                    path: '/api',
+                    name: 'api',
+                    component: () =>
+                        import ('../pages/Api')
+                },
+                {
+                    path: '/genCodes',
+                    name: 'genCodes',
+                    component: () =>
+                        import ('../pages/GenCodes')
+                },
+                {
+                    path: '/genCode',
+                    name: 'genCode',
+                    component: () =>
+                        import ('../pages/GenCode')
+                },
+                {
+                    path: '/permissions',
+                    name: 'permissions',
+                    component: () =>
+                        import ('../pages/Permissions')
+                },
+                {
+                    path: '/permission',
+                    name: 'permission',
+                    component: () =>
+                        import ('../pages/Permission')
+                },
+                {
+                    path: '/departs',
+                    name: 'departs',
+                    component: () =>
+                        import ('../pages/Departs')
+                },
+                {
+                    path: '/lineChart',
+                    name: 'lineChart',
+                    component: () =>
+                        import ('../pages/LineChart')
+                },
+                {
+                    path: '/barChart',
+                    name: 'barChart',
+                    component: () =>
+                        import ('../pages/BarChart')
+                },
+                {
+                    path: '/polarAreaChart',
+                    name: 'polarAreaChart',
+                    component: () =>
+                        import ('../pages/PolarAreaChart')
+                },
+                {
+                    path: '/pieChart',
+                    name: 'pieChart',
+                    component: () =>
+                        import ('../pages/PieChart')
+                },
+                {
+                    path: '/radarChart',
+                    name: 'radarChart',
+                    component: () =>
+                        import ('../pages/RadarChart')
+                },
+                {
+                    path: '/bubbleChart',
+                    name: 'bubbleChart',
+                    component: () =>
+                        import ('../pages/BubbleChart')
+                },
+                {
+                    path: '/processModels',
+                    name: 'processModels',
+                    component: () =>
+                        import ('../pages/ProcessModels')
+                },
+                {
+                    path: '/processDefinitions',
+                    name: 'processDefinitions',
+                    component: () =>
+                        import ('../pages/ProcessDefinitions')
+                },
+                {
+                    path: '/myProcesses',
+                    name: 'myProcesses',
+                    component: () =>
+                        import ('../pages/MyProcesses')
+                },
+                {
+                    path: '/myTasks',
+                    name: 'myTasks',
+                    component: () =>
+                        import ('../pages/MyTasks')
+                },
+                {
+                    path: '/completeTaskDynamic',
+                    name: 'CompleteTaskDynamic',
+                    component: () =>
+                        import ('../pages/CompleteTaskDynamic')
+                },
+                {
+                    path: '/tableShouyiYaopinxinxis',
+                    name: 'tableShouyiYaopinxinxis',
+                    component: () =>
+                        import ('../pages/TableShouyiYaopinxinxis')
+                },
+                {
+                    path: '/tableShouyiYaopinxinxi',
+                    name: 'tableShouyiYaopinxinxi',
+                    component: () =>
+                        import ('../pages/TableShouyiYaopinxinxi')
+                },
+                {
+                    path: '/testAaas',
+                    name: 'testAaas',
+                    component: () =>
+                        import ('../pages/TestAaas')
+                },
+                {
+                    path: '/testAaa',
+                    name: 'testAaa',
+                    component: () =>
+                        import ('../pages/TestAaa')
+                },
+                {
+                    path: '/testAaaLineChart',
+                    name: 'testAaaLineChart',
+                    component: () =>
+                        import ('../pages/TestAaaLineChart')
+                },
+                {
+                    path: '/commonQuerys',
+                    name: 'commonQuerys',
+                    component: () =>
+                        import ('../pages/CommonQuerys')
+                },
+                {
+                    path: '/commonQuery',
+                    name: 'commonQuery',
+                    component: () =>
+                        import ('../pages/CommonQuery')
+                },
+                {
+                    path: '/commonIframe',
+                    name: 'commonIframe',
+                    component: () =>
+                        import ('../pages/CommonIframe')
+                },
+                {
+                    path: '/queryConfigs',
+                    name: 'queryConfigs',
+                    component: () =>
+                        import ('../pages/QueryConfigs')
+                },
+                {
+                    path: '/queryConfig',
+                    name: 'queryConfig',
+                    component: () =>
+                        import ('../pages/QueryConfig')
+                },
+                {
+                    path: '/testBbbs',
+                    name: 'testBbbs',
+                    component: () =>
+                        import ('../pages/TestBbbs')
+                },
+                {
+                    path: '/testBbb',
+                    name: 'testBbb',
+                    component: () =>
+                        import ('../pages/TestBbb')
+                },
+                {
+                    path: '/testBbbCopys',
+                    name: 'testBbbCopys',
+                    component: () =>
+                        import ('../pages/TestBbbCopys')
+                },
+                {
+                    path: '/testBbbCopy',
+                    name: 'testBbbCopy',
+                    component: () =>
+                        import ('../pages/TestBbbCopy')
+                },
+                {
+                    path: '/dataSourceInfos',
+                    name: 'dataSourceInfos',
+                    component: () =>
+                        import ('../pages/DataSourceInfos')
+                },
+                {
+                    path: '/dataSourceInfo',
+                    name: 'dataSourceInfo',
+                    component: () =>
+                        import ('../pages/DataSourceInfo')
+                },
+                {
+                    path: '/testSqlserverAaas',
+                    name: 'testSqlserverAaas',
+                    component: () =>
+                        import ('../pages/TestSqlserverAaas')
+                },
+                {
+                    path: '/TestSqlserverAaa',
+                    name: 'TestSqlserverAaa',
+                    component: () =>
+                        import ('../pages/TestSqlserverAaa')
+                },
+                {
+                    path: '/deploySystem',
+                    name: 'DeploySystem',
+                    component: () =>
+                        import ('../pages/DeploySystem')
+                },
+                {
+                    path: '/testDeploy',
+                    name: 'TestDeploy',
+                    component: () =>
+                        import ('../pages/TestDeploy')
+                },
+                {
+                    path: '/testDeploys',
+                    name: 'TestDeploys',
+                    component: () =>
+                        import ('../pages/TestDeploys')
+                },
+                {
+                    path: '/testaaaone',
+                    name: 'Testaaaone',
+                    component: () =>
+                        import ('../pages/Testaaaone')
+                },
+                {
+                    path: '/testaaaones',
+                    name: 'Testaaaones',
+                    component: () =>
+                        import ('../pages/Testaaaones')
+                },
+                {
+                    path: '/testgit',
+                    name: 'Testgit',
+                    component: () =>
+                        import ('../pages/Testgit')
+                },
+                {
+                    path: '/testgits',
+                    name: 'Testgits',
+                    component: () =>
+                        import ('../pages/Testgits')
+                },
+                {
+                    path: '/testCaidan',
+                    name: 'TestCaidan',
+                    component: () =>
+                        import ('../pages/TestCaidan')
+                },
+                {
+                    path: '/testCaidans',
+                    name: 'TestCaidans',
+                    component: () =>
+                        import ('../pages/TestCaidans')
+                },
+                {
+                    path: '/tableNiuseRongliang',
+                    name: 'TableNiuseRongliang',
+                    component: () =>
+                        import ('../pages/TableNiuseRongliang')
+                },
+                {
+                    path: '/tableNiuseRongliangs',
+                    name: 'TableNiuseRongliangs',
+                    component: () =>
+                        import ('../pages/TableNiuseRongliangs')
+                },
+                /**INSERT_LOCATION**/
 
-        {
-            path: '/handleLeaveAdd',
-            name: 'handleLeaveAdd',
-            component: () =>
-                import('../pages/HandleLeaveAdd'),
-            meta: {
-                type: '手持机录入',
-                title: '离场登记'
-            }
-        },
+                {
+                    path: '/handleLeaveAdd',
+                    name: 'handleLeaveAdd',
+                    component: () =>
+                        import ('../pages/HandleLeaveAdd'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '离场登记'
+                    }
+                },
 
-        {
-            path: '/handleEstrusEvent',
-            name: 'handleEstrusEvent',
-            component: () =>
-                import('../pages/HandleEstrusEvent'),
-            meta: {
-                type: '手持机录入',
-                title: '发情事件'
-            }
-        },
+                {
+                    path: '/handleEstrusEvent',
+                    name: 'handleEstrusEvent',
+                    component: () =>
+                        import ('../pages/HandleEstrusEvent'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '发情事件'
+                    }
+                },
 
-        {
-            path: '/handleMatch',
-            name: 'handleMatch',
-            component: () =>
-                import('../pages/HandleMatch'),
-            meta: {
-                type: '手持机录入',
-                title: '配种任务'
-            }
-        },
-        {
-            path: '/handleSimultaneousMatch',
-            name: 'handleSimultaneousMatch',
-            component: () =>
-                import('../pages/HandleSimultaneousMatch'),
-            meta: {
-                type: '手持机录入',
-                title: '同期配种'
-            }
-        },
-        {
-            path: '/handleInitial',
-            name: 'handleInitial',
-            component: () =>
-                import('../pages/HandleInitial'),
-            meta: {
-                type: '手持机录入',
-                title: '初检录入'
-            }
-        },
-        {
-            path: '/handleRecheck',
-            name: 'handleRecheck',
-            component: () =>
-                import('../pages/HandleRecheck'),
-            meta: {
-                type: '手持机录入',
-                title: '复检录入'
-            }
-        },
-        {
-            path: '/handleAbortion',
-            name: 'handleAbortion',
-            component: () =>
-                import('../pages/HandleAbortion'),
-            meta: {
-                type: '手持机录入',
-                title: '流产登记'
-            }
-        },
-        {
-            path: '/handleDryMilk',
-            name: 'handleDryMilk',
-            component: () =>
-                import('../pages/HandleDryMilk'),
-            meta: {
-                type: '手持机录入',
-                title: '干奶登记'
-            }
-        },
-        {
-            path: '/handlePerinatalCare',
-            name: 'handlePerinatalCare',
-            component: () =>
-                import('../pages/HandlePerinatalCare'),
-            meta: {
-                type: '手持机录入',
-                title: '围产期护理'
-            }
-        },
-        {
-            path: '/handleFeeding',
-            name: 'handleFeeding',
-            component: () =>
-                import('../pages/HandleFeeding'),
-            meta: {
-                type: '手持机录入',
-                title: '投喂博威钙'
-            }
-        },
-        {
-            path: '/handleHoofCare',
-            name: 'handleHoofCare',
-            component: () =>
-                import('../pages/HandleHoofCare'),
-            meta: {
-                type: '手持机录入',
-                title: '修蹄保健'
-            }
-        },
-        {
-            path: '/handleTransferHouse',
-            name: 'handleTransferHouse',
-            component: () =>
-                import('../pages/HandleTransferHouse'),
-            meta: {
-                type: '手持机录入',
-                title: '奶牛转舍'
-            }
-        },
-        {
-            path: '/handleCalving',
-            name: 'handleCalving',
-            component: () =>
-                import('../pages/HandleCalving'),
-            meta: {
-                type: '手持机录入',
-                title: '产犊登记'
-            }
-        },
-        {
-            path: '/handleCalf',
-            name: 'handleCalf',
-            component: () =>
-                import('../pages/HandleCalf'),
-            meta: {
-                type: '手持机录入',
-                title: '犊牛登记'
-            }
-        },
-        {
-            path: '/handlePerinatal',
-            name: 'handlePerinatal',
-            component: () =>
-                import('../pages/HandlePerinatal'),
-            meta: {
-                type: '手持机录入',
-                title: '产前围产'
-            }
-        },
-        {
-            path: '/handleDiagnosis',
-            name: 'handleDiagnosis',
-            component: () =>
-                import('../pages/HandleDiagnosis'),
-            meta: {
-                type: '手持机录入',
-                title: '疾病确诊'
-            }
-        },
-        {
-            path: '/handleTreatment',
-            name: 'handleTreatment',
-            component: () =>
-                import('../pages/HandleTreatment'),
-            meta: {
-                type: '手持机录入',
-                title: '日常治疗'
-            }
-        },
-        {
-            path: '/handleSampling',
-            name: 'handleSampling',
-            component: () =>
-                import('../pages/HandleSampling'),
-            meta: {
-                type: '手持机录入',
-                title: '过抗采样'
-            }
-        },
-        {
-            path: '/handleOutcome',
-            name: 'handleOutcome',
-            component: () =>
-                import('../pages/HandleOutcome'),
-            meta: {
-                type: '手持机录入',
-                title: '转归处理'
-            }
-        },
-        {
-            path: '/handleBlindMilk',
-            name: 'handleBlindMilk',
-            component: () =>
-                import('../pages/HandleBlindMilk'),
-            meta: {
-                type: '手持机录入',
-                title: '盲乳登记'
-            }
-        },
-        {
-            path: '/handleGrowth',
-            name: 'handleGrowth',
-            component: () =>
-                import('../pages/HandleGrowth'),
-            meta: {
-                type: '手持机录入',
-                title: '盲乳登记'
-            }
-        },
-        {
-            path: '/handleProhibition',
-            name: 'handleProhibition',
-            component: () =>
-                import('../pages/HandleProhibition'),
-            meta: {
-                type: '手持机录入',
-                title: '禁配解禁'
-            }
-        },
-        {
-            path: '/handleFeedingMagnet',
-            name: 'handleFeedingMagnet',
-            component: () =>
-                import('../pages/HandleFeedingMagnet'),
-            meta: {
-                type: '手持机录入 ',
-                title: '投喂磁石'
-            }
+                {
+                    path: '/handleMatch',
+                    name: 'handleMatch',
+                    component: () =>
+                        import ('../pages/HandleMatch'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '配种任务'
+                    }
+                },
+                {
+                    path: '/handleSimultaneousMatch',
+                    name: 'handleSimultaneousMatch',
+                    component: () =>
+                        import ('../pages/HandleSimultaneousMatch'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '同期配种'
+                    }
+                },
+                {
+                    path: '/handleInitial',
+                    name: 'handleInitial',
+                    component: () =>
+                        import ('../pages/HandleInitial'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '初检录入'
+                    }
+                },
+                {
+                    path: '/handleRecheck',
+                    name: 'handleRecheck',
+                    component: () =>
+                        import ('../pages/HandleRecheck'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '复检录入'
+                    }
+                },
+                {
+                    path: '/handleAbortion',
+                    name: 'handleAbortion',
+                    component: () =>
+                        import ('../pages/HandleAbortion'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '流产登记'
+                    }
+                },
+                {
+                    path: '/handleDryMilk',
+                    name: 'handleDryMilk',
+                    component: () =>
+                        import ('../pages/HandleDryMilk'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '干奶登记'
+                    }
+                },
+                {
+                    path: '/handlePerinatalCare',
+                    name: 'handlePerinatalCare',
+                    component: () =>
+                        import ('../pages/HandlePerinatalCare'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '围产期护理'
+                    }
+                },
+                {
+                    path: '/handleFeeding',
+                    name: 'handleFeeding',
+                    component: () =>
+                        import ('../pages/HandleFeeding'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '投喂博威钙'
+                    }
+                },
+                {
+                    path: '/handleHoofCare',
+                    name: 'handleHoofCare',
+                    component: () =>
+                        import ('../pages/HandleHoofCare'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '修蹄保健'
+                    }
+                },
+                {
+                    path: '/handleTransferHouse',
+                    name: 'handleTransferHouse',
+                    component: () =>
+                        import ('../pages/HandleTransferHouse'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '奶牛转舍'
+                    }
+                },
+                {
+                    path: '/handleCalving',
+                    name: 'handleCalving',
+                    component: () =>
+                        import ('../pages/HandleCalving'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '产犊登记'
+                    }
+                },
+                {
+                    path: '/handleCalf',
+                    name: 'handleCalf',
+                    component: () =>
+                        import ('../pages/HandleCalf'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '犊牛登记'
+                    }
+                },
+                {
+                    path: '/handlePerinatal',
+                    name: 'handlePerinatal',
+                    component: () =>
+                        import ('../pages/HandlePerinatal'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '产前围产'
+                    }
+                },
+                {
+                    path: '/handleDiagnosis',
+                    name: 'handleDiagnosis',
+                    component: () =>
+                        import ('../pages/HandleDiagnosis'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '疾病确诊'
+                    }
+                },
+                {
+                    path: '/handleTreatment',
+                    name: 'handleTreatment',
+                    component: () =>
+                        import ('../pages/HandleTreatment'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '日常治疗'
+                    }
+                },
+                {
+                    path: '/handleSampling',
+                    name: 'handleSampling',
+                    component: () =>
+                        import ('../pages/HandleSampling'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '过抗采样'
+                    }
+                },
+                {
+                    path: '/handleOutcome',
+                    name: 'handleOutcome',
+                    component: () =>
+                        import ('../pages/HandleOutcome'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '转归处理'
+                    }
+                },
+                {
+                    path: '/handleBlindMilk',
+                    name: 'handleBlindMilk',
+                    component: () =>
+                        import ('../pages/HandleBlindMilk'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '盲乳登记'
+                    }
+                },
+                {
+                    path: '/handleGrowth',
+                    name: 'handleGrowth',
+                    component: () =>
+                        import ('../pages/HandleGrowth'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '盲乳登记'
+                    }
+                },
+                {
+                    path: '/handleProhibition',
+                    name: 'handleProhibition',
+                    component: () =>
+                        import ('../pages/HandleProhibition'),
+                    meta: {
+                        type: '手持机录入',
+                        title: '禁配解禁'
+                    }
+                },
+                {
+                    path: '/handleFeedingMagnet',
+                    name: 'handleFeedingMagnet',
+                    component: () =>
+                        import ('../pages/HandleFeedingMagnet'),
+                    meta: {
+                        type: '手持机录入 ',
+                        title: '投喂磁石'
+                    }
+                },
+                {
+                    path: '/handleImmunopotency',
+                    name: 'handleImmunopotency',
+                    component: () =>
+                        import ('../pages/HandleImmunopotency'),
+                    meta: {
+                        type: '手持机录入 ',
+                        title: '免疫效价'
+                    }
+                },
+                {
+                    path: '/handlePhoto',
+                    name: 'handlePhoto',
+                    component: () =>
+                        import ('../pages/HandlePhoto'),
+                    meta: {
+                        type: '手持机录入 ',
+                        title: '犊牛拍照'
+                    }
+                },
+                {
+                    path: '/handleBeestings',
+                    name: 'handleBeestings',
+                    component: () =>
+                        import ('../pages/HandleBeestings'),
+                    meta: {
+                        type: '手持机录入 ',
+                        title: '初乳饲喂'
+                    }
+                },
+                {
+                    path: '/handleWeaning',
+                    name: 'handleWeaning',
+                    component: () =>
+                        import ('../pages/HandleWeaning'),
+                    meta: {
+                        type: '手持机录入 ',
+                        title: '断奶登记'
+                    }
+                },
+                {
+                    path: '/handleApproach',
+                    name: 'handleApproach',
+                    component: () =>
+                        import ('../pages/HandleApproach'),
+                    meta: {
+                        type: '手持机录入 ',
+                        title: '进场登记'
+                    }
+                },
+                {
+                    path: '/handleTransition',
+                    name: 'handleTransition',
+                    component: () =>
+                        import ('../pages/HandleTransition'),
+                    meta: {
+                        type: '手持机录入 ',
+                        title: '转场登记'
+                    }
+                }
+            ]
         },
         {
-            path: '/handleImmunopotency',
-            name: 'handleImmunopotency',
+            path: '/login',
+            name: 'login',
             component: () =>
-                import('../pages/HandleImmunopotency'),
-            meta: {
-                type: '手持机录入 ',
-                title: '免疫效价'
-            }
-        },
-            // {
-            //     path: '/handlePhoto',
-            //     name: 'handlePhoto',
-            //     component: () =>
-            //         import ('../pages/HandlePhoto'),
-            //     meta: {
-            //         type: '手持机录入 ',
-            //         title: '犊牛拍照'
-            //     }
-            // }
-        ]
-    },
-    {
-        path: '/login',
-        name: 'login',
-        component: () =>
-            import('../pages/Login')
-    }
+                import ('../pages/Login')
+        }
     ]
 });
 router.beforeEach((to, from, next) => {