|
|
@@ -138,10 +138,18 @@
|
|
|
<el-table-column label="跳转方式" min-width="60px" align="center" prop="buttontype" />
|
|
|
<el-table-column label="开始重量" min-width="60px" align="center" prop="lastactualweight" />
|
|
|
<el-table-column label="结束重量" min-width="60px" align="center" prop="actualweight" />
|
|
|
+ <el-table-column
|
|
|
+ fixed="right"
|
|
|
+ label="操作"
|
|
|
+ width="80px">
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <el-button @click="handleClick(scope.row)" type="text" size="small">编辑</el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
</el-table>
|
|
|
</div>
|
|
|
</el-col>
|
|
|
- <!-- 撒料计划 -->
|
|
|
+ <!-- 撒料计划 3-->
|
|
|
<el-col v-if="isSpreadingPlan" :span="16">
|
|
|
<div class="title">
|
|
|
<b>过程详情</b>
|
|
|
@@ -178,7 +186,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="Mixture">
|
|
|
- <h4>混料详情</h4>
|
|
|
+ <h4>混料详情3</h4>
|
|
|
<el-table
|
|
|
:key="table3.tableKey"
|
|
|
v-loading="table3.listLoading"
|
|
|
@@ -209,11 +217,18 @@
|
|
|
<el-table-column label="跳转方式" min-width="70px" align="center" prop="buttontype" />
|
|
|
<el-table-column label="开始重量" min-width="70px" align="center" prop="lastactualweight" />
|
|
|
<el-table-column label="结束重量" min-width="70px" align="center" prop="actualweight" />
|
|
|
+ <el-table-column
|
|
|
+ label="操作"
|
|
|
+ width="90px">
|
|
|
+ <template slot-scope="scope" >
|
|
|
+ <el-button v-if="scope.row.sort != '合计'" @click="handleClick(scope.row,1)" type="text" size="small">编辑</el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
</el-table>
|
|
|
</div>
|
|
|
|
|
|
<div class="SpreadingMaterials">
|
|
|
- <h4>撒料详情</h4>
|
|
|
+ <h4>撒料详情3</h4>
|
|
|
<el-table
|
|
|
:key="table4.tableKey"
|
|
|
v-loading="table4.listLoading"
|
|
|
@@ -244,6 +259,13 @@
|
|
|
<el-table-column label="跳转方式" min-width="70px" align="center" prop="buttontype" />
|
|
|
<el-table-column label="开始重量" min-width="70px" align="center" prop="lastactualweight" />
|
|
|
<el-table-column label="结束重量" min-width="70px" align="center" prop="actualweight" />
|
|
|
+ <el-table-column
|
|
|
+ label="操作"
|
|
|
+ width="90px">
|
|
|
+ <template slot-scope="scope" >
|
|
|
+ <el-button v-if="scope.row.sort != '合计'" @click="handleClick(scope.row,2)" type="text" size="small">编辑</el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
</el-table>
|
|
|
</div>
|
|
|
<div class="ControlChart">
|
|
|
@@ -251,7 +273,7 @@
|
|
|
<div id="chartLine" style="width: 100%;height:300px;" />
|
|
|
</div>
|
|
|
</el-col>
|
|
|
- <!-- 剩料计划 -->
|
|
|
+ <!-- 剩料计划 2-->
|
|
|
<el-col v-if="isResidualMaterialPlan" :span="16">
|
|
|
<div class="title">
|
|
|
<b>过程详情</b>
|
|
|
@@ -326,7 +348,7 @@
|
|
|
</el-table>
|
|
|
</div>
|
|
|
</el-col>
|
|
|
- <!-- 撒料计划-混料 -->
|
|
|
+ <!-- 撒料计划-混料 1-->
|
|
|
<el-col v-if="isSpreadingPlanSH" :span="16">
|
|
|
<div class="title">
|
|
|
<b>过程详情</b>
|
|
|
@@ -363,7 +385,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="Mixture">
|
|
|
- <h4>混料详情</h4>
|
|
|
+ <h4>混料详情1</h4>
|
|
|
<el-table
|
|
|
:key="table3.tableKey"
|
|
|
v-loading="table3.listLoading"
|
|
|
@@ -379,8 +401,8 @@
|
|
|
max-height="270px"
|
|
|
|
|
|
>
|
|
|
- <el-table-column label="操作编号" min-width="60px" align="center" prop="sort" />
|
|
|
- <el-table-column label="饲料名称" min-width="60px" align="center" prop="fname" />
|
|
|
+ <el-table-column label="操作编号" min-width="60px" align="center" prop="sort" />
|
|
|
+ <el-table-column label="饲料名称" min-width="80px" align="center" prop="fname" />
|
|
|
<el-table-column label="计划重量" min-width="60px" align="center" prop="lweight" />
|
|
|
<el-table-column label="实际重量" min-width="60px" align="center" prop="actualweightminus">
|
|
|
<template slot-scope="{row}">
|
|
|
@@ -395,11 +417,18 @@
|
|
|
<el-table-column label="跳转方式" min-width="60px" align="center" prop="buttontype" />
|
|
|
<el-table-column label="开始重量" min-width="60px" align="center" prop="lastactualweight" />
|
|
|
<el-table-column label="结束重量" min-width="60px" align="center" prop="actualweight" />
|
|
|
+ <el-table-column
|
|
|
+ label="操作"
|
|
|
+ width="90">
|
|
|
+ <template slot-scope="scope" >
|
|
|
+ <el-button v-if="scope.row.sort != '合计'" @click="handleClick(scope.row,1)" type="text" size="small">编辑1</el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
</el-table>
|
|
|
</div>
|
|
|
|
|
|
<div class="SpreadingMaterials">
|
|
|
- <h4>撒料详情</h4>
|
|
|
+ <h4>撒料详情1</h4>
|
|
|
<el-table
|
|
|
:key="table4.tableKey"
|
|
|
v-loading="table4.listLoading"
|
|
|
@@ -414,10 +443,10 @@
|
|
|
class="elTable table-fixed"
|
|
|
max-height="260px"
|
|
|
>
|
|
|
- <el-table-column label="操作编号" min-width="60px" align="center" prop="sort" />
|
|
|
- <el-table-column label="撒料车辆" min-width="60px" align="center" prop="fname" />
|
|
|
+ <el-table-column label="操作编号" min-width="60px" align="center" prop="sort" />
|
|
|
+ <el-table-column label="撒料车辆" min-width="80px" align="center" prop="fname" />
|
|
|
<el-table-column label="计划重量" min-width="60px" align="center" prop="lweight" />
|
|
|
- <el-table-column label="实际重量" min-width="60px" align="center" prop="actualweightminus">
|
|
|
+ <el-table-column label="实际重量" min-width="70px" align="center" prop="actualweightminus">
|
|
|
<template slot-scope="{row}">
|
|
|
<a v-if="row.actualweightminus == 0" style="color: red;">{{ row.actualweightminus }}</a>
|
|
|
<a v-else>{{ row.actualweightminus }}</a>
|
|
|
@@ -430,6 +459,13 @@
|
|
|
<el-table-column label="跳转方式" min-width="60px" align="center" prop="buttontype" />
|
|
|
<el-table-column label="开始重量" min-width="60px" align="center" prop="lastactualweight" />
|
|
|
<el-table-column label="结束重量" min-width="60px" align="center" prop="actualweight" />
|
|
|
+ <el-table-column
|
|
|
+ label="操作"
|
|
|
+ width="90">
|
|
|
+ <template slot-scope="scope" >
|
|
|
+ <el-button v-if="scope.row.sort != '合计'" @click="handleClick(scope.row,2)" type="text" size="small">编辑1</el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
</el-table>
|
|
|
</div>
|
|
|
<div class="ControlChart">
|
|
|
@@ -474,7 +510,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="Mixture">
|
|
|
- <h4>混料详情</h4>
|
|
|
+ <h4>混料详情2</h4>
|
|
|
<el-table
|
|
|
:key="table3.tableKey"
|
|
|
v-loading="table3.listLoading"
|
|
|
@@ -505,11 +541,18 @@
|
|
|
<el-table-column label="跳转方式" min-width="60px" align="center" prop="buttontype" />
|
|
|
<el-table-column label="开始重量" min-width="60px" align="center" prop="lastactualweight" />
|
|
|
<el-table-column label="结束重量" min-width="60px" align="center" prop="actualweight" />
|
|
|
+ <el-table-column
|
|
|
+ label="操作"
|
|
|
+ width="90px">
|
|
|
+ <template slot-scope="scope" >
|
|
|
+ <el-button v-if="scope.row.sort != '合计'" @click="handleClick(scope.row,1)" type="text" size="small">编辑</el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
</el-table>
|
|
|
</div>
|
|
|
|
|
|
<div class="SpreadingMaterials">
|
|
|
- <h4>撒料详情</h4>
|
|
|
+ <h4>撒料详情2</h4>
|
|
|
<el-table
|
|
|
:key="table4.tableKey"
|
|
|
v-loading="table4.listLoading"
|
|
|
@@ -527,7 +570,7 @@
|
|
|
<el-table-column label="操作编号" min-width="70px" align="center" prop="sort" />
|
|
|
<el-table-column label="撒料车辆" min-width="70px" align="center" prop="fname" />
|
|
|
<el-table-column label="计划重量" min-width="70px" align="center" prop="lweight" />
|
|
|
- <el-table-column label="实际重量" min-width="60px" align="center" prop="actualweightminus">
|
|
|
+ <el-table-column label="实际重量" min-width="80px" align="center" prop="actualweightminus">
|
|
|
<template slot-scope="{row}">
|
|
|
<a v-if="row.actualweightminus == 0" style="color: red;">{{ row.actualweightminus }}</a>
|
|
|
<a v-else>{{ row.actualweightminus }}</a>
|
|
|
@@ -539,7 +582,14 @@
|
|
|
<el-table-column label="过程时间" min-width="70px" align="center" prop="proesstime" />
|
|
|
<el-table-column label="跳转方式" min-width="70px" align="center" prop="buttontype" />
|
|
|
<el-table-column label="开始重量" min-width="70px" align="center" prop="lastactualweight" />
|
|
|
- <el-table-column label="结束重量" min-width="70px" align="center" prop="actualweight" />
|
|
|
+ <el-table-column label="结束重量" min-width="80px" align="center" prop="actualweight" />
|
|
|
+ <el-table-column
|
|
|
+ label="操作"
|
|
|
+ width="90px">
|
|
|
+ <template slot-scope="scope" >
|
|
|
+ <el-button v-if="scope.row.sort != '合计'" @click="handleClick(scope.row,2)" type="text" size="small">编辑</el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
</el-table>
|
|
|
</div>
|
|
|
<div class="ControlChart">
|
|
|
@@ -549,6 +599,22 @@
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
|
|
|
+ <!-- 修改实际重量 -->
|
|
|
+ <el-dialog title="修改实际重量" :visible.sync="dialogFormVisible" width="40%">
|
|
|
+ <el-form :model="form">
|
|
|
+ <el-form-item label="原实际重量" label-width="120px">
|
|
|
+ <el-input v-model="form.weightOld" disabled type="number"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item label="现实际重量" label-width="120px">
|
|
|
+ <el-input v-model="form.weight" type="number"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ <div slot="footer" class="dialog-footer">
|
|
|
+ <el-button style="padding:10px" @click="dialogFormVisible = false">取 消</el-button>
|
|
|
+ <el-button style="padding:10px" type="primary" @click="handleUpdateWg">确 定</el-button>
|
|
|
+ </div>
|
|
|
+</el-dialog>
|
|
|
+
|
|
|
</div>
|
|
|
|
|
|
</template>
|
|
|
@@ -557,13 +623,18 @@
|
|
|
import echarts from 'echarts'
|
|
|
|
|
|
require('echarts/theme/macarons')
|
|
|
-import { GetDataByName, GetReportform, formatNum,processAnalysist } from '@/api/common'
|
|
|
+import { GetDataByName, GetReportform, formatNum,processAnalysist,editWeightHL,editWeightSL } from '@/api/common'
|
|
|
import Cookies from 'js-cookie'
|
|
|
import { parseTime } from '@/utils/index.js'
|
|
|
export default {
|
|
|
name: 'PastureProcessAnalysis',
|
|
|
data() {
|
|
|
return {
|
|
|
+ dialogFormVisible:false,
|
|
|
+ form:{
|
|
|
+ weightOld:'',
|
|
|
+ weight:""
|
|
|
+ },
|
|
|
hlwc1:undefined ,
|
|
|
hlwc2:undefined ,
|
|
|
hlzq1:undefined ,
|
|
|
@@ -633,7 +704,7 @@ export default {
|
|
|
pastureid: Cookies.get('pastureid'),
|
|
|
startTime: parseTime(new Date(), '{y}-{m}-{d}'),
|
|
|
stopTime: parseTime(new Date(), '{y}-{m}-{d}'),
|
|
|
- inputDatetime: [new Date(), new Date()],
|
|
|
+ inputDatetime: [new Date(), new Date()], //['2023-06-05','2023-06-15'],
|
|
|
iscompleted: '',
|
|
|
tmrtname: '',
|
|
|
lpplantype: '',
|
|
|
@@ -741,6 +812,58 @@ export default {
|
|
|
this.getList()
|
|
|
},
|
|
|
methods: {
|
|
|
+ // 编辑实际重量
|
|
|
+ handleClick(row,type){
|
|
|
+ this.dialogFormVisible = true;
|
|
|
+ this.form.weight = row.actualweightminus;
|
|
|
+ this.form.weightOld = row.actualweightminus;
|
|
|
+ this.form.pid = this.table3.getdataListParm.parammaps.pid;
|
|
|
+ this.form.sort = row.sort;
|
|
|
+ this.form.userId = Cookies.get('employeid')
|
|
|
+ this.form.type = type;
|
|
|
+ console.log(row,'实际重量');
|
|
|
+
|
|
|
+
|
|
|
+ },
|
|
|
+ // 点击确认修改
|
|
|
+ handleUpdateWg(){
|
|
|
+ if(this.form.weight == this.form.weightOld ){
|
|
|
+ this.dialogFormVisible = false
|
|
|
+ return
|
|
|
+ }
|
|
|
+ // 1:混料 2:撒料
|
|
|
+ if(this.form.type == 1){
|
|
|
+ this.handleEditWgHL(this.form)
|
|
|
+ } else{
|
|
|
+ this.handleEditWgSL(this.form)
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
+ // 混料
|
|
|
+ async handleEditWgHL(obj){
|
|
|
+ const {data} =await editWeightHL(obj);
|
|
|
+ console.log(data,'=====混hss')
|
|
|
+ if(data == true){
|
|
|
+ this.$message({ type: 'success', message: '混料实际重量修改成功', duration: 2000 })
|
|
|
+ } else{
|
|
|
+ this.$message({ type: 'error', message: '修改失败,请重新修改', duration: 2000 })
|
|
|
+ }
|
|
|
+ this.getList3()
|
|
|
+ this.dialogFormVisible = false
|
|
|
+ },
|
|
|
+ // 撒料
|
|
|
+ async handleEditWgSL(obj){
|
|
|
+ const {data} =await editWeightSL(obj);
|
|
|
+ console.log(data,'=====撒hss')
|
|
|
+ if(data == true){
|
|
|
+ this.$message({ type: 'success', message: '撒料实际重量修改成功', duration: 2000 })
|
|
|
+ } else{
|
|
|
+ this.$message({ type: 'error', message: data, duration: 2000 })
|
|
|
+ }
|
|
|
+ this.getList4()
|
|
|
+ this.dialogFormVisible = false
|
|
|
+
|
|
|
+ },
|
|
|
change_date(e){
|
|
|
console.log(e)
|
|
|
this.getDownList()
|
|
|
@@ -1373,7 +1496,7 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
rowStyle({ row, rowIndex }) {
|
|
|
- console.log(row, rowIndex,'777777');
|
|
|
+ // console.log(row, rowIndex,'777777');s
|
|
|
let stylejson = {};
|
|
|
if (row.abnormal == 1) {
|
|
|
stylejson.background = "#fb8072";// 背景颜色
|