| | |
| | | |
| | | <view class="input-group input1"> |
| | | <view class="input-wrapper"> |
| | | <button class="btn upload-btn" @click="chooseImage"> |
| | | <uni-icons type="upload" size="16" color="#fff"></uni-icons> |
| | | 上传/查看图片 |
| | | </button> |
| | | <input v-if="tableData.length < formData.levelNum" v-model="formData.fcheckResu" class="result-input" |
| | | placeholder="请输入检验结果..." type="number"/> |
| | | <button v-if="tableData.length < formData.levelNum" class="btn primary-btn" @click="submit">保存结果 |
| | | <button v-if="tableData.length < formData.levelNum" class="btn primary-btn" @click="submit" style="margin: 0;">保存结果 |
| | | |
| | | </button> |
| | | <button v-if="isShowImg" class="btn upload-btn" @click="previewImage"> |
| | | <uni-icons color="#fff" size="16" type="image"></uni-icons> |
| | |
| | | <!-- 响应式设计的第二个输入组 --> |
| | | <view class="input-group input2"> |
| | | <view class="input-wrapper"> |
| | | <button class="btn upload-btn" @click="chooseImage"> |
| | | <uni-icons type="upload" size="16" color="#fff"></uni-icons> |
| | | 上传/查看图片 |
| | | </button> |
| | | <button v-if="isShowImg" class="btn upload-btn" @click="previewImage"> |
| | | <uni-icons color="#fff" size="16" type="image"></uni-icons> |
| | | 查看图片 |
| | |
| | | return; |
| | | } |
| | | |
| | | if (this.formData.fcheckResu >= this.formData.minValue && this.formData.fcheckResu <= this.formData |
| | | .maxValue) { |
| | | let checkValue = Number(this.formData.fcheckResu); |
| | | let minValue = Number(this.formData.minValue); |
| | | let maxValue = Number(this.formData.maxValue); |
| | | |
| | | if (isNaN(checkValue) || isNaN(minValue) || isNaN(maxValue)) { |
| | | this.$showMessage("检验值或范围值格式不正确,请检查输入"); |
| | | return; |
| | | } |
| | | |
| | | if (checkValue >= minValue && checkValue <= maxValue) { |
| | | fstand = "√" |
| | | } else { |
| | | fstand = "×"; |
| | |
| | | } |
| | | }).then(res => { |
| | | this.formData = res.data.tbBillList.itemXj01; |
| | | // 确保formData包含id属性,用于图片上传功能 |
| | | if (!this.formData.id && this.id) { |
| | | this.formData.id = this.id; |
| | | } |
| | | |
| | | this.tableData = res.data.tbBillList.itemXj02s; |
| | | |
| | |
| | | return; |
| | | } |
| | | |
| | | if (this.editData.fcheckResu >= this.formData.minValue && this.editData.fcheckResu <= this.formData |
| | | .maxValue) { |
| | | let checkValue = Number(this.editData.fcheckResu); |
| | | let minValue = Number(this.formData.minValue); |
| | | let maxValue = Number(this.formData.maxValue); |
| | | |
| | | if (isNaN(checkValue) || isNaN(minValue) || isNaN(maxValue)) { |
| | | this.$showMessage("检验值或范围值格式不正确,请检查输入"); |
| | | return; |
| | | } |
| | | |
| | | if (checkValue >= minValue && checkValue <= maxValue) { |
| | | this.editData.isPass = 1 |
| | | } else { |
| | | this.editData.isPass = 0 |
| | |
| | | }) |
| | | }, |
| | | numberEdit(item) { |
| | | |
| | | let fstand = "√"; |
| | | let fcheckResu = 1; |
| | | |
| | |
| | | this.$showMessage("修改成功"); |
| | | this.refreshResult(); //刷新页面 |
| | | }) |
| | | }, |
| | | // 上传图片 |
| | | chooseImage() { |
| | | uni.navigateTo({ |
| | | url: 'ImageItem?id=666' + this.formData.id + '&gid=' + this.gid |
| | | }); |
| | | }, |
| | | saveRemarks() { |
| | | this.remarksPopup = !this.remarksPopup; |
| | |
| | | color: #fff; |
| | | padding: 0 10px; |
| | | margin: 0; |
| | | height: 45px; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: center; |
| | | border: none; |
| | | border-radius: 4px; |
| | | } |
| | | } |
| | | } |
| | |
| | | &.primary-btn { |
| | | background-color: $primary-color; |
| | | color: #fff; |
| | | height: 45px; |
| | | display: flex; |
| | | align-items: center; |
| | | justify-content: center; |
| | | border: none; |
| | | border-radius: 4px; |
| | | padding: 0 20px; |
| | | } |
| | | |
| | | &.danger-btn { |