You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

4183 lines
157 KiB

3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
11 months ago
11 months ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
5 months ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
1 year ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
5 months ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
1 year ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
5 months ago
3 years ago
3 years ago
3 years ago
3 years ago
5 months ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
3 years ago
  1. <template>
  2. <div class="mod-config">
  3. <!-- 条件查询 -->
  4. <el-form :inline="true" label-position="top" :model="searchData">
  5. <el-form-item :label="'BU'">
  6. <el-select v-model="searchData.buNo" placeholder="请选择" clearable style="width: 75px">
  7. <el-option
  8. v-for = "i in buList"
  9. :key = "i.buNo"
  10. :label = "i.buDesc"
  11. :value = "i.buNo">
  12. </el-option>
  13. </el-select>
  14. </el-form-item>
  15. <el-form-item :label="'检验单号'">
  16. <el-input v-model="searchData.inspectionNo" clearable style="width: 120px"></el-input>
  17. </el-form-item>
  18. <el-form-item :label="'物料编码'">
  19. <el-input v-model="searchData.partNo" clearable style="width: 120px"></el-input>
  20. </el-form-item>
  21. <el-form-item :label="'SKU'">
  22. <el-input v-model="searchData.sku" clearable style="width: 120px"></el-input>
  23. </el-form-item>
  24. <el-form-item :label="'物料名称'">
  25. <el-input v-model="searchData.partDesc" clearable style="width: 200px"></el-input>
  26. </el-form-item>
  27. <el-form-item :label="'检验结论'">
  28. <el-select v-model="searchData.inspectionResult" clearable style="width: 80px">
  29. <el-option label="合格" value="合格"></el-option>
  30. <el-option label="不合格" value="不合格"></el-option>
  31. </el-select>
  32. </el-form-item>
  33. <el-form-item :label="'处置措施'">
  34. <el-select v-model="searchData.disposalMeasures" clearable style="width: 90px">
  35. <el-option
  36. v-for = "i in disposalMeasuresOptions"
  37. :key = "i.id"
  38. :label = "i.disposalMeasures"
  39. :value = "i.disposalMeasures">
  40. </el-option>
  41. </el-select>
  42. </el-form-item>
  43. </el-form>
  44. <el-form :inline="true" label-position="top" :model="searchData">
  45. <el-form-item :label="'PN'">
  46. <el-input v-model="searchData.cinvSourceCode" clearable style="width: 120px"></el-input>
  47. </el-form-item>
  48. <el-form-item :label="'工单号'">
  49. <el-input v-model="searchData.orderNo" clearable style="width: 137px"></el-input>
  50. </el-form-item>
  51. <el-form-item :label="'派工单号'">
  52. <el-input v-model="searchData.seqNo" clearable style="width: 167px"></el-input>
  53. </el-form-item>
  54. <el-form-item :label="'工序'">
  55. <el-input v-model="searchData.operationDesc" clearable style="width: 108px"></el-input>
  56. </el-form-item>
  57. <el-form-item :label="'状态'">
  58. <el-select v-model="searchData.states" multiple style="width:340px">
  59. <el-option label="未开始" value="未开始"></el-option>
  60. <el-option label="待检验" value="待检验"></el-option>
  61. <el-option label="待审核" value="待审核"></el-option>
  62. <el-option label="已完成" value="已完成"></el-option>
  63. </el-select>
  64. </el-form-item>
  65. </el-form>
  66. <el-form :inline="true" label-position="top" :model="searchData">
  67. <el-form-item :label="'送检日期'">
  68. <el-date-picker style="width: 150px" v-model="searchData.startDate2" type="datetime" value-format='yyyy-MM-dd HH:mm' format='yyyy-MM-dd HH:mm' placeholder="开始日期"></el-date-picker>
  69. -
  70. <el-date-picker style="width: 150px" v-model="searchData.endDate2" type="datetime" value-format='yyyy-MM-dd HH:mm' format='yyyy-MM-dd HH:mm' placeholder="结束日期"></el-date-picker>
  71. </el-form-item>
  72. <el-form-item :label="'检验时间'">
  73. <el-date-picker style="width: 170px" v-model="searchData.startDate" type="datetime"
  74. value-format='yyyy-MM-dd HH:mm:ss' format='yyyy-MM-dd HH:mm:ss' placeholder="开始日期">
  75. </el-date-picker>
  76. -
  77. <el-date-picker style="width: 170px" v-model="searchData.endDate" type="datetime"
  78. value-format='yyyy-MM-dd HH:mm:ss' format='yyyy-MM-dd HH:mm:ss' placeholder="结束日期">
  79. </el-date-picker>
  80. </el-form-item>
  81. <el-form-item :label="' '">
  82. <el-button v-if="!authSearch" type="primary" :loading="searchLoading" @click="getDataList">查询</el-button>
  83. <el-button v-if="!authSave" type="primary" @click="addModal">新增</el-button>
  84. <el-button v-if="!authCheck" type="primary" @click="submitResult">审核</el-button>
  85. <el-button v-if="!authCancelCheck" type="primary" @click="cancelApproval">取消审核</el-button>
  86. <el-button v-if="!authDelete" type="primary" @click="deleteModal">删除</el-button>
  87. <el-button type="primary" @click="printList">打印</el-button>
  88. <download-excel
  89. :fields="fields()"
  90. :data="exportData"
  91. type="xls"
  92. :name="exportName"
  93. :header="exportHeader"
  94. :footer="exportFooter"
  95. :fetch="createExportData"
  96. :before-generate="startDownload"
  97. :before-finish="finishDownload"
  98. worksheet="导出信息"
  99. class="el-button el-button--primary el-button--medium">
  100. {{ "导出" }}
  101. </download-excel>
  102. </el-form-item>
  103. </el-form>
  104. <!-- 检验记录展示列表 -->
  105. <el-table
  106. :height="height"
  107. :data="dataList"
  108. border
  109. ref="FAITable"
  110. @row-click="FAIClickRow"
  111. @selection-change="selectionFAI"
  112. style="width: 100%;">
  113. <el-table-column
  114. type="selection"
  115. header-align="center"
  116. align="center"
  117. :selectable="selectFlag"
  118. width="50">
  119. </el-table-column>
  120. <el-table-column
  121. prop="state"
  122. header-align="center"
  123. align="center"
  124. label="状态">
  125. <template slot-scope="scope">
  126. <div :style="{fontWeight:'bold', color: scope.row.state === '待检验' ? 'red' : scope.row.state === '待审核' ? '#ffa500e0' : scope.row.state === '已完成' ? '#3ac252' : ''}">
  127. {{scope.row.state}}
  128. </div>
  129. </template>
  130. </el-table-column>
  131. <el-table-column
  132. v-for="(item,index) in columnList1" :key="index"
  133. :sortable="item.columnSortable"
  134. :prop="item.columnProp"
  135. :header-align="item.headerAlign"
  136. :show-overflow-tooltip="item.showOverflowTooltip"
  137. :align="item.align"
  138. :fixed="item.fixed==''?false:item.fixed"
  139. :min-width="item.columnWidth"
  140. :label="item.columnLabel">
  141. <template slot-scope="scope">
  142. <span v-if="!item.columnHidden"> {{ scope.row[item.columnProp] }}</span>
  143. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  144. </template>
  145. </el-table-column>
  146. <el-table-column
  147. fixed="right"
  148. header-align="center"
  149. align="center"
  150. width="130"
  151. label="操作">
  152. <template slot-scope="scope">
  153. <el-link style="cursor: pointer" v-if="!authDetail && scope.row.state === '未开始'" @click="actionModal(scope.row)">开始检验</el-link>
  154. <el-link style="cursor: pointer" v-if="!authDetail && scope.row.state !== '未开始'" @click="detailModal(scope.row)">检验单</el-link>
  155. <el-link style="cursor: pointer" v-if="!authFile" @click="getFileContentData(scope.row)">工作文件</el-link>
  156. </template>
  157. </el-table-column>
  158. </el-table>
  159. <!-- 分页-->
  160. <el-pagination
  161. @size-change="sizeChangeHandle"
  162. @current-change="currentChangeHandle"
  163. :current-page="pageIndex"
  164. :page-sizes="[20, 50, 100, 200, 500]"
  165. :page-size="pageSize"
  166. :total="totalPage"
  167. layout="total, sizes, prev, pager, next, jumper">
  168. </el-pagination>
  169. <!-- 新增检验记录 -->
  170. <el-dialog title="新增检验记录" :close-on-click-modal="false" v-drag :visible.sync="modalFlag" width="495px">
  171. <el-form :inline="true" label-position="top" :model="modalData" :rules="rules" style="margin-left: 7px;margin-top: -5px;">
  172. <el-form-item label="BU" prop="bu" :rules="rules.bu">
  173. <el-select v-model="modalData.bu" placeholder="请选择" @change="buChange" style="width: 221px">
  174. <el-option
  175. v-for = "i in userBuList"
  176. :key = "i.buNo"
  177. :label = "i.sitename"
  178. :value = "i.buNo">
  179. <span style="float: left;width: 100px">{{ i.sitename }}</span>
  180. <span style="float: right; color: #8492a6;white-space:nowrap;overflow:hidden;text-overflow:ellipsis; font-size: 11px;width: 60px">
  181. {{ i.buDesc }}
  182. </span>
  183. </el-option>
  184. </el-select>
  185. </el-form-item>
  186. <el-form-item label="标签号">
  187. <!-- <el-autocomplete v-if="this.modalData.specialTaskFlag === 'Y'" disabled style="width: 456px" size="mini" v-model="modalData.rollNo" clearable-->
  188. <!-- :fetch-suggestions="querySearchAsync" @select="handleSelect"-->
  189. <!-- placeholder="请输入标签号">-->
  190. <!-- </el-autocomplete>-->
  191. <!-- <el-autocomplete v-if="this.modalData.specialTaskFlag !== 'Y'" style="width: 456px" size="mini" v-model="modalData.rollNo" clearable-->
  192. <!-- :fetch-suggestions="querySearchAsync" @select="handleSelect"-->
  193. <!-- placeholder="请输入标签号">-->
  194. <!-- </el-autocomplete>-->
  195. <el-input v-if="this.modalData.specialTaskFlag === 'Y'" disabled v-model="modalData.rollNo" style="width: 221px"></el-input>
  196. <el-input v-else v-model="modalData.rollNo" @keyup.native.enter="rollNoEnter" clearable style="width: 221px"></el-input>
  197. </el-form-item>
  198. </el-form>
  199. <el-form :inline="true" label-position="top" :model="modalData" :rules="rules" style="margin-left: 7px;margin-top: -5px;">
  200. <el-form-item v-if="this.modalData.specialTaskFlag !== 'Y' && (this.modalData.rollNo === '' || this.modalData.rollNo == null)" prop="orderNo" :rules="rules.seqNoType">
  201. <span style="cursor: pointer" slot="label" @click="getBaseList(1052)"><a herf="#">派工单号</a></span>
  202. <el-input v-model="modalData.seqNo" style="width: 221px"></el-input>
  203. </el-form-item>
  204. <el-form-item v-if="this.modalData.specialTaskFlag !== 'Y' && this.modalData.rollNo !== '' && this.modalData.rollNo != null" prop="orderNo" :rules="rules.seqNoType">
  205. <span slot="label">派工单号</span>
  206. <el-input v-model="modalData.seqNo" disabled style="width: 221px"></el-input>
  207. </el-form-item>
  208. <el-form-item v-if="this.modalData.specialTaskFlag === 'Y'" prop="orderNo" :rules="rules.seqNoType">
  209. <span slot="label">派工单号</span>
  210. <el-input v-model="modalData.seqNo" disabled style="width: 221px"></el-input>
  211. </el-form-item>
  212. <el-form-item label="工单号" prop="orderNo" :rules="rules.orderNoType">
  213. <el-input v-model="modalData.orderNo" style="width: 221px" disabled></el-input>
  214. </el-form-item>
  215. </el-form>
  216. <el-form :inline="true" label-position="top" :model="modalData" :rules="rules" style="margin-left: 7px;margin-top: -5px;">
  217. <el-form-item label="工序" prop="operationDesc" :rules="rules.operationDescType">
  218. <el-select v-model="modalData.operationDesc" placeholder="请选择" style="width: 221px">
  219. <el-option
  220. v-for = "i in operationList"
  221. :key = "i.operationNo"
  222. :label = "i.operationDesc"
  223. :value = "i.operationDesc">
  224. </el-option>
  225. </el-select>
  226. </el-form-item>
  227. <el-form-item v-if="this.modalData.specialTaskFlag === 'Y'">
  228. <span style="cursor: pointer" slot="label" @click="getBaseList(505)"><a herf="#">机台</a></span>
  229. <el-input v-model="modalData.resourceDesc" style="width: 221px"></el-input>
  230. </el-form-item>
  231. <el-form-item v-else label="机台" prop="resourceId" :rules="rules.resourceIdType">
  232. <!-- <el-select v-model="modalData.resourceDesc" placeholder="请选择" style="width: 221px">-->
  233. <!-- <el-option-->
  234. <!-- v-for = "i in resourceList"-->
  235. <!-- :key = "i.resourceId"-->
  236. <!-- :label = "i.resourceDesc"-->
  237. <!-- :value = "i.resourceId">-->
  238. <!-- </el-option>-->
  239. <!-- </el-select>-->
  240. <el-input v-model="modalData.resourceDesc" style="width: 221px"></el-input>
  241. </el-form-item>
  242. </el-form>
  243. <el-form :inline="true" label-position="top" :model="modalData" style="margin-left: 7px;margin-top: -5px;">
  244. <el-form-item v-if="this.modalData.specialTaskFlag === 'Y'" :model="modalData">
  245. <span style="cursor: pointer" slot="label" @click="queryPartList"><a herf="#">物料编码</a></span>
  246. <el-input v-model="modalData.partNo" style="width: 221px"></el-input>
  247. </el-form-item>
  248. <el-form-item v-else label="物料编码" prop="partNo" :rules="rules.partNoType">
  249. <el-input v-model="modalData.partNo" readonly style="width: 221px"></el-input>
  250. </el-form-item>
  251. <el-form-item label="物料名称">
  252. <el-input v-model="modalData.partDesc" readonly style="width: 221px"></el-input>
  253. </el-form-item>
  254. </el-form>
  255. <el-form :inline="true" label-position="top" :model="modalData" style="margin-left: 7px;margin-top: -5px;">
  256. <el-form-item label="物料类别">
  257. <el-input v-model="modalData.invdefinetype" readonly style="width: 221px"></el-input>
  258. </el-form-item>
  259. <el-form-item label="SKU">
  260. <el-input v-model="modalData.sku" readonly style="width: 221px"></el-input>
  261. </el-form-item>
  262. </el-form>
  263. <el-form :inline="true" label-position="top" :model="modalData" :rules="rules" style="margin-left: 7px;margin-top: -5px;">
  264. <el-form-item prop="templateId" :rules="rules.templateId">
  265. <span style="cursor: pointer" v-if="this.controlData.baseData === '控制'" slot="label" @click="queryTemplateList"><a>检验模板</a></span>
  266. <span v-else slot="label">检验模板</span>
  267. <el-input v-model="modalData.templateName" disabled style="width: 221px"></el-input>
  268. </el-form-item>
  269. <el-form-item label="送检数量:" prop="rollQty" :rules="rules.rollQtyType">
  270. <el-input v-model="modalData.rollQty" type="number" style="width: 103px"></el-input>
  271. </el-form-item>
  272. <el-form-item label="单位" prop="umId" :rules="rules.umIdType">
  273. <el-select v-model="modalData.umId" placeholder="请选择" style="width: 103px">
  274. <el-option
  275. v-for = "i in umList"
  276. :key = "i.umId"
  277. :label = "i.umName"
  278. :value = "i.umId">
  279. </el-option>
  280. </el-select>
  281. </el-form-item>
  282. </el-form>
  283. <el-form :inline="true" label-position="top" :model="modalData" style="margin-left: 7px;margin-top: -5px;">
  284. <el-form-item label="老卷号">
  285. <el-input v-model="modalData.batchRollNo" style="width: 221px"></el-input>
  286. </el-form-item>
  287. <el-form-item label="送检总数">
  288. <el-input v-model="modalData.sjzs" disabled style="width: 120px"></el-input>
  289. </el-form-item>
  290. <el-form-item label=" ">
  291. <input type="checkbox" id="specialTask" name="specialTask" v-model="checked" @click="changeSpecialTask"/> <label for="specialTask">无工单检验</label>
  292. </el-form-item>
  293. </el-form>
  294. <el-form :inline="true" label-position="top" :model="modalData" style="margin-left: 7px;margin-top: -5px;">
  295. <el-form-item label="特殊要求">
  296. <el-input type="textarea" v-model="modalData.specialRequirements" :rows="3" resize='none' show-word-limit style="width: 456px;height: 30px"></el-input>
  297. </el-form-item>
  298. </el-form>
  299. <el-footer style="height:40px;margin-top: 55px;text-align:center">
  300. <el-button type="primary" :loading="saveLoading" @click="saveData">保存</el-button>
  301. <el-button type="primary" @click="modalFlag = false">关闭</el-button>
  302. </el-footer>
  303. </el-dialog>
  304. <!-- 检验单详情页 -->
  305. <el-dialog title="检验明细清单" :close-on-click-modal="false" v-drag :visible.sync="detailInformationFlag" width="1200px">
  306. <el-form :inline="true" label-position="top" @keyup.enter.native = "getDataList">
  307. <el-form-item :label="'物料编码'">
  308. <el-input v-model="detailData.partNo" readonly style="width: 100px"></el-input>
  309. </el-form-item>
  310. <el-form-item :label="'物料类别'">
  311. <el-input v-model="detailData.invdefinetype" readonly style="width: 100px"></el-input>
  312. </el-form-item>
  313. <el-form-item :label="'PN'">
  314. <el-input v-model="detailData.cinvSourceCode" readonly style="width: 100px"></el-input>
  315. </el-form-item>
  316. <el-form-item :label="'SKU'">
  317. <el-input v-model="detailData.sku" readonly style="width: 100px"></el-input>
  318. </el-form-item>
  319. <el-form-item :label="'物料名称'">
  320. <el-input v-model="detailData.partDesc" readonly style="width: 300px"></el-input>
  321. </el-form-item>
  322. <el-form-item :label="'单位'">
  323. <el-input v-model="detailData.umName" readonly style="width: 60px"></el-input>
  324. </el-form-item>
  325. <el-form-item>
  326. <span v-if="detailData.submitFlag === 'Y'" slot="label">协同人员</span>
  327. <span v-else style="cursor: pointer" slot="label" @click="getOperatorList"><a>协同人员</a></span>
  328. <el-input v-model="detailData.operatorName" readonly style="width: 150px"></el-input>
  329. </el-form-item>
  330. <el-form-item>
  331. <span v-if="detailData.submitFlag === 'Y'" slot="label">责任人</span>
  332. <span v-else style="cursor: pointer" slot="label" @click="getResponsiblePersonList"><a>责任人</a></span>
  333. <el-input v-model="detailData.responsiblePersonName" readonly style="width: 150px"></el-input>
  334. </el-form-item>
  335. </el-form>
  336. <el-form :inline="true" label-position="top" @keyup.enter.native = "getDataList">
  337. <el-form-item :label="'送检数量'">
  338. <el-input-number :controls="false" :step="0" v-model="detailData.rollQty" style="width: 85px"></el-input-number>
  339. </el-form-item>
  340. <el-form-item :label="'抽样数量'">
  341. <el-input-number :controls="false" :step="0" v-model="detailData.samplingQty" style="width: 85px"></el-input-number>
  342. </el-form-item>
  343. <el-form-item :label="'合格数量'">
  344. <el-input-number :controls="false" :step="0" min="0" v-if="detailData.submitFlag === 'Y'" v-model="detailData.passQty" disabled style="width: 85px"></el-input-number>
  345. <el-input-number :controls="false" :step="0" min="0" v-else v-model="detailData.passQty" style="width: 85px"></el-input-number>
  346. </el-form-item>
  347. <el-form-item :label="'不合格数量'">
  348. <el-input-number :controls="false" :step="0" min="0" v-model="detailData.notPassQty" disabled style="width: 85px"></el-input-number>
  349. </el-form-item>
  350. <el-form-item :label="'不合格项目数量'">
  351. <el-input-number :controls="false" :step="0" v-if="detailData.submitFlag === 'Y'" v-model="detailData.unqualifiedQty" disabled style="width: 85px"></el-input-number>
  352. <el-input-number :controls="false" :step="0" v-else v-model="detailData.unqualifiedQty" style="width: 85px"></el-input-number>
  353. </el-form-item>
  354. <el-form-item :label="'批次合格数'">
  355. <el-input-number :controls="false" :step="0" min="0" v-model="detailData.batchQualifiedQty" disabled style="width: 85px"></el-input-number>
  356. </el-form-item>
  357. <el-form-item style="margin-top: 13px;margin-left: 405px">
  358. <el-button v-if="detailData.submitFlag !== 'Y'" :loading="loadFlag" @click="dataAcquisition">
  359. <svg t="1739002700745" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="38076" width="22" height="22"><path d="M922.000696 762.746435V465.363478l55.652174-0.111304v299.542261c0 131.695304-106.562783 239.571478-236.922435 239.571478H285.42887C155.158261 1004.365913 48.484174 896.623304 48.484174 764.794435V465.252174h59.258435v299.542261c0 101.843478 77.022609 179.712 177.775304 179.712H740.841739c100.61913 0 181.158957-79.916522 181.158957-181.76z" fill="#1D293F" p-id="38077"></path><path d="M290.148174 192.556522c20.301913-20.925217 30.47513-48.617739 30.47513-83.099826 0-72.548174-36.285217-108.833391-108.722087-108.833392H141.401043v223.365566h70.255305c32.055652-0.111304 58.167652-10.529391 78.491826-31.432348z m-105.227131-7.635479V39.446261h23.596522c19.70087 0 35.661913 6.166261 47.994435 18.632348 12.354783 12.466087 18.387478 29.740522 18.387478 52.001391 0 22.973217-5.921391 41.22713-17.652869 54.650435s-27.937391 20.190609-48.617739 20.190608H184.921043zM634.434783 595.366957h-84.057044V498.866087a102.511304 102.511304 0 0 0 74.262261-98.54887c0-56.230957-45.478957-102.310957-101.10887-102.310956-55.629913 0-101.086609 46.08-101.086608 102.310956 0 46.08 30.586435 85.25913 72.192 97.947826v96.990609h-81.252174c-16.829217-43.78713-50.688-99.283478-81.65287-143.070609a101.331478 101.331478 0 0 0 14.269218-52.001391c0-56.230957-45.946435-102.310957-102.177392-102.310956s-102.177391 46.08-102.177391 102.310956c0 56.230957 45.946435 102.310957 102.177391 102.310957 15.716174 0 30.72-3.628522 44.009739-10.017392 21.170087 34.326261 42.829913 74.351304 57.811479 102.778435h-73.906087l128.333913 130.493218 94.675478-108.966957v145.853217h-111.616l148.034783 148.858435 130.715826-148.858435h-111.504696v-129.402434l91.180522 92.516174 113.307826-130.248348h-53.203478c14.758957-28.42713 36.173913-68.452174 57.210434-102.800696 13.178435 6.41113 27.937391 10.039652 43.542261 10.039652 55.629913 0 101.086609-46.08 101.086609-102.310956 0-56.230957-45.456696-102.310957-101.086609-102.310957-55.652174 0-101.220174 46.08-101.220174 102.310957a102.4 102.4 0 0 0 14.135653 52.001391c-30.72 43.653565-64.200348 99.283478-80.896 142.937044z m-390.611479-148.48a46.614261 46.614261 0 0 1-46.436174-46.458435c0-25.510957 20.925217-46.436174 46.436174-46.436174s46.436174 20.925217 46.436174 46.436174-20.925217 46.436174-46.436174 46.436174z m279.819131 0c-25.266087 0-45.946435-20.925217-45.946435-46.458435 0-25.510957 20.702609-46.436174 45.968696-46.436174 25.266087 0 45.946435 20.925217 45.946434 46.436174s-20.680348 46.436174-45.946434 46.436174z m278.639304-93.005914c25.288348 0 45.968696 20.925217 45.968696 46.436174s-20.702609 46.436174-45.968696 46.436174c-25.266087 0-45.946435-20.925217-45.946435-46.436174s20.680348-46.436174 45.946435-46.436174zM395.130435 172.722087h74.128695l15.248696 51.155478h47.415652L458.707478 0.623304h-51.155478L332.8 223.98887h47.170783l15.11513-51.266783z m32.768-114.777044c1.825391-6.032696 3.027478-12.332522 3.517217-18.854956h1.202087c0.601043 8.102957 1.691826 14.514087 3.138783 19.456l23.218087 77.401043h-54.405566l23.329392-78.002087z m168.96 165.932522h43.631304V39.446261h58.189913V0.623304h-159.877565v38.956522h58.056348v184.297739z m169.894956-51.155478h74.128696l15.248696 51.155478h47.415652L830.330435 0.623304h-51.155478l-74.752 223.365566h47.193043l15.09287-51.266783z m32.768-114.777044c1.825391-6.032696 3.027478-12.332522 3.517218-18.854956h1.202087c0.601043 8.102957 1.691826 14.514087 3.161043 19.456l23.218087 77.401043h-54.427826l23.329391-78.002087z" fill="#FD9F01" p-id="38078"></path></svg>
  360. </el-button>
  361. <el-button @click="getFileContentData(detailData)">
  362. <svg t="1739002974630" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="59598" width="22" height="22"><path d="M807.3216 889.5488H221.184c-78.7456 0-142.848-64.1024-142.848-142.848V286.976c0-78.7456 64.1024-142.848 142.848-142.848h178.8416c20.7872 0 40.7552 8.8064 54.784 24.1664l77.568 85.0944c2.4064 2.6112 5.8368 4.1472 9.3696 4.1472h265.5232c78.7456 0 142.848 64.1024 142.848 142.848v346.2656c0.0512 78.7968-64.0512 142.8992-142.7968 142.8992zM221.184 205.568c-44.9024 0-81.408 36.5056-81.408 81.408v459.6736c0 44.9024 36.5056 81.408 81.408 81.408h586.1376c44.9024 0 81.408-36.5056 81.408-81.408V400.4352c0-44.9024-36.5056-81.408-81.408-81.408h-265.5232c-20.7872 0-40.7552-8.8064-54.784-24.1664L409.3952 209.7152c-2.4064-2.6112-5.8368-4.1472-9.3696-4.1472H221.184z" fill="#6FB1F9" p-id="59599"></path><path d="M466.0224 453.8368H249.0368c-16.9472 0-30.72-13.7728-30.72-30.72s13.7728-30.72 30.72-30.72h216.9856c16.9472 0 30.72 13.7728 30.72 30.72s-13.7728 30.72-30.72 30.72z" fill="#6FB1F9" p-id="59600"></path></svg>
  363. </el-button>
  364. <el-button @click="subDetailUpload">
  365. <svg t="1739002903501" class="icon" viewBox="0 0 1550 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="50418" width="22" height="22"><path d="M985.000229 727.917714c20.48 0 34.113829-13.663086 34.113828-34.143085 0-10.24-3.393829-17.056914-10.24-23.873829l-204.8-204.8c-6.816914-6.846171-13.633829-10.24-23.873828-10.24-10.24 0-17.086171 3.393829-23.903086 10.24l-204.8 204.8c-6.816914 6.816914-10.24 13.633829-10.24 23.873829 0 20.48 13.663086 34.143086 34.143086 34.143085 10.24 0 17.056914-3.423086 23.873828-10.24l146.783086-146.783085v395.966171c0 20.48 13.663086 34.113829 34.143086 34.113829s34.113829-13.633829 34.113828-34.113829V570.894629l146.783086 146.783085c6.816914 6.816914 13.663086 10.24 23.903086 10.24z m282.799542-353.045943c0-10.24 1.287314-17.086171 0-27.296914C1240.502857 128.117029 1043.0464 29.257143 858.199771 29.257143 701.205943 29.257143 564.662857 117.994057 496.405943 247.720229 469.079771 240.874057 441.782857 234.057143 414.485943 234.057143 281.365943 234.057143 175.542857 307.112229 175.542857 440.232229c0 17.056914 3.423086 34.113829 6.816914 51.2C97.514057 535.786057 29.257143 585.5232 29.257143 723.031771c0 170.656914 136.543086 277.942857 307.2 277.942858H585.142857c20.48 0 34.143086-13.633829 34.143086-34.113829S605.622857 932.717714 585.142857 932.717714h-248.685714c-133.12 0-238.943086-76.565943-238.943086-209.685943 0-82.797714 37.566171-131.657143 105.325714-166.765714l58.046172-20.48-13.663086-61.44c-3.423086-10.24-3.423086-23.873829-3.423086-34.113828 0-95.583086 75.103086-137.918171 170.686172-137.918172 20.48 0 37.536914 3.423086 58.016914 10.24l54.623086 20.48 27.296914-51.2c61.44-112.64 179.317029-198.100114 303.776914-184.32 184.846629 20.48 309.511314 71.68 341.343086 250.0608 1.199543 6.787657 0 10.24 0 17.056914v6.846172l-3.423086 47.776914 44.383086 20.48c110.094629 34.6112 222.354286 143.36 222.354286 249.183086 0 150.176914-122.88 243.799771-273.056914 243.799771h-214.571886c-20.48 0-34.113829 13.663086-34.113829 34.143086s13.633829 34.113829 34.113829 34.113829h214.571886c187.713829 0 341.313829-124.342857 341.313828-312.056686 0-144.530286-121.270857-269.663086-263.314286-314.046172z" fill="#6C5FFC" p-id="50419"></path></svg>
  366. </el-button>
  367. </el-form-item>
  368. </el-form>
  369. <el-form :inline="true" label-position="top">
  370. <el-form-item :label="'检验结论'">
  371. <el-select v-if="detailData.submitFlag === 'Y'" v-model="detailData.inspectionResult" disabled style="width: 100px" placeholder="请选择">
  372. <el-option label="合格" value="合格"></el-option>
  373. <el-option label="不合格" value="不合格"></el-option>
  374. </el-select>
  375. <el-select v-else v-model="detailData.inspectionResult" @change="resultChange" style="width: 100px" placeholder="请选择">
  376. <el-option label="合格" value="合格"></el-option>
  377. <el-option label="不合格" value="不合格"></el-option>
  378. </el-select>
  379. </el-form-item>
  380. <el-form-item :label="'质检备注'">
  381. <el-input v-if="detailData.submitFlag === 'Y'" v-model="detailData.inspectionRemark" disabled style="width: 293px"></el-input>
  382. <el-input v-else v-model="detailData.inspectionRemark" style="width: 293px"></el-input>
  383. </el-form-item>
  384. <el-form-item v-show="detailData.inspectionResult === '不合格'" style="margin-top: 5px">
  385. <el-form-item :label="'处置措施'">
  386. <el-select v-if="detailData.submitFlag === 'Y'" clearable v-model="detailData.disposalMeasures" disabled style="width: 100px">
  387. <el-option
  388. v-for = "i in disposalMeasuresOptions"
  389. :key = "i.id"
  390. :label = "i.disposalMeasures"
  391. :value = "i.disposalMeasures">
  392. </el-option>
  393. </el-select>
  394. <el-select v-else clearable v-model="detailData.disposalMeasures" style="width: 100px">
  395. <el-option
  396. v-for = "i in disposalMeasuresOptions"
  397. :key = "i.id"
  398. :label = "i.disposalMeasures"
  399. :value = "i.disposalMeasures">
  400. </el-option>
  401. </el-select>
  402. </el-form-item>
  403. <el-form-item :label="'处置说明'">
  404. <el-input v-if="detailData.submitFlag === 'Y'" v-model="detailData.disposalRemark" disabled style="width: 293px"></el-input>
  405. <el-input v-else v-model="detailData.disposalRemark" style="width: 293px"></el-input>
  406. </el-form-item>
  407. </el-form-item>
  408. </el-form>
  409. <!-- 展示列表 -->
  410. <div class="rq ">
  411. <el-table
  412. :height="500"
  413. :data="detailList"
  414. border
  415. style="width: 100%;">
  416. <el-table-column
  417. prop=""
  418. header-align="center"
  419. align="center"
  420. min-width="90"
  421. label="操作">
  422. <template slot-scope="scope">
  423. <el-button class="el-icon-picture" type="primary" @click="uploadImageModal(scope.row)"></el-button>
  424. <el-button style="margin-left: 2px" class="el-icon-s-platform" type="primary" :loading="loadFlag" @click="dataAcquisitionByItem(scope.row)"></el-button>
  425. </template>
  426. </el-table-column>
  427. <el-table-column
  428. v-for="(item,index) in detailColumnList" :key="index"
  429. :sortable="item.columnSortable"
  430. :prop="item.columnProp"
  431. :header-align="item.headerAlign"
  432. :show-overflow-tooltip="item.showOverflowTooltip"
  433. :align="item.align"
  434. :fixed="item.fixed==''?false:item.fixed"
  435. :min-width="item.columnWidth"
  436. :label="item.columnLabel">
  437. <template slot-scope="scope">
  438. <span v-if="!item.columnHidden"> {{ scope.row[item.columnProp] }}</span>
  439. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  440. </template>
  441. </el-table-column>
  442. <el-table-column
  443. prop=""
  444. header-align="center"
  445. align="right"
  446. min-width="80"
  447. label="实测值">
  448. <template slot-scope="scope">
  449. <el-input :ref="`textValue${scope.$index}`" v-if="scope.row.valueTypeDb === 'N'" v-model="scope.row.numberValue" @keyup.enter.native="focusNextInput(scope.$index, 'textValue')" type="number" @change="updateItemResult(scope.row)" style="height: 11px; width: 98%"></el-input>
  450. <el-input :ref="`textValue${scope.$index}`" v-else v-model="scope.row.textValue" @keyup.enter.native="focusNextInput(scope.$index, 'textValue')" style="height: 11px; width: 98%"></el-input>
  451. </template>
  452. </el-table-column>
  453. <el-table-column
  454. prop=""
  455. header-align="center"
  456. align="center"
  457. min-width="80"
  458. label="检验明细">
  459. <template slot-scope="scope">
  460. <el-button v-if="scope.row.subDetailRecordNum > 0" type="success" @click="subDetailModal(scope.row) ">点击输入</el-button>
  461. <el-button v-else type="primary" @click="subDetailModal(scope.row) ">点击输入</el-button>
  462. </template>
  463. </el-table-column>
  464. <el-table-column
  465. prop=""
  466. header-align="center"
  467. align="right"
  468. min-width="80"
  469. label="抽样数量">
  470. <template slot-scope="scope">
  471. <el-input-number :controls="false" :step="0" v-if="detailData.submitFlag === 'Y'" v-model="scope.row.samplingQty" disabled style="height: 11px; width: 98%"></el-input-number>
  472. <el-input-number :controls="false" :step="0" v-else :ref="`samplingQty${scope.$index}`" v-model="scope.row.samplingQty" @keyup.enter.native="focusNextInput(scope.$index, 'samplingQty')" style="height: 11px; width: 98%"></el-input-number>
  473. </template>
  474. </el-table-column>
  475. <el-table-column
  476. prop=""
  477. header-align="center"
  478. align="right"
  479. min-width="80"
  480. label="不合格数量">
  481. <template slot-scope="scope">
  482. <el-input-number :controls="false" :step="0" v-if="detailData.submitFlag === 'Y'" v-model="scope.row.unqualifiedQuantity" disabled style="height: 11px; width: 98%"></el-input-number>
  483. <el-input-number :controls="false" :step="0" v-else :ref="`unqualifiedQuantity${scope.$index}`" v-model="scope.row.unqualifiedQuantity" @keyup.enter.native="focusNextInput(scope.$index, 'unqualifiedQuantity')" style="height: 11px; width: 98%"></el-input-number>
  484. </template>
  485. </el-table-column>
  486. <el-table-column
  487. prop=""
  488. header-align="center"
  489. align="right"
  490. min-width="90"
  491. label="项目检验结论">
  492. <template slot-scope="scope">
  493. <el-select :class="{redElSelect:scope.row.itemResult === 'N', greenElSelect:scope.row.itemResult === 'Y'}" v-if="detailData.submitFlag === 'Y'" v-model="scope.row.itemResult" disabled style="height: 11px" >
  494. <el-option label="合格" value="Y" style="color: green"></el-option>
  495. <el-option label="不合格" value="N" style="color: red"></el-option>
  496. </el-select>
  497. <el-select :class="{redElSelect:scope.row.itemResult === 'N', greenElSelect:scope.row.itemResult === 'Y'}" v-else v-model="scope.row.itemResult" style="height: 11px" placeholder="合格">
  498. <el-option label="合格" value="Y" style="color: green"></el-option>
  499. <el-option label="不合格" value="N" style="color: red"></el-option>
  500. </el-select>
  501. </template>
  502. </el-table-column>
  503. </el-table>
  504. </div>
  505. <el-footer style="height:40px;margin-top: 20px;text-align:center">
  506. <el-button v-if="detailData.state === '待检验'" type="primary" :loading="transferLoadFlag" @click="Transfer('1')">应用</el-button>
  507. <el-button v-if="detailData.state === '待检验' || detailData.state === '待审核'" type="primary" :loading="transferLoadFlag" @click="Transfer('2')">保存</el-button>
  508. <el-button type="primary" @click="detailInformationFlag=false">关闭</el-button>
  509. </el-footer>
  510. </el-dialog>
  511. <!-- 派工单号 -->
  512. <el-dialog title="派工单号" @close="closeDialog" :close-on-click-modal="false" v-drag :visible.sync="seqDetailFlag" width="952px" height="273px">
  513. <el-form :inline="true" label-position="top" :model="seqDetailData" style="margin-left: 7px;margin-top: -5px;">
  514. <el-form-item label="工单号">
  515. <el-input v-model="seqDetailData.orderNo" clearable style="width: 150px"></el-input>
  516. </el-form-item>
  517. <el-form-item label="派工单号">
  518. <el-input v-model="seqDetailData.seqNo" clearable style="width: 150px"></el-input>
  519. </el-form-item>
  520. <el-form-item label="SKU">
  521. <el-input v-model="seqDetailData.sku" clearable style="width: 150px"></el-input>
  522. </el-form-item>
  523. <el-form-item label="状态">
  524. <el-select v-model="seqDetailData.status" style="width: 100px" placeholder="请选择">
  525. <el-option label="下达" value="下达"></el-option>
  526. <el-option label="关闭" value="关闭"></el-option>
  527. </el-select>
  528. </el-form-item>
  529. </el-form>
  530. <el-form :inline="true" label-position="top" :model="seqDetailData" style="margin-left: 7px;margin-top: -5px;">
  531. <el-form-item label="物料编码">
  532. <el-input v-model="seqDetailData.partNo" clearable style="width: 150px"></el-input>
  533. </el-form-item>
  534. <el-form-item label="物料名称">
  535. <el-input v-model="seqDetailData.partDesc" clearable style="width: 315px"></el-input>
  536. </el-form-item>
  537. <el-form-item label="工序">
  538. <el-input v-model="seqDetailData.operationDesc" clearable style="width: 150px"></el-input>
  539. </el-form-item>
  540. <el-form-item>
  541. <el-button type="primary" @click="searchSeqInfo" style="margin-top: 24px">查询</el-button>
  542. </el-form-item>
  543. </el-form>
  544. <el-table
  545. :height="400"
  546. :data="seqInfoList"
  547. @row-dblclick="getRowData1"
  548. border
  549. style="width: 100%;">
  550. <el-table-column
  551. v-for="(item,index) in seqDetailColumnList" :key="index"
  552. :sortable="item.columnSortable"
  553. :prop="item.columnProp"
  554. :header-align="item.headerAlign"
  555. :show-overflow-tooltip="item.showOverflowTooltip"
  556. :align="item.align"
  557. :fixed="item.fixed==''?false:item.fixed"
  558. :min-width="item.columnWidth"
  559. :label="item.columnLabel">
  560. </el-table-column>
  561. </el-table>
  562. <el-footer style="height:40px;margin-top: 10px;text-align:center">
  563. <el-button type="primary" @click="seqDetailFlag = false">关闭</el-button>
  564. </el-footer>
  565. </el-dialog>
  566. <!-- 子明细信息 -->
  567. <el-dialog title="子明细信息" :close-on-click-modal="false" v-drag :visible.sync="subDetailFlag" width="1102px">
  568. <el-button type="success" icon="el-icon-plus" size="mini" @click="handleAddBtn(subDetailData)">添加</el-button>
  569. <el-button type="danger" icon="el-icon-delete" size="mini" @click="handleDeleteBtn(subDetailData)">删除</el-button>
  570. <el-button type="primary" icon="el-icon-more" size="mini" @click="batchHandleAdd(subDetailData)">批量新增</el-button>
  571. <div class="rq ">
  572. <el-table
  573. :height="400"
  574. :data="templateTableData"
  575. border
  576. v-loading="subDetailLoading"
  577. element-loading-text="拼命加载中"
  578. :row-class-name="rowClassName"
  579. @selection-change="handleDetailSelectionChange"
  580. style="width: 100%;">
  581. <el-table-column type="selection" align="center" width="40"></el-table-column>
  582. <el-table-column label="序号" align="center" prop="num" width="50"></el-table-column>
  583. <el-table-column prop="samplingLocation" header-align="center" align="center" :required="true" label="抽样位置A" width="120">
  584. <template slot-scope="{row}">
  585. <el-input v-if="templateTableData[row.xh-1].isSubmit==='Y'" v-model="templateTableData[row.xh-1].samplingLocation" readonly placeholder="请输入抽样位置A"></el-input>
  586. <el-input v-else :ref="`${row.xh-1}` + `a`" v-model="templateTableData[row.xh-1].samplingLocation" @keyup.enter.native="nextFocus1(row.xh-1)" placeholder="请输入抽样位置A"></el-input>
  587. </template>
  588. </el-table-column>
  589. <el-table-column prop="samplingLocationB" header-align="center" align="center" :required="true" label="抽样位置B" width="120">
  590. <template slot-scope="{row}">
  591. <el-input v-if="templateTableData[row.xh-1].isSubmit==='Y'" v-model="templateTableData[row.xh-1].samplingLocationB" readonly placeholder="请输入抽样位置B"></el-input>
  592. <el-input v-else :ref="`${row.xh-1}` + `b`" v-model="templateTableData[row.xh-1].samplingLocationB" @keyup.enter.native="nextFocus2(row.xh-1)" placeholder="请输入抽样位置B"></el-input>
  593. </template>
  594. </el-table-column>
  595. <el-table-column prop="subDetailValue" header-align="center" align="center" :required="true" label="实测值A" width="150">
  596. <template slot-scope="{row}">
  597. <el-input v-if="templateTableData[row.xh-1].isSubmit==='Y'" v-model="templateTableData[row.xh-1].subDetailValue" readonly placeholder="请输入实测值A"></el-input>
  598. <el-input v-else :ref="`${row.xh-1}` + `c`" v-model="templateTableData[row.xh-1].subDetailValue" @keyup.enter.native="nextFocus3(row.xh-1)" placeholder="请输入实测值A"></el-input>
  599. </template>
  600. </el-table-column>
  601. <el-table-column prop="subDetailValueB" header-align="center" align="center" :required="true" label="实测值B" width="150">
  602. <template slot-scope="{row}">
  603. <el-input v-if="templateTableData[row.xh-1].isSubmit === 'Y'" v-model="templateTableData[row.xh-1].subDetailValueB" readonly placeholder="请输入实测值B"></el-input>
  604. <el-input v-else :ref="`${row.xh-1}` + `d`" v-model="templateTableData[row.xh-1].subDetailValueB" @keyup.enter.native="nextFocus4(row.xh-1)" placeholder="请输入实测值B"></el-input>
  605. </template>
  606. </el-table-column>
  607. <el-table-column prop="subDetailValueC" header-align="center" align="center" :required="true" label="实测值C" width="150">
  608. <template slot-scope="{row}">
  609. <el-input v-if="templateTableData[row.xh-1].isSubmit === 'Y'" v-model="templateTableData[row.xh-1].subDetailValueC" readonly placeholder="请输入实测值C"></el-input>
  610. <el-input v-else :ref="`${row.xh-1}` + `e`" v-model="templateTableData[row.xh-1].subDetailValueC" @keyup.enter.native="nextFocus5(row.xh-1)" placeholder="请输入实测值C"></el-input>
  611. </template>
  612. </el-table-column>
  613. <el-table-column prop="subDetailValueD" header-align="center" align="center" :required="true" label="实测值D" width="150">
  614. <template slot-scope="{row}">
  615. <el-input v-if="templateTableData[row.xh-1].isSubmit === 'Y'" v-model="templateTableData[row.xh-1].subDetailValueD" readonly placeholder="请输入实测值D"></el-input>
  616. <el-input v-else :ref="`${row.xh-1}` + `f`" v-model="templateTableData[row.xh-1].subDetailValueD" @keyup.enter.native="nextFocus6(row.xh-1)" placeholder="请输入实测值D"></el-input>
  617. </template>
  618. </el-table-column>
  619. <el-table-column prop="subDetailValueE" header-align="center" align="center" :required="true" label="实测值E" width="150">
  620. <template slot-scope="{row}">
  621. <el-input v-if="templateTableData[row.xh-1].isSubmit === 'Y'" v-model="templateTableData[row.xh-1].subDetailValueE" readonly placeholder="请输入实测值E"></el-input>
  622. <el-input v-else :ref="`${row.xh-1}` + `g`" v-model="templateTableData[row.xh-1].subDetailValueE" @keyup.enter.native="nextFocus7(row.xh-1)" placeholder="请输入实测值E"></el-input>
  623. </template>
  624. </el-table-column>
  625. </el-table>
  626. <!-- 分页-->
  627. <el-pagination
  628. @size-change="sizeChangeHandle2"
  629. @current-change="currentChangeHandle2"
  630. :current-page="pageIndex2"
  631. :page-sizes="[20, 50, 100, 200, 500]"
  632. :page-size="pageSize2"
  633. :total="tableData.length"
  634. layout="total, sizes, prev, pager, next, jumper">
  635. </el-pagination>
  636. </div>
  637. <el-footer style="height:40px;margin-top: 10px;text-align:center">
  638. <el-button v-if="detailData.submitFlag !== 'Y'" type="primary" :loading="subDetailVisiable" @click="saveSubDetailResult">保存</el-button>
  639. <el-button type="primary" @click="subDetailFlag = false">关闭</el-button>
  640. </el-footer>
  641. </el-dialog>
  642. <!-- 批量新增子明细操作-->
  643. <el-dialog title="批量新增" :close-on-click-modal="false" v-drag :visible.sync="batchHandleAddModalFlag" width="510px">
  644. <el-form :inline="true" label-position="top">
  645. <el-form-item :label="'默认抽样位置A'">
  646. <el-input v-model="batchAddData.samplingLocation" style="width: 150px"></el-input>
  647. </el-form-item>
  648. <el-form-item :label="'默认抽样位置B'">
  649. <el-input v-model="batchAddData.samplingLocationB" style="width: 150px"></el-input>
  650. </el-form-item>
  651. <el-form-item :label="'抽样数量'">
  652. <el-input type="number" v-model="batchAddData.samplingNumber" style="width: 150px"></el-input>
  653. </el-form-item>
  654. </el-form>
  655. <el-footer style="height:40px;margin-top: 10px;text-align:center">
  656. <el-button type="primary" @click="batchHandleAddModal">保存</el-button>
  657. <el-button type="primary" @click="batchHandleAddModalFlag=false">关闭</el-button>
  658. </el-footer>
  659. </el-dialog>
  660. <!-- 检验模板 -->
  661. <el-dialog title="检验模板清单" :close-on-click-modal="false" v-drag :visible.sync="templateModelFlag" width="520px">
  662. <div class="rq">
  663. <el-form :inline="true" label-position="top" :model="templateData">
  664. <el-form-item :label="'模板编码'">
  665. <el-input v-model="templateData.templateId" clearable style="width: 120px"></el-input>
  666. </el-form-item>
  667. <el-form-item :label="'模板名称'">
  668. <el-input v-model="templateData.templateName" clearable style="width: 120px"></el-input>
  669. </el-form-item>
  670. <!-- <el-form-item :label="'检验类型'">-->
  671. <!-- <el-select v-model="templateData.inspectionTypeNo" style="width: 100px">-->
  672. <!-- <el-option-->
  673. <!-- v-for = "i in typeOptions"-->
  674. <!-- :key = "i.inspectionTypeNo"-->
  675. <!-- :label = "i.inspectionTypeName"-->
  676. <!-- :value = "i.inspectionTypeNo">-->
  677. <!-- </el-option>-->
  678. <!-- </el-select>-->
  679. <!-- </el-form-item>-->
  680. <el-form-item :label="' '">
  681. <el-button type="primary" @click="queryTemplateList">查询</el-button>
  682. </el-form-item>
  683. </el-form>
  684. <el-table
  685. :height="300"
  686. :data="templateList"
  687. @row-dblclick="getRowData"
  688. border
  689. style="width: 100%;">
  690. <el-table-column
  691. v-for="(item,index) in templateDetailList" :key="index"
  692. :sortable="item.columnSortable"
  693. :prop="item.columnProp"
  694. :header-align="item.headerAlign"
  695. :show-overflow-tooltip="item.showOverflowTooltip"
  696. :align="item.align"
  697. :fixed="item.fixed==''?false:item.fixed"
  698. :min-width="item.columnWidth"
  699. :label="item.columnLabel">
  700. <template slot-scope="scope">
  701. <span v-if="!item.columnHidden">{{scope.row[item.columnProp]}}</span>
  702. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  703. </template>
  704. </el-table-column>
  705. </el-table>
  706. </div>
  707. <el-footer style="height:40px;margin-top: 20px;text-align:center">
  708. <el-button type="primary" @click="templateModelFlag=false">关闭</el-button>
  709. </el-footer>
  710. </el-dialog>
  711. <!-- 物料 -->
  712. <el-dialog title="物料清单" :close-on-click-modal="false" v-drag :visible.sync="partModelFlag" width="520px">
  713. <div class="rq">
  714. <el-form :inline="true" label-position="top" :model="partData">
  715. <el-form-item :label="'物料编码'">
  716. <el-input v-model="partData.partNo" clearable style="width: 115px"></el-input>
  717. </el-form-item>
  718. <el-form-item :label="'物料名称'">
  719. <el-input v-model="partData.partDesc" clearable style="width: 115px"></el-input>
  720. </el-form-item>
  721. <el-form-item :label="'SKU'">
  722. <el-input v-model="partData.sku" clearable style="width: 79px"></el-input>
  723. </el-form-item>
  724. <el-form-item :label="'PN'">
  725. <el-input v-model="partData.cinvSourceCode" clearable style="width: 79px"></el-input>
  726. </el-form-item>
  727. <el-form-item :label="' '">
  728. <el-button type="primary" @click="queryPartList">查询</el-button>
  729. </el-form-item>
  730. </el-form>
  731. <el-table
  732. :height="300"
  733. :data="partList"
  734. @row-dblclick="getRowData2"
  735. border
  736. style="width: 100%;">
  737. <el-table-column
  738. v-for="(item,index) in partDetailList" :key="index"
  739. :sortable="item.columnSortable"
  740. :prop="item.columnProp"
  741. :header-align="item.headerAlign"
  742. :show-overflow-tooltip="item.showOverflowTooltip"
  743. :align="item.align"
  744. :fixed="item.fixed==''?false:item.fixed"
  745. :min-width="item.columnWidth"
  746. :label="item.columnLabel">
  747. <template slot-scope="scope">
  748. <span v-if="!item.columnHidden">{{scope.row[item.columnProp]}}</span>
  749. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  750. </template>
  751. </el-table-column>
  752. </el-table>
  753. </div>
  754. <el-footer style="height:40px;margin-top: 20px;text-align:center">
  755. <el-button type="primary" @click="partModelFlag=false">关闭</el-button>
  756. </el-footer>
  757. </el-dialog>
  758. <!-- 文件清单 -->
  759. <el-dialog title="文件清单" :close-on-click-modal="false" v-drag :visible.sync="fileFlag" width="800px">
  760. <el-form :inline="true" label-position="top">
  761. <el-form-item v-if="detailInformationFlag">
  762. <el-button type="primary" @click="addUploadFileModal">上传文件</el-button>
  763. </el-form-item>
  764. </el-form>
  765. <iqc-file-table :columns="fileColumnList" :data-list="fileContentList" :query-loading="fileLoading"></iqc-file-table>
  766. <el-footer style="height:35px;margin-top: 10px;text-align:center">
  767. <el-button type="primary" @click="fileFlag = false">关闭</el-button>
  768. </el-footer>
  769. </el-dialog>
  770. <!-- 机修人员清单 -->
  771. <el-dialog title="人员清单" :close-on-click-modal="false" v-drag :visible.sync="operatorModelFlag" width="820px">
  772. <div class="rq">
  773. <el-form :inline="true" label-position="top" :model="operatorData">
  774. <el-form-item v-if="operatorData.flag !== '2'" :label="'所属角色'">
  775. <el-select v-model="operatorData.roleId" placeholder="请选择" style="width: 120px">
  776. <el-option
  777. v-for = "i in roleList"
  778. :key = "i.roleId"
  779. :label = "i.roleName"
  780. :value = "i.roleId">
  781. </el-option>
  782. </el-select>
  783. </el-form-item>
  784. <el-form-item :label="'用户编码'">
  785. <el-input v-model="operatorData.adminID" clearable style="width: 120px"></el-input>
  786. </el-form-item>
  787. <el-form-item :label="'用户姓名'">
  788. <el-input v-model="operatorData.adminName" clearable style="width: 120px"></el-input>
  789. </el-form-item>
  790. <el-form-item :label="' '">
  791. <el-button type="primary" @click="getOperatorList2">查询</el-button>
  792. </el-form-item>
  793. </el-form>
  794. <el-table
  795. :height="300"
  796. :data="operatorList"
  797. ref="operatorTable"
  798. @row-click="operatorClickRow"
  799. @selection-change="selectionChangeHandle2"
  800. border
  801. style="width: 100%;">
  802. <el-table-column
  803. type="selection"
  804. header-align="center"
  805. align="center"
  806. width="50">
  807. </el-table-column>
  808. <el-table-column
  809. v-for="(item,index) in operatorDetailList" :key="index"
  810. :sortable="item.columnSortable"
  811. :prop="item.columnProp"
  812. :header-align="item.headerAlign"
  813. :show-overflow-tooltip="item.showOverflowTooltip"
  814. :align="item.align"
  815. :fixed="item.fixed==''?false:item.fixed"
  816. :min-width="item.columnWidth"
  817. :label="item.columnLabel">
  818. <template slot-scope="scope">
  819. <span v-if="!item.columnHidden">{{scope.row[item.columnProp]}}</span>
  820. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  821. </template>
  822. </el-table-column>
  823. </el-table>
  824. </div>
  825. <el-footer style="height:40px;margin-top: 20px;text-align:center">
  826. <el-button type="primary" @click="confirmOperator">确认</el-button>
  827. <el-button type="primary" @click="operatorModelFlag = false">关闭</el-button>
  828. </el-footer>
  829. </el-dialog>
  830. <!-- 配置项目设备 -->
  831. <el-dialog title="检验项目" :close-on-click-modal="false" v-drag :visible.sync="ItemObjectModelFlag" width="666px">
  832. <div class="rq">
  833. <el-table
  834. :height="350"
  835. :data="itemObjectList"
  836. border
  837. style="width: 100%">
  838. <el-table-column
  839. v-for="(item,index) in itemObjectColumnList" :key="index"
  840. :sortable="item.columnSortable"
  841. :prop="item.columnProp"
  842. :header-align="item.headerAlign"
  843. :show-overflow-tooltip="item.showOverflowTooltip"
  844. :align="item.align"
  845. :fixed="item.fixed===''?false:item.fixed"
  846. :min-width="item.columnWidth"
  847. :label="item.columnLabel">
  848. <template slot-scope="scope">
  849. <span v-if="!item.columnHidden">{{scope.row[item.columnProp]}}</span>
  850. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  851. </template>
  852. </el-table-column>
  853. <el-table-column
  854. header-align="center"
  855. align="center"
  856. min-width="100"
  857. label="设备">
  858. <template slot-scope="scope">
  859. <el-select v-model="scope.row.equipmentNo" style="height: 11px" placeholder="请选择设备">
  860. <el-option
  861. v-for = "i in scope.row.objectList"
  862. :key = "i.objectID"
  863. :label = "i.objectDesc"
  864. :value = "i.objectID">
  865. </el-option>
  866. </el-select>
  867. </template>
  868. </el-table-column>
  869. </el-table>
  870. </div>
  871. <el-footer style="height:35px;margin-top: 15px;text-align:center">
  872. <el-button type="primary" @click="actionModal2">保存</el-button>
  873. <el-button type="primary" @click="ItemObjectModelFlag=false">关闭</el-button>
  874. </el-footer>
  875. </el-dialog>
  876. <!-- chooseList模态框 -->
  877. <Chooselist ref="baseList" @getBaseData="getBaseData"></Chooselist>
  878. <!-- 上传文件的modal -->
  879. <qcFAIUploadFile ref="qcFAIUploadFile" @refreshPageTables="()=>{this.getFileContentData(this.detailData)}" v-drag></qcFAIUploadFile>
  880. <!-- 上传文件的modal -->
  881. <comQcItemImageUploadFile ref="comQcItemImageUploadFile" @refreshPageTables2="getInspectionFormData" v-drag></comQcItemImageUploadFile>
  882. <!-- 子明细导入 -->
  883. <subDetailUpload @changeEvent="changeMyString" ref="subDetailUpload" @refreshPageTables="getInspectionFormData" v-drag></subDetailUpload>
  884. <!-- 打印标签 -->
  885. <qr-code ref="qrCode"></qr-code>
  886. </div>
  887. </template>
  888. <script>
  889. import {
  890. qcFAIInspectionSearch, // 查询FAI的检验记录
  891. faiDetailSearch, // 查询FAI的检验明细
  892. inspectorSearch, // 查询检验员
  893. faiRecordDelete, // 删除检验记录
  894. saveFAIDetailedRecord, // 新增明细信息
  895. saveFAISubmitResult, // 审核
  896. saveFAISubDetailed, // 新增子明细信息
  897. selectFAISubDetailedRecord, // 子明细记录信息查询
  898. checkFAIIsSubmit, // 检查是否已提交
  899. getResourceList, // 查询机台列表
  900. getOperationList, // 查询工序列表
  901. getPartList, // 查询物料列表
  902. saveFAIInspection, // 新增FAI检验
  903. queryController, // 检查动控
  904. queryTemplateList, // 获取检验模板列表
  905. getSpecialOperationList, // 获取特殊工序列表
  906. inspectionTypeSearch, // 搜索所有检验类型
  907. disposalMeasuresSearch, // 获取处置措施列表
  908. getRollNo, // 模糊查询标签号
  909. rollNoEnter, // 标签号回车事件
  910. queryPartList, // 查询物料集合
  911. umSearch, // 查询单位列表
  912. getSiteAndBuByUserName,
  913. getSiteAndBuByUserName2,
  914. searchSeqInfo, // 派工单号查询
  915. actionFAIInspection, // 开始检验
  916. dataAcquisition, // 数据采集
  917. getResponsibleOperatorList, // 获取责任人列表
  918. getFAIItemObjectList, // 查询项目设备
  919. dataAcquisitionByItem, // 根据项目数据采集
  920. cancelApproval2, // 取消审核
  921. searchPartAttributeDetails, // 查询物料属性模板
  922. } from "@/api/qc/qc.js"
  923. import {getTableDefaultListLanguage, getTableUserListLanguage} from "@/api/table.js"
  924. import Chooselist from '@/views/modules/common/Chooselist_eam'
  925. import {getInspectionFile} from '@/api/eam/eam_object_list.js'
  926. import {
  927. deleteObjectFile,
  928. getUserRoleList, // 获取用户角色列表
  929. getOperatorList
  930. } from '@/api/eam/eam.js'
  931. import {userFavoriteList, saveUserFavorite, removeUserFavorite} from '@/api/userFavorite.js'
  932. import {qcPrint} from '@/api/qc/qcPrint.js'
  933. import qcFAIUploadFile from "./qc_FAI_upload_file"
  934. import comQcItemImageUploadFile from "./com_qc_itemImage_upload_file"
  935. import subDetailUpload from "./sub_detail_upload"
  936. import QrCode from "../common/QrCode.vue";
  937. import IqcFileTable from "./IQCFileTable.vue";
  938. /*上传文件的組件*/
  939. export default {
  940. components: {
  941. IqcFileTable,
  942. QrCode,
  943. Chooselist,
  944. qcFAIUploadFile,
  945. comQcItemImageUploadFile,
  946. subDetailUpload
  947. },
  948. computed: {
  949. templateTableData () {
  950. let start = (this.pageIndex2 - 1) * this.pageSize2
  951. let end = start + this.pageSize2
  952. if (end > this.tableData.length){
  953. end = this.tableData.length
  954. }
  955. return this.tableData.slice(start,end)
  956. }
  957. },
  958. watch: {
  959. detailData: {
  960. deep: true,
  961. handler: function (newV, oldV) {
  962. this.detailData.notPassQty = this.detailData.samplingQty - this.detailData.passQty
  963. if (this.detailData.inspectionResult === '不合格') {
  964. if (this.detailData.disposalMeasures === '让步接收' || this.detailData.disposalMeasures === '') {
  965. this.detailData.batchQualifiedQty = this.detailData.rollQty
  966. } else if (this.detailData.disposalMeasures === '挑选使用') {
  967. this.detailData.batchQualifiedQty = this.detailData.rollQty - this.detailData.notPassQty
  968. } else {
  969. this.detailData.batchQualifiedQty = 0
  970. }
  971. } else {
  972. this.detailData.batchQualifiedQty = this.detailData.rollQty
  973. }
  974. }
  975. },
  976. detailList: {
  977. deep: true,
  978. handler: function (newV, oldV) {
  979. let num2 = 0
  980. for (let i = 0; i < this.detailList.length; i++) {
  981. if (this.detailList[i].itemResult === 'N') {
  982. num2++
  983. }
  984. }
  985. this.detailData.unqualifiedQty = num2
  986. }
  987. },
  988. },
  989. data () {
  990. return {
  991. loadFlag: false,
  992. transferLoadFlag: false,
  993. inspectionNo: '',
  994. fileFlag: false,
  995. fileContentList: [],
  996. // 是否收藏
  997. favorite: false,
  998. // 导出 start
  999. exportData: [],
  1000. exportName: "FAI检验录入" + this.dayjs().format('YYYYMMDDHHmmss'),
  1001. exportHeader: ["FAI检验录入"],
  1002. exportFooter: [],
  1003. exportList: [],
  1004. // 导出 end
  1005. checkCompletedData: {
  1006. inspectionNo: ''
  1007. },
  1008. submitData: {
  1009. site: this.$store.state.user.site,
  1010. inspectionNo: '',
  1011. submit_flag: '',
  1012. inspectionResult: '',
  1013. submitList: [],
  1014. updateBy: this.$store.state.user.name,
  1015. type: 'fai'
  1016. },
  1017. tagNo: '',
  1018. searchData: {
  1019. site: '',
  1020. userName: this.$store.state.user.name,
  1021. inspectionNo: '',
  1022. state: '',
  1023. inspectionResult: '',
  1024. orderNo: '',
  1025. operationDesc: '',
  1026. buNo: '',
  1027. startDate: '',
  1028. endDate: '',
  1029. startDate2: '',
  1030. endDate2: '',
  1031. partNo: '',
  1032. partDesc: '',
  1033. cinvSourceCode: '',
  1034. sku: '',
  1035. disposalMeasures: '',
  1036. page: 1,
  1037. limit: 10,
  1038. seqNo: '',
  1039. states: ['未开始','待检验'],
  1040. },
  1041. pageIndex: 1,
  1042. pageSize: 20,
  1043. totalPage: 0,
  1044. pageIndex2: 1,
  1045. pageSize2: 20,
  1046. totalPage2: 0,
  1047. height: 200,
  1048. dataList: [],
  1049. dataListSelections: [],
  1050. modalData: {
  1051. flag: '',
  1052. site: '',
  1053. bu: '',
  1054. inspectionNo: '',
  1055. partNo: '',
  1056. partDesc: '',
  1057. inspectionTypeNo: '106',
  1058. inspectionTypeName: '',
  1059. inspectorNo: '',
  1060. inspectorName: '',
  1061. submit_flag: '',
  1062. seqNo: '',
  1063. batchRollNo: '',
  1064. invdefinetype: '',
  1065. orderNo: '',
  1066. sku: '',
  1067. cinvSourceCode: '',
  1068. qtyrequired: '',
  1069. lotsize:'',
  1070. operationDesc:'',
  1071. specialRequirements: '',
  1072. templateId: '',
  1073. templateName: '',
  1074. specialTaskFlag: '',
  1075. workCenterNo: '',
  1076. rollNo: '',
  1077. umId: '',
  1078. umName: '',
  1079. sjzs: ''
  1080. },
  1081. // 展示列集
  1082. columnList1: [
  1083. {
  1084. userId: this.$store.state.user.name,
  1085. functionId: 301007,
  1086. serialNumber: '301007Table1BuDesc',
  1087. tableId: "301007Table1",
  1088. tableName: "FAI检验记录表",
  1089. columnProp: 'buDesc',
  1090. headerAlign: "center",
  1091. align: "center",
  1092. columnLabel: 'BU',
  1093. columnHidden: false,
  1094. columnImage: false,
  1095. columnSortable: false,
  1096. sortLv: 0,
  1097. status: true,
  1098. fixed: '',
  1099. columnWidth: 100,
  1100. },
  1101. {
  1102. userId: this.$store.state.user.name,
  1103. functionId: 301007,
  1104. serialNumber: '301007Table1InspectionNo',
  1105. tableId: "301007Table1",
  1106. tableName: "FAI检验记录表",
  1107. columnProp: 'inspectionNo',
  1108. headerAlign: "center",
  1109. align: "center",
  1110. columnLabel: '检验单号',
  1111. columnHidden: false,
  1112. columnImage: false,
  1113. columnSortable: false,
  1114. sortLv: 0,
  1115. status: true,
  1116. fixed: '',
  1117. columnWidth: 120,
  1118. },
  1119. {
  1120. userId: this.$store.state.user.name,
  1121. functionId: 301007,
  1122. serialNumber: '301007Table1BatchRollNo',
  1123. tableId: "301007Table1",
  1124. tableName: "FQC检验记录表",
  1125. columnProp: 'batchRollNo',
  1126. headerAlign: "center",
  1127. align: "center",
  1128. columnLabel: '老卷号',
  1129. columnHidden: false,
  1130. columnImage: false,
  1131. columnSortable: false,
  1132. sortLv: 0,
  1133. status: true,
  1134. fixed: '',
  1135. columnWidth: 150,
  1136. },
  1137. {
  1138. userId: this.$store.state.user.name,
  1139. functionId: 301007,
  1140. serialNumber: '301007Table1RollNo',
  1141. tableId: "301007Table1",
  1142. tableName: "FQC检验记录表",
  1143. columnProp: 'rollNo',
  1144. headerAlign: "center",
  1145. align: "center",
  1146. columnLabel: '标签条码',
  1147. columnHidden: false,
  1148. columnImage: false,
  1149. columnSortable: false,
  1150. sortLv: 0,
  1151. status: true,
  1152. fixed: '',
  1153. columnWidth: 150,
  1154. },
  1155. {
  1156. userId: this.$store.state.user.name,
  1157. functionId: 301007,
  1158. serialNumber: '301007Table1InspectionResult',
  1159. tableId: "301007Table1",
  1160. tableName: "FQC检验记录表",
  1161. columnProp: 'inspectionResult',
  1162. headerAlign: "center",
  1163. align: "center",
  1164. columnLabel: '检验结论',
  1165. columnHidden: false,
  1166. columnImage: false,
  1167. columnSortable: false,
  1168. sortLv: 0,
  1169. status: true,
  1170. fixed: '',
  1171. columnWidth: 100,
  1172. },
  1173. {
  1174. userId: this.$store.state.user.name,
  1175. functionId: 301007,
  1176. serialNumber: '301007Table1DisposalMeasures',
  1177. tableId: "301007Table1",
  1178. tableName: "FQC检验记录表",
  1179. columnProp: 'disposalMeasures',
  1180. headerAlign: "center",
  1181. align: "center",
  1182. columnLabel: '处置措施',
  1183. columnHidden: false,
  1184. columnImage: false,
  1185. columnSortable: false,
  1186. sortLv: 0,
  1187. status: true,
  1188. fixed: '',
  1189. columnWidth: 100,
  1190. },
  1191. {
  1192. userId: this.$store.state.user.name,
  1193. functionId: 301007,
  1194. serialNumber: '301007Table1TaskDate',
  1195. tableId: "301007Table1",
  1196. tableName: "FQC检验记录表",
  1197. columnProp: 'taskDate',
  1198. headerAlign: "center",
  1199. align: "center",
  1200. columnLabel: '送检日期',
  1201. columnHidden: false,
  1202. columnImage: false,
  1203. columnSortable: false,
  1204. sortLv: 0,
  1205. status: true,
  1206. fixed: '',
  1207. columnWidth: 130,
  1208. },
  1209. {
  1210. userId: this.$store.state.user.name,
  1211. functionId: 301007,
  1212. serialNumber: '301007Table1InspectionCycle',
  1213. tableId: "301007Table1",
  1214. tableName: "FQC检验记录表",
  1215. columnProp: 'inspectionCycle',
  1216. headerAlign: "center",
  1217. align: "right",
  1218. columnLabel: '检验周期(h)',
  1219. columnHidden: false,
  1220. columnImage: false,
  1221. columnSortable: false,
  1222. sortLv: 0,
  1223. status: true,
  1224. fixed: '',
  1225. columnWidth: 100,
  1226. },
  1227. {
  1228. userId: this.$store.state.user.name,
  1229. functionId: 301007,
  1230. serialNumber: '301007Table1OrderNo',
  1231. tableId: "301007Table1",
  1232. tableName: "FQC检验记录表",
  1233. columnProp: 'orderNo',
  1234. headerAlign: "center",
  1235. align: "left",
  1236. columnLabel: '工单号',
  1237. columnHidden: false,
  1238. columnImage: false,
  1239. columnSortable: false,
  1240. sortLv: 0,
  1241. status: true,
  1242. fixed: '',
  1243. columnWidth: 150,
  1244. },
  1245. {
  1246. userId: this.$store.state.user.name,
  1247. functionId: 301007,
  1248. serialNumber: '301007Table1SeqNo',
  1249. tableId: "301007Table1",
  1250. tableName: "FQC检验记录表",
  1251. columnProp: 'seqNo',
  1252. headerAlign: "center",
  1253. align: "left",
  1254. columnLabel: '派工单号',
  1255. columnHidden: false,
  1256. columnImage: false,
  1257. columnSortable: false,
  1258. sortLv: 0,
  1259. status: true,
  1260. fixed: '',
  1261. columnWidth: 200,
  1262. },
  1263. {
  1264. userId: this.$store.state.user.name,
  1265. functionId: 301007,
  1266. serialNumber: '301007Table1OperationDesc',
  1267. tableId: "301007Table1",
  1268. tableName: "FQC检验记录表",
  1269. columnProp: 'operationDesc',
  1270. headerAlign: "center",
  1271. align: "left",
  1272. columnLabel: '工序',
  1273. columnHidden: false,
  1274. columnImage: false,
  1275. columnSortable: false,
  1276. sortLv: 0,
  1277. status: true,
  1278. fixed: '',
  1279. columnWidth: 120,
  1280. },
  1281. {
  1282. userId: this.$store.state.user.name,
  1283. functionId: 301007,
  1284. serialNumber: '301007Table1ResourceDesc',
  1285. tableId: "301007Table1",
  1286. tableName: "FQC检验记录表",
  1287. columnProp: 'resourceDesc',
  1288. headerAlign: "center",
  1289. align: "left",
  1290. columnLabel: '机台',
  1291. columnHidden: false,
  1292. columnImage: false,
  1293. columnSortable: false,
  1294. sortLv: 0,
  1295. status: true,
  1296. fixed: '',
  1297. columnWidth: 120,
  1298. },
  1299. {
  1300. userId: this.$store.state.user.name,
  1301. functionId: 301007,
  1302. serialNumber: '301007Table1PartNo',
  1303. tableId: "301007Table1",
  1304. tableName: "FQC检验记录表",
  1305. columnProp: 'partNo',
  1306. headerAlign: "center",
  1307. align: "center",
  1308. columnLabel: '物料编码',
  1309. columnHidden: false,
  1310. columnImage: false,
  1311. columnSortable: false,
  1312. sortLv: 0,
  1313. status: true,
  1314. fixed: '',
  1315. columnWidth: 120,
  1316. },
  1317. {
  1318. userId: this.$store.state.user.name,
  1319. functionId: 301007,
  1320. serialNumber: '301007Table1PartDesc',
  1321. tableId: "301007Table1",
  1322. tableName: "FQC检验记录表",
  1323. columnProp: 'partDesc',
  1324. headerAlign: "center",
  1325. align: "left",
  1326. columnLabel: '物料名称',
  1327. columnHidden: false,
  1328. columnImage: false,
  1329. columnSortable: false,
  1330. sortLv: 0,
  1331. status: true,
  1332. fixed: '',
  1333. columnWidth: 300,
  1334. },
  1335. {
  1336. userId: this.$store.state.user.name,
  1337. functionId: 301007,
  1338. serialNumber: '301007Table1Sku',
  1339. tableId: "301007Table1",
  1340. tableName: "FQC检验记录表",
  1341. columnProp: 'sku',
  1342. headerAlign: "center",
  1343. align: "center",
  1344. columnLabel: 'SKU',
  1345. columnHidden: false,
  1346. columnImage: false,
  1347. columnSortable: false,
  1348. sortLv: 0,
  1349. status: true,
  1350. fixed: '',
  1351. columnWidth: 120,
  1352. },
  1353. {
  1354. userId: this.$store.state.user.name,
  1355. functionId: 301007,
  1356. serialNumber: '301007Table1CinvSourceCode',
  1357. tableId: "301007Table1",
  1358. tableName: "FQC检验记录表",
  1359. columnProp: 'cinvSourceCode',
  1360. headerAlign: "center",
  1361. align: "center",
  1362. columnLabel: 'PN',
  1363. columnHidden: false,
  1364. columnImage: false,
  1365. columnSortable: false,
  1366. sortLv: 0,
  1367. status: true,
  1368. fixed: '',
  1369. columnWidth: 120,
  1370. },
  1371. {
  1372. userId: this.$store.state.user.name,
  1373. functionId: 301007,
  1374. serialNumber: '301007Table1Invdefinetype',
  1375. tableId: "301007Table1",
  1376. tableName: "FQC检验记录表",
  1377. columnProp: 'invdefinetype',
  1378. headerAlign: "center",
  1379. align: "left",
  1380. columnLabel: '物料类别',
  1381. columnHidden: false,
  1382. columnImage: false,
  1383. columnSortable: false,
  1384. sortLv: 0,
  1385. status: true,
  1386. fixed: '',
  1387. columnWidth: 120,
  1388. },
  1389. {
  1390. userId: this.$store.state.user.name,
  1391. functionId: 301007,
  1392. serialNumber: '301007Table1RollQty',
  1393. tableId: "301007Table1",
  1394. tableName: "FQC检验记录表",
  1395. columnProp: 'rollQty',
  1396. headerAlign: "center",
  1397. align: "right",
  1398. columnLabel: '送检数量',
  1399. columnHidden: false,
  1400. columnImage: false,
  1401. columnSortable: false,
  1402. sortLv: 0,
  1403. status: true,
  1404. fixed: '',
  1405. columnWidth: 100,
  1406. },
  1407. {
  1408. userId: this.$store.state.user.name,
  1409. functionId: 301007,
  1410. serialNumber: '301007Table1SamplingQty',
  1411. tableId: "301007Table1",
  1412. tableName: "FQC检验记录表",
  1413. columnProp: 'samplingQty',
  1414. headerAlign: "center",
  1415. align: "right",
  1416. columnLabel: '抽样数量',
  1417. columnHidden: false,
  1418. columnImage: false,
  1419. columnSortable: false,
  1420. sortLv: 0,
  1421. status: true,
  1422. fixed: '',
  1423. columnWidth: 100,
  1424. },
  1425. {
  1426. userId: this.$store.state.user.name,
  1427. functionId: 301007,
  1428. serialNumber: '301007Table1UmName',
  1429. tableId: "301007Table1",
  1430. tableName: "FQC检验记录表",
  1431. columnProp: 'umName',
  1432. headerAlign: "center",
  1433. align: "center",
  1434. columnLabel: '单位',
  1435. columnHidden: false,
  1436. columnImage: false,
  1437. columnSortable: false,
  1438. sortLv: 0,
  1439. status: true,
  1440. fixed: '',
  1441. columnWidth: 100,
  1442. },
  1443. {
  1444. userId: this.$store.state.user.name,
  1445. functionId: 301007,
  1446. serialNumber: '301007Table1InspectionRemark',
  1447. tableId: "301007Table1",
  1448. tableName: "FQC检验记录表",
  1449. columnProp: 'inspectionRemark',
  1450. headerAlign: "center",
  1451. align: "left",
  1452. columnLabel: '质检备注',
  1453. columnHidden: false,
  1454. columnImage: false,
  1455. columnSortable: false,
  1456. sortLv: 0,
  1457. status: true,
  1458. fixed: '',
  1459. columnWidth: 200,
  1460. },
  1461. {
  1462. userId: this.$store.state.user.name,
  1463. functionId: 301007,
  1464. serialNumber: '301007Table1DisposalRemark',
  1465. tableId: "301007Table1",
  1466. tableName: "FQC检验记录表",
  1467. columnProp: 'disposalRemark',
  1468. headerAlign: "center",
  1469. align: "left",
  1470. columnLabel: '处置说明',
  1471. columnHidden: false,
  1472. columnImage: false,
  1473. columnSortable: false,
  1474. sortLv: 0,
  1475. status: true,
  1476. fixed: '',
  1477. columnWidth: 200,
  1478. },
  1479. {
  1480. userId: this.$store.state.user.name,
  1481. functionId: 301007,
  1482. serialNumber: '301007Table1ActionDate',
  1483. tableId: "301007Table1",
  1484. tableName: "FQC检验记录表",
  1485. columnProp: 'actionDate',
  1486. headerAlign: "center",
  1487. align: "center",
  1488. columnLabel: '开始检验时间',
  1489. columnHidden: false,
  1490. columnImage: false,
  1491. columnSortable: false,
  1492. sortLv: 0,
  1493. status: true,
  1494. fixed: '',
  1495. columnWidth: 170,
  1496. },
  1497. {
  1498. userId: this.$store.state.user.name,
  1499. functionId: 301007,
  1500. serialNumber: '301007Table1InspectorDate',
  1501. tableId: "301007Table1",
  1502. tableName: "FQC检验记录表",
  1503. columnProp: 'inspectorDate',
  1504. headerAlign: "center",
  1505. align: "center",
  1506. columnLabel: '检验时间',
  1507. columnHidden: false,
  1508. columnImage: false,
  1509. columnSortable: false,
  1510. sortLv: 0,
  1511. status: true,
  1512. fixed: '',
  1513. columnWidth: 170,
  1514. },
  1515. {
  1516. userId: this.$store.state.user.name,
  1517. functionId: 301007,
  1518. serialNumber: '301007Table1InspectorName',
  1519. tableId: "301007Table1",
  1520. tableName: "FQC检验记录表",
  1521. columnProp: 'inspectorName',
  1522. headerAlign: "center",
  1523. align: "center",
  1524. columnLabel: '质检员',
  1525. columnHidden: false,
  1526. columnImage: false,
  1527. columnSortable: false,
  1528. sortLv: 0,
  1529. status: true,
  1530. fixed: '',
  1531. columnWidth: 100,
  1532. },
  1533. {
  1534. userId: this.$store.state.user.name,
  1535. functionId: 301007,
  1536. serialNumber: '301007Table1SpecialRequirements',
  1537. tableId: "301007Table1",
  1538. tableName: "FQC检验记录表",
  1539. columnProp: 'specialRequirements',
  1540. headerAlign: "center",
  1541. align: "left",
  1542. columnLabel: '特殊要求',
  1543. columnHidden: false,
  1544. columnImage: false,
  1545. columnSortable: false,
  1546. sortLv: 0,
  1547. status: true,
  1548. fixed: '',
  1549. columnWidth: 200,
  1550. },
  1551. ],
  1552. //项目清单
  1553. detailData: {
  1554. site: '',
  1555. buNo: '',
  1556. inspectionNo:'',
  1557. partNo:'',
  1558. partDesc:'',
  1559. rollQty:'',
  1560. samplingQty: '',
  1561. unqualifiedQty: 0,
  1562. unqualifiedQuantity:'',
  1563. disposalMeasures:'',
  1564. disposalRemark: '',
  1565. inspectionResult: '',
  1566. inspectorNo: '',
  1567. inspectorName: '',
  1568. inspectionRemark: '',
  1569. submitFlag: '',
  1570. cinvSourceCode: '',
  1571. sku: '',
  1572. invdefinetype: '',
  1573. umId: '',
  1574. umName: '',
  1575. operator: '',
  1576. operatorName: '',
  1577. responsiblePerson: '',
  1578. responsiblePersonName: '',
  1579. state: '',
  1580. passQty: '',
  1581. notPassQty: '',
  1582. batchQualifiedQty: ''
  1583. },
  1584. detailInformationFlag: false,
  1585. detailList: [],
  1586. saveInformationData: {
  1587. site: '',
  1588. buNo: '',
  1589. inspectionNo:'',
  1590. disposalMeasures: '',
  1591. disposalRemark: '',
  1592. inspectorNo: '',
  1593. inspectionRemark: '',
  1594. samplingQty: '',
  1595. rollQty: '',
  1596. itemList:[],
  1597. unqualifiedQty: '',
  1598. partNo: '',
  1599. partDesc: '',
  1600. operator: '',
  1601. operatorName: '',
  1602. responsiblePerson: '',
  1603. responsiblePersonName: '',
  1604. subDetailList: [],
  1605. type: '',
  1606. passQty: '',
  1607. notPassQty: '',
  1608. batchQualifiedQty: ''
  1609. },
  1610. detailColumnList: [
  1611. {
  1612. userId: this.$store.state.user.name,
  1613. functionId: 301007,
  1614. serialNumber: '301007Table2ItemNo',
  1615. tableId: "301007Table2",
  1616. tableName: "检验单明细表",
  1617. columnProp: 'itemNo',
  1618. headerAlign: "center",
  1619. align: "center",
  1620. columnLabel: '检验项目编码',
  1621. columnHidden: false,
  1622. columnImage: false,
  1623. columnSortable: false,
  1624. sortLv: 0,
  1625. status: true,
  1626. fixed: '',
  1627. columnWidth: 120,
  1628. },
  1629. {
  1630. userId: this.$store.state.user.name,
  1631. functionId: 301007,
  1632. serialNumber: '301007Table2ItemDesc',
  1633. tableId: "301007Table2",
  1634. tableName: "检验单明细表",
  1635. columnProp: 'itemDesc',
  1636. headerAlign: "center",
  1637. align: "left",
  1638. columnLabel: '检验项目名称',
  1639. columnHidden: false,
  1640. columnImage: false,
  1641. columnSortable: false,
  1642. sortLv: 0,
  1643. status: true,
  1644. fixed: '',
  1645. columnWidth: 150,
  1646. },
  1647. {
  1648. userId: this.$store.state.user.name,
  1649. functionId: 301007,
  1650. serialNumber: '301007Table2SamplingLevelDesc',
  1651. tableId: "301007Table2",
  1652. tableName: "检验单明细表",
  1653. columnProp: 'samplingLevelDesc',
  1654. headerAlign: "center",
  1655. align: "left",
  1656. columnLabel: '检验水平',
  1657. columnHidden: false,
  1658. columnImage: false,
  1659. columnSortable: false,
  1660. sortLv: 0,
  1661. status: true,
  1662. fixed: '',
  1663. columnWidth: 120,
  1664. },
  1665. {
  1666. userId: this.$store.state.user.name,
  1667. functionId: 301007,
  1668. serialNumber: '301007Table2SamplingProgrammeDesc',
  1669. tableId: "301007Table2",
  1670. tableName: "检验单明细表",
  1671. columnProp: 'samplingProgrammeDesc',
  1672. headerAlign: "center",
  1673. align: "left",
  1674. columnLabel: '检验方案',
  1675. columnHidden: false,
  1676. columnImage: false,
  1677. columnSortable: false,
  1678. sortLv: 0,
  1679. status: true,
  1680. fixed: '',
  1681. columnWidth: 120,
  1682. },
  1683. {
  1684. userId: this.$store.state.user.name,
  1685. functionId: 301007,
  1686. serialNumber: '301007Table2MethodName',
  1687. tableId: "301007Table2",
  1688. tableName: "检验单明细表",
  1689. columnProp: 'methodName',
  1690. headerAlign: "center",
  1691. align: "left",
  1692. columnLabel: '检验方法',
  1693. columnHidden: false,
  1694. columnImage: false,
  1695. columnSortable: false,
  1696. sortLv: 0,
  1697. status: true,
  1698. fixed: '',
  1699. columnWidth: 120,
  1700. },
  1701. {
  1702. userId: this.$store.state.user.name,
  1703. functionId: 301007,
  1704. serialNumber: '301007Table2MethodRemark',
  1705. tableId: "301007Table2",
  1706. tableName: "检验单明细表",
  1707. columnProp: 'methodRemark',
  1708. headerAlign: "center",
  1709. align: "left",
  1710. columnLabel: '检验方法说明',
  1711. columnHidden: false,
  1712. columnImage: false,
  1713. columnSortable: false,
  1714. sortLv: 0,
  1715. status: true,
  1716. fixed: '',
  1717. columnWidth: 200,
  1718. },
  1719. {
  1720. userId: this.$store.state.user.name,
  1721. functionId: 301007,
  1722. serialNumber: '301007Table2ObjectDesc',
  1723. tableId: "301007Table2",
  1724. tableName: "检验单明细表",
  1725. columnProp: 'objectDesc',
  1726. headerAlign: "center",
  1727. align: "center",
  1728. columnLabel: '检测仪器',
  1729. columnHidden: false,
  1730. columnImage: false,
  1731. columnSortable: false,
  1732. sortLv: 0,
  1733. status: true,
  1734. fixed: '',
  1735. columnWidth: 120,
  1736. },
  1737. {
  1738. userId: this.$store.state.user.name,
  1739. functionId: 301007,
  1740. serialNumber: '301007Table2Aql',
  1741. tableId: "301007Table2",
  1742. tableName: "检验单明细表",
  1743. columnProp: 'aql',
  1744. headerAlign: "center",
  1745. align: "right",
  1746. columnLabel: 'AQL',
  1747. columnHidden: false,
  1748. columnImage: false,
  1749. columnSortable: false,
  1750. sortLv: 0,
  1751. status: true,
  1752. fixed: '',
  1753. columnWidth: 100,
  1754. },
  1755. {
  1756. userId: this.$store.state.user.name,
  1757. functionId: 301007,
  1758. serialNumber: '301007Table2Ac',
  1759. tableId: "301007Table2",
  1760. tableName: "检验单明细表",
  1761. columnProp: 'ac',
  1762. headerAlign: "center",
  1763. align: "right",
  1764. columnLabel: 'AC',
  1765. columnHidden: false,
  1766. columnImage: false,
  1767. columnSortable: false,
  1768. sortLv: 0,
  1769. status: true,
  1770. fixed: '',
  1771. columnWidth: 100,
  1772. },
  1773. {
  1774. userId: this.$store.state.user.name,
  1775. functionId: 301007,
  1776. serialNumber: '301007Table2Re',
  1777. tableId: "301007Table2",
  1778. tableName: "检验单明细表",
  1779. columnProp: 're',
  1780. headerAlign: "center",
  1781. align: "right",
  1782. columnLabel: 'RE',
  1783. columnHidden: false,
  1784. columnImage: false,
  1785. columnSortable: false,
  1786. sortLv: 0,
  1787. status: true,
  1788. fixed: '',
  1789. columnWidth: 100,
  1790. },
  1791. {
  1792. userId: this.$store.state.user.name,
  1793. functionId: 301007,
  1794. serialNumber: '301007Table2DefaultValue',
  1795. tableId: "301007Table2",
  1796. tableName: "检验单明细表",
  1797. columnProp: 'defaultValue',
  1798. headerAlign: "center",
  1799. align: "right",
  1800. columnLabel: '标准值',
  1801. columnHidden: false,
  1802. columnImage: false,
  1803. columnSortable: false,
  1804. sortLv: 0,
  1805. status: true,
  1806. fixed: '',
  1807. columnWidth: 100,
  1808. },
  1809. {
  1810. userId: this.$store.state.user.name,
  1811. functionId: 301007,
  1812. serialNumber: '301007Table2MaxValue',
  1813. tableId: "301007Table2",
  1814. tableName: "检验单明细表",
  1815. columnProp: 'maxValue',
  1816. headerAlign: "center",
  1817. align: "right",
  1818. columnLabel: '上限值',
  1819. columnHidden: false,
  1820. columnImage: false,
  1821. columnSortable: false,
  1822. sortLv: 0,
  1823. status: true,
  1824. fixed: '',
  1825. columnWidth: 100,
  1826. },
  1827. {
  1828. userId: this.$store.state.user.name,
  1829. functionId: 301007,
  1830. serialNumber: '301007Table2MinValue',
  1831. tableId: "301007Table2",
  1832. tableName: "检验单明细表",
  1833. columnProp: 'minValue',
  1834. headerAlign: "center",
  1835. align: "right",
  1836. columnLabel: '下限值',
  1837. columnHidden: false,
  1838. columnImage: false,
  1839. columnSortable: false,
  1840. sortLv: 0,
  1841. status: true,
  1842. fixed: '',
  1843. columnWidth: 100,
  1844. },
  1845. {
  1846. userId: this.$store.state.user.name,
  1847. functionId: 301007,
  1848. serialNumber: '301007Table2ValueType',
  1849. tableId: "301007Table2",
  1850. tableName: "检验单明细表",
  1851. columnProp: 'valueType',
  1852. headerAlign: "center",
  1853. align: "center",
  1854. columnLabel: '检测值类型',
  1855. columnHidden: false,
  1856. columnImage: false,
  1857. columnSortable: false,
  1858. sortLv: 0,
  1859. status: true,
  1860. fixed: '',
  1861. columnWidth: 100,
  1862. },
  1863. ],
  1864. fileColumnList: [
  1865. {
  1866. columnProp: 'fileName',
  1867. headerAlign: "center",
  1868. align: "center",
  1869. columnLabel: '文件名称',
  1870. columnHidden: false,
  1871. columnImage: false,
  1872. columnSortable: false,
  1873. sortLv: 0,
  1874. status: true,
  1875. fixed: '',
  1876. },
  1877. {
  1878. columnProp: 'createdBy',
  1879. headerAlign: "center",
  1880. align: 'center',
  1881. columnLabel: '上传人',
  1882. columnHidden: false,
  1883. columnImage: false,
  1884. columnSortable: true,
  1885. sortLv: 0,
  1886. status: true,
  1887. fixed: false
  1888. },
  1889. {
  1890. columnProp: 'createDate',
  1891. headerAlign: "center",
  1892. align: 'center',
  1893. columnLabel: '上传时间',
  1894. columnHidden: false,
  1895. columnImage: false,
  1896. columnSortable: true,
  1897. sortLv: 0,
  1898. status: true,
  1899. fixed: false
  1900. },
  1901. {
  1902. columnProp: 'orderRef3',
  1903. headerAlign: "center",
  1904. align: 'center',
  1905. columnLabel: '备注',
  1906. columnHidden: false,
  1907. columnImage: false,
  1908. columnSortable: true,
  1909. sortLv: 0,
  1910. status: true,
  1911. fixed: false
  1912. },
  1913. ],
  1914. // 派工单号
  1915. seqInfoList: [],
  1916. seqDetailFlag: false,
  1917. seqDetailData: {
  1918. orderNo: '',
  1919. seqNo: '',
  1920. sku: '',
  1921. partNo: '',
  1922. partDesc: '',
  1923. operationDesc: '',
  1924. qtyrequired: '',
  1925. lotsize: '',
  1926. status: '下达'
  1927. },
  1928. seqDetailColumnList: [
  1929. {
  1930. userId: this.$store.state.user.name,
  1931. functionId: 301007,
  1932. serialNumber: '301007Table3OrderNo',
  1933. tableId: "301007Table3",
  1934. tableName: "派工单号表",
  1935. fixed: '',
  1936. columnWidth: 80,
  1937. columnProp: 'orderNo',
  1938. headerAlign: "center",
  1939. align: "center",
  1940. columnLabel: '工单号',
  1941. columnHidden: false,
  1942. columnImage: false,
  1943. columnSortable: false,
  1944. sortLv: 0,
  1945. status: true,
  1946. },
  1947. {
  1948. userId: this.$store.state.user.name,
  1949. functionId: 301007,
  1950. serialNumber: '301007Table3SeqNo',
  1951. tableId: "301007Table3",
  1952. tableName: "派工单号表",
  1953. fixed: '',
  1954. columnWidth: 80,
  1955. columnProp: 'seqNo',
  1956. headerAlign: "center",
  1957. align: "center",
  1958. columnLabel: '派工单号',
  1959. columnHidden: false,
  1960. columnImage: false,
  1961. columnSortable: false,
  1962. sortLv: 0,
  1963. status: true,
  1964. },
  1965. {
  1966. userId: this.$store.state.user.name,
  1967. functionId: 301007,
  1968. serialNumber: '301007Table3Sku',
  1969. tableId: "301007Table3",
  1970. tableName: "派工单号表",
  1971. fixed: '',
  1972. columnWidth: 80,
  1973. columnProp: 'sku',
  1974. headerAlign: "center",
  1975. align: "center",
  1976. columnLabel: 'SKU',
  1977. columnHidden: false,
  1978. columnImage: false,
  1979. columnSortable: false,
  1980. sortLv: 0,
  1981. status: true,
  1982. },
  1983. {
  1984. userId: this.$store.state.user.name,
  1985. functionId: 301007,
  1986. serialNumber: '301007Table3PartNo',
  1987. tableId: "301007Table3",
  1988. tableName: "派工单号表",
  1989. fixed: '',
  1990. columnWidth: 80,
  1991. columnProp: 'partNo',
  1992. headerAlign: "center",
  1993. align: "center",
  1994. columnLabel: '物料编码',
  1995. columnHidden: false,
  1996. columnImage: false,
  1997. columnSortable: false,
  1998. sortLv: 0,
  1999. status: true,
  2000. },
  2001. {
  2002. userId: this.$store.state.user.name,
  2003. functionId: 301007,
  2004. serialNumber: '301007Table3PartDesc',
  2005. tableId: "301007Table3",
  2006. tableName: "派工单号表",
  2007. fixed: '',
  2008. columnWidth: 80,
  2009. columnProp: 'partDesc',
  2010. headerAlign: "center",
  2011. align: "center",
  2012. columnLabel: '物料名称',
  2013. columnHidden: false,
  2014. columnImage: false,
  2015. columnSortable: false,
  2016. sortLv: 0,
  2017. status: true,
  2018. },
  2019. {
  2020. userId: this.$store.state.user.name,
  2021. functionId: 301007,
  2022. serialNumber: '301007Table3Lotsize',
  2023. tableId: "301007Table3",
  2024. tableName: "派工单号表",
  2025. fixed: '',
  2026. columnWidth: 80,
  2027. columnProp: 'lotsize',
  2028. headerAlign: "center",
  2029. align: "center",
  2030. columnLabel: '工单数量',
  2031. columnHidden: false,
  2032. columnImage: false,
  2033. columnSortable: false,
  2034. sortLv: 0,
  2035. status: true,
  2036. },
  2037. {
  2038. userId: this.$store.state.user.name,
  2039. functionId: 301007,
  2040. serialNumber: '301007Table3Qtyrequired',
  2041. tableId: "301007Table3",
  2042. tableName: "派工单号表",
  2043. fixed: '',
  2044. columnWidth: 80,
  2045. columnProp: 'qtyrequired',
  2046. headerAlign: "center",
  2047. align: "center",
  2048. columnLabel: '派工数量',
  2049. columnHidden: false,
  2050. columnImage: false,
  2051. columnSortable: false,
  2052. sortLv: 0,
  2053. status: true,
  2054. },
  2055. {
  2056. userId: this.$store.state.user.name,
  2057. functionId: 301007,
  2058. serialNumber: '301007Table3OperationDesc',
  2059. tableId: "301007Table3",
  2060. tableName: "派工单号表",
  2061. fixed: '',
  2062. columnWidth: 80,
  2063. columnProp: 'operationDesc',
  2064. headerAlign: "center",
  2065. align: "center",
  2066. columnLabel: '工序',
  2067. columnHidden: false,
  2068. columnImage: false,
  2069. columnSortable: false,
  2070. sortLv: 0,
  2071. status: true,
  2072. }
  2073. ],
  2074. // 子明细数据对象
  2075. tableData: [],
  2076. checkedDetail: [],
  2077. subDetailFlag: false,
  2078. subDetailData: {
  2079. site: '',
  2080. buNo: '',
  2081. inspectionNo: '',
  2082. itemNo: '',
  2083. itemDesc: '',
  2084. defaultValue: '',
  2085. maxValue: '',
  2086. minValue: '',
  2087. valueTypeDb: '',
  2088. subDetailValues:[],
  2089. page: 1,
  2090. limit: 10,
  2091. },
  2092. options: [],
  2093. FAISelections: [],
  2094. modalFlag: false,
  2095. rules: {
  2096. orderNoType:[
  2097. {
  2098. required: true,
  2099. message: ' ',
  2100. trigger: ['blur','change']
  2101. }
  2102. ],
  2103. operationDescType:[
  2104. {
  2105. required: true,
  2106. message: ' ',
  2107. trigger: ['blur','change']
  2108. }
  2109. ],
  2110. resourceIdType:[
  2111. {
  2112. required: true,
  2113. message: ' ',
  2114. trigger: ['blur','change']
  2115. }
  2116. ],
  2117. rollQtyType:[
  2118. {
  2119. required: true,
  2120. message: ' ',
  2121. trigger: ['blur','change']
  2122. }
  2123. ],
  2124. seqNoType: [
  2125. {
  2126. required: true,
  2127. message: ' ',
  2128. trigger: ['blur','change']
  2129. }
  2130. ],
  2131. partNoType: [
  2132. {
  2133. required: true,
  2134. message: ' ',
  2135. trigger: ['blur','change']
  2136. }
  2137. ],
  2138. umIdType: [
  2139. {
  2140. required: true,
  2141. message: ' ',
  2142. trigger: ['blur','change']
  2143. }
  2144. ],
  2145. templateId: [
  2146. {
  2147. required: true,
  2148. message: ' ',
  2149. trigger: ['blur','change']
  2150. }
  2151. ],
  2152. bu:[
  2153. {
  2154. required: true,
  2155. message: ' ',
  2156. trigger: ['blur','change']
  2157. }
  2158. ]
  2159. },
  2160. resourceList: [],
  2161. operationList: [],
  2162. partList: [],
  2163. batchHandleAddModalFlag: false,
  2164. batchAddData: {
  2165. samplingLocation: '',
  2166. samplingLocationB: '',
  2167. samplingNumber: ''
  2168. },
  2169. controlData: {},
  2170. templateData: {
  2171. site: '',
  2172. bu: '',
  2173. templateId: '',
  2174. templateName: '',
  2175. inspectionTypeNo: '',
  2176. inspectionTypeName: ''
  2177. },
  2178. templateList: [],
  2179. templateModelFlag: false,
  2180. templateDetailList: [
  2181. {
  2182. columnProp: 'templateId',
  2183. headerAlign: "center",
  2184. align: "center",
  2185. columnLabel: '模板编码',
  2186. columnHidden: false,
  2187. columnImage: false,
  2188. columnSortable: false,
  2189. sortLv: 0,
  2190. status: true,
  2191. fixed: '',
  2192. },
  2193. {
  2194. columnProp: 'templateName',
  2195. headerAlign: "center",
  2196. align: "center",
  2197. columnLabel: '模板名称',
  2198. columnHidden: false,
  2199. columnImage: false,
  2200. columnSortable: false,
  2201. sortLv: 0,
  2202. status: true,
  2203. fixed: '',
  2204. },
  2205. {
  2206. columnProp: 'inspectionTypeName',
  2207. headerAlign: "center",
  2208. align: "center",
  2209. columnLabel: '检验类型',
  2210. columnHidden: false,
  2211. columnImage: false,
  2212. columnSortable: false,
  2213. sortLv: 0,
  2214. status: true,
  2215. fixed: '',
  2216. },
  2217. ],
  2218. checked: false,
  2219. typeOptions: [],
  2220. disposalMeasuresOptions: [],
  2221. timeout: null,
  2222. partData: {
  2223. site: '',
  2224. bu: '',
  2225. partNo: '',
  2226. partDesc: '',
  2227. sku: '',
  2228. cinvSourceCode: '',
  2229. },
  2230. partDetailList: [
  2231. {
  2232. columnProp: 'partNo',
  2233. headerAlign: "center",
  2234. align: "center",
  2235. columnLabel: '物料编码',
  2236. columnHidden: false,
  2237. columnImage: false,
  2238. columnSortable: false,
  2239. sortLv: 0,
  2240. status: true,
  2241. fixed: '',
  2242. },
  2243. {
  2244. columnProp: 'partDesc',
  2245. headerAlign: "center",
  2246. align: "center",
  2247. columnLabel: '物料名称',
  2248. columnHidden: false,
  2249. columnImage: false,
  2250. columnSortable: false,
  2251. sortLv: 0,
  2252. status: true,
  2253. fixed: '',
  2254. },
  2255. {
  2256. columnProp: 'sku',
  2257. headerAlign: "center",
  2258. align: "center",
  2259. columnLabel: 'SKU',
  2260. columnHidden: false,
  2261. columnImage: false,
  2262. columnSortable: false,
  2263. sortLv: 0,
  2264. status: true,
  2265. fixed: '',
  2266. },
  2267. {
  2268. columnProp: 'cinvSourceCode',
  2269. headerAlign: "center",
  2270. align: "center",
  2271. columnLabel: 'PN',
  2272. columnHidden: false,
  2273. columnImage: false,
  2274. columnSortable: false,
  2275. sortLv: 0,
  2276. status: true,
  2277. fixed: '',
  2278. },
  2279. ],
  2280. partModelFlag: false,
  2281. umList: [],
  2282. userBuList: [],
  2283. buList: [],
  2284. authSearch: false,
  2285. authSave: false,
  2286. authCheck: false,
  2287. authCancelCheck: false,
  2288. authDelete: false,
  2289. authDetail: false,
  2290. authFile: false,
  2291. menuId: this.$route.meta.menuId,
  2292. roleList: [],
  2293. operatorList: [],
  2294. operatorData: {
  2295. flag: '',
  2296. site: '',
  2297. bu: '',
  2298. adminID: '',
  2299. adminName: '',
  2300. roleName: '',
  2301. roleId: '',
  2302. userName: this.$store.state.user.name
  2303. },
  2304. operatorModelFlag: false,
  2305. dataListSelections2: [],
  2306. operatorDetailList: [
  2307. {
  2308. columnProp: 'adminID',
  2309. headerAlign: "center",
  2310. align: "center",
  2311. columnLabel: '用户账号',
  2312. columnHidden: false,
  2313. columnImage: false,
  2314. columnSortable: false,
  2315. sortLv: 0,
  2316. status: true,
  2317. fixed: '',
  2318. },
  2319. {
  2320. columnProp: 'adminName',
  2321. headerAlign: "center",
  2322. align: "center",
  2323. columnLabel: '用户名称',
  2324. columnHidden: false,
  2325. columnImage: false,
  2326. columnSortable: false,
  2327. sortLv: 0,
  2328. status: true,
  2329. fixed: '',
  2330. },
  2331. {
  2332. columnProp: 'email',
  2333. headerAlign: "center",
  2334. align: "center",
  2335. columnLabel: '邮箱',
  2336. columnHidden: false,
  2337. columnImage: false,
  2338. columnSortable: false,
  2339. sortLv: 0,
  2340. status: true,
  2341. fixed: '',
  2342. },
  2343. {
  2344. columnProp: 'phone',
  2345. headerAlign: "center",
  2346. align: "center",
  2347. columnLabel: '手机号',
  2348. columnHidden: false,
  2349. columnImage: false,
  2350. columnSortable: false,
  2351. sortLv: 0,
  2352. status: true,
  2353. fixed: '',
  2354. },
  2355. ],
  2356. acquisitionList: [],
  2357. ItemObjectModelFlag: false,
  2358. itemObjectList: [],
  2359. itemObjectColumnList: [
  2360. {
  2361. columnProp: 'itemNo',
  2362. headerAlign: "center",
  2363. align: "center",
  2364. columnLabel: '项目编码',
  2365. columnHidden: false,
  2366. columnImage: false,
  2367. status: true,
  2368. columnWidth: 120,
  2369. },
  2370. {
  2371. columnProp: 'itemDesc',
  2372. headerAlign: "center",
  2373. align: "left",
  2374. columnLabel: '项目名称',
  2375. columnHidden: false,
  2376. columnImage: false,
  2377. status: true,
  2378. columnWidth: 200,
  2379. },
  2380. ],
  2381. actionData: {
  2382. site: '',
  2383. buNo: '',
  2384. inspectionNo: ''
  2385. },
  2386. fileLoading: false,
  2387. subDetailLoading: false,
  2388. saveLoading: false,
  2389. searchLoading: false,
  2390. subDetailVisiable: false,
  2391. }
  2392. },
  2393. mounted () {
  2394. this.$nextTick(() => {
  2395. this.height = window.innerHeight - 250
  2396. })
  2397. },
  2398. created () {
  2399. // 按钮控制
  2400. this.getButtonAuthData()
  2401. // 获取用户的 site 和 bu
  2402. this.getSiteAndBuByUserName()
  2403. // 获取用户的 site 和 bu
  2404. this.getSiteAndBuByUserName2()
  2405. // 收藏
  2406. this.favoriteIsOk()
  2407. // 检验类型
  2408. this.inspectionTypeSearch()
  2409. // 处置措施列表
  2410. this.disposalMeasuresSearch()
  2411. // 单位
  2412. this.umSearch()
  2413. // 查看 质量任务生成规则控制 动控是否开启
  2414. this.queryController()
  2415. // 动态列
  2416. this.getTableUserColumn(this.$route.meta.menuId+'table1',1)
  2417. this.getTableUserColumn(this.$route.meta.menuId+'table2',2)
  2418. this.getTableUserColumn(this.$route.meta.menuId+'table3',3)
  2419. if (!this.authSearch) {
  2420. // 获取数据列表
  2421. this.getDataList()
  2422. }
  2423. // 获取用户角色
  2424. this.getUserRoleList()
  2425. },
  2426. methods: {
  2427. // 获取用户的bu
  2428. getSiteAndBuByUserName2 () {
  2429. let tempData = {
  2430. username: this.$store.state.user.name,
  2431. }
  2432. getSiteAndBuByUserName2(tempData).then(({data}) => {
  2433. if (data.code === 0) {
  2434. this.buList = data.rows
  2435. }
  2436. })
  2437. },
  2438. // 批量打印标签
  2439. printList () {
  2440. if (this.FAISelections.length === 0) {
  2441. this.$message.warning('请勾选要打印的检验单!')
  2442. return
  2443. }
  2444. const inspectionNos = this.$refs.qrCode.init(this.FAISelections.map(item => item.inspectionNo))
  2445. for (let i = 0; i < inspectionNos.length; i++) {
  2446. this.FAISelections[i].qrCode = inspectionNos[i]
  2447. }
  2448. qcPrint(this.FAISelections)
  2449. },
  2450. // 数据采集
  2451. dataAcquisition () {
  2452. this.loadFlag = true
  2453. let tempDate = {
  2454. site: this.detailData.site,
  2455. buNo: this.detailData.buNo,
  2456. inspectionNo: this.detailData.inspectionNo,
  2457. flag: 'fai'
  2458. }
  2459. dataAcquisition(tempDate).then(({data}) => {
  2460. if (data.code === 0) {
  2461. // this.acquisitionList = data.rows
  2462. this.changeMyString(data.rows)
  2463. this.$message({
  2464. message: '数据采集成功',
  2465. type: 'success',
  2466. duration: 1500
  2467. })
  2468. } else {
  2469. this.$message({
  2470. message: data.msg,
  2471. type: 'warning',
  2472. duration: 1500
  2473. })
  2474. }
  2475. this.loadFlag = false
  2476. })
  2477. },
  2478. // 根据项目数据采集
  2479. dataAcquisitionByItem (row) {
  2480. this.loadFlag = true
  2481. let tempDate = {
  2482. site: row.site,
  2483. buNo: row.buNo,
  2484. inspectionNo: row.inspectionNo,
  2485. templateId: row.templateId,
  2486. itemNo: row.itemNo,
  2487. flag: 'fai'
  2488. }
  2489. dataAcquisitionByItem(tempDate).then(({data}) => {
  2490. if (data.code === 0) {
  2491. this.changeMyString(data.rows)
  2492. this.$message({
  2493. message: '数据采集成功',
  2494. type: 'success',
  2495. duration: 1500
  2496. })
  2497. } else {
  2498. this.$message({
  2499. message: data.msg,
  2500. type: 'warning',
  2501. duration: 1500
  2502. })
  2503. }
  2504. this.loadFlag = false
  2505. })
  2506. },
  2507. // 获取用户角色
  2508. getUserRoleList () {
  2509. getUserRoleList().then(({data}) => {
  2510. if (data.code === 0) {
  2511. this.roleList = data.rows
  2512. } else {
  2513. this.roleList = []
  2514. }
  2515. })
  2516. },
  2517. // 获取协同人员列表
  2518. getOperatorList () {
  2519. this.operatorData.flag = '1'
  2520. this.operatorData.bu = this.detailData.site + '_' + this.detailData.buNo
  2521. if (this.roleList.length > 0) {
  2522. let filterList = this.roleList.filter(item => item.roleName === '机修人员')
  2523. if (filterList.length > 0) {
  2524. this.operatorData.roleId = filterList[0].roleId
  2525. } else {
  2526. this.operatorData.roleId = this.roleList[0].roleId
  2527. }
  2528. } else {
  2529. this.operatorData.roleId = ''
  2530. }
  2531. // 先清空缓存选中
  2532. this.$nextTick(() => this.$refs.operatorTable.clearSelection())
  2533. // 拿到选中的人员编号
  2534. let tempDataList = (this.detailData.operator == null ? '' : this.detailData.operator).split(';')
  2535. getOperatorList(this.operatorData).then(({data}) => {
  2536. if (data && data.code === 0) {
  2537. this.operatorList = data.rows
  2538. this.operatorList.forEach(val => {
  2539. // 回显选中
  2540. if (tempDataList.includes(val.adminID)) {
  2541. this.$nextTick(() => this.$refs.operatorTable.toggleRowSelection(val, true))
  2542. }
  2543. })
  2544. this.operatorModelFlag = true
  2545. } else {
  2546. this.$alert(data.msg, '错误', {
  2547. confirmButtonText: '确定'
  2548. })
  2549. }
  2550. })
  2551. },
  2552. // 获取责任人员列表
  2553. getResponsiblePersonList () {
  2554. this.operatorData.flag = '2'
  2555. this.operatorData.bu = this.detailData.site + '_' + this.detailData.buNo
  2556. // 先清空缓存选中
  2557. this.$nextTick(() => this.$refs.operatorTable.clearSelection())
  2558. // 拿到选中的人员编号
  2559. let tempDataList = (this.detailData.responsiblePerson == null ? '' : this.detailData.responsiblePerson).split(';')
  2560. getResponsibleOperatorList(this.operatorData).then(({data}) => {
  2561. if (data && data.code === 0) {
  2562. this.operatorList = data.rows
  2563. this.operatorList.forEach(val => {
  2564. // 回显选中
  2565. if (tempDataList.includes(val.adminID)) {
  2566. this.$nextTick(() => this.$refs.operatorTable.toggleRowSelection(val, true))
  2567. }
  2568. })
  2569. this.operatorModelFlag = true
  2570. } else {
  2571. this.$alert(data.msg, '错误', {
  2572. confirmButtonText: '确定'
  2573. })
  2574. }
  2575. })
  2576. },
  2577. // 查询机修人员列表
  2578. getOperatorList2 () {
  2579. if (this.operatorData.flag === '1') {
  2580. // 拿到选中的人员编号
  2581. let tempDataList = (this.detailData.operator == null ? '' : this.detailData.operator).split(';')
  2582. getOperatorList(this.operatorData).then(({data}) => {
  2583. if (data && data.code === 0) {
  2584. this.operatorList = data.rows
  2585. this.operatorList.forEach(val => {
  2586. // 回显选中的部门
  2587. if (tempDataList.includes(val.adminID)) {
  2588. this.$nextTick(() => this.$refs.operatorTable.toggleRowSelection(val, true))
  2589. }
  2590. })
  2591. } else {
  2592. this.operatorList = []
  2593. }
  2594. })
  2595. } else {
  2596. // 拿到选中的人员编号
  2597. let tempDataList = (this.detailData.responsiblePerson == null ? '' : this.detailData.responsiblePerson).split(';')
  2598. getResponsibleOperatorList(this.operatorData).then(({data}) => {
  2599. if (data && data.code === 0) {
  2600. this.operatorList = data.rows
  2601. this.operatorList.forEach(val => {
  2602. // 回显选中的部门
  2603. if (tempDataList.includes(val.adminID)) {
  2604. this.$nextTick(() => this.$refs.operatorTable.toggleRowSelection(val, true))
  2605. }
  2606. })
  2607. } else {
  2608. this.operatorList = []
  2609. }
  2610. })
  2611. }
  2612. },
  2613. // 点击行选中复选框
  2614. operatorClickRow (row) {
  2615. this.$refs.operatorTable.toggleRowSelection(row)
  2616. },
  2617. // 多选
  2618. selectionChangeHandle2 (val) {
  2619. this.dataListSelections2 = val
  2620. },
  2621. // 确认多选协同人员
  2622. confirmOperator () {
  2623. if (this.dataListSelections2.length === 0) {
  2624. this.$message.warning('请勾选人员!')
  2625. return
  2626. }
  2627. if (this.operatorData.flag === '1') {
  2628. for (let i = 0; i < this.dataListSelections2.length; i++) {
  2629. if (!this.detailData.operator.split(';').includes(this.dataListSelections2[i].adminID)) {
  2630. this.detailData.operatorName = this.detailData.operatorName + ";" + this.dataListSelections2[i].adminName
  2631. this.detailData.operator = this.detailData.operator + ";" + this.dataListSelections2[i].adminID
  2632. }
  2633. }
  2634. if (this.detailData.operator.charAt(0) === ';') {
  2635. this.detailData.operator = this.detailData.operator.substring(1)
  2636. this.detailData.operatorName = this.detailData.operatorName.substring(1)
  2637. }
  2638. } else {
  2639. for (let i = 0; i < this.dataListSelections2.length; i++) {
  2640. if (!this.detailData.responsiblePerson.split(';').includes(this.dataListSelections2[i].adminID)) {
  2641. this.detailData.responsiblePersonName = this.detailData.responsiblePersonName + ";" + this.dataListSelections2[i].adminName
  2642. this.detailData.responsiblePerson = this.detailData.responsiblePerson + ";" + this.dataListSelections2[i].adminID
  2643. }
  2644. }
  2645. if (this.detailData.responsiblePerson.charAt(0) === ';') {
  2646. this.detailData.responsiblePerson = this.detailData.responsiblePerson.substring(1)
  2647. this.detailData.responsiblePersonName = this.detailData.responsiblePersonName.substring(1)
  2648. }
  2649. }
  2650. this.operatorData = {
  2651. flag: '',
  2652. site: '',
  2653. bu: '',
  2654. adminID: '',
  2655. adminName: '',
  2656. roleName: '',
  2657. roleId: '',
  2658. userName: this.$store.state.user.name
  2659. }
  2660. this.operatorModelFlag = false
  2661. },
  2662. // bu内容改变事件
  2663. buChange () {
  2664. if (this.modalData.specialTaskFlag !== 'Y') { // 正常检验
  2665. this.modalData.templateId = ''
  2666. this.modalData.templateName = ''
  2667. } else { // 无工单检验
  2668. this.modalData.partNo = ''
  2669. this.modalData.partDesc = ''
  2670. this.modalData.invdefinetype = ''
  2671. this.modalData.sku = ''
  2672. this.modalData.cinvSourceCode = ''
  2673. this.modalData.templateId = ''
  2674. this.modalData.templateName = ''
  2675. }
  2676. },
  2677. // 获取用户的bu
  2678. getSiteAndBuByUserName () {
  2679. let tempData = {
  2680. username: this.$store.state.user.name,
  2681. }
  2682. getSiteAndBuByUserName(tempData).then(({data}) => {
  2683. if (data.code === 0) {
  2684. this.userBuList = data.rows
  2685. }
  2686. })
  2687. },
  2688. // 子明细导入
  2689. subDetailUpload () {
  2690. let currentData = {
  2691. flag: 'FAI',
  2692. site: this.detailData.site,
  2693. buNo: this.detailData.buNo,
  2694. inspectionNo: this.detailData.inspectionNo
  2695. }
  2696. //打开组件 去做新增业务
  2697. this.$nextTick(() => {
  2698. this.$refs.subDetailUpload.init(currentData)
  2699. })
  2700. },
  2701. // 查询单位
  2702. umSearch () {
  2703. let tempData = {
  2704. site: this.$store.state.user.site,
  2705. active: 'Y'
  2706. }
  2707. umSearch(tempData).then(({data}) => {
  2708. if (data.code === 0) {
  2709. this.umList = data.rows
  2710. }
  2711. })
  2712. },
  2713. // 标签号回车事件
  2714. rollNoEnter () {
  2715. const regex = /\(08\)(.*)/
  2716. const result = this.modalData.rollNo.match(regex)
  2717. let tempData = {
  2718. site: '',
  2719. bu: this.modalData.bu,
  2720. rollNo: result == null ? this.modalData.rollNo : result[1]
  2721. }
  2722. rollNoEnter(tempData).then(({data}) => {
  2723. if (data && data.code === 0) {
  2724. this.operationList = data.rows
  2725. this.modalData.seqNo = data.rows[0].seqNo
  2726. this.modalData.orderNo = data.rows[0].orderNo
  2727. this.modalData.operationDesc = data.rows[0].operationDesc
  2728. this.modalData.workCenterNo = data.rows[0].workCenterNo
  2729. this.modalData.resourceId = data.rows[0].resourceId
  2730. this.modalData.resourceDesc = data.rows[0].resourceDesc
  2731. this.modalData.partNo = data.rows[0].partNo
  2732. this.modalData.partDesc = data.rows[0].partDesc
  2733. this.modalData.invdefinetype = data.rows[0].invdefinetype
  2734. this.modalData.sku = data.rows[0].sku
  2735. this.modalData.cinvSourceCode = data.rows[0].cinvSourceCode
  2736. } else {
  2737. this.$alert(data.msg, '错误', {
  2738. confirmButtonText: '确定'
  2739. })
  2740. }
  2741. })
  2742. },
  2743. querySearchAsync (queryString, cb) {
  2744. clearTimeout(this.timeout)
  2745. let results = []
  2746. if (queryString === '') {
  2747. cb(results)
  2748. } else {
  2749. // 掉接口需要的参数
  2750. let find = {
  2751. rollNo: queryString, //上面输入框绑定的数据
  2752. site: this.$store.state.user.site,
  2753. }
  2754. // 这里去调后端的接口.根据自己接口的情况进行赋值
  2755. getRollNo(find).then(({data}) => {
  2756. if (data.code === 0) {
  2757. let result = data.rows
  2758. // 循环放到一个远程搜索需要的数组
  2759. for (let i = 0; i < result.length; i++) {
  2760. const element = result[i]
  2761. results.push({
  2762. value: element.rollNo,
  2763. seqNo: element.seqNo,
  2764. orderNo: element.orderNo
  2765. })
  2766. }
  2767. cb(results)
  2768. } else {
  2769. results = []
  2770. cb(results)
  2771. }
  2772. })
  2773. }
  2774. },
  2775. //点击出现搜索后点击的每一项
  2776. handleSelect (item) {
  2777. this.modalData.rollNo = item.value
  2778. this.modalData.seqNo = item.seqNo
  2779. this.modalData.orderNo = item.orderNo
  2780. this.getOperationList()
  2781. //this.getPartList()
  2782. },
  2783. // 获取处置措施列表
  2784. disposalMeasuresSearch () {
  2785. let tempData = {
  2786. inspectionTypeNo: '106'
  2787. }
  2788. disposalMeasuresSearch(tempData).then(({data}) => {
  2789. if (data.code === 0) {
  2790. this.disposalMeasuresOptions = data.rows
  2791. }
  2792. })
  2793. },
  2794. // 查询检验类型
  2795. inspectionTypeSearch () {
  2796. let tempData = {
  2797. site: this.$store.state.user.site
  2798. }
  2799. inspectionTypeSearch(tempData).then(({data}) => {
  2800. if (data.code === 0) {
  2801. this.typeOptions = data.rows
  2802. this.typeOptions.forEach(val => {
  2803. if (val.inspectionTypeName.includes('FAI')) {
  2804. this.templateData.inspectionTypeNo = val.inspectionTypeNo
  2805. this.templateData.inspectionTypeName = val.inspectionTypeName
  2806. }
  2807. })
  2808. }
  2809. })
  2810. },
  2811. // 获取基础数据列表S
  2812. getBaseList (val,type) {
  2813. this.tagNo = val
  2814. this.$nextTick(() => {
  2815. let strVal = ''
  2816. if (val === 1052) {
  2817. this.searchSeqInfo()
  2818. this.seqDetailFlag = true
  2819. }
  2820. if (val === 505) {
  2821. strVal = this.modalData.resourceDesc
  2822. this.$refs.baseList.init(val, strVal)
  2823. }
  2824. // if (val === 206) {
  2825. // strVal = this.modalData.partNo
  2826. // this.$refs.baseList.init(val, strVal)
  2827. // }
  2828. })
  2829. },
  2830. /* 列表方法的回调 */
  2831. getBaseData (val) {
  2832. if (this.tagNo === 1052) {
  2833. this.modalData.seqNo = val.seqno
  2834. this.modalData.orderNo = val.orderno
  2835. this.modalData.operationDesc = ''
  2836. this.modalData.resourceId = ''
  2837. this.getOperationList()
  2838. //this.getPartList()
  2839. }
  2840. if (this.tagNo === 505) {
  2841. this.modalData.resourceId = val.resource_id
  2842. this.modalData.resourceDesc = val.resource_desc
  2843. }
  2844. // if (this.tagNo === 206) {
  2845. // this.modalData.partNo = val.part_no
  2846. // this.modalData.partDesc = val.part_desc
  2847. // // 获取物料的其他信息
  2848. // this.getPartInformation()
  2849. // }
  2850. },
  2851. // // 获取物料其它信息
  2852. // getPartInformation () {
  2853. // getPartInformation(this.modalData).then(({data}) => {
  2854. // if (data && data.code === 0) {
  2855. // this.modalData.spec = data.rows[0].spec
  2856. // this.modalData.sku = data.rows[0].sku
  2857. // } else {
  2858. // this.$alert(data.msg, '错误', {
  2859. // confirmButtonText: '确定'
  2860. // })
  2861. // }
  2862. // })
  2863. // },
  2864. // 获取机台列表
  2865. getResourceList () {
  2866. // 判断是否为特殊任务,特殊任务的机台不随工序改变
  2867. if (this.modalData.specialTaskFlag === 'Y') {
  2868. return
  2869. } else {
  2870. getResourceList(this.modalData).then(({data}) => {
  2871. if (data && data.code === 0) {
  2872. //this.resourceList = data.rows
  2873. this.modalData.workCenterNo = data.rows[0].workCenterNo
  2874. this.modalData.resourceId = data.rows[0].resourceId
  2875. this.modalData.resourceDesc = data.rows[0].resourceDesc
  2876. } else {
  2877. this.$alert(data.msg, '错误', {
  2878. confirmButtonText: '确定'
  2879. })
  2880. }
  2881. })
  2882. }
  2883. },
  2884. // 获取工序列表
  2885. getOperationList () {
  2886. getOperationList(this.modalData).then(({data}) => {
  2887. if (data && data.code === 0) {
  2888. this.operationList = data.rows
  2889. this.modalData.operationDesc = data.rows[0].operationDesc
  2890. //this.getResourceList()
  2891. this.modalData.workCenterNo = data.rows[0].workCenterNo
  2892. this.modalData.resourceId = data.rows[0].resourceId
  2893. this.modalData.resourceDesc = data.rows[0].resourceDesc
  2894. this.modalData.partNo = data.rows[0].partNo
  2895. this.modalData.partDesc = data.rows[0].partDesc
  2896. this.modalData.invdefinetype = data.rows[0].invdefinetype
  2897. this.modalData.sku = data.rows[0].sku
  2898. this.modalData.cinvSourceCode = data.rows[0].cinvSourceCode
  2899. this.modalData.operationDesc = data.rows[0].operationDesc
  2900. this.modalData.qtyrequired = data.rows[0].qtyrequired
  2901. this.modalData.lotsize = data.rows[0].lotsize
  2902. } else {
  2903. this.$alert(data.msg, '错误', {
  2904. confirmButtonText: '确定'
  2905. })
  2906. }
  2907. })
  2908. },
  2909. // 获取物料列表
  2910. getPartList () {
  2911. getPartList(this.modalData).then(({data}) => {
  2912. if (data && data.code === 0) {
  2913. this.partList = data.rows
  2914. this.modalData.partNo = this.partList[0].partNo
  2915. this.modalData.partDesc = this.partList[0].partDesc
  2916. this.modalData.invdefinetype = this.partList[0].invdefinetype
  2917. this.modalData.sku = this.partList[0].sku
  2918. this.modalData.cinvSourceCode = this.partList[0].cinvSourceCode
  2919. } else {
  2920. this.$alert(data.msg, '错误', {
  2921. confirmButtonText: '确定'
  2922. })
  2923. }
  2924. })
  2925. },
  2926. // 是否新增特殊任务
  2927. changeSpecialTask () {
  2928. // 先重置数据
  2929. this.modalData = {
  2930. flag: '1',
  2931. site: '',
  2932. bu: this.userBuList[0].buNo,
  2933. inspectionNo: '',
  2934. partNo: '',
  2935. partDesc: '',
  2936. inspectionTypeNo: '',
  2937. inspectionTypeName: '',
  2938. inspectorNo: '',
  2939. inspectorName: '',
  2940. submit_flag: '',
  2941. orderNo: '',
  2942. operationDesc: '',
  2943. operationNo: '',
  2944. resourceId: '',
  2945. resourceDesc: '',
  2946. rollQty: '',
  2947. seqNo: '',
  2948. batchRollNo: '',
  2949. invdefinetype: '',
  2950. sku: '',
  2951. cinvSourceCode: '',
  2952. specialRequirements: '',
  2953. templateId: '',
  2954. templateName: '',
  2955. specialTaskFlag: '',
  2956. workCenterNo: '',
  2957. rollNo: '',
  2958. umId: this.umList[0].umId,
  2959. umName: this.umList[0].umName
  2960. }
  2961. // 获取选中框
  2962. let obj = document.getElementsByName('specialTask')
  2963. // 判断是否打勾
  2964. if (obj[0].checked) {
  2965. let tempData = {
  2966. site: '',
  2967. bu: this.modalData.bu
  2968. }
  2969. this.modalData.specialTaskFlag = 'Y'
  2970. // 获取特殊工序列表
  2971. getSpecialOperationList(tempData).then(({data}) => {
  2972. if (data && data.code === 0) {
  2973. this.operationList = data.rows
  2974. } else {
  2975. this.$alert(data.msg, '错误', {
  2976. confirmButtonText: '确定'
  2977. })
  2978. }
  2979. })
  2980. // 派工单和工单号赋值
  2981. this.modalData.seqNo = '000#1TSGD'
  2982. this.modalData.orderNo = '000#1'
  2983. } else {
  2984. this.operationList = []
  2985. this.modalData.specialTaskFlag = ''
  2986. }
  2987. },
  2988. // 新增FAI巡检记录
  2989. saveData () {
  2990. if (this.modalData.bu === '' || this.modalData.bu == null) {
  2991. this.$message.warning('请选择BU!')
  2992. return
  2993. }
  2994. if (this.modalData.seqNo === '' || this.modalData.seqNo == null) {
  2995. this.$message.warning('请选择派工单!')
  2996. return
  2997. }
  2998. if (this.modalData.orderNo === '' || this.modalData.orderNo == null) {
  2999. this.$message.warning('请选择工单!')
  3000. return
  3001. }
  3002. if (this.modalData.specialTaskFlag !== 'Y' && (this.modalData.partNo === '' || this.modalData.partNo == null)) {
  3003. this.$message.warning('请选择物料!')
  3004. return
  3005. }
  3006. if (this.modalData.operationDesc === '' || this.modalData.operationDesc == null) {
  3007. this.$message.warning('请选择工序!')
  3008. return
  3009. }
  3010. if (this.modalData.specialTaskFlag !== 'Y' && (this.modalData.resourceId === '' || this.modalData.resourceId == null)) {
  3011. this.$message.warning('请选择机台!')
  3012. return
  3013. }
  3014. if (this.modalData.rollQty === '' || this.modalData.rollQty == null) {
  3015. this.$message.warning('请填写送检数量!')
  3016. return
  3017. }
  3018. if (this.modalData.umId === '' || this.modalData.umId == null) {
  3019. this.$message.warning('请选择单位!')
  3020. return
  3021. }
  3022. if (this.controlData.baseData === '控制' && (this.modalData.templateId == null || this.modalData.templateId === '')) {
  3023. this.$message.warning('请选择检验模板!')
  3024. return
  3025. }
  3026. this.saveLoading = true
  3027. if (this.modalData.flag === '1') {
  3028. saveFAIInspection(this.modalData).then(({data}) => {
  3029. if (data && data.code === 0) {
  3030. this.getDataList()
  3031. this.operationList = []
  3032. this.resourceList = []
  3033. this.partList = []
  3034. this.modalFlag = false
  3035. this.$message({
  3036. message: '操作成功',
  3037. type: 'success',
  3038. duration: 1500,
  3039. onClose: () => {}
  3040. })
  3041. } else {
  3042. this.$alert(data.msg, '错误', {
  3043. confirmButtonText: '确定'
  3044. })
  3045. }
  3046. this.saveLoading = false
  3047. }).catch(()=>{
  3048. this.saveLoading = false
  3049. })
  3050. }
  3051. },
  3052. // 检查动控是否开启
  3053. queryController () {
  3054. let tempData = {
  3055. controlNo: '10004',
  3056. site: this.$store.state.user.site,
  3057. }
  3058. queryController(tempData).then(({data}) => {
  3059. if (data && data.code === 0) {
  3060. this.controlData = data.rows
  3061. } else {
  3062. this.$alert(data.msg, '错误', {
  3063. confirmButtonText: '确定'
  3064. })
  3065. }
  3066. })
  3067. },
  3068. // 新增
  3069. addModal () {
  3070. this.modalData = {
  3071. flag: '1',
  3072. site: '',
  3073. bu: this.userBuList[0].buNo,
  3074. inspectionNo: '',
  3075. partNo: '',
  3076. partDesc: '',
  3077. inspectionTypeNo: '106',
  3078. inspectionTypeName: '',
  3079. inspectorNo: '',
  3080. inspectorName: '',
  3081. submit_flag: '',
  3082. orderNo: '',
  3083. operationDesc: '',
  3084. operationNo: '',
  3085. resourceId: '',
  3086. resourceDesc: '',
  3087. rollQty: '',
  3088. seqNo: '',
  3089. batchRollNo: '',
  3090. invdefinetype: '',
  3091. sku: '',
  3092. cinvSourceCode: '',
  3093. specialRequirements: '',
  3094. templateId: '',
  3095. templateName: '',
  3096. specialTaskFlag: '',
  3097. workCenterNo: '',
  3098. rollNo: '',
  3099. umId: this.umList[0].umId,
  3100. umName: this.umList[0].umName,
  3101. sjzs: '',
  3102. }
  3103. this.operationList = []
  3104. this.resourceList = []
  3105. this.partList = []
  3106. this.modalFlag = true
  3107. this.checked = false
  3108. },
  3109. // 获取检验模板列表
  3110. queryTemplateList () {
  3111. this.templateData.bu = this.modalData.bu
  3112. // 查询所有检验模板
  3113. queryTemplateList(this.templateData).then(({data}) => {
  3114. if (data && data.code === 0) {
  3115. this.templateList = data.rows
  3116. this.templateModelFlag = true
  3117. }else {
  3118. this.$alert(data.msg, '错误', {
  3119. confirmButtonText: '确定'
  3120. })
  3121. }
  3122. })
  3123. },
  3124. // 获取物料列表
  3125. queryPartList () {
  3126. this.partData.bu = this.modalData.bu
  3127. // 查询所有物料
  3128. if (this.partData.partNo === '' && this.partData.partDesc === '' && this.partData.sku === '' && this.partData.cinvSourceCode === '') {
  3129. this.partList = []
  3130. this.partModelFlag = true
  3131. } else {
  3132. queryPartList(this.partData).then(({data}) => {
  3133. if (data && data.code === 0) {
  3134. this.partList = data.rows
  3135. this.partModelFlag = true
  3136. }else {
  3137. this.$alert(data.msg, '错误', {
  3138. confirmButtonText: '确定'
  3139. })
  3140. }
  3141. })
  3142. }
  3143. },
  3144. // 选中检验模板
  3145. getRowData (row) {
  3146. this.modalData.templateId = row.templateId
  3147. this.modalData.templateName = row.templateName
  3148. this.templateModelFlag = false
  3149. },
  3150. // 选中派工单号
  3151. getRowData1 (row) {
  3152. this.modalData.sku = row.sku
  3153. this.modalData.partNo = row.partNo
  3154. this.modalData.partDesc = row.partDesc
  3155. this.modalData.orderNo = row.orderNo
  3156. this.modalData.seqNo = row.seqNo
  3157. this.modalData.lotsize = row.lotsize
  3158. this.modalData.operationDesc = row.operationDesc
  3159. this.modalData.qtyrequired = row.qtyrequired
  3160. this.modalData.rollQty = row.qtyrequired
  3161. this.modalData.sjzs = row.sjzs
  3162. this.getOperationList()
  3163. //查询物料对应的模板
  3164. let params = {
  3165. site: this.modalData.bu.split('_')[0],
  3166. buNo: this.modalData.bu.split('_')[1],
  3167. partNo: this.modalData.partNo,
  3168. attributeNo: this.modalData.partNo,
  3169. partDesc: this.modalData.partDesc,
  3170. attributeType: 'A',
  3171. inspectionTypeNo: '106'
  3172. }
  3173. searchPartAttributeDetails(params).then(({data}) => {
  3174. if (data.total = 1){
  3175. this.modalData.templateId = data.rows[0].templateId
  3176. this.modalData.templateName = data.rows[0].templateName
  3177. }
  3178. })
  3179. this.seqDetailFlag = false
  3180. },
  3181. // 选中物料
  3182. getRowData2 (row) {
  3183. this.modalData.partNo = row.partNo
  3184. this.modalData.partDesc = row.partDesc
  3185. this.modalData.sku = row.sku
  3186. this.modalData.cinvSourceCode = row.cinvSourceCode
  3187. this.modalData.invdefinetype = row.invdefinetype
  3188. this.partData = {
  3189. site: '',
  3190. bu: '',
  3191. partNo: '',
  3192. partDesc: '',
  3193. sku: '',
  3194. cinvSourceCode: '',
  3195. }
  3196. this.partModelFlag = false
  3197. },
  3198. selectFlag () {
  3199. return true
  3200. },
  3201. // 单机选中
  3202. FAIClickRow (row) {
  3203. this.$refs.FAITable.toggleRowSelection(row)
  3204. },
  3205. // 复选
  3206. selectionFAI (val) {
  3207. this.FAISelections = val
  3208. },
  3209. //刷新派设备文档的列表
  3210. getFileContentData (row) {
  3211. let currentData = {
  3212. orderRef1: row.site,
  3213. orderRef2: row.inspectionNo,
  3214. orderRef4: row.buNo,
  3215. partNo: row.partNo
  3216. }
  3217. this.fileLoading = true
  3218. getInspectionFile(currentData).then(({data}) => {
  3219. // 区分请求成功和失败的状况
  3220. if (data && data.code === 0) {
  3221. this.fileContentList = data.rows
  3222. } else {
  3223. this.fileContentList = []
  3224. }
  3225. this.fileLoading = false
  3226. }).catch(()=>{
  3227. this.fileLoading = false
  3228. })
  3229. this.fileFlag = true
  3230. },
  3231. /*新增文件的modal*/
  3232. addUploadFileModal () {
  3233. let currentData = {
  3234. titleCon: 'FAI文件上传',
  3235. site: this.detailData.site,
  3236. buNo: this.detailData.buNo,
  3237. createBy: this.$store.state.user.name,
  3238. inspectionNo: this.detailData.inspectionNo,
  3239. remark: '',
  3240. folder: 'qcFAI',
  3241. }
  3242. //打开组件 去做新增业务
  3243. this.$nextTick(() => {
  3244. this.$refs.qcFAIUploadFile.init(currentData)
  3245. })
  3246. },
  3247. // 上传项目图片
  3248. uploadImageModal (row) {
  3249. let currentData = {
  3250. site: this.detailData.site,
  3251. buNo: this.detailData.buNo,
  3252. createBy: this.$store.state.user.name,
  3253. inspectionNo: this.detailData.inspectionNo,
  3254. itemNo: row.itemNo,
  3255. folder: 'FAIItemImageFile'
  3256. }
  3257. //打开组件 去做新增业务
  3258. this.$nextTick(() => {
  3259. this.$refs.comQcItemImageUploadFile.init(currentData)
  3260. })
  3261. },
  3262. // 查询质检员信息列表
  3263. inspectorSearch () {
  3264. inspectorSearch().then(({data}) => {
  3265. if (data.code === 0) {
  3266. this.options = data.rows
  3267. }
  3268. })
  3269. },
  3270. // 获取主信息数据列表
  3271. getDataList () {
  3272. this.searchLoading = true
  3273. this.searchData.limit = this.pageSize
  3274. this.searchData.page = this.pageIndex
  3275. qcFAIInspectionSearch(this.searchData).then(({data}) => {
  3276. if (data.code === 0) {
  3277. this.dataList = data.page.list
  3278. this.pageIndex = data.page.currPage
  3279. this.pageSize = data.page.pageSize
  3280. this.totalPage = data.page.totalCount
  3281. this.searchLoading = false
  3282. } else {
  3283. this.searchLoading = false
  3284. }
  3285. }).catch(()=>{
  3286. this.searchLoading = false
  3287. })
  3288. },
  3289. // 每页数
  3290. sizeChangeHandle (val) {
  3291. this.pageSize = val
  3292. this.pageIndex = 1
  3293. this.getDataList()
  3294. },
  3295. // 当前页
  3296. currentChangeHandle (val) {
  3297. this.pageIndex = val
  3298. this.getDataList()
  3299. },
  3300. // 子明细每页数
  3301. sizeChangeHandle2 (val) {
  3302. this.pageSize2 = val
  3303. },
  3304. // 子明细当前页
  3305. currentChangeHandle2 (val) {
  3306. this.pageIndex2 = val
  3307. },
  3308. // 多选
  3309. selectionChangeHandle (val) {
  3310. this.dataListSelections = val
  3311. },
  3312. // 删除检验记录
  3313. deleteModal () {
  3314. if (this.FAISelections.length === 0) {
  3315. this.$alert('请勾选要删除的检验单!', '提示', {
  3316. confirmButtonText: '确定'
  3317. })
  3318. return false
  3319. }
  3320. this.$confirm(`是否删除该 `+ this.FAISelections.length +` 条检验记录?`, '提示', {
  3321. confirmButtonText: '确定',
  3322. cancelButtonText: '取消',
  3323. type: 'warning'
  3324. }).then(() => {
  3325. let tempData = {
  3326. site: '',
  3327. submitList: this.FAISelections
  3328. }
  3329. faiRecordDelete(tempData).then(({data}) => {
  3330. if (data && data.code === 0) {
  3331. this.getDataList()
  3332. this.FAISelections = []
  3333. this.$message({
  3334. message: '操作成功',
  3335. type: 'success',
  3336. duration: 1500,
  3337. onClose: () => {}
  3338. })
  3339. } else {
  3340. this.$alert(data.msg, '错误', {
  3341. confirmButtonText: '确定'
  3342. })
  3343. }
  3344. })
  3345. }).catch(() => {
  3346. })
  3347. },
  3348. Transfer (type) {
  3349. if (type === '2') {
  3350. if (this.detailData.inspectionResult === '' || this.detailData.inspectionResult == null) {
  3351. this.$message.warning('请选择检验结论!')
  3352. return
  3353. }
  3354. if (this.detailData.inspectionResult === '不合格' && (this.detailData.disposalMeasures == null || this.detailData.disposalMeasures === '')) {
  3355. this.$message.warning('请选择处置措施!')
  3356. return
  3357. }
  3358. if (this.detailList.length > 0 && this.detailData.inspectionResult === '不合格') {
  3359. const flag = this.detailList.some(item => item.itemResult === 'N')
  3360. if (!flag) {
  3361. this.$message.warning('请选择不合格项目!')
  3362. return
  3363. }
  3364. }
  3365. if (this.detailData.inspectionResult !== '不合格') {
  3366. this.detailData.disposalMeasures = ''
  3367. this.detailData.disposalRemark = ''
  3368. }
  3369. }
  3370. this.saveDetailInformation(type)
  3371. },
  3372. // 新增明细信息
  3373. saveDetailInformation (type) {
  3374. this.saveInformationData.site = this.detailData.site
  3375. this.saveInformationData.buNo = this.detailData.buNo
  3376. this.saveInformationData.inspectionNo = this.detailData.inspectionNo
  3377. this.saveInformationData.disposalMeasures = this.detailData.disposalMeasures
  3378. this.saveInformationData.disposalRemark = this.detailData.disposalRemark
  3379. this.saveInformationData.inspectorNo = this.$store.state.user.name
  3380. this.saveInformationData.inspectionResult = this.detailData.inspectionResult
  3381. this.saveInformationData.inspectionRemark = this.detailData.inspectionRemark
  3382. this.saveInformationData.rollQty = this.detailData.rollQty
  3383. this.saveInformationData.samplingQty = this.detailData.samplingQty
  3384. this.saveInformationData.unqualifiedQty = this.detailData.unqualifiedQty
  3385. this.saveInformationData.partNo = this.detailData.partNo
  3386. this.saveInformationData.partDesc = this.detailData.partDesc
  3387. this.saveInformationData.operator = this.detailData.operator
  3388. this.saveInformationData.responsiblePerson = this.detailData.responsiblePerson
  3389. this.saveInformationData.itemList = JSON.parse(JSON.stringify(this.detailList))
  3390. this.saveInformationData.passQty = this.detailData.passQty == null ? 0 : this.detailData.passQty
  3391. this.saveInformationData.notPassQty = this.detailData.notPassQty == null ? 0 : this.detailData.notPassQty
  3392. this.saveInformationData.batchQualifiedQty = this.detailData.batchQualifiedQty == null ? 0 : this.detailData.batchQualifiedQty
  3393. this.saveInformationData.type = type
  3394. this.transferLoadFlag = true
  3395. // this.saveInformationData.subDetailList = this.acquisitionList
  3396. saveFAIDetailedRecord(this.saveInformationData).then(({data}) => {
  3397. if (data && data.code === 0) {
  3398. this.getDataList()
  3399. this.detailInformationFlag = false
  3400. this.$message({
  3401. message: '操作成功',
  3402. type: 'success',
  3403. duration: 1500,
  3404. onClose: () => {}
  3405. })
  3406. } else {
  3407. this.$alert(data.msg, '错误', {
  3408. confirmButtonText: '确定'
  3409. })
  3410. }
  3411. this.transferLoadFlag = false
  3412. }).catch(()=>{
  3413. this.transferLoadFlag = false
  3414. })
  3415. },
  3416. // 开始检验
  3417. actionModal (row) {
  3418. this.actionData = {
  3419. site: row.site,
  3420. buNo: row.buNo,
  3421. inspectionNo: row.inspectionNo
  3422. }
  3423. getFAIItemObjectList(this.actionData).then(({data}) => {
  3424. if (data && data.code === 0) {
  3425. if (data.rows.length === 0) {
  3426. this.actionModal2()
  3427. } else {
  3428. this.itemObjectList = data.rows
  3429. this.ItemObjectModelFlag = true
  3430. }
  3431. } else {
  3432. this.$alert(data.msg, '错误', {
  3433. confirmButtonText: '确定'
  3434. })
  3435. }
  3436. })
  3437. },
  3438. // 开始检验
  3439. actionModal2 () {
  3440. this.$confirm(`确认开始检验?`, '提示', {
  3441. confirmButtonText: '确定',
  3442. cancelButtonText: '取消',
  3443. type: 'warning'
  3444. }).then(() => {
  3445. let tempData = {
  3446. site: this.actionData.site,
  3447. buNo: this.actionData.buNo,
  3448. inspectionNo: this.actionData.inspectionNo,
  3449. actionBy: this.$store.state.user.name,
  3450. state: '待检验',
  3451. equipmentList: this.itemObjectList
  3452. }
  3453. actionFAIInspection(tempData).then(({data}) => {
  3454. if (data && data.code === 0) {
  3455. this.getDataList()
  3456. this.$message({
  3457. message: '操作成功',
  3458. type: 'success',
  3459. duration: 1500,
  3460. onClose: () => {}
  3461. })
  3462. this.ItemObjectModelFlag = false
  3463. } else {
  3464. this.$alert(data.msg, '错误', {
  3465. confirmButtonText: '确定'
  3466. })
  3467. }
  3468. })
  3469. })
  3470. },
  3471. // 明细记录信息查询
  3472. detailModal (row) {
  3473. this.detailData.site = row.site
  3474. this.detailData.buNo = row.buNo
  3475. this.detailData.inspectionNo = row.inspectionNo
  3476. this.detailData.partNo = row.partNo
  3477. this.detailData.partDesc = row.partDesc
  3478. this.detailData.rollQty = row.rollQty
  3479. this.detailData.samplingQty = row.samplingQty
  3480. this.detailData.unqualifiedQty = row.unqualifiedQty
  3481. this.detailData.unqualifiedQuantity = row.unqualifiedQuantity
  3482. this.detailData.submitFlag = row.submitFlag
  3483. this.detailData.disposalMeasures = row.disposalMeasures
  3484. this.detailData.disposalRemark = row.disposalRemark
  3485. this.detailData.inspectionResult = row.inspectionResult
  3486. this.detailData.inspectorNo = row.inspectorNo
  3487. this.detailData.inspectorName = row.inspectorName
  3488. this.detailData.inspectionRemark = row.inspectionRemark
  3489. this.detailData.cinvSourceCode = row.cinvSourceCode
  3490. this.detailData.sku = row.sku
  3491. this.detailData.invdefinetype = row.invdefinetype
  3492. this.detailData.umId = row.umId
  3493. this.detailData.umName = row.umName
  3494. this.detailData.operator = row.operator
  3495. this.detailData.operatorName = row.operatorName
  3496. this.detailData.responsiblePerson = row.responsiblePerson
  3497. this.detailData.responsiblePersonName = row.responsiblePersonName
  3498. this.detailData.state = row.state
  3499. if (row.state === '待检验') {
  3500. this.detailData.passQty = row.samplingQty
  3501. } else {
  3502. this.detailData.passQty = row.passQty
  3503. this.detailData.notPassQty = row.notPassQty
  3504. }
  3505. this.detailData.batchQualifiedQty = row.batchQualifiedQty
  3506. this.getInspectionFormData()
  3507. this.inspectorSearch()
  3508. // this.acquisitionList = []
  3509. this.detailInformationFlag = true
  3510. },
  3511. // 检验单明细
  3512. getInspectionFormData () {
  3513. faiDetailSearch(this.detailData).then(({data}) => {
  3514. if (data && data.code === 0) {
  3515. this.detailList = data.rows
  3516. } else {
  3517. this.detailList = []
  3518. }
  3519. })
  3520. },
  3521. // 子明细记录信息查询
  3522. subDetailModal (row) {
  3523. this.subDetailLoading = true
  3524. this.subDetailData = row
  3525. this.pageIndex2 = 1
  3526. selectFAISubDetailedRecord(this.subDetailData).then(({data}) => {
  3527. if (data.code === 0) {
  3528. this.tableData = data.rows
  3529. }
  3530. this.subDetailLoading = false
  3531. }).catch(()=>{
  3532. this.subDetailLoading = false
  3533. })
  3534. this.batchAddData = {
  3535. samplingLocation: '',
  3536. samplingLocationB: '',
  3537. samplingNumber: ''
  3538. }
  3539. this.subDetailFlag = true
  3540. },
  3541. // 子明细分页查询
  3542. subDetailModal2 () {
  3543. selectFAISubDetailedRecord(this.subDetailData).then(({data}) => {
  3544. if (data.code === 0) {
  3545. this.tableData = data.rows
  3546. }
  3547. })
  3548. },
  3549. // 审核按钮
  3550. submitResult () {
  3551. let tempData1 = '' // 记录不是待审核状态的单号
  3552. let tempData2 = '' // 记录处置措施未填写的单号
  3553. if (this.FAISelections.length === 0) {
  3554. this.$alert('请勾选要审核的检验单!', '提示', {
  3555. confirmButtonText: '确定'
  3556. })
  3557. return false
  3558. }
  3559. for (let i = 0; i < this.FAISelections.length; i++) {
  3560. if (this.FAISelections[i].state !== '待审核') {
  3561. tempData1 = tempData1 + this.FAISelections[i].inspectionNo + '、'
  3562. }
  3563. if (this.FAISelections[i].inspectionResult === '不合格' && (this.FAISelections[i].disposalMeasures === '' || this.FAISelections[i].disposalMeasures == null)) {
  3564. tempData2 = tempData2 + this.FAISelections[i].inspectionNo + '、'
  3565. }
  3566. }
  3567. if (tempData1 !== '') {
  3568. tempData1 = tempData1.substring(0, tempData1.length - 1)
  3569. this.$alert('检验单号 ' + tempData1 + ' 不是待审核状态!', '提示', {
  3570. confirmButtonText: '确定'
  3571. })
  3572. return false
  3573. }
  3574. if (tempData2 !== '') {
  3575. tempData2 = tempData2.substring(0, tempData2.length - 1)
  3576. this.$alert('检验单号 ' + tempData2 + ' 的处置措施未选择!', '提示', {
  3577. confirmButtonText: '确定'
  3578. })
  3579. return false
  3580. }
  3581. this.$confirm(`已确认单据信息无误,确定审核该 ` + this.FAISelections.length + ` 条记录`, '提示', {
  3582. confirmButtonText: '确定',
  3583. cancelButtonText: '取消',
  3584. type: 'warning'
  3585. }).then(() => {
  3586. this.submitData.submitList = this.FAISelections
  3587. saveFAISubmitResult(this.submitData).then(({data}) => {
  3588. if (data && data.code === 0) {
  3589. this.getDataList()
  3590. this.FAISelections = []
  3591. this.$message({
  3592. message: '操作成功',
  3593. type: 'success',
  3594. duration: 1500,
  3595. onClose: () => {}
  3596. })
  3597. } else {
  3598. this.$alert(data.msg, '错误', {
  3599. confirmButtonText: '确定'
  3600. })
  3601. }
  3602. })
  3603. })
  3604. },
  3605. // 取消审核
  3606. cancelApproval () {
  3607. let tempData1 = '' // 记录不是已完成状态的单号
  3608. if (this.FAISelections.length === 0) {
  3609. this.$message.warning('请勾选要取消审核的检验单!')
  3610. return
  3611. }
  3612. for (let i = 0; i < this.FAISelections.length; i++) {
  3613. if (this.FAISelections[i].state !== '已完成') {
  3614. tempData1 = tempData1 + this.FAISelections[i].inspectionNo + '、'
  3615. }
  3616. }
  3617. if (tempData1 !== '') {
  3618. tempData1 = tempData1.substring(0, tempData1.length - 1)
  3619. this.$message.warning('检验单号 ' + tempData1 + ' ,不是已完成状态!')
  3620. return
  3621. }
  3622. this.$confirm(`确定取消审核该 ` + this.FAISelections.length + ` 条记录`, '提示', {
  3623. confirmButtonText: '确定',
  3624. cancelButtonText: '取消',
  3625. type: 'warning'
  3626. }).then(() => {
  3627. this.submitData.submitList = this.FAISelections
  3628. cancelApproval2(this.submitData).then(({data}) => {
  3629. if (data && data.code === 0) {
  3630. this.getDataList()
  3631. this.FAISelections = []
  3632. this.$message({
  3633. message: '操作成功',
  3634. type: 'success',
  3635. duration: 1500,
  3636. onClose: () => {}
  3637. })
  3638. } else {
  3639. this.$alert(data.msg, '错误', {
  3640. confirmButtonText: '确定'
  3641. })
  3642. }
  3643. })
  3644. })
  3645. },
  3646. // 子明细方法
  3647. //表格的新增
  3648. rowClassName ({ row, rowIndex }) {
  3649. row.xh = rowIndex + 1
  3650. row.num = this.tableData.indexOf(row) + 1
  3651. },
  3652. //单选框选中数据
  3653. handleDetailSelectionChange (selection) {
  3654. this.checkedDetail = selection
  3655. },
  3656. //点击新增更多
  3657. handleAddBtn (td) {
  3658. checkFAIIsSubmit(td).then(({data}) => {
  3659. if (data.flag !== 1) {
  3660. let obj = {
  3661. subDetailValue: '',
  3662. samplingLocation: '',
  3663. samplingLocationB: '',
  3664. subDetailValueB: '',
  3665. subDetailValueC: '',
  3666. subDetailValueD: '',
  3667. subDetailValueE: '',
  3668. }
  3669. this.tableData.push(obj)
  3670. } else {
  3671. this.$alert("记录已提交!", '错误', {
  3672. confirmButtonText: '确定'
  3673. })
  3674. }
  3675. })
  3676. },
  3677. // 批量新增操作
  3678. batchHandleAdd (td) {
  3679. checkFAIIsSubmit(td).then(({data}) => {
  3680. if (data.flag !== 1) {
  3681. this.batchHandleAddModalFlag = true
  3682. } else {
  3683. this.$alert("记录已提交!", '错误', {
  3684. confirmButtonText: '确定'
  3685. })
  3686. }
  3687. })
  3688. },
  3689. // 批量新增行
  3690. batchHandleAddModal () {
  3691. for (let i = 0; i < this.batchAddData.samplingNumber; i++) {
  3692. let obj = {
  3693. samplingLocation: this.batchAddData.samplingLocation,
  3694. samplingLocationB: this.batchAddData.samplingLocationB,
  3695. subDetailValue: '',
  3696. subDetailValueB: '',
  3697. subDetailValueC: '',
  3698. subDetailValueD: '',
  3699. subDetailValueE: '',
  3700. }
  3701. this.tableData.push(obj)
  3702. }
  3703. this.batchHandleAddModalFlag = false
  3704. },
  3705. // 回车事件
  3706. nextFocus1 (index) {
  3707. let a1 = `${index + 1}` + `a`
  3708. this.$nextTick(() => {
  3709. this.$refs[a1].focus()
  3710. })
  3711. },
  3712. nextFocus2 (index) {
  3713. let a2 = `${index + 1}` + `b`
  3714. this.$nextTick(() => {
  3715. this.$refs[a2].focus()
  3716. })
  3717. },
  3718. nextFocus3 (index) {
  3719. let a3 = `${index + 1}` + `c`
  3720. this.$nextTick(() => {
  3721. this.$refs[a3].focus()
  3722. })
  3723. },
  3724. nextFocus4 (index) {
  3725. let a = `${index + 1}` + `d`
  3726. this.$nextTick(() => {
  3727. this.$refs[a].focus()
  3728. })
  3729. },
  3730. nextFocus5 (index) {
  3731. let a = `${index + 1}` + `e`
  3732. this.$nextTick(() => {
  3733. this.$refs[a].focus()
  3734. })
  3735. },
  3736. nextFocus6 (index) {
  3737. let a = `${index + 1}` + `f`
  3738. this.$nextTick(() => {
  3739. this.$refs[a].focus()
  3740. })
  3741. },
  3742. nextFocus7 (index) {
  3743. let a = `${index + 1}` + `g`
  3744. this.$nextTick(() => {
  3745. this.$refs[a].focus()
  3746. })
  3747. },
  3748. focusNextInput(index, type) {
  3749. let aaa = ''
  3750. if (this.detailList.length - 1 === index) {
  3751. aaa = `${type}0`
  3752. } else {
  3753. aaa = `${type}${index + 1}`
  3754. }
  3755. this.$nextTick(() => {
  3756. this.$refs[aaa].focus()
  3757. })
  3758. },
  3759. updateItemResult(row){
  3760. if (row.maxValue == null && row.minValue == null&&row.defaultValue==null) {
  3761. return;
  3762. }
  3763. if (row.maxValue == null && row.minValue == null) {
  3764. if (row.numberValue!=row.defaultValue){
  3765. row.itemResult = 'N'
  3766. }
  3767. }else if (row.maxValue != null && row.minValue != null){
  3768. if (row.numberValue>row.maxValue ||row.numberValue<row.minValue){
  3769. row.itemResult = 'N'
  3770. }else {
  3771. row.itemResult = 'Y'
  3772. }
  3773. }else if(row.maxValue != null){
  3774. if ( row.numberValue>row.maxValue) {
  3775. row.itemResult = 'N'
  3776. }else {
  3777. row.itemResult = 'Y'
  3778. }
  3779. }else if(row.minValue != null){
  3780. if ( row.numberValue<row.minValue) {
  3781. row.itemResult = 'N'
  3782. }else {
  3783. row.itemResult = 'Y'
  3784. }
  3785. }
  3786. },
  3787. //删除
  3788. handleDeleteBtn (td) {
  3789. checkFAIIsSubmit(td).then(({data}) => {
  3790. if (data.flag !== 1) {
  3791. if (this.checkedDetail.length === 0) {
  3792. this.$alert("请先选择要删除的数据", "提示", {
  3793. confirmButtonText: "确定",
  3794. })
  3795. } else {
  3796. this.$confirm("请是否确认删除该子明细记录?", "提示", {
  3797. confirmButtonText: "确定",
  3798. cancelButtonText: "取消",
  3799. type: "warning",
  3800. callback: (action) => {
  3801. if (action === "confirm") {
  3802. let val = this.checkedDetail
  3803. val.forEach((val, index) => {
  3804. this.tableData.splice(this.tableData.indexOf(val), 1)
  3805. if (this.templateTableData.length === 0) {
  3806. this.pageIndex2--
  3807. }
  3808. })
  3809. this.$message({
  3810. message: "删除成功!",
  3811. type: "success",
  3812. })
  3813. return
  3814. } else {
  3815. this.$message({
  3816. message: "已取消删除操作",
  3817. type: "warning",
  3818. })
  3819. return
  3820. }
  3821. },
  3822. })
  3823. }
  3824. } else {
  3825. this.$alert("记录已提交!", '错误', {
  3826. confirmButtonText: '确定'
  3827. })
  3828. }
  3829. })
  3830. },
  3831. // 新增子明细记录
  3832. saveSubDetailResult () {
  3833. for (let i = 0; i < this.tableData.length; i++) {
  3834. if (this.tableData[i].subDetailValue === '' || this.tableData[i].subDetailValue == null) {
  3835. this.$message.warning('序号' + (i+1) +'未填写实测值!')
  3836. return
  3837. }
  3838. }
  3839. this.subDetailData.subDetailValues = this.tableData
  3840. this.subDetailVisiable = true
  3841. saveFAISubDetailed(this.subDetailData).then(({data}) => {
  3842. if (data && data.code === 0) {
  3843. if (data.count > 0) {
  3844. this.subDetailData.itemResult = 'N'
  3845. this.subDetailData.unqualifiedQuantity = data.count
  3846. }
  3847. if (this.subDetailData.subDetailValues.length > 0) {
  3848. this.subDetailData.subDetailRecordNum = 1
  3849. } else {
  3850. this.subDetailData.subDetailRecordNum = -1
  3851. this.subDetailData.unqualifiedQuantity = 0
  3852. this.subDetailData.itemResult = 'Y'
  3853. }
  3854. this.subDetailFlag = false
  3855. this.tableData = []
  3856. this.$message({
  3857. message: '操作成功',
  3858. type: 'success',
  3859. duration: 1500,
  3860. onClose: () => {}
  3861. })
  3862. } else {
  3863. this.$alert(data.msg, '错误', {
  3864. confirmButtonText: '确定'
  3865. })
  3866. }
  3867. }).finally(() => {
  3868. this.subDetailVisiable = false
  3869. })
  3870. },
  3871. // 检验结论改变事件
  3872. resultChange () {
  3873. if (this.detailData.inspectionResult === '不合格') {
  3874. this.detailData.passQty = 0
  3875. }
  3876. },
  3877. // 校验用户是否收藏
  3878. favoriteIsOk () {
  3879. let userFavorite = {
  3880. userId: this.$store.state.user.id,
  3881. languageCode: this.$i18n.locale
  3882. }
  3883. userFavoriteList(userFavorite).then(({data}) => {
  3884. for (let i = 0; i < data.list.length; i++) {
  3885. if (this.$route.meta.menuId === data.list[i].menuId) {
  3886. this.favorite = true
  3887. }
  3888. }
  3889. })
  3890. },
  3891. // 收藏 OR 取消收藏
  3892. favoriteFunction () {
  3893. let userFavorite = {
  3894. userId: this.$store.state.user.id,
  3895. functionId: this.$route.meta.menuId,
  3896. }
  3897. if (this.favorite) {
  3898. removeUserFavorite(userFavorite).then(({data}) => {
  3899. this.$message.success(data.msg)
  3900. this.favorite = false
  3901. })
  3902. } else {
  3903. // 收藏
  3904. saveUserFavorite(userFavorite).then(({data}) => {
  3905. this.$message.success(data.msg)
  3906. this.favorite = true
  3907. })
  3908. }
  3909. },
  3910. //导出excel
  3911. async createExportData () {
  3912. this.searchData.limit = -1
  3913. this.searchData.page = 1
  3914. await qcFAIInspectionSearch(this.searchData).then(({data}) => {
  3915. this.exportList = data.page.list
  3916. })
  3917. return this.exportList
  3918. },
  3919. startDownload () {},
  3920. finishDownload () {},
  3921. fields () {
  3922. let json = "{"
  3923. this.columnList1.forEach((item, index) => {
  3924. if (index == this.columnList1.length - 1) {
  3925. json += "\"" + item.columnLabel + "\"" + ":" + "\"" + item.columnProp + "\""
  3926. } else {
  3927. json += "\"" + item.columnLabel + "\"" + ":" + "\"" + item.columnProp + "\"" + ","
  3928. }
  3929. })
  3930. json += "}"
  3931. let s = eval("(" + json + ")")
  3932. return s
  3933. },
  3934. // 动态列开始 获取 用户保存的 格式列
  3935. async getTableUserColumn (tableId, columnId) {
  3936. let queryTableUser = {
  3937. userId: this.$store.state.user.name,
  3938. functionId: this.$route.meta.menuId,
  3939. tableId: tableId,
  3940. status: true,
  3941. languageCode: this.$i18n.locale
  3942. }
  3943. await getTableUserListLanguage(queryTableUser).then(({data}) => {
  3944. if (data.rows.length > 0) {
  3945. //this.columnList1 = []
  3946. switch (columnId) {
  3947. case 1:
  3948. this.columnList1 = data.rows
  3949. break;
  3950. case 2:
  3951. this.detailColumnList = data.rows
  3952. break;
  3953. case 3:
  3954. this.seqDetailColumnList = data.rows
  3955. break;
  3956. // case 4:
  3957. // this.columnList3 = data.rows
  3958. // break;
  3959. }
  3960. } else {
  3961. this.getColumnList(tableId, columnId)
  3962. }
  3963. })
  3964. },
  3965. // 获取 tableDefault 列
  3966. async getColumnList (tableId, columnId) {
  3967. let queryTable = {
  3968. functionId: this.$route.meta.menuId,
  3969. tableId: tableId,
  3970. languageCode: this.$i18n.locale
  3971. }
  3972. await getTableDefaultListLanguage(queryTable).then(({data}) => {
  3973. if (!data.rows.length == 0) {
  3974. switch (columnId) {
  3975. case 1:
  3976. this.columnList1 = data.rows
  3977. break;
  3978. case 2:
  3979. this.detailColumnList = data.rows
  3980. break;
  3981. case 3:
  3982. this.seqDetailColumnList = data.rows
  3983. break;
  3984. // case 4:
  3985. // this.columnList3 = data.rows
  3986. // break;
  3987. }
  3988. } else {
  3989. // this.showDefault = true.
  3990. }
  3991. })
  3992. },
  3993. /**
  3994. * 明细导入后将返回值回传给父组件
  3995. * @param val
  3996. */
  3997. changeMyString (val) {
  3998. for (let i = 0; i < this.detailList.length; i++) {
  3999. if (val[this.detailList[i].itemNo] !== undefined) {
  4000. this.detailList[i].unqualifiedQuantity = val[this.detailList[i].itemNo]
  4001. if (val[this.detailList[i].itemNo] != null) {
  4002. this.detailList[i].subDetailRecordNum = 1
  4003. }
  4004. if (val[this.detailList[i].itemNo] > 0) {
  4005. this.detailList[i].itemResult = 'N'
  4006. }
  4007. }
  4008. }
  4009. },
  4010. searchSeqInfo () {
  4011. let tempData = {
  4012. // 取modalData.bu中index为0的字符作为site 例:2_01-Label 取2
  4013. bu: this.modalData.bu,
  4014. seqNo: this.seqDetailData.seqNo,
  4015. orderNo: this.seqDetailData.orderNo,
  4016. sku: this.seqDetailData.sku,
  4017. partDesc: this.seqDetailData.partDesc,
  4018. partNo: this.seqDetailData.partNo,
  4019. operationDesc: this.seqDetailData.operationDesc,
  4020. status: this.seqDetailData.status
  4021. }
  4022. if (!this.seqDetailData.seqNo && !this.seqDetailData.orderNo && !this.seqDetailData.sku && !this.seqDetailData.partNo && !this.seqDetailData.partDesc && !this.seqDetailData.operationDesc){
  4023. this.seqInfoList = []
  4024. } else {
  4025. searchSeqInfo(tempData).then(({data}) => {
  4026. if (data && data.code === 0) {
  4027. this.seqInfoList = data.rows
  4028. } else {
  4029. this.$alert(data.msg, '错误', {
  4030. confirmButtonText: '确定'
  4031. })
  4032. }
  4033. })
  4034. }
  4035. },
  4036. closeDialog () {
  4037. this.seqDetailData = {
  4038. seqNo : '',
  4039. orderNo: '',
  4040. sku: '',
  4041. partNo: '',
  4042. partDesc: '',
  4043. operationDesc: '',
  4044. status: '下达'
  4045. }
  4046. this.seqInfoList = []
  4047. },
  4048. //获取按钮的权限数据
  4049. getButtonAuthData () {
  4050. let searchFlag = this.isAuth(this.menuId + ":search")
  4051. let checkFlag = this.isAuth(this.menuId + ":check")
  4052. let saveFlag = this.isAuth(this.menuId + ":save")
  4053. let deleteFlag = this.isAuth(this.menuId + ":delete")
  4054. let detailFlag = this.isAuth(this.menuId + ":detail")
  4055. let fileFlag = this.isAuth(this.menuId + ":file")
  4056. let cancelCheckFlag = this.isAuth(this.menuId + ":cancelCheck")
  4057. //处理页面的权限数据
  4058. this.authSearch = !searchFlag
  4059. this.authCheck = !checkFlag
  4060. this.authSave = !saveFlag
  4061. this.authDelete = !deleteFlag
  4062. this.authDetail = !detailFlag
  4063. this.authFile = !fileFlag
  4064. this.authCancelCheck = !cancelCheckFlag
  4065. },
  4066. }
  4067. }
  4068. </script>
  4069. <style scoped>
  4070. /deep/ .redElSelect .el-input--suffix .el-input__inner{
  4071. color: red;
  4072. font-weight: bold;
  4073. }
  4074. /deep/ .greenElSelect .el-input--suffix .el-input__inner{
  4075. color: rgb(103,194,58);
  4076. font-weight: bold;
  4077. }
  4078. .el-table /deep/ .cell{
  4079. height: auto;
  4080. line-height: 1.5;
  4081. }
  4082. </style>