|
@@ -60,7 +60,7 @@
|
|
<span>{{ scope.row.cowclass }}</span>
|
|
<span>{{ scope.row.cowclass }}</span>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
- <el-table-column label="牛头数" min-width="58px" align="center">
|
|
|
|
|
|
+ <el-table-column label="羊只数" min-width="58px" align="center">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<span>{{ scope.row.cowsum }}</span>
|
|
<span>{{ scope.row.cowsum }}</span>
|
|
</template>
|
|
</template>
|
|
@@ -95,7 +95,7 @@
|
|
<span>{{ scope.row.dayspre }}</span>
|
|
<span>{{ scope.row.dayspre }}</span>
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
- <el-table-column label="产奶量(kg/头)" min-width="60px" align="center">
|
|
|
|
|
|
+ <el-table-column label="产奶量(kg/只)" min-width="60px" align="center">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
<span>{{ scope.row.product }}</span>
|
|
<span>{{ scope.row.product }}</span>
|
|
</template>
|
|
</template>
|
|
@@ -200,7 +200,7 @@
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-col>
|
|
</el-col>
|
|
<el-col :span="6">
|
|
<el-col :span="6">
|
|
- <el-form-item label="牛头数:" prop="cowsum">
|
|
|
|
|
|
+ <el-form-item label="羊只数:" prop="cowsum">
|
|
<el-input ref="cowsum" v-model="create.temp.cowsum" class="filter-item" placeholder="正整数" type="number" step="0.01" />
|
|
<el-input ref="cowsum" v-model="create.temp.cowsum" class="filter-item" placeholder="正整数" type="number" step="0.01" />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-col>
|
|
</el-col>
|
|
@@ -249,7 +249,7 @@
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-col>
|
|
</el-col>
|
|
<el-col :span="6">
|
|
<el-col :span="6">
|
|
- <el-form-item label="产奶量(kg/头):" prop="product">
|
|
|
|
|
|
+ <el-form-item label="产奶量(kg/只):" prop="product">
|
|
<el-input ref="product" v-model="create.temp.product" :disabled="create.temp.bigcowclass=='后备牛' || create.temp.bigcowclass=='干奶牛'" class="filter-item" placeholder="最多两位小数" type="number" />
|
|
<el-input ref="product" v-model="create.temp.product" :disabled="create.temp.bigcowclass=='后备牛' || create.temp.bigcowclass=='干奶牛'" class="filter-item" placeholder="最多两位小数" type="number" />
|
|
</el-form-item>
|
|
</el-form-item>
|
|
</el-col>
|
|
</el-col>
|
|
@@ -395,7 +395,7 @@ export default {
|
|
uploadData() {
|
|
uploadData() {
|
|
return {
|
|
return {
|
|
name: 'checkbarname,checkclassname,insertBarmilkUpload',
|
|
name: 'checkbarname,checkclassname,insertBarmilkUpload',
|
|
- importParams: '栏舍名称,牲畜类别,牛头数,环境温度(℃),平均月龄,体重(kg),日增重(kg),怀孕天数,胎次,平均泌乳天数,产奶量(kg/头),乳脂率(%),乳蛋白率(%),乳糖率(%),记录人,生效日期',
|
|
|
|
|
|
+ importParams: '栏舍名称,牲畜类别,羊只数,环境温度(℃),平均月龄,体重(kg),日增重(kg),怀孕天数,胎次,平均泌乳天数,产奶量(kg/只),乳脂率(%),乳蛋白率(%),乳糖率(%),记录人,生效日期',
|
|
sheetname: 'Sheet1',
|
|
sheetname: 'Sheet1',
|
|
// 登录牧场
|
|
// 登录牧场
|
|
pastureid: Cookies.get('pastureid'),
|
|
pastureid: Cookies.get('pastureid'),
|
|
@@ -404,7 +404,7 @@ export default {
|
|
// 必填参数
|
|
// 必填参数
|
|
requiredParams: '栏舍名称',
|
|
requiredParams: '栏舍名称',
|
|
// 为数值的参数
|
|
// 为数值的参数
|
|
- numParams: '牛头数,环境温度(℃),平均月龄,体重(kg),日增重(kg),怀孕天数,胎次,平均泌乳天数,产奶量(kg/头),乳脂率(%),乳蛋白率(%),乳糖率(%)'
|
|
|
|
|
|
+ numParams: '羊只数,环境温度(℃),平均月龄,体重(kg),日增重(kg),怀孕天数,胎次,平均泌乳天数,产奶量(kg/只),乳脂率(%),乳蛋白率(%),乳糖率(%)'
|
|
}
|
|
}
|
|
},
|
|
},
|
|
// 设置上传地址
|
|
// 设置上传地址
|
|
@@ -555,10 +555,10 @@ export default {
|
|
this.isokDisable = false
|
|
this.isokDisable = false
|
|
}, 1000)
|
|
}, 1000)
|
|
const positiveInteger = /^[1-9]\d*$/
|
|
const positiveInteger = /^[1-9]\d*$/
|
|
- // 牛头数
|
|
|
|
|
|
+ // 羊只数
|
|
if (this.create.temp.cowsum !== '') {
|
|
if (this.create.temp.cowsum !== '') {
|
|
if (!positiveInteger.test(parseFloat(this.create.temp.cowsum))) {
|
|
if (!positiveInteger.test(parseFloat(this.create.temp.cowsum))) {
|
|
- this.$message({ type: 'error', message: '牛头数请输入正整数', duration: 2000 })
|
|
|
|
|
|
+ this.$message({ type: 'error', message: '羊只数请输入正整数', duration: 2000 })
|
|
return false
|
|
return false
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -700,10 +700,10 @@ export default {
|
|
this.isokDisable = false
|
|
this.isokDisable = false
|
|
}, 1000)
|
|
}, 1000)
|
|
const positiveInteger = /^[1-9]\d*$/
|
|
const positiveInteger = /^[1-9]\d*$/
|
|
- // 牛头数
|
|
|
|
|
|
+ // 羊只数
|
|
if (this.create.temp.cowsum !== '') {
|
|
if (this.create.temp.cowsum !== '') {
|
|
if (!positiveInteger.test(parseFloat(this.create.temp.cowsum))) {
|
|
if (!positiveInteger.test(parseFloat(this.create.temp.cowsum))) {
|
|
- this.$message({ type: 'error', message: '牛头数请输入正整数', duration: 2000 })
|
|
|
|
|
|
+ this.$message({ type: 'error', message: '羊只数请输入正整数', duration: 2000 })
|
|
return false
|
|
return false
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -862,10 +862,10 @@ export default {
|
|
this.isokDisable = false
|
|
this.isokDisable = false
|
|
}, 1000)
|
|
}, 1000)
|
|
const positiveInteger = /^[1-9]\d*$/
|
|
const positiveInteger = /^[1-9]\d*$/
|
|
- // 牛头数
|
|
|
|
|
|
+ // 羊只数
|
|
if (this.create.temp.cowsum !== '') {
|
|
if (this.create.temp.cowsum !== '') {
|
|
if (!positiveInteger.test(parseFloat(this.create.temp.cowsum))) {
|
|
if (!positiveInteger.test(parseFloat(this.create.temp.cowsum))) {
|
|
- this.$message({ type: 'error', message: '牛头数请输入正整数', duration: 2000 })
|
|
|
|
|
|
+ this.$message({ type: 'error', message: '羊只数请输入正整数', duration: 2000 })
|
|
return false
|
|
return false
|
|
}
|
|
}
|
|
}
|
|
}
|
|
@@ -1124,7 +1124,7 @@ export default {
|
|
}
|
|
}
|
|
var excelDatas = [
|
|
var excelDatas = [
|
|
{
|
|
{
|
|
- tHeader: ['栏舍名称', '牲畜类别', '牛头数', '环境温度(℃)', '平均月龄', '体重(kg)', '日增重(kg)', '怀孕天数', '胎次', '平均泌乳天数', '产奶量(kg/头)', '乳脂率(%)', '乳蛋白率(%)', '乳糖率(%)', '记录人', '生效日期'],
|
|
|
|
|
|
+ tHeader: ['栏舍名称', '牲畜类别', '羊只数', '环境温度(℃)', '平均月龄', '体重(kg)', '日增重(kg)', '怀孕天数', '胎次', '平均泌乳天数', '产奶量(kg/只)', '乳脂率(%)', '乳蛋白率(%)', '乳糖率(%)', '记录人', '生效日期'],
|
|
filterVal: ['barname', 'cowclass', 'cowsum', 'tem', 'avgmonthage', 'bw', 'dayw', 'dayspre', 'fetal', 'avgdim', 'product', 'fat', 'pro', 'lactose', 'emp', 'productdate'],
|
|
filterVal: ['barname', 'cowclass', 'cowsum', 'tem', 'avgmonthage', 'bw', 'dayw', 'dayspre', 'fetal', 'avgdim', 'product', 'fat', 'pro', 'lactose', 'emp', 'productdate'],
|
|
tableDatas: this.download.list,
|
|
tableDatas: this.download.list,
|
|
sheetName: 'Sheet1'
|
|
sheetName: 'Sheet1'
|
|
@@ -1150,10 +1150,10 @@ export default {
|
|
import('@/vendor/Export2Excel').then(excel => {
|
|
import('@/vendor/Export2Excel').then(excel => {
|
|
const list1 = res.data.result
|
|
const list1 = res.data.result
|
|
const tHeader = [
|
|
const tHeader = [
|
|
- '栏舍名称', '牲畜类别', '牛头数', '环境温度(℃)', '平均月龄', '体重(kg)', '日增重(kg)', '怀孕天数', '胎次', '平均泌乳天数', '产奶量(kg/头)', '乳脂率(%)', '乳蛋白率(%)', '乳糖率(%)', '记录人', '生效日期', '错误信息'
|
|
|
|
|
|
+ '栏舍名称', '牲畜类别', '羊只数', '环境温度(℃)', '平均月龄', '体重(kg)', '日增重(kg)', '怀孕天数', '胎次', '平均泌乳天数', '产奶量(kg/只)', '乳脂率(%)', '乳蛋白率(%)', '乳糖率(%)', '记录人', '生效日期', '错误信息'
|
|
]
|
|
]
|
|
const filterVal = [
|
|
const filterVal = [
|
|
- '栏舍名称', '牲畜类别', '牛头数', '环境温度(℃)', '平均月龄', '体重(kg)', '日增重(kg)', '怀孕天数', '胎次', '平均泌乳天数', '产奶量(kg/头)', '乳脂率(%)', '乳蛋白率(%)', '乳糖率(%)', '记录人', '生效日期', 'error_msg'
|
|
|
|
|
|
+ '栏舍名称', '牲畜类别', '羊只数', '环境温度(℃)', '平均月龄', '体重(kg)', '日增重(kg)', '怀孕天数', '胎次', '平均泌乳天数', '产奶量(kg/只)', '乳脂率(%)', '乳蛋白率(%)', '乳糖率(%)', '记录人', '生效日期', 'error_msg'
|
|
]
|
|
]
|
|
const data1 = this.formatJson(filterVal, list1)
|
|
const data1 = this.formatJson(filterVal, list1)
|
|
excel.export_json_to_excel({ header: tHeader, data: data1, filename: '栏舍生产性能导入报错信息', autoWidth: true, bookType: 'xlsx' })
|
|
excel.export_json_to_excel({ header: tHeader, data: data1, filename: '栏舍生产性能导入报错信息', autoWidth: true, bookType: 'xlsx' })
|