|
|
@@ -154,9 +154,9 @@
|
|
|
<view class="content_table2">
|
|
|
<view class="head row rx-sc">
|
|
|
<view class="item ww20" :class="{'ww30' : taskTypeName == 'CVI' } ">工序名称</view>
|
|
|
- <view class="item ww20" v-if="taskTypeName == 'CVI'">标准系数</view>
|
|
|
<view class="item ww20" v-if="taskTypeName == 'CVI'">坯体密度</view>
|
|
|
- <view class="item ww20" v-if="taskTypeName == 'CVI'">报工重量</view>
|
|
|
+ <view class="item ww20" v-if="taskTypeName == 'CVI'">密度系数</view>
|
|
|
+ <view class="item ww20" v-if="taskTypeName == 'CVI'">重量</view>
|
|
|
|
|
|
|
|
|
<view class="item ww20" v-if="taskTypeName == 'PIP'">坯体图体积</view>
|
|
|
@@ -179,90 +179,93 @@
|
|
|
</view>
|
|
|
|
|
|
|
|
|
- <view class="item ww20 content_num"
|
|
|
- v-if="taskTypeName == 'CVI' && (idx == 0 || idx != paramList.length - 1)">
|
|
|
- < <input class="uni-input" v-model="it.density" type="digit"></input>
|
|
|
- </view>
|
|
|
- <view class="item ww20 "
|
|
|
- v-if="taskTypeName == 'CVI' && paramList.length > 1 && idx == paramList.length - 1">
|
|
|
- ≥ <input class="uni-input" disabled
|
|
|
- v-model="it.density = paramList[paramList.length - 2].density"
|
|
|
- type="digit"></input>
|
|
|
- </view>
|
|
|
-
|
|
|
<view class="item ww20 content_num" v-if="taskTypeName == 'CVI'">
|
|
|
<input class="uni-input" v-model="it.billet" type="digit"
|
|
|
@input="changeInp(it, idx)"></input>
|
|
|
</view>
|
|
|
|
|
|
- <view class="item ww20" v-if="taskTypeName == 'CVI'">
|
|
|
- {{reportWeight}}
|
|
|
+
|
|
|
+ <view class="item ww20 content_num" v-if="taskTypeName == 'CVI'">
|
|
|
+ <input class="uni-input" v-model="it.density" type="digit"
|
|
|
+ @input="changeInp(it, idx)"></input>
|
|
|
</view>
|
|
|
|
|
|
|
|
|
|
|
|
- <!-- -------------PIP ------------- -->
|
|
|
+ <view class="item ww20"
|
|
|
+ v-if="taskTypeName == 'CVI' && (idx == 0 || idx != paramList.length - 1)">
|
|
|
+ < {{it.CVIWeight}} </view>
|
|
|
|
|
|
- <view class="item ww20 content_num" v-if="taskTypeName == 'PIP'">
|
|
|
- <input class="uni-input" v-model="it.volume" type="digit"
|
|
|
- @input="jsPIPWeight(it, idx)"></input>
|
|
|
- </view>
|
|
|
+ <view class="item ww20"
|
|
|
+ v-if="taskTypeName == 'CVI' && paramList.length > 1 && idx == paramList.length - 1">
|
|
|
+ ≥ {{it.CVIWeight }}
|
|
|
+ </view>
|
|
|
|
|
|
- <view class="item ww20 content_num" v-if="taskTypeName == 'PIP'">
|
|
|
- <input class="uni-input" v-model="it.PIPDensity" type="digit"
|
|
|
- @input="jsPIPWeight(it, idx)"></input>
|
|
|
- </view>
|
|
|
|
|
|
- <view class="item ww15 content_num" v-if="taskTypeName == 'PIP'">
|
|
|
- <input class="uni-input" v-model="it.coefficient" type="digit"
|
|
|
- @input="jsPIPWeight(it, idx)"></input>
|
|
|
- </view>
|
|
|
|
|
|
- <view class="item ww15 " v-if="taskTypeName == 'PIP'">
|
|
|
- < {{it.PIPWeight}} </view>
|
|
|
|
|
|
+ <!-- -------------PIP ------------- -->
|
|
|
|
|
|
+ <view class="item ww20 content_num" v-if="taskTypeName == 'PIP'">
|
|
|
+ <input class="uni-input" v-model="it.volume" type="digit"
|
|
|
+ @input="jsPIPWeight(it, idx)"></input>
|
|
|
+ </view>
|
|
|
|
|
|
+ <view class="item ww20 content_num" v-if="taskTypeName == 'PIP'">
|
|
|
+ <input class="uni-input" v-model="it.PIPDensity" type="digit"
|
|
|
+ @input="jsPIPWeight(it, idx)"></input>
|
|
|
+ </view>
|
|
|
|
|
|
- <view class="item ww10 rx-cc" @click="getDelete(idx)">
|
|
|
- <uni-icons custom-prefix="iconfont" type="icon-shanchu" size="20"
|
|
|
- color="#fa3534"></uni-icons>
|
|
|
+ <view class="item ww15 content_num" v-if="taskTypeName == 'PIP'">
|
|
|
+ <input class="uni-input" v-model="it.coefficient" type="digit"
|
|
|
+ @input="jsPIPWeight(it, idx)"></input>
|
|
|
</view>
|
|
|
|
|
|
- </view>
|
|
|
+ <view class="item ww15 " v-if="taskTypeName == 'PIP'">
|
|
|
+ < {{it.PIPWeight}} </view>
|
|
|
|
|
|
|
|
|
- </view>
|
|
|
|
|
|
- <view class="formula_box" v-if="taskTypeName == 'CVI'">计算公式: 报工重量*坯体密度/物料重量 </view>
|
|
|
- <view class="formula_box" v-if="taskTypeName == 'PIP'">计算公式: 坯体图体积*要求密度*系数 </view>
|
|
|
|
|
|
- <view class="rx-cc">
|
|
|
+ <view class="item ww10 rx-cc" @click="getDelete(idx)">
|
|
|
+ <uni-icons custom-prefix="iconfont" type="icon-shanchu" size="20"
|
|
|
+ color="#fa3534"></uni-icons>
|
|
|
+ </view>
|
|
|
|
|
|
- <u-button size="small" class="u-reset-button" style="width: 300rpx;margin: 20rpx;"
|
|
|
- type="success" @click="paramSave">工序列表保存</u-button>
|
|
|
- </view>
|
|
|
+ </view>
|
|
|
|
|
|
- <view class="reportWeight rx-sc">
|
|
|
- 物料重量: {{weight}} ;
|
|
|
- 报工重量: {{reportWeight}}
|
|
|
- <text v-if="taskTypeName == 'CVI'">; 密度系数:{{ densityFactor }} </text>
|
|
|
|
|
|
- </view>
|
|
|
+ </view>
|
|
|
|
|
|
+ <view class="formula_box" v-if="taskTypeName == 'CVI'">计算公式: 物料重量/坯体密度*密度系数 </view>
|
|
|
+ <view class="formula_box" v-if="taskTypeName == 'PIP'">计算公式: 坯体图体积*要求密度*系数 </view>
|
|
|
|
|
|
+ <view class="rx-cc">
|
|
|
|
|
|
+ <u-button size="small" class="u-reset-button" style="width: 300rpx;margin: 20rpx;"
|
|
|
+ type="success" @click="paramSave">工序列表保存</u-button>
|
|
|
+ </view>
|
|
|
|
|
|
+ <view class="reportWeight rx-sc">
|
|
|
+ 物料重量: {{weight}} ;
|
|
|
+ 报工重量: {{reportWeight}}
|
|
|
|
|
|
|
|
|
- </view>
|
|
|
+ </view>
|
|
|
+
|
|
|
|
|
|
|
|
|
- <view class="operate_box rx-sc">
|
|
|
- <u-button size="small" class="u-reset-button" @click="cancel">取消</u-button>
|
|
|
- <u-button size="small" class="u-reset-button" type="success" @click="save">确定</u-button>
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+ </view>
|
|
|
+
|
|
|
+
|
|
|
+ <view class="operate_box rx-sc">
|
|
|
+ <u-button size="small" class="u-reset-button" @click="cancel">取消</u-button>
|
|
|
+ <u-button size="small" class="u-reset-button" type="success" @click="save">确定</u-button>
|
|
|
+ </view>
|
|
|
</view>
|
|
|
- </view>
|
|
|
|
|
|
|
|
|
</u-popup>
|
|
|
@@ -329,7 +332,7 @@
|
|
|
|
|
|
weight: 0,
|
|
|
reportWeight: 0,
|
|
|
- densityFactor: 0,
|
|
|
+
|
|
|
resultObj: {},
|
|
|
resultIdx: 0,
|
|
|
|
|
|
@@ -404,12 +407,8 @@
|
|
|
},
|
|
|
|
|
|
changeInp(item, index) {
|
|
|
- if (Number(item.billet)) {
|
|
|
-
|
|
|
- this.paramList.forEach(e => {
|
|
|
- e.billet = item.billet
|
|
|
- e.result = (Number(this.reportWeight) * item.billet / this.weight).toFixed(2)
|
|
|
- })
|
|
|
+ if (Number(item.billet) && Number(item.density)) {
|
|
|
+ this.paramList[index].CVIWeight = (Number(this.weight) / item.billet * item.density).toFixed(2)
|
|
|
|
|
|
}
|
|
|
|
|
|
@@ -476,10 +475,7 @@
|
|
|
})
|
|
|
this.getCompute()
|
|
|
|
|
|
- if (this.paramList.length > 0) {
|
|
|
- this.densityFactor = Number(this.reportWeight * this.paramList[0].billet / this.weight)
|
|
|
- .toFixed(2)
|
|
|
- }
|
|
|
+
|
|
|
|
|
|
})
|
|
|
|
|
|
@@ -497,9 +493,6 @@
|
|
|
this.reportWeight = row.extInfo.reportWeight
|
|
|
this.resultIdx = idx
|
|
|
|
|
|
- if (this.paramList.length > 0) {
|
|
|
- this.densityFactor = Number(this.reportWeight * this.paramList[0].billet / this.weight).toFixed(2)
|
|
|
- }
|
|
|
|
|
|
|
|
|
this.show = true
|
|
|
@@ -525,22 +518,22 @@
|
|
|
this.resultObj = {}
|
|
|
|
|
|
|
|
|
- if (Number(this.densityFactor) < this.paramList[0].density) {
|
|
|
+ if (Number(this.reportWeight) < this.paramList[0].CVIWeight) {
|
|
|
this.resultObj = this.paramList[0]
|
|
|
this.setDataSave()
|
|
|
return false
|
|
|
}
|
|
|
|
|
|
|
|
|
- if (Number(this.densityFactor) >= this.paramList[this.paramList.length - 1].density) {
|
|
|
+ if (Number(this.reportWeight) >= this.paramList[this.paramList.length - 1].CVIWeight) {
|
|
|
this.resultObj = this.paramList[this.paramList.length - 1]
|
|
|
this.setDataSave()
|
|
|
return false
|
|
|
}
|
|
|
|
|
|
for (let i = 1; i < this.paramList.length; i++) {
|
|
|
- if (Number(this.paramList[i - 1].density) < Number(this.densityFactor) <= Number(this.paramList[i]
|
|
|
- .density)) {
|
|
|
+ if (Number(this.paramList[i - 1].CVIWeight) < Number(this.reportWeight) <= Number(this.paramList[i]
|
|
|
+ .CVIWeight)) {
|
|
|
this.resultObj = this.paramList[i]
|
|
|
break;
|
|
|
}
|