| ¶Ô±ÈÐÂÎļþ |
| | |
| | | <!-- 设å¤éªæ¶ --> |
| | | <template> |
| | | <div> |
| | | <div class="search"> |
| | | <div class="search_thing"> |
| | | <div class="search_label">æµç¨ç¼å·ï¼</div> |
| | | <div class="search_input"><el-input v-model="search.processNumber" clearable placeholder="请è¾å
¥" size="small" |
| | | @keyup.enter.native="getDeviceAList(clickNodeVal.value)"></el-input></div> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 30px;"> |
| | | <el-button size="small" @click="resetSearch">é ç½®</el-button> |
| | | <el-button size="small" type="primary" @click="getDeviceAList(clickNodeVal.value)">æ¥ è¯¢</el-button> |
| | | </div> |
| | | <div class="btns"> |
| | | <el-button size="small" type="primary" @click="dialogVisible = true">æ·»å éªæ¶</el-button> |
| | | <el-button :loading="outLoading" size="small" type="primary" @click="handleDown">导åº</el-button> |
| | | </div> |
| | | </div> |
| | | <div class="tables" style="margin-top: 10px;"> |
| | | <el-table ref="table" :data="tableDataAlist" height="100%" v-loading="tableLoading"> |
| | | <el-table-column label="åºå·" type="index" width="60"> |
| | | <template v-slot="scope"> |
| | | <span>{{ (search.current - 1) * search.size + scope.$index + 1 }}</span> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æµç¨ç¼å·" min-width="150" prop="processNumber" show-overflow-tooltip/> |
| | | <el-table-column label="设å¤åç§°" min-width="140" prop="deviceName" show-overflow-tooltip/> |
| | | <el-table-column label="管çç¼å·" min-width="140" prop="managementNumber" show-overflow-tooltip/> |
| | | <el-table-column label="åºåå·" min-width="80" prop="serialNumber" /> |
| | | <el-table-column label="æäº¤è
" min-width="100" prop="submitUser" /> |
| | | <el-table-column label="æäº¤æ¥æ" min-width="150" prop="createTime" /> |
| | | <el-table-column label="å½åç¶æ" min-width="140" prop="currentState" /> |
| | | <el-table-column label="å½åè´è´£äºº" min-width="120" prop="currentResponsible" /> |
| | | <el-table-column fixed="right" label="æä½" min-width="140"> |
| | | <template #default="{ row }"> |
| | | <el-button size="small" type="text" @click="handleAttachmentClick(row)">éä»¶</el-button> |
| | | <el-button size="small" type="text" @click="handleViewClick(row)">æ¥ç</el-button> |
| | | <el-button size="small" type="text" @click="handleDeleteClick(row)">å é¤</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-pagination :current-page="1" :page-size="search.size" :page-sizes="[10, 20, 30, 50, 100]" |
| | | :total="search.total" layout="->,total, sizes, prev, pager, next, jumper" @size-change="handleSizeChange" |
| | | @current-change="handleCurrentChange"> |
| | | </el-pagination> |
| | | </div> |
| | | <!-- æ·»å è®¾å¤æ
éè®°å½ --> |
| | | <el-dialog :close-on-click-modal="false" :close-on-press-escape="false" :visible.sync="dialogVisible" title="仪å¨è®¾å¤éªæ¶è®°å½" |
| | | width="60%" @open="openRecordAcceptance"> |
| | | <el-steps :active="currentStep" finish-status="success"> |
| | | <el-step v-for="(v, i) in steps" :key="i" :title="v" style="cursor:pointer" |
| | | @click.native="choiceStep(i)"></el-step> |
| | | </el-steps> |
| | | <el-form ref="form" :model="form" :rules="rules" label-width="130px"> |
| | | <div v-show="currentStepClick === 0"> |
| | | <el-card style="margin-top: 1em; height: 56vh; overflow-y: scroll;"> |
| | | <!-- æ°å¢è®¾å¤äºè®°å½å¡ç --> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-form-item label="æµç¨ç¼å·ï¼" prop="processNumber"> |
| | | <el-input v-model="form.processNumber" disabled size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="设å¤åç§°ï¼"> |
| | | <el-input v-model="form.deviceName" disabled size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="ç产åå®¶ï¼"> |
| | | <el-input v-model="form.manufacturer" disabled size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="设å¤åå·ï¼"> |
| | | <el-input v-model="form.specificationModel" disabled size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item label="管çç¼å·ï¼"> |
| | | <el-input v-model="form.managementNumber" disabled size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item :rules="[{ required: currentStep === 0, message: '请è¾å
¥åºåå·', trigger: 'blur' }]" label="åºåå·ï¼" |
| | | prop="serialNumber"> |
| | | <el-input v-model="form.serialNumber" :disabled="currentStep !== 0" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item :rules="[{ required: currentStep === 0, message: '请è¾å
¥è®¾å¤ç±»å«', trigger: 'change' }]" label="设å¤ç±»å«ï¼" |
| | | prop="deviceClass"> |
| | | <el-radio-group v-model="form.deviceClass" :disabled="currentStep !== 0"> |
| | | <el-radio label="0precision">ç²¾å¯å设å¤</el-radio> |
| | | <el-radio label="1conventional">常è§è®¾å¤</el-radio><br /> |
| | | <el-radio label="2auxiliary_class">è¾
å©ç±»è®¾å¤</el-radio> |
| | | <el-radio label="4environmental">ç¯å¢ç±»è®¾å¤</el-radio> |
| | | </el-radio-group> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item :rules="[{ required: currentStep === 0, message: '请è¾å
¥å¼ç®±åæ£æ¥å¤å
è£
ææ ç ´æ', trigger: 'blur' }]" label="å¼ç®±åæ£æ¥å¤å
è£
ææ ç ´æï¼" label-width="220px" |
| | | prop="checkOuterPackaging"> |
| | | <el-input v-model="form.checkOuterPackaging" :disabled="currentStep !== 0" size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="ç¸å
³éä»¶ï¼" prop="fileName"> |
| | | <el-input v-model="form.fileName" :style="`width: ${currentStep == 0 ? '88%' : '100%'};`" disabled |
| | | size="small"> |
| | | <el-button v-if="currentStep === 0" slot="append" icon="el-icon-delete-solid" |
| | | @click="deleteFile"></el-button> |
| | | </el-input> |
| | | <el-upload ref="upload" :action="action" :on-success="onSuccess" :show-file-list="false" |
| | | style="float: right;"> |
| | | <el-button v-if="currentStep === 0" slot="trigger" class="uploadFile" size="small" |
| | | style="position: relative;top: -4px" type="primary">éä»¶ä¸ä¼ </el-button> |
| | | </el-upload> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item :rules="[{ required: currentStep === 0, message: 'è¯·éæ©ä¸ç¯è责任人', trigger: 'change' }]" label="ä¸ç¯è责任人ï¼" |
| | | prop="submitNextPesponsible"> |
| | | <el-select v-model="form.submitNextPesponsible" :disabled="currentStep !== 0" clearable filterable |
| | | placeholder="è¯·éæ©ä¸ç¯èè´è´£äºº" size="small" style="width: 50%;"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.id" :label="item.name" :value="item.name"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | | <el-form-item :rules="[{ required: currentStep === 0, message: '请è¾å
¥è®¾å¤å¼ç®±éªæ¶ç»è®º', trigger: 'change' }]" label="设å¤å¼ç®±éªæ¶ç»è®ºï¼" label-width="150px" |
| | | prop="unpackingAcceptanceConclusion"> |
| | | <el-radio-group v-model="form.unpackingAcceptanceConclusion" :disabled="currentStep !== 0"> |
| | | <el-radio :label="'0qualified'">åæ ¼</el-radio> |
| | | <el-radio :label="'1unqualified'">ä¸åæ ¼ï¼ç¼ºå°å¤ä»¶ä¾åºåè¡¥å</el-radio> |
| | | </el-radio-group> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <div style="margin-bottom: 20px; width: 100%;"> |
| | | <label>å¤ä»¶ç¡®è®¤ï¼</label> |
| | | <el-button v-if="currentStep === 0" size="small" style="float: right;" |
| | | type="primary" @click="addTableRow('sparePartsConfirmationList')">å¢å è¡</el-button> |
| | | </div> |
| | | <el-table :data="form.sparePartsConfirmationList" border stripe style="width: 100%; min-height: 30vh"> |
| | | <el-table-column label="åºå·" prop="åºå·" type="index" width="80" /> |
| | | <el-table-column label="åç§°" min-width="120" prop="name"> |
| | | <template v-slot="scope"> |
| | | <el-input v-if="currentStep === 0" v-model="scope.row.name" size="small"></el-input> |
| | | <label v-else>{{ scope.row.name }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æ°é" min-width="120" prop="number"> |
| | | <template v-slot="scope"> |
| | | <el-input v-if="currentStep === 0" v-model="scope.row.number" size="small"></el-input> |
| | | <label v-else>{{ scope.row.number }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="夿³¨" min-width="120" prop="note"> |
| | | <template v-slot="scope"> |
| | | <el-input v-if="currentStep === 0" v-model="scope.row.note" size="small"></el-input> |
| | | <label v-else>{{ scope.row.note }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column v-if="currentStep === 0" fixed="right" label="æä½" width="90"> |
| | | <template slot-scope="scope"> |
| | | <el-button icon="el-icon-delete" type="text" |
| | | @click="deleteRow(scope.$index, scope.row, 'sparePartsConfirmationList')">å é¤</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <div style="margin: 20px 0; width: 100%;"> |
| | | <label>æä»¶ç±»ç¡®è®¤ï¼</label> |
| | | <el-button v-if="currentStep === 0" size="small" style="float: right;" |
| | | type="primary" @click="addTableRow('fileClassConfirmationList')">å¢å è¡</el-button> |
| | | </div> |
| | | <el-table :data="form.fileClassConfirmationList" border stripe style="width: 100%; min-height: 30vh"> |
| | | <el-table-column label="åºå·" prop="åºå·" type="index" width="80" /> |
| | | <el-table-column label="åºæåæ°" min-width="120" prop="expectedCopies"> |
| | | <template v-slot="scope"> |
| | | <el-input v-if="currentStep === 0" v-model="scope.row.expectedCopies" size="small"></el-input> |
| | | <label v-else>{{ scope.row.expectedCopies }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="å®é
æ¶å°åæ°" min-width="120" prop="actualCopies"> |
| | | <template v-slot="scope"> |
| | | <el-input v-if="currentStep === 0" v-model="scope.row.actualCopies" size="small"></el-input> |
| | | <label v-else>{{ scope.row.actualCopies }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column v-if="currentStep === 0" fixed="right" label="æä½" width="90"> |
| | | <template v-slot="scope"> |
| | | <el-button icon="el-icon-delete" type="text" |
| | | @click="deleteRow(scope.$index, scope.row, 'fileClassConfirmationList')">å é¤</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | </el-col> |
| | | <el-col :span="24" style="margin-top: 10px;"> |
| | | <el-form-item label="夿³¨ï¼" label-width="90px"> |
| | | <el-input v-model="form.submitRemarks" :disabled="currentStep !== 0" size="small" |
| | | type="textarea"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-card> |
| | | <el-row style="margin-top: 1em;"> |
| | | <el-col :span="4"> |
| | | æä½äººï¼{{ form.submitOperatingPersonnel }} |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | æ¥æï¼{{ form.submitDate }} |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <div v-show="currentStepClick === 1"> |
| | | <el-card style="margin-top: 1em; height: 56vh; overflow-y: scroll;"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-form-item label="夿 ¸æè§ï¼" prop="accidentDescription"> |
| | | <el-input v-model="form.unpackingReviewOpinion" :disabled="currentStep !== 1" size="small" |
| | | type="textarea"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item :rules="[{ required: currentStep === 1, message: '请è¾å
¥ä¸ç¯è责任人', trigger: 'change' }]" label="ä¸ç¯è责任人ï¼" |
| | | prop="unpackingNextPesponsible"> |
| | | <el-select v-model="form.unpackingNextPesponsible" :disabled="currentStep !== 1" clearable filterable |
| | | placeholder="è¯·éæ©ä¸ç¯èè´è´£äºº" size="small" style="width: 50%;"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.id" :label="item.name" :value="item.name"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-card> |
| | | <el-row style="margin-top: 1em;"> |
| | | <el-col :span="4"> |
| | | æä½äººï¼{{ form.unpackingOperatingPersonnel }} |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | æ¥æï¼{{ form.unpackingDate }} |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <div v-show="currentStepClick === 2"> |
| | | <el-card style="margin-top: 1em; height: 56vh; overflow-y: scroll;"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-form-item :rules="[{ required: currentStep === 2, message: '请è¾å
¥å®è£
ä½ç½®', trigger: 'blur' }]" label="å®è£
ä½ç½®ï¼" |
| | | prop="installLocation"> |
| | | <el-input v-model="form.installLocation" :disabled="currentStep !== 2" clearable placeholder="请è¾å
¥å®è£
ä½ç½®" |
| | | size="small"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item label="夿³¨ï¼"> |
| | | <el-input v-model="form.installRemarks" :disabled="currentStep !== 2" size="small" |
| | | type="textarea"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item :rules="[{ required: currentStep === 2, message: '请è¾å
¥ä¸ç¯è责任人', trigger: 'blur' }]" label="ä¸ç¯è责任人ï¼" |
| | | prop="installNextPesponsible"> |
| | | <el-select v-model="form.installNextPesponsible" :disabled="currentStep !== 2" clearable filterable |
| | | placeholder="è¯·éæ©ä¸ç¯èè´è´£äºº" size="small" style="width: 50%;"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.id" :label="item.name" :value="item.name"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <div style="margin-bottom: 20px; width: 100%;"> |
| | | <label>å®è£
éªæ¶è®°å½</label> |
| | | <el-button v-if="currentStep === 2" size="small" style="float: right;" |
| | | type="primary" @click="addTableRow('installationAcceptanceRecordList')">å¢å è¡</el-button> |
| | | </div> |
| | | <el-table :data="form.installationAcceptanceRecordList" border stripe |
| | | style="width: 100%; min-height: 30vh"> |
| | | <el-table-column label="åºå·" prop="åºå·" type="index" width="80" /> |
| | | <el-table-column label="项ç®" min-width="120" prop="installationProject"> |
| | | <template v-slot="scope"> |
| | | <el-input v-if="currentStep === 2" v-model="scope.row.installationProject" |
| | | size="small"></el-input> |
| | | <label v-else>{{ scope.row.installationProject }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="å®è£
æ
åµ" min-width="120" prop="installationSituation"> |
| | | <template v-slot="scope"> |
| | | <el-input v-if="currentStep === 2" v-model="scope.row.installationSituation" |
| | | size="small"></el-input> |
| | | <label v-else>{{ scope.row.installationSituation }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="å®è£
宿" min-width="120" prop="installationCompleted"> |
| | | <template v-slot="scope"> |
| | | <el-select v-if="currentStep === 2" v-model="scope.row.installationCompleted" placeholder="è¯·éæ©"> |
| | | <el-option label="æ¯" value="0yes"></el-option> |
| | | <el-option label="å¦" value="1no"></el-option> |
| | | </el-select> |
| | | <label v-else>{{ scope.row.installationCompleted === '0yes' ? 'æ¯' : |
| | | scope.row.installationCompleted === '1no' ? 'å¦' : '' }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column v-if="currentStep === 2" fixed="right" label="æä½" width="90"> |
| | | <template slot-scope="scope"> |
| | | <el-button icon="el-icon-delete" type="text" |
| | | @click="deleteRow(scope.$index, scope.row, 'installationAcceptanceRecordList')">å é¤</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | </el-col> |
| | | </el-row> |
| | | </el-card> |
| | | <el-row style="margin-top: 1em;"> |
| | | <el-col :span="4"> |
| | | æä½äººï¼{{ form.installOperatingPersonnel }} |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | æ¥æï¼{{ form.installDate }} |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <div v-show="currentStepClick === 3"> |
| | | <el-card style="margin-top: 1em; height: 56vh; overflow-y: scroll;"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-form-item :rules="[{ required: currentStep === 3, message: '请è¾å
¥å¤åæè§', trigger: 'blur' }]" label="å¤åæè§ï¼" |
| | | prop="installationAcceptanceCompoundOpinion"> |
| | | <el-input v-model="form.installationAcceptanceCompoundOpinion" :disabled="currentStep !== 3" |
| | | size="small" type="textarea"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | <el-col :span="24"> |
| | | <el-form-item :rules="[{ required: currentStep === 3, message: '请è¾å
¥ä¸ç¯èè´è´£äºº', trigger: 'change' }]" label="ä¸ç¯è责任人ï¼" |
| | | prop="installationAcceptanceNextPesponsible"> |
| | | <el-select v-model="form.installationAcceptanceNextPesponsible" :disabled="currentStep !== 3" clearable |
| | | filterable placeholder="è¯·éæ©ä¸ç¯èè´è´£äºº" size="small" style="width: 50%;"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.id" :label="item.name" :value="item.name"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-card> |
| | | <el-row style="margin-top: 1em;"> |
| | | <el-col :span="4"> |
| | | æä½äººï¼{{ form.installationAcceptanceOperatingPersonnel }} |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | æ¥æï¼{{ form.installationAcceptanceDate }} |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <div v-show="currentStepClick === 4"> |
| | | <el-card style="margin-top: 1em; height: 56vh; overflow-y: scroll;"> |
| | | <div style="margin-bottom: 20px; width: 100%;"> |
| | | <label>éªæ¶æ ¸æ¥è®°å½ï¼</label> |
| | | <el-button v-if="currentStep === 4" size="small" style="float: right;" |
| | | type="primary" @click="addTableRow('acceptanceCheckRecordList')">å¢å è¡</el-button> |
| | | </div> |
| | | <el-table :data="form.acceptanceCheckRecordList" border style="width: 100%; min-height: 30vh"> |
| | | <el-table-column label="åºå·" prop="sequence" width="80"> |
| | | </el-table-column> |
| | | <el-table-column label="ä»ªå¨æ¨¡å" min-width="120" prop="instrumentModule"> |
| | | <template v-slot="scope"> |
| | | <el-input v-if="currentStep === 4" v-model="scope.row.instrumentModule" size="small"></el-input> |
| | | <label v-else>{{ scope.row.instrumentModule }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æ ¸æ¥åæ°" min-width="120" prop="verificationParameter"> |
| | | <template v-slot="scope"> |
| | | <el-input v-if="currentStep === 4" v-model="scope.row.verificationParameter" size="small"></el-input> |
| | | <label v-else>{{ scope.row.verificationParameter }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="坿¥æ¶é" min-width="120" prop="acceptableLimit"> |
| | | <template v-slot="scope"> |
| | | <el-input v-if="currentStep === 4" v-model="scope.row.acceptableLimit" size="small"></el-input> |
| | | <label v-else>{{ scope.row.acceptableLimit }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æ ¸æ¥ç»æ" min-width="120" prop="verificationResult"> |
| | | <template v-slot="scope"> |
| | | <el-input v-if="currentStep === 4" v-model="scope.row.verificationResult" size="small"></el-input> |
| | | <label v-else>{{ scope.row.verificationResult }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column label="æ ¸æ¥ç»è®º" min-width="120" prop="verificationConclusion"> |
| | | <template v-slot="scope"> |
| | | <el-select v-if="currentStep === 4" v-model="scope.row.verificationConclusion" placeholder="è¯·éæ©"> |
| | | <el-option label="符å" value="0accordWith"></el-option> |
| | | <el-option label="ä¸ç¬¦å" value="1inconformity"></el-option> |
| | | </el-select> |
| | | <label v-else>{{ scope.row.verificationConclusion }}</label> |
| | | </template> |
| | | </el-table-column> |
| | | <el-table-column v-if="currentStep === 4" fixed="right" label="æä½" width="90"> |
| | | <template slot-scope="scope"> |
| | | <el-button size="small" type="text" |
| | | @click="deleteRow(scope.$index, scope.row, 'acceptanceCheckRecordList')">å é¤</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | | <el-form-item :rules="[{ required: currentStep === 4, message: '请è¾å
¥è®¾å¤å¼ç®±éªæ¶ç»è®º', trigger: 'change' }]" label="设å¤å¼ç®±éªæ¶ç»è®ºï¼" |
| | | label-width="150px" prop="acceptanceCheckUnpackingConclusion"> |
| | | <el-radio-group v-model="form.acceptanceCheckUnpackingConclusion" :disabled="currentStep !== 4"> |
| | | <el-radio :label="'0qualified'">åæ ¼</el-radio> |
| | | <el-radio :label="'1unqualified'">ä¸åæ ¼ï¼ç¼ºå°å¤ä»¶ä¾åºåè¡¥å</el-radio> |
| | | </el-radio-group> |
| | | </el-form-item> |
| | | <el-form-item :rules="[{ required: currentStep === 4, message: '请è¾å
¥ä¸ç¯è责任人', trigger: 'change' }]" label="ä¸ç¯è责任人ï¼" |
| | | prop="acceptanceCheckNextPesponsible"> |
| | | <el-select v-model="form.acceptanceCheckNextPesponsible" :disabled="currentStep !== 4" clearable |
| | | filterable placeholder="è¯·éæ©ä¸ç¯èè´è´£äºº" size="small" style="width: 50%;"> |
| | | <el-option v-for="item in responsibleOptions" :key="item.value" :label="item.label" :value="item.name"> |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | </el-card> |
| | | <el-row style="margin-top: 1em;"> |
| | | <el-col :span="4"> |
| | | æä½äººï¼{{ form.acceptanceCheckOperatingPersonnel }} |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | æ¥æï¼{{ form.acceptanceCheckDate }} |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | <div v-show="currentStepClick === 5"> |
| | | <el-card style="margin-top: 1em; height: 56vh; overflow-y: scroll;"> |
| | | <el-row> |
| | | <el-col :span="24"> |
| | | <el-form-item :rules="[{ required: currentStep === 5, message: '请è¾å
¥å®¡æ ¸æè§', trigger: 'blur' }]" label="å®¡æ ¸æè§ï¼" |
| | | prop="acceptanceAuditAuditOpinion"> |
| | | <el-input v-model="form.acceptanceAuditAuditOpinion" :disabled="currentStep !== 5" size="small" |
| | | type="textarea"></el-input> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | | </el-card> |
| | | <el-row style="margin-top: 1em;"> |
| | | <el-col :span="4"> |
| | | æä½äººï¼{{ form.acceptanceAuditOperatingPersonnel }} |
| | | </el-col> |
| | | <el-col :span="6"> |
| | | æ¥æï¼{{ form.acceptanceAuditDate }} |
| | | </el-col> |
| | | </el-row> |
| | | </div> |
| | | </el-form> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button v-if="currentStep !== 0 && currentStep !== 6" @click="submitForm('3reject')">驳å</el-button> |
| | | <el-button v-if="currentStep === 0" @click="submitForm('2save')">ä¿å</el-button> |
| | | <el-button v-if="currentStep !== 6" type="primary" @click="submitForm('1submit')">{{ currentStep === 0 ? 'æäº¤' : |
| | | 'éè¿' |
| | | }}</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | <!-- æ¥åç¼è¾æ¡ --> |
| | | </template> |
| | | |
| | | <script> |
| | | import { dateFormat } from '@/utils/date' |
| | | import file from "@/utils/file"; |
| | | import { |
| | | deleteCNASFile, deleteIncidentReport, |
| | | deleteIncidentReportAll, getShowIncidentReport, incidentReportExport, incidentReportPage, |
| | | saveIncidentReportData, |
| | | selectDeviceByCode |
| | | } from "@/api/cnas/resourceDemand/device"; |
| | | import {selectUserCondition} from "@/api/system/user"; |
| | | import {mapGetters} from "vuex"; |
| | | |
| | | export default { |
| | | props: { |
| | | clickNodeVal: { |
| | | type: Object, |
| | | default: () => { |
| | | return {}; |
| | | } |
| | | } |
| | | }, |
| | | data() { |
| | | return { |
| | | //äºæ
设å¤ä¿¡æ¯ |
| | | tableDataAlist: [], // æ´æ¹åéåç§° |
| | | tableLoading: false, |
| | | dialogVisible: false, |
| | | rules: { |
| | | quantity: [{ required: true, message: '请è¾å
¥æ°é', trigger: 'blur' }], |
| | | }, |
| | | currentStep: 0, // æ¥éª¤æ¡æ¾ç¤ºç¬¬å æ¥ |
| | | currentStepClick: 0, // ç¹å»æ¥éª¤æ¡åå |
| | | steps: ['æäº¤', 'å¼ç®±éªæ¶å¤æ ¸', 'å®è£
éªæ¶æ£æ¥', 'å®è£
éªæ¶å¤æ ¸', 'éªæ¶æ ¸æ¥', 'éªæ¶æ ¸æ¥å®¡æ ¸'], |
| | | form: { |
| | | sparePartsConfirmationList: [], // å¤ä»¶ç¡®è®¤List |
| | | fileClassConfirmationList: [], // æä»¶ç¡®è®¤List |
| | | installationAcceptanceRecordList: [], // å®è£
éªæ¶è®°å½ |
| | | acceptanceCheckRecordList: [], // éªæ¶æ ¸æ¥è®°å½ |
| | | fileName: '', // æä»¶åç§° |
| | | systemFileName: '', // ç³»ç»æä»¶åç§° |
| | | }, |
| | | outLoading: false, |
| | | responsibleOptions: [], // ä¸ç¯èè´è´£äººlist |
| | | isUpdate: false, |
| | | search: { |
| | | size: 20, |
| | | current: 1, |
| | | total: 0, |
| | | processNumber: '', |
| | | }, |
| | | } |
| | | }, |
| | | computed: { |
| | | action() { |
| | | return this.javaApi + '/personBasicInfo/saveCNASFile' |
| | | }, |
| | | ...mapGetters(["nickName"]), |
| | | }, |
| | | mounted() { |
| | | // è·å设å¤äºæ
ä¿¡æ¯ |
| | | this.getDeviceAList(this.clickNodeVal.value); |
| | | window.excelClosed = this.closed |
| | | }, |
| | | methods: { |
| | | handleSizeChange(val) { |
| | | this.search.size = val |
| | | this.getDeviceAList(this.clickNodeVal.value); |
| | | }, |
| | | handleCurrentChange(val) { |
| | | this.search.current = val |
| | | this.getDeviceAList(this.clickNodeVal.value); |
| | | }, |
| | | deleteFile() { |
| | | this.$confirm('æ¤æä½å°æ°¸ä¹
å é¤è¯¥æä»¶, æ¯å¦ç»§ç»?', 'æç¤º', { |
| | | confirmButtonText: 'ç¡®å®', |
| | | cancelButtonText: 'åæ¶', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | deleteCNASFile({fileName: this.form.systemFileName}).then(res => { |
| | | if (res.code == 200) { |
| | | this.$message.success('å 餿åï¼') |
| | | } |
| | | }) |
| | | }).catch(() => { |
| | | this.$message({ |
| | | type: 'info', |
| | | message: '已忶å é¤' |
| | | }); |
| | | }); |
| | | }, |
| | | onSuccess(response, file, fileList) { |
| | | if (response.code == 200) { |
| | | // å¨ä¿åèµå¼æ°æä»¶ |
| | | this.form.fileName = file.name |
| | | this.form.systemFileName = response.data |
| | | } else { |
| | | this.$message.error(response.message) |
| | | } |
| | | }, |
| | | addTableRow(value) { |
| | | switch (value) { |
| | | // å¤ä»¶ç¡®è®¤ |
| | | case 'sparePartsConfirmationList': |
| | | const obj = Object.assign({ |
| | | name: '', |
| | | number: null, |
| | | note: '' |
| | | }) |
| | | this.form.sparePartsConfirmationList.push(obj) |
| | | break |
| | | // æä»¶ç¡®è®¤List |
| | | case 'fileClassConfirmationList': |
| | | const obj1 = Object.assign({ |
| | | expectedCopies: '', |
| | | actualCopies: '', |
| | | }) |
| | | this.form.fileClassConfirmationList.push(obj1) |
| | | break |
| | | // å®è£
éªæ¶è®°å½ |
| | | case 'installationAcceptanceRecordList': |
| | | const obj2 = Object.assign({ |
| | | installationProject: '', |
| | | installationSituation: '', |
| | | installationCompleted: '' |
| | | }) |
| | | this.form.installationAcceptanceRecordList.push(obj2) |
| | | break |
| | | // éªæ¶æ ¸æ¥è®°å½ |
| | | case 'acceptanceCheckRecordList': |
| | | const obj3 = Object.assign({ |
| | | instrumentModule: '', |
| | | verificationParameter: '', |
| | | acceptableLimit: '', |
| | | verificationResult: '', |
| | | verificationConclusion: '' |
| | | }) |
| | | this.form.acceptanceCheckRecordList.push(obj3) |
| | | default: |
| | | break |
| | | } |
| | | }, |
| | | deleteRow(index, row, type) { |
| | | switch (type) { |
| | | // å¤ä»¶ç¡®è®¤ |
| | | case 'sparePartsConfirmationList': |
| | | if (row.sparePartsId) { |
| | | deleteIncidentReportAll({sparePartsId: row.sparePartsId}).then(res => { }); |
| | | } |
| | | this.form.sparePartsConfirmationList.splice(index, 1) |
| | | this.$message.success('å 餿åï¼') |
| | | break |
| | | // æä»¶ç¡®è®¤List |
| | | case 'fileClassConfirmationList': |
| | | if (row.fileId) { |
| | | deleteIncidentReportAll({fileId: row.fileId}).then(res => { }); |
| | | } |
| | | this.form.fileClassConfirmationList.splice(index, 1) |
| | | this.$message.success('å 餿åï¼') |
| | | break |
| | | // å®è£
éªæ¶è®°å½ |
| | | case 'installationAcceptanceRecordList': |
| | | if (row.installId) { |
| | | deleteIncidentReportAll({installId: row.installId}).then(res => { }); |
| | | } |
| | | this.form.installationAcceptanceRecordList.splice(index, 1) |
| | | this.$message.success('å 餿åï¼') |
| | | break |
| | | // éªæ¶æ ¸æ¥è®°å½ |
| | | case 'acceptanceCheckRecordList': |
| | | if (row.acceptanceCheckId) { |
| | | deleteIncidentReportAll({acceptanceCheckId: row.acceptanceCheckId}).then(res => { }); |
| | | } |
| | | this.form.acceptanceCheckRecordList.splice(index, 1) |
| | | this.$message.success('å 餿åï¼') |
| | | default: |
| | | break |
| | | } |
| | | }, |
| | | choiceStep(index) { |
| | | this.currentStepClick = index |
| | | }, |
| | | openRecordAcceptance() { |
| | | // è·å设å¤åºç¡ä¿¡æ¯ |
| | | selectDeviceByCode({id: this.clickNodeVal.value}).then(res => { |
| | | this.form.deviceName = res.data.deviceName |
| | | this.form.manufacturer = res.data.manufacturer |
| | | this.form.specificationModel = res.data.specificationModel |
| | | this.form.managementNumber = res.data.managementNumber |
| | | this.$nextTick(() => { |
| | | this.$refs['form'].clearValidate() |
| | | }) |
| | | }); |
| | | // è·åè´è´£äººä¿¡æ¯ |
| | | this.getUserList() |
| | | }, |
| | | //æäº¤è¡¨å |
| | | async submitForm(saveState) { |
| | | this.$refs.form.validate((valid) => { |
| | | if (valid === true || saveState !== '1submit') { |
| | | // ç»å½åç¯è设置åå»ºäººä¸æ¶é´ |
| | | const dateTime = dateFormat(new Date()) |
| | | // è·åå½åç¯èæä½äººä¸æ¥æ |
| | | switch (this.currentStep) { |
| | | case 0: |
| | | this.form.submitOperatingPersonnel = this.nickName |
| | | this.form.submitDate = dateTime |
| | | break |
| | | case 1: |
| | | this.form.unpackingOperatingPersonnel = this.nickName |
| | | this.form.unpackingDate = dateTime |
| | | break |
| | | case 2: |
| | | this.form.installOperatingPersonnel = this.nickName |
| | | this.form.installDate = dateTime |
| | | break |
| | | case 3: |
| | | this.form.installationAcceptanceOperatingPersonnel = this.nickName |
| | | this.form.installationAcceptanceDate = dateTime |
| | | break |
| | | case 4: |
| | | this.form.acceptanceCheckOperatingPersonnel = this.nickName |
| | | this.form.acceptanceCheckDate = dateTime |
| | | break |
| | | case 5: |
| | | this.form.acceptanceAuditOperatingPersonnel = this.nickName |
| | | this.form.acceptanceAuditDate = dateTime |
| | | break |
| | | default: |
| | | break |
| | | } |
| | | // è·åå½åç¯èè´è´£äºº |
| | | switch (saveState === '3reject' ? this.currentStep - 1 : this.currentStep) { |
| | | case 0: |
| | | this.form.currentResponsible = this.form.submitNextPesponsible |
| | | break |
| | | case 1: |
| | | this.form.currentResponsible = this.form.unpackingNextPesponsible |
| | | break |
| | | case 2: |
| | | this.form.currentResponsible = this.form.installNextPesponsible |
| | | break |
| | | case 3: |
| | | this.form.currentResponsible = this.form.installationAcceptanceNextPesponsible |
| | | break |
| | | case 4: |
| | | this.form.currentResponsible = this.form.acceptanceCheckNextPesponsible |
| | | break |
| | | default: |
| | | break |
| | | } |
| | | let currentStepAction; |
| | | // 设置该æä½å¤ææ¯å¦ä¸ºæäº¤ï¼ä¿åï¼é©³åï¼éè¿ |
| | | switch (saveState) { |
| | | // æäº¤ï¼éè¿ |
| | | case '1submit': |
| | | currentStepAction = this.currentStep + 1 |
| | | break |
| | | // ä¿å |
| | | case '2save': |
| | | currentStepAction = this.currentStep |
| | | break |
| | | // 驳å |
| | | case '3reject': |
| | | currentStepAction = this.currentStep - 1 |
| | | break |
| | | default: |
| | | break |
| | | } |
| | | // è·åå½åç¶æ |
| | | this.form.currentState = currentStepAction === 6 ? 'å
³é' : this.steps[currentStepAction] |
| | | this.form.deviceId = this.clickNodeVal.value |
| | | saveIncidentReportData(this.form).then(res => { |
| | | if (res.code == 200) { |
| | | this.$message.success('æäº¤æå') |
| | | this.getDeviceAList(this.clickNodeVal.value); |
| | | this.dialogVisible = false |
| | | } |
| | | }) |
| | | } else { |
| | | let step = this.steps[this.currentStep] |
| | | this.$message.warning(step + ' æµç¨ä¸æå¿
填项æªå¡«ï¼'); |
| | | } |
| | | }); |
| | | }, |
| | | // è·åè´è´£äººä¿¡æ¯æ¥å£ |
| | | getUserList() { |
| | | selectUserCondition().then(res => { |
| | | if (res.code == 200) { |
| | | this.responsibleOptions = res.data |
| | | } |
| | | }) |
| | | }, |
| | | resetSearch() { |
| | | this.search = { |
| | | size: 20, |
| | | current: 1, |
| | | total: 0, |
| | | processNumber: '', |
| | | } |
| | | this.getDeviceAList(this.clickNodeVal.value); |
| | | }, |
| | | // è·å设å¤äºæ
ä¿¡æ¯(æ ¹æ®ä»vuexä¸è·åå°ç设å¤åç§°idè¿è¡æ°æ®æ¥è¯¢) |
| | | getDeviceAList(deviceId) { |
| | | this.tableLoading = true |
| | | incidentReportPage({deviceId: deviceId, size:this.search.size, current:this.search.current, processNumber: this.search.processNumber}).then(res => { |
| | | this.tableLoading = false |
| | | if (res.code == 200) { |
| | | this.tableDataAlist = res.data.records |
| | | this.search.total = res.data.total |
| | | } |
| | | }).catch(err => { |
| | | this.tableLoading = false |
| | | }) |
| | | }, |
| | | //table äºä»¶å¤çå¼å§å¤ |
| | | // ä¸è½½éä»¶ |
| | | handleAttachmentClick(row) { |
| | | this.$download.saveAs(row.systemFileName, row.fileName) |
| | | }, |
| | | handleViewClick(row) { |
| | | getShowIncidentReport({id: row.id}).then(res => { |
| | | this.form = { ...res.data } |
| | | // å¦æç´¢å¼ä¸º6表示å
¨é¨éè¿ |
| | | this.currentStep = this.steps.indexOf(this.form.currentState) === -1 ? 6 : this.steps.indexOf(this.form.currentState) |
| | | this.currentStepClick = this.currentStep === 6 ? 0 : this.currentStep |
| | | this.$nextTick(() => { |
| | | this.$refs['form'].clearValidate() |
| | | }) |
| | | }) |
| | | this.dialogVisible = true |
| | | }, |
| | | handleDeleteClick(row) { |
| | | this.$confirm('æ¤æä½å°å é¤è¯¥æ°æ®, æ¯å¦ç»§ç»?', 'æç¤º', { |
| | | confirmButtonText: 'ç¡®å®', |
| | | cancelButtonText: 'åæ¶', |
| | | type: 'warning' |
| | | }).then(() => { |
| | | deleteIncidentReport({id: row.id}).then(res => { |
| | | if (res.code == 200) { |
| | | this.$message.success('å 餿å') |
| | | this.getDeviceAList(this.clickNodeVal.value); |
| | | } |
| | | }) |
| | | }).catch(() => { |
| | | this.$message({ |
| | | type: 'info', |
| | | message: '已忶å é¤' |
| | | }); |
| | | }); |
| | | |
| | | }, |
| | | //å¯¼åº |
| | | handleDown() { |
| | | this.outLoading = true |
| | | incidentReportExport({deviceId: this.clickNodeVal.value}).then(res => { |
| | | this.outLoading = false |
| | | const blob = new Blob([res], { type: 'application/octet-stream' }); |
| | | this.$download.saveAs(blob, '设å¤éªæ¶.xlsx') |
| | | }) |
| | | }, |
| | | }, |
| | | watch: { |
| | | // çå¬ç¹å»el-treeçæ°æ®ï¼è¿è¡æ°æ®å·æ° |
| | | clickNodeVal(newVal) { |
| | | if (newVal.value) { |
| | | this.getDeviceAList(newVal.value); |
| | | } |
| | | }, |
| | | dialogVisible(newVal) { |
| | | if (!newVal) { |
| | | this.form = { |
| | | sparePartsConfirmationList: [], // å¤ä»¶ç¡®è®¤List |
| | | fileClassConfirmationList: [], // æä»¶ç¡®è®¤List |
| | | installationAcceptanceRecordList: [], // å®è£
éªæ¶è®°å½ |
| | | acceptanceCheckRecordList: [], // éªæ¶æ ¸æ¥è®°å½ |
| | | fileName: '', // æä»¶åç§° |
| | | systemFileName: '', // ç³»ç»æä»¶åç§° |
| | | } |
| | | this.currentStep = 0 // æ¥éª¤æ¡æ¾ç¤ºç¬¬å æ¥ |
| | | this.currentStepClick = 0 // ç¹å»æ¥éª¤æ¡åå |
| | | this.$refs['form'].clearValidate() |
| | | } |
| | | } |
| | | } |
| | | } |
| | | function downloadImage(url) { |
| | | const link = document.createElement('a'); |
| | | link.href = url; |
| | | link.download = 'attachment.jpg'; // æä»¶å |
| | | document.body.appendChild(link); |
| | | link.click(); |
| | | document.body.removeChild(link); |
| | | } |
| | | </script> |
| | | |
| | | <style scoped> |
| | | >>>.el-radio { |
| | | color: #606266; |
| | | font-weight: 500; |
| | | cursor: pointer; |
| | | margin-right: 0px; |
| | | width: 10em; |
| | | } |
| | | |
| | | .tables { |
| | | width: 100%; |
| | | height: calc(100vh - 17em); |
| | | } |
| | | |
| | | .search { |
| | | margin-top: 10px; |
| | | background-color: #fff; |
| | | height: 40px; |
| | | display: flex; |
| | | align-items: center; |
| | | position: relative; |
| | | } |
| | | |
| | | .search_thing { |
| | | display: flex; |
| | | align-items: center; |
| | | height: 40px; |
| | | } |
| | | |
| | | .search_label { |
| | | font-size: 14px; |
| | | text-align: right; |
| | | } |
| | | |
| | | .search_input { |
| | | width: calc(100% - 120px); |
| | | } |
| | | |
| | | .btns { |
| | | position: absolute; |
| | | right: 0px; |
| | | top: 40%; |
| | | transform: translate(0, -50%); |
| | | /* text-align: right; */ |
| | | } |
| | | |
| | | .search_thing { |
| | | display: flex; |
| | | margin-bottom: 10px; |
| | | } |
| | | |
| | | .search_label { |
| | | /* width: 150px; */ |
| | | text-align: right; |
| | | padding-right: 10px; |
| | | } |
| | | |
| | | .search_input { |
| | | flex-grow: 1; |
| | | } |
| | | |
| | | .line { |
| | | width: 20px; |
| | | height: 1px; |
| | | background-color: #ccc; |
| | | display: inline-block; |
| | | margin-right: 10px; |
| | | } |
| | | |
| | | .form .search_label { |
| | | width: 120px; |
| | | } |
| | | </style> |