| | |
| | | startTime: undefined, |
| | | endTime: undefined, |
| | | weightRatio: undefined, // 重量比(水/料) |
| | | pva: undefined, // PVAn粘合剂重量 |
| | | pva: undefined, // PVA粘合剂重量 |
| | | dispersantWeight: undefined, // 分散剂重量 |
| | | releaseAgentWeight: undefined, // 脱模剂重量 |
| | | }, |
| | |
| | | case 'stirredMillConfirmId': |
| | | formData.otherData.stirredMill.confirmName = selectedUser.userName; |
| | | break; |
| | | case 'granulationBUserId': |
| | | formData.otherData.granulationB.userName = selectedUser.userName; |
| | | break; |
| | | case 'granulationBConfirmId': |
| | | formData.otherData.granulationB.confirmName = selectedUser.userName; |
| | | break; |
| | | } |
| | | } else { |
| | | switch (reportType) { |
| | |
| | | case 'stirredMillConfirmId': |
| | | formData.otherData.stirredMill.confirmName = ""; |
| | | break; |
| | | case 'granulationBUserId': |
| | | formData.otherData.granulationB.userName = ""; |
| | | break; |
| | | case 'granulationBConfirmId': |
| | | formData.otherData.granulationB.confirmName = ""; |
| | | break; |
| | | } |
| | | } |
| | | }; |
| | | // todo 修改作业员,在所有作业员中获取填入的值,如果没有则提示不提交 |
| | | |
| | | const handleReport = () => { |
| | | if (!formData.otherData.userId && !formData.otherData.surfaceCopperPasteUserId && !formData.otherData.underlyingCopperPasteUserId) { |
| | | if (!formData.otherData.stirredMillIncludesMixing.userId && !formData.otherData.stirredMill.userId && !formData.otherData.burningMaterial.userId && !formData.otherData.granulationB.userId) { |
| | | ElMessage.error('请选择作业员') |
| | | return; |
| | | } |
| | |
| | | ElMessage.error('请输入生产数量') |
| | | return; |
| | | } |
| | | formData.userId = formData.otherData.surfaceCopperPasteUserId || formData.otherData.underlyingCopperPasteUserId; |
| | | formData.userId = formData.otherData.stirredMillIncludesMixing.userId || formData.otherData.stirredMill.userId || formData.otherData.burningMaterial.userId || formData.otherData.granulationB.userId; |
| | | |
| | | const otherData = JSON.stringify(formData.otherData); |
| | | const submitData = { |
| | |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.burningMaterial.calcinationWeight) }}</span> |
| | | <span>KG</span> |
| | | </td> |
| | | <td class="label" colspan="2" rowspan="3"> |
| | | <td class="label" colspan="2" rowspan="2"> |
| | | <span>确认人:</span> |
| | | <el-select v-model="formData.otherData.burningMaterial.confirmId" |
| | | v-if="props.isEdit" |
| | |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.stirredMill.confirmName || formData.otherData.stirredMill.confirmId) }}</span> |
| | | </td> |
| | | </tr> |
| | | <!-- todo搅拌行开始,确认人行留空,已在上面表格预留 --> |
| | | <tr> |
| | | <td class="label" colspan="2" rowspan="2">搅拌</td> |
| | | <td class="label" colspan="4"> |
| | | <span>开始时间:</span> |
| | | <el-date-picker |
| | | v-if="props.isEdit" |
| | | v-model="formData.otherData.stir.startTime" |
| | | type="datetime" |
| | | value-format="YYYY-MM-DD HH:mm:ss" |
| | | format="YYYY-MM-DD HH:mm:ss" |
| | | placeholder="请选择" |
| | | style="width: 100%" |
| | | /> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.stir.startTime) }}</span> |
| | | </td> |
| | | <td class="label" colspan="4"> |
| | | <span>结束时间:</span> |
| | | <el-date-picker |
| | | v-if="props.isEdit" |
| | | v-model="formData.otherData.stir.endTime" |
| | | type="datetime" |
| | | value-format="YYYY-MM-DD HH:mm:ss" |
| | | format="YYYY-MM-DD HH:mm:ss" |
| | | placeholder="请选择" |
| | | style="width: 100%" |
| | | /> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.stir.endTime) }}</span> |
| | | </td> |
| | | <td class="label" colspan="4"> |
| | | <span>重量比(水/料):</span> |
| | | <el-input v-if="props.isEdit" v-model="formData.otherData.stir.weightRatio" placeholder="请输入"/> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.stir.weightRatio) }}</span> |
| | | </td> |
| | | </tr> |
| | | <tr> |
| | | <td class="label" colspan="4"> |
| | | <span>PVA粘合剂重量 :</span> |
| | | <el-input v-if="props.isEdit" v-model="formData.otherData.stir.pva" placeholder="请输入"/> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.stir.pva) }}</span> |
| | | </td> |
| | | <td class="label" colspan="4"> |
| | | <span>分散剂重量 :</span> |
| | | <el-input v-if="props.isEdit" v-model="formData.otherData.stir.dispersantWeight" placeholder="请输入"/> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.stir.dispersantWeight) }}</span> |
| | | </td> |
| | | <td class="label" colspan="4"> |
| | | <span>脱模剂重量 :</span> |
| | | <el-input v-if="props.isEdit" v-model="formData.otherData.stir.releaseAgentWeight" placeholder="请输入"/> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.stir.releaseAgentWeight) }}</span> |
| | | </td> |
| | | </tr> |
| | | <tr> |
| | | <td class="label" colspan="2" rowspan="4">造粒</td> |
| | | <td class="label" colspan="6"> |
| | | <span>开始时间:</span> |
| | | <el-date-picker |
| | | v-if="props.isEdit" |
| | | v-model="formData.otherData.granulationB.startTime" |
| | | type="datetime" |
| | | value-format="YYYY-MM-DD HH:mm:ss" |
| | | format="YYYY-MM-DD HH:mm:ss" |
| | | placeholder="请选择" |
| | | style="width: 100%" |
| | | /> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.granulationB.startTime) }}</span> |
| | | </td> |
| | | <td class="label" colspan="6"> |
| | | <span>结束时间:</span> |
| | | <el-date-picker |
| | | v-if="props.isEdit" |
| | | v-model="formData.otherData.granulationB.endTime" |
| | | type="datetime" |
| | | value-format="YYYY-MM-DD HH:mm:ss" |
| | | format="YYYY-MM-DD HH:mm:ss" |
| | | placeholder="请选择" |
| | | style="width: 100%" |
| | | /> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.granulationB.endTime) }}</span> |
| | | </td> |
| | | <td class="label" colspan="2" rowspan="2"> |
| | | <span>作业员:</span> |
| | | <el-select v-model="formData.otherData.granulationB.userId" |
| | | v-if="props.isEdit" |
| | | style="width: 100%" |
| | | placeholder="请选择作业员" |
| | | clearable |
| | | filterable |
| | | @change="handleUserChange($event, 'granulationBUserId')"> |
| | | <el-option v-for="user in userOptions" |
| | | :key="user.userId" |
| | | :label="user.userName" |
| | | :value="user.userId"/> |
| | | </el-select> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.granulationB.userName || formData.otherData.granulationB.userId) }}</span> |
| | | </td> |
| | | </tr> |
| | | |
| | | <tr> |
| | | <td class="label" colspan="4"> |
| | | <span>雾化器转速 :</span> |
| | | <el-input v-if="props.isEdit" v-model="formData.otherData.granulationB.atomizerRotationalSpeed" placeholder="请输入"> |
| | | <template #append>r/min</template> |
| | | </el-input> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.granulationB.atomizerRotationalSpeed) }}</span> |
| | | </td> |
| | | <td class="label" colspan="4"> |
| | | <span>进口速度 :</span> |
| | | <el-input v-if="props.isEdit" v-model="formData.otherData.granulationB.importSpeed" placeholder="请输入"/> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.granulationB.importSpeed) }}</span> |
| | | </td> |
| | | <td class="label" colspan="4"> |
| | | <span>出口速度 :</span> |
| | | <el-input v-if="props.isEdit" v-model="formData.otherData.granulationB.outSpeed" placeholder="请输入"/> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.granulationB.outSpeed) }}</span> |
| | | </td> |
| | | </tr> |
| | | <tr> |
| | | <td class="label" colspan="6"> |
| | | <span>产出总数 :</span> |
| | | <el-input v-if="props.isEdit" v-model="formData.quantity" placeholder="请输入"> |
| | | <template #append>KG</template> |
| | | </el-input> |
| | | <span v-else class="view-value">{{ displayValue(formData.quantity) }}</span> |
| | | </td> |
| | | <td class="label" colspan="6"> |
| | | <span>合格重量 :</span> |
| | | <el-input v-if="props.isEdit" v-model="formData.otherData.granulationB.qualifiedWeight" placeholder="请输入"> |
| | | <template #append>KG</template> |
| | | </el-input> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.granulationB.qualifiedWeight) }}</span> |
| | | </td> |
| | | <td class="label" colspan="2" rowspan="2"> |
| | | <span>确认人:</span> |
| | | <el-select v-model="formData.otherData.granulationB.confirmId" |
| | | v-if="props.isEdit" |
| | | style="width: 100%" |
| | | placeholder="请选择确认人" |
| | | clearable |
| | | filterable |
| | | @change="handleUserChange($event, 'stirredMillConfirmId')"> |
| | | <el-option v-for="user in userOptions" |
| | | :key="user.userId" |
| | | :label="user.userName" |
| | | :value="user.userId"/> |
| | | </el-select> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.granulationB.confirmName || formData.otherData.granulationB.confirmId) }}</span> |
| | | </td> |
| | | </tr> |
| | | <tr> |
| | | <td class="label" colspan="6"> |
| | | <span>尾料 :</span> |
| | | <el-input v-if="props.isEdit" v-model="formData.otherData.granulationB.wasteMaterials" placeholder="请输入"> |
| | | <template #append>KG</template> |
| | | </el-input> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.granulationB.wasteMaterials) }}</span> |
| | | </td> |
| | | <td class="label" colspan="6"> |
| | | <span>壁料 :</span> |
| | | <el-input v-if="props.isEdit" v-model="formData.otherData.granulationB.wallMaterial" placeholder="请输入"> |
| | | <template #append>KG</template> |
| | | </el-input> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.granulationB.wallMaterial) }}</span> |
| | | </td> |
| | | </tr> |
| | | <tr> |
| | | <td class="label" colspan="16"> |
| | | <span>备注 :</span> |
| | | <el-input v-if="props.isEdit" v-model="formData.otherData.remark" placeholder="请输入"/> |
| | | <span v-else class="view-value">{{ displayValue(formData.otherData.remark) }}</span> |
| | | </td> |
| | | </tr> |
| | | </tbody> |
| | | </table> |
| | | </el-form> |