plm前端
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.

2980 lines
116 KiB

2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 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: 130px">
  7. <el-option
  8. v-for = "i in buList"
  9. :key = "i.buNo"
  10. :label = "i.buNo"
  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.partNo" clearable style="width: 120px"/>
  17. </el-form-item>
  18. <el-form-item label="物料名称">
  19. <el-input v-model="searchData.partDesc" clearable style="width: 150px"/>
  20. </el-form-item>
  21. <el-form-item label="客户编码">
  22. <el-input v-model="searchData.customerId" clearable style="width: 120px"/>
  23. </el-form-item>
  24. <el-form-item label="客户名称">
  25. <el-input v-model="searchData.customerDesc" clearable style="width: 150px"/>
  26. </el-form-item>
  27. <el-form-item label="项目编码">
  28. <el-input v-model="searchData.projectId" clearable style="width: 120px"/>
  29. </el-form-item>
  30. <el-form-item label="项目名称">
  31. <el-input v-model="searchData.projectDesc" clearable style="width: 150px"/>
  32. </el-form-item>
  33. <el-form-item label="技术参数卡编码">
  34. <el-input v-model="searchData.codeNo" clearable style="width: 120px"/>
  35. </el-form-item>
  36. <el-form-item label=" ">
  37. <el-button plain type="primary" @click="getDataList">查询</el-button>
  38. <el-button type="primary" @click="changeModel">变更申请</el-button>
  39. <download-excel
  40. :fields="fields()"
  41. :data="exportData"
  42. type="xls"
  43. :name="exportName"
  44. :header="exportHeader"
  45. :footer="exportFooter"
  46. :fetch="createExportData"
  47. :before-generate="startDownload"
  48. :before-finish="finishDownload"
  49. worksheet="导出信息"
  50. class="el-button el-button--primary el-button--medium">
  51. {{ "导出" }}
  52. </download-excel>
  53. </el-form-item>
  54. </el-form>
  55. <!-- 数据列表 -->
  56. <el-table
  57. :height="height"
  58. :data="dataList"
  59. border
  60. @selection-change="selectionData"
  61. style="width: 100%;">
  62. <el-table-column
  63. type="selection"
  64. header-align="center"
  65. align="center"
  66. width="50">
  67. </el-table-column>
  68. <el-table-column
  69. v-for="(item,index) in columnList" :key="index"
  70. :sortable="item.columnSortable"
  71. :prop="item.columnProp"
  72. :header-align="item.headerAlign"
  73. :show-overflow-tooltip="item.showOverflowTooltip"
  74. :align="item.align"
  75. :fixed="item.fixed === ''?false:item.fixed"
  76. :min-width="item.columnWidth"
  77. :label="item.columnLabel">
  78. <template slot-scope="scope">
  79. <span v-if="!item.columnHidden">{{ scope.row[item.columnProp] }}</span>
  80. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  81. </template>
  82. </el-table-column>
  83. </el-table>
  84. <selectDiv ref="selectDiv"></selectDiv>
  85. <!-- 分页插件 -->
  86. <el-pagination
  87. @size-change="sizeChangeHandle"
  88. @current-change="currentChangeHandle"
  89. :current-page="pageIndex"
  90. :page-sizes="[20, 50, 100, 200, 500]"
  91. :page-size="pageSize"
  92. :total="totalPage"
  93. layout="total, sizes, prev, pager, next, jumper">
  94. </el-pagination>
  95. <!-- 变更申请模态框 -->
  96. <el-dialog :title="changeTitle" :close-on-click-modal="false" top="10vh" v-drag :visible.sync="modalFlag" width="1060px" :showClose="false">
  97. <el-tabs tab-position="left" type="border-card" v-model="activeName" @tab-click="refreshCurrentTabTable" style="width: 100%;height: 720px;">
  98. <el-tab-pane label="基本信息" name="basicInformation">
  99. <div style="height: 675px">
  100. <el-form :inline="true" label-position="top" :model="modalData" :rules="rules" style="margin-top: -5px;">
  101. <el-form-item prop="applicantId" :rules="rules.applicantId">
  102. <span style="cursor: pointer" slot="label" @click="getBaseList(103, 1)"><a herf="#">申请人</a></span>
  103. <el-input v-model="modalData.applicantId" @blur="applicantBlur(103)" style="width: 120px"></el-input>
  104. <el-input v-model="modalData.applicantName" disabled style="width: 300px"></el-input>
  105. </el-form-item>
  106. <el-form-item label="申请部门" >
  107. <el-input v-model="modalData.applicationDepartmentId" readonly style="width: 120px"></el-input>
  108. <el-input v-model="modalData.applicationDepartmentName" disabled style="width: 300px"></el-input>
  109. </el-form-item>
  110. </el-form>
  111. <el-form :inline="true" label-position="top" :model="modalData" :rules="rules">
  112. <el-form-item label="申请日期" prop="applyDate" :rules="rules.applyDate">
  113. <el-date-picker
  114. style="width: 205px"
  115. v-model="modalData.applyDate"
  116. type="date"
  117. value-format="yyyy-MM-dd"
  118. placeholder="请选择日期"
  119. :editable=false>
  120. </el-date-picker>
  121. </el-form-item>
  122. <!-- <el-form-item label="ECN变更影响" prop="changeImpact" :rules="rules.changeImpact">-->
  123. <!-- <dict-data-select v-if="modalFlag" v-model="modalData.changeImpact" style="width: 205px" dict-type="change_change_Impact"></dict-data-select>-->
  124. <!-- </el-form-item>-->
  125. <el-form-item label="变更影响描述" prop="changeImpactDesc">
  126. <el-input v-model="modalData.changeImpactDesc" style="width: 641px"></el-input>
  127. </el-form-item>
  128. </el-form>
  129. <el-form :inline="true" label-position="top" :model="modalData" :rules="rules">
  130. <el-form-item label="ECN阶段" prop="ecnStage" :rules="rules.ecnStage">
  131. <dict-data-select v-if="modalFlag" v-model="modalData.ecnStage" style="width: 95px" dict-type="change_ecn_stage"></dict-data-select>
  132. </el-form-item>
  133. <el-form-item label="变更类别" prop="changeType" :rules="rules.changeType">
  134. <dict-data-select v-if="modalFlag" v-model="modalData.changeType" style="width: 95px" dict-type="change_change_type"></dict-data-select>
  135. </el-form-item>
  136. <el-form-item label="ECN种类" prop="ecnType" :rules="rules.ecnType">
  137. <dict-data-select v-if="modalFlag" v-model="modalData.ecnType" style="width: 100px" dict-type="change_ecn_type"></dict-data-select>
  138. </el-form-item>
  139. <el-form-item label=" ">
  140. <el-button type="primary" @click="chooseEcnTypeModal" style="width: 90px">ECN种类</el-button>
  141. </el-form-item>
  142. <el-form-item prop="tpEngineerId" :rules="rules.tpEngineerId">
  143. <span style="cursor: pointer" slot="label" @click="getBaseList(2005)"><a herf="#">审批人员</a></span>
  144. <el-input v-model="modalData.tpEngineerId" @blur="tpEngineerBlur(2005)" style="width: 120px"></el-input>
  145. <el-input v-model="modalData.tpEngineerName" disabled style="width: 300px"></el-input>
  146. </el-form-item>
  147. </el-form>
  148. <el-form :inline="true" label-position="top" :model="modalData" :rules="rules">
  149. <el-form-item label="变更生效日期" prop="changePhaseInDate" :rules="rules.changePhaseInDate">
  150. <el-date-picker
  151. style="width: 205px"
  152. v-model="modalData.changePhaseInDate"
  153. type="date"
  154. value-format="yyyy-MM-dd"
  155. placeholder="请选择日期"
  156. :editable=false>
  157. </el-date-picker>
  158. </el-form-item>
  159. <!-- <el-form-item label="印刷方式" prop="printing" :rules="rules.printing">-->
  160. <!-- <dict-data-select v-model="modalData.printing" style="width: 205px" dict-type="change_printing"></dict-data-select>-->
  161. <!-- </el-form-item>-->
  162. <el-form-item label="是否DF产品" prop="dfIsProduct" :rules="rules.dfIsProduct">
  163. <dict-data-select v-if="modalFlag" v-model="modalData.dfIsProduct" style="width: 202px" dict-type="change_df_is_product"></dict-data-select>
  164. </el-form-item>
  165. <el-form-item label=" " prop="industrialEngineerId" :rules="[{required: modalData.dfIsProduct === 'Yes',message: ' ',trigger: ['blur','change']}]">
  166. <span style="cursor: pointer" slot="label" @click="getBaseList(2006)"><a herf="#">I/E</a></span>
  167. <el-input v-model="modalData.industrialEngineerId" @blur="industrialEngineerBlur(2006)" style="width: 120px"></el-input>
  168. <el-input v-model="modalData.industrialEngineerName" disabled style="width: 300px"></el-input>
  169. </el-form-item>
  170. <!-- <el-form-item label="制造成本是否变更" prop="manufacturingCostIsChange" :rules="rules.manufacturingCostIsChange">-->
  171. <!-- <dict-data-select v-model="modalData.manufacturingCostIsChange" style="width: 205px" dict-type="change_manufacturing_cost_is_change"></dict-data-select>-->
  172. <!-- </el-form-item>-->
  173. </el-form>
  174. <el-form :inline="true" label-position="top" :model="modalData">
  175. <el-form-item label=" ">
  176. <span style="cursor: pointer" slot="label" @click="getBaseList(2007)"><a herf="#">CQC</a></span>
  177. <el-input v-model="modalData.cqcOperatorId" @blur="cqcOperatorBlur(2007)" style="width: 120px"></el-input>
  178. <el-input v-model="modalData.cqcOperatorName" disabled style="width: 297px"></el-input>
  179. </el-form-item>
  180. <el-form-item label=" ">
  181. <span style="cursor: pointer" slot="label" @click="getBaseList(2008)"><a herf="#">FAI</a></span>
  182. <el-input v-model="modalData.faiOperatorId" @blur="faiOperatorBlur(2008)" style="width: 120px"></el-input>
  183. <el-input v-model="modalData.faiOperatorName" disabled style="width: 300px"></el-input>
  184. </el-form-item>
  185. </el-form>
  186. <el-form :inline="true" label-position="top" :model="modalData" :rules="rules">
  187. <el-form-item label="变更要求描述" prop="changeRequestDesc" :rules="rules.changeRequestDesc">
  188. <el-input type="textarea" v-model="modalData.changeRequestDesc" :rows="3" resize='none' show-word-limit style="width: 643px;height: 30px"></el-input>
  189. </el-form-item>
  190. <!-- <el-form-item label="是否重新报价" prop="isReQuote" :rules="rules.isReQuote">-->
  191. <!-- <dict-data-select v-model="modalData.isReQuote" style="width: 205px" dict-type="change_is_re_quote"></dict-data-select>-->
  192. <!-- <el-button type="primary" icon="el-icon-upload" @click="uploadFileModal" style="margin-top: 12px;width: 105px">文件上传</el-button>-->
  193. <!-- </el-form-item>-->
  194. <el-form-item label="印刷方式" prop="printing" :rules="rules.printing">
  195. <dict-data-select v-if="modalFlag" v-model="modalData.printing" style="width: 205px" dict-type="change_printing"></dict-data-select>
  196. <el-button type="primary" icon="el-icon-upload" @click="uploadFileModal" style="margin-top: 12px;width: 105px">文件上传</el-button>
  197. </el-form-item>
  198. </el-form>
  199. <!-- <el-form :inline="true" label-position="top" :model="modalData" :rules="rules" style="margin-top: 50px">-->
  200. <!-- <el-form-item label="原产品是否UL认证要求" prop="ulCertificationRequirements" :rules="rules.ulCertificationRequirements">-->
  201. <!-- <dict-data-select v-model="modalData.ulCertificationRequirements" style="width: 423px" dict-type="change_ul_certification_requirements"></dict-data-select>-->
  202. <!-- </el-form-item>-->
  203. <!-- <el-form-item label="如果有,变更后能否继续满足此需求" prop="ulContinueToMeetDemand" :rules="rules.ulContinueToMeetDemand">-->
  204. <!-- <dict-data-select v-model="modalData.ulContinueToMeetDemand" style="width: 423px" dict-type="change_ul_continue_to_meet_demand"></dict-data-select>-->
  205. <!-- </el-form-item>-->
  206. <!-- </el-form>-->
  207. <!-- <el-form :inline="true" label-position="top" :model="modalData" :rules="rules">-->
  208. <!-- <el-form-item label="原产品是否GP要求" prop="gpCertificationRequirements" :rules="rules.gpCertificationRequirements">-->
  209. <!-- <dict-data-select v-model="modalData.gpCertificationRequirements" style="width: 423px" dict-type="change_gp_certification_requirements"></dict-data-select>-->
  210. <!-- </el-form-item>-->
  211. <!-- <el-form-item label="如果有,变更后能否继续满足此需求" prop="gpContinueToMeetDemand" :rules="rules.gpContinueToMeetDemand">-->
  212. <!-- <dict-data-select v-model="modalData.gpContinueToMeetDemand" style="width: 423px" dict-type="change_gp_continue_to_meet_demand"></dict-data-select>-->
  213. <!-- </el-form-item>-->
  214. <!-- </el-form>-->
  215. <el-form :inline="true" label-position="top" style="margin-top: 50px">
  216. <div class="rq">
  217. <el-table
  218. :data="chooseDataList"
  219. height="348px"
  220. border
  221. style="width:100%">
  222. <el-table-column
  223. v-for="(item,index) in columnChooseDataList" :key="index"
  224. :sortable="item.columnSortable"
  225. :prop="item.columnProp"
  226. :header-align="item.headerAlign"
  227. :show-overflow-tooltip="item.showOverflowTooltip"
  228. :align="item.align"
  229. :fixed="item.fixed == ''?false:item.fixed"
  230. :min-width="item.columnWidth"
  231. :label="item.columnLabel">
  232. <template slot-scope="scope">
  233. <span v-if="!item.columnHidden">{{scope.row[item.columnProp]}}</span>
  234. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  235. </template>
  236. </el-table-column>
  237. <el-table-column
  238. prop=""
  239. header-align="center"
  240. align="center"
  241. min-width="170"
  242. label="新物料编码">
  243. <template slot-scope="scope">
  244. <el-input @input="(val)=>partInput(scope.row, val)" :ref="`newPartNo${scope.$index}`" v-model="scope.row.newPartNo" @keyup.enter.native="focusNextInput(scope.$index, 'newPartNo')" style="width:77%"></el-input>
  245. <el-button type="primary" @click="choosePartNo(scope.row)" style="width:18%;padding: 3px 7px">·&nbsp;·&nbsp;·</el-button>
  246. </template>
  247. </el-table-column>
  248. <el-table-column
  249. prop=""
  250. header-align="center"
  251. align="center"
  252. min-width="90"
  253. label="新图纸编码">
  254. <template slot-scope="scope">
  255. <el-input :ref="`newDrawingNo${scope.$index}`" v-model="scope.row.newDrawingNo" @keyup.enter.native="focusNextInput(scope.$index, 'newDrawingNo')" style="width:98%"></el-input>
  256. </template>
  257. </el-table-column>
  258. <el-table-column
  259. prop=""
  260. header-align="center"
  261. align="center"
  262. min-width="90"
  263. label="新图稿编码">
  264. <template slot-scope="scope">
  265. <el-input :ref="`newDraftNo${scope.$index}`" v-model="scope.row.newDraftNo" @keyup.enter.native="focusNextInput(scope.$index, 'newDraftNo')" style="width:98%"></el-input>
  266. </template>
  267. </el-table-column>
  268. <el-table-column
  269. fixed="right"
  270. header-align="center"
  271. align="center"
  272. width="60"
  273. label="操作">
  274. <template slot-scope="scope">
  275. <el-link style="cursor: pointer" @click="deleteChooseDataModal(scope.row)">删除</el-link>
  276. </template>
  277. </el-table-column>
  278. </el-table>
  279. </div>
  280. </el-form>
  281. </div>
  282. <el-footer style="height:25px;text-align:center">
  283. <el-button v-if="basicInformationFlag" type="primary" @click="saveData(1)">应用</el-button>
  284. <el-button type="primary" @click="closeModalFlag">关闭</el-button>
  285. <el-button v-if="basicInformationFlag" type="primary" @click="saveData(2)">保存并跳转</el-button>
  286. </el-footer>
  287. </el-tab-pane>
  288. <el-tab-pane label="库存成本影响" name="inventoryCostImpact">
  289. <div style="height: 675px">
  290. <el-form :inline="true" label-position="top" :model="costImpactData" style="margin-top: -5px;">
  291. <el-form-item style="margin-top: 20px;width: 155px">
  292. <el-checkbox v-model="costImpactData.productionProductFlag" true-label="Y">在生产品</el-checkbox>
  293. </el-form-item>
  294. <el-form-item label="数量">
  295. <el-input class="inlineNumber numInput" v-model="costImpactData.productionProductNumber" :disabled="costImpactData.productionProductFlag !== 'Y'" type="number" style="width: 100px"></el-input>
  296. </el-form-item>
  297. <el-form-item label="处理意见">
  298. <!-- <dict-data-select v-if="modalFlag" v-model="costImpactData.productionProductOpinions" :disabled="costImpactData.productionProductFlag !== 'Y'" style="width: 200px" dict-type="change_production_product_opinions"></dict-data-select>-->
  299. <el-input v-if="modalFlag" v-model="costImpactData.productionProductOpinions" :disabled="costImpactData.productionProductFlag !== 'Y'" style="width: 200px"></el-input>
  300. </el-form-item>
  301. <el-form-item label="报废金额">
  302. <el-input class="inlineNumber numInput" v-model="costImpactData.productionProductScrapAmount" :disabled="costImpactData.productionProductFlag !== 'Y'" @input="handleInput(costImpactData.productionProductScrapAmount,1)" type="number" style="width: 140px"></el-input>
  303. </el-form-item>
  304. <!-- <el-form-item label=" " style="margin-left: -10px">-->
  305. <!-- <el-input v-model="costImpactData.productionProductRemark" :disabled="costImpactData.productionProductFlag !== 'Y'" style="width: 300px"></el-input>-->
  306. <!-- </el-form-item>-->
  307. <el-form-item>
  308. <span style="cursor: pointer" slot="label" @click="getBaseList(103, 3)"><a herf="#">执行人</a></span>
  309. <el-input v-model="costImpactData.productionProductExecutorName" :disabled="costImpactData.productionProductFlag !== 'Y'" style="width: 130px"></el-input>
  310. </el-form-item>
  311. </el-form>
  312. <el-form :inline="true" label-position="top" :model="costImpactData" style="margin-top: 10px;">
  313. <el-form-item style="margin-top: 20px;width: 155px">
  314. <el-checkbox v-model="costImpactData.inventoryProductFlag" true-label="Y">成品库存</el-checkbox>
  315. </el-form-item>
  316. <el-form-item label="数量">
  317. <el-input class="inlineNumber numInput" v-model="costImpactData.inventoryProductNumber" :disabled="costImpactData.inventoryProductFlag !== 'Y'" type="number" style="width: 100px"></el-input>
  318. </el-form-item>
  319. <el-form-item label="处理意见">
  320. <!-- <dict-data-select v-if="modalFlag" v-model="costImpactData.inventoryProductOpinions" :disabled="costImpactData.inventoryProductFlag !== 'Y'" style="width: 200px" dict-type="change_inventory_product_opinions"></dict-data-select>-->
  321. <el-input v-if="modalFlag" v-model="costImpactData.inventoryProductOpinions" :disabled="costImpactData.inventoryProductFlag !== 'Y'" style="width: 200px"></el-input>
  322. </el-form-item>
  323. <el-form-item label="报废金额">
  324. <el-input class="inlineNumber numInput" v-model="costImpactData.inventoryProductScrapAmount" :disabled="costImpactData.inventoryProductFlag !== 'Y'" @input="handleInput(costImpactData.inventoryProductScrapAmount,2)" type="number" style="width: 140px"></el-input>
  325. </el-form-item>
  326. <!-- <el-form-item label=" " style="margin-left: -10px">-->
  327. <!-- <el-input v-model="costImpactData.inventoryProductRemark" :disabled="costImpactData.inventoryProductFlag !== 'Y'" style="width: 300px"></el-input>-->
  328. <!-- </el-form-item>-->
  329. <el-form-item>
  330. <span style="cursor: pointer" slot="label" @click="getBaseList(103, 4)"><a herf="#">执行人</a></span>
  331. <el-input v-model="costImpactData.inventoryProductExecutorName" :disabled="costImpactData.inventoryProductFlag !== 'Y'" style="width: 130px"></el-input>
  332. </el-form-item>
  333. </el-form>
  334. <el-form :inline="true" label-position="top" :model="costImpactData" style="margin-top: 10px;">
  335. <el-form-item style="margin-top: 20px;width: 155px">
  336. <el-checkbox v-model="costImpactData.newOrderFlag" true-label="Y">新订单</el-checkbox>
  337. </el-form-item>
  338. <el-form-item label="数量">
  339. <el-input class="inlineNumber numInput" v-model="costImpactData.newOrderNumber" :disabled="costImpactData.newOrderFlag !== 'Y'" type="number" style="width: 100px"></el-input>
  340. </el-form-item>
  341. </el-form>
  342. <el-form :inline="true" label-position="top" :model="costImpactData" style="margin-top: 10px;">
  343. <el-form-item style="margin-top: 20px;width: 155px">
  344. <el-checkbox v-model="costImpactData.affectedFlag" true-label="Y">影响的原材料及其库存量</el-checkbox>
  345. </el-form-item>
  346. <el-form-item label="数量">
  347. <el-input class="inlineNumber numInput" v-model="costImpactData.affectedNumber" :disabled="costImpactData.affectedFlag !== 'Y'" type="number" style="width: 100px"></el-input>
  348. </el-form-item>
  349. <el-form-item label="处理意见">
  350. <!-- <dict-data-select v-if="modalFlag" v-model="costImpactData.affectedOpinions" :disabled="costImpactData.affectedFlag !== 'Y'" style="width: 200px" dict-type="change_affected_opinions"></dict-data-select>-->
  351. <el-input v-if="modalFlag" v-model="costImpactData.affectedOpinions" :disabled="costImpactData.affectedFlag !== 'Y'" style="width: 200px"></el-input>
  352. </el-form-item>
  353. <el-form-item label="报废金额">
  354. <el-input class="inlineNumber numInput" v-model="costImpactData.affectedScrapAmount" :disabled="costImpactData.affectedFlag !== 'Y'" @input="handleInput(costImpactData.affectedScrapAmount,3)" type="number" style="width: 140px"></el-input>
  355. </el-form-item>
  356. <!-- <el-form-item label=" " style="margin-left: -10px">-->
  357. <!-- <el-input v-model="costImpactData.affectedRemark" :disabled="costImpactData.affectedFlag !== 'Y'" style="width: 300px"></el-input>-->
  358. <!-- </el-form-item>-->
  359. <el-form-item>
  360. <span style="cursor: pointer" slot="label" @click="getBaseList(103, 5)"><a herf="#">执行人</a></span>
  361. <el-input v-model="costImpactData.affectedExecutorName" :disabled="costImpactData.affectedFlag !== 'Y'" style="width: 130px"></el-input>
  362. </el-form-item>
  363. </el-form>
  364. <el-form :inline="true" label-position="top" :model="costImpactData" style="margin-top: 10px;">
  365. <el-form-item label="ECN变更总成本" style="width: 155px">
  366. <el-input class="inlineNumber numInput" v-model="totalCost" readonly type="number" style="width: 125px"></el-input>
  367. </el-form-item>
  368. <el-form-item label="备注">
  369. <el-input v-model="costImpactData.remark" style="width: 612px"></el-input>
  370. </el-form-item>
  371. </el-form>
  372. </div>
  373. <el-footer style="height:25px;text-align:center">
  374. <el-button v-if="InventoryCostImpactFlag" type="primary" @click="inventoryCostImpactSave(1)">应用</el-button>
  375. <el-button type="primary" @click="closeModalFlag">关闭</el-button>
  376. <el-button v-if="InventoryCostImpactFlag" type="primary" @click="inventoryCostImpactSave(2)">保存并跳转</el-button>
  377. </el-footer>
  378. </el-tab-pane>
  379. <el-tab-pane label="TP&执行信息" name="actionInformation">
  380. <div style="height: 670px">
  381. <el-button type="primary" @click="chooseFeasibilityAssessmentModel">选择评估信息</el-button>
  382. <div class="rq">
  383. <el-table
  384. :data="chooseItemList2"
  385. height="230px"
  386. border
  387. style="width: 100%">
  388. <el-table-column
  389. v-for="(item,index) in columnChooseItemList2" :key="index"
  390. :sortable="item.columnSortable"
  391. :prop="item.columnProp"
  392. :header-align="item.headerAlign"
  393. :show-overflow-tooltip="item.showOverflowTooltip"
  394. :align="item.align"
  395. :fixed="item.fixed == ''?false:item.fixed"
  396. :min-width="item.columnWidth"
  397. :label="item.columnLabel">
  398. <template slot-scope="scope">
  399. <span v-if="!item.columnHidden">{{scope.row[item.columnProp]}}</span>
  400. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  401. </template>
  402. </el-table-column>
  403. <!-- <el-table-column-->
  404. <!-- prop=""-->
  405. <!-- header-align="center"-->
  406. <!-- align="center"-->
  407. <!-- min-width="80"-->
  408. <!-- label="可选值">-->
  409. <!-- <template slot-scope="scope">-->
  410. <!-- <el-select v-model="scope.row.chooseValue" placeholder="请选择">-->
  411. <!-- <el-option v-for="item in scope.row.availableValueList" :key="index" :label="item.availableValue" :value="item.availableValue"></el-option>-->
  412. <!-- </el-select>-->
  413. <!-- </template>-->
  414. <!-- </el-table-column>-->
  415. <el-table-column
  416. prop=""
  417. header-align="center"
  418. align="center"
  419. min-width="100"
  420. label="备注">
  421. <template slot-scope="scope">
  422. <el-input v-model="scope.row.itemRemark" style="width:98%"></el-input>
  423. </template>
  424. </el-table-column>
  425. <!-- <el-table-column-->
  426. <!-- fixed="right"-->
  427. <!-- header-align="center"-->
  428. <!-- align="center"-->
  429. <!-- width="60"-->
  430. <!-- label="操作">-->
  431. <!-- <template slot-scope="scope">-->
  432. <!-- <el-link style="cursor: pointer" v-if="scope.row.executeFlag !== 'Y'" @click="executeModal2(scope.row)">执行</el-link>-->
  433. <!-- </template>-->
  434. <!-- </el-table-column>-->
  435. </el-table>
  436. </div>
  437. <div style="text-align: center;font-size: 11px;margin-top: 5px">
  438. <span> --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- </span>
  439. </div>
  440. <el-form :inline="true" label-position="top" :model="executionInfoData">
  441. <el-form-item label="原菲林编号">
  442. <el-input v-model="executionInfoData.originalFilmNo" style="width: 230px"></el-input>
  443. </el-form-item>
  444. <el-form-item label="原啤刀编号">
  445. <el-input v-model="executionInfoData.originalDieCuttingRuleNo" style="width: 230px"></el-input>
  446. </el-form-item>
  447. <el-form-item label="原网板/印版编号">
  448. <el-input v-model="executionInfoData.originalStencilNo" style="width: 230px"></el-input>
  449. </el-form-item>
  450. <el-form-item label="ECN执行日期">
  451. <el-date-picker style="width: 130px" v-model="executionInfoData.executionDate" type="date" value-format="yyyy-MM-dd" placeholder="请选择日期" :editable=false></el-date-picker>
  452. </el-form-item>
  453. </el-form>
  454. <el-form :inline="true" label-position="top" :model="executionInfoData" style="margin-top: -5px;">
  455. <el-form-item label="新菲林编号">
  456. <el-input v-model="executionInfoData.newFilmNo" style="width: 230px"></el-input>
  457. </el-form-item>
  458. <el-form-item label="新啤刀编号">
  459. <el-input v-model="executionInfoData.newDieCuttingRuleNo" style="width: 230px"></el-input>
  460. </el-form-item>
  461. <el-form-item label="新网板/印版编号">
  462. <el-input v-model="executionInfoData.newStencilNo" style="width: 230px"></el-input>
  463. </el-form-item>
  464. </el-form>
  465. <div style="text-align: center ;font-size: 11px">
  466. <span> --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- </span>
  467. </div>
  468. <el-button type="primary" @click="chooseModel">选择执行信息</el-button>
  469. <div class="rq">
  470. <el-table
  471. :data="chooseItemList"
  472. height="230px"
  473. border
  474. style="width: 100%">
  475. <el-table-column
  476. v-for="(item,index) in columnChooseItemList" :key="index"
  477. :sortable="item.columnSortable"
  478. :prop="item.columnProp"
  479. :header-align="item.headerAlign"
  480. :show-overflow-tooltip="item.showOverflowTooltip"
  481. :align="item.align"
  482. :fixed="item.fixed == ''?false:item.fixed"
  483. :min-width="item.columnWidth"
  484. :label="item.columnLabel">
  485. <template slot-scope="scope">
  486. <span v-if="!item.columnHidden">{{scope.row[item.columnProp]}}</span>
  487. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  488. </template>
  489. </el-table-column>
  490. <el-table-column
  491. prop=""
  492. header-align="center"
  493. align="center"
  494. min-width="130"
  495. label="执行人">
  496. <template slot-scope="scope">
  497. <el-input @input="(val)=>executorInput(scope.row, val)" v-model="scope.row.executor" style="width:77%"></el-input>
  498. <el-button type="primary" @click="chooseExecutor(scope.row)" style="width:18%;padding: 3px 7px">·&nbsp;·&nbsp;·</el-button>
  499. </template>
  500. </el-table-column>
  501. <el-table-column
  502. prop=""
  503. header-align="center"
  504. align="center"
  505. min-width="150"
  506. label="备注">
  507. <template slot-scope="scope">
  508. <el-input v-model="scope.row.itemRemark" style="height: 11px" allow-create>;width:98%"></el-input>
  509. </template>
  510. </el-table-column>
  511. <el-table-column
  512. fixed="right"
  513. header-align="center"
  514. align="center"
  515. width="60"
  516. label="操作">
  517. <template slot-scope="scope">
  518. <el-link style="cursor: pointer" v-if="scope.row.executeFlag !== 'Y'" @click="executeModal(scope.row)">执行</el-link>
  519. </template>
  520. </el-table-column>
  521. </el-table>
  522. </div>
  523. </div>
  524. <el-footer style="height:25px;text-align:center">
  525. <el-button v-if="actionInformationFlag" type="primary" @click="executionInformationSave(1)">应用</el-button>
  526. <el-button type="primary" @click="closeModalFlag">关闭</el-button>
  527. <el-button v-if="actionInformationFlag" type="primary" @click="executionInformationSave(2)">保存并跳转</el-button>
  528. </el-footer>
  529. </el-tab-pane>
  530. <el-tab-pane label="会签信息" name="countersignature">
  531. <div style="height: 670px">
  532. <el-button type="primary" @click="chooseCSModel">选择会签信息</el-button>
  533. <div class="rq">
  534. <el-table
  535. :data="chooseCSItemList"
  536. height="600px"
  537. border
  538. style="width: 100%">
  539. <el-table-column
  540. v-for="(item,index) in columnChooseCSItemList" :key="index"
  541. :sortable="item.columnSortable"
  542. :prop="item.columnProp"
  543. :header-align="item.headerAlign"
  544. :show-overflow-tooltip="item.showOverflowTooltip"
  545. :align="item.align"
  546. :fixed="item.fixed == ''?false:item.fixed"
  547. :min-width="item.columnWidth"
  548. :label="item.columnLabel">
  549. <template slot-scope="scope">
  550. <span v-if="!item.columnHidden">{{scope.row[item.columnProp]}}</span>
  551. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  552. </template>
  553. </el-table-column>
  554. <el-table-column
  555. prop=""
  556. header-align="center"
  557. align="center"
  558. min-width="100"
  559. label="备注">
  560. <template slot-scope="scope">
  561. <el-input v-model="scope.row.itemRemark" style="height: 11px" allow-create>;width:98%"></el-input>
  562. </template>
  563. </el-table-column>
  564. <el-table-column
  565. fixed="right"
  566. header-align="center"
  567. align="center"
  568. width="60"
  569. label="操作">
  570. <template slot-scope="scope">
  571. <el-link style="cursor: pointer" v-if="scope.row.executeFlag !== 'Y'" @click="executeCSModal(scope.row)">执行</el-link>
  572. </template>
  573. </el-table-column>
  574. </el-table>
  575. </div>
  576. </div>
  577. <el-footer style="height:25px;text-align:center">
  578. <el-button v-if="CountersignatureFlag" type="primary" @click="countersignatureSave(1)">应用</el-button>
  579. <el-button type="primary" @click="closeModalFlag">关闭</el-button>
  580. <el-button v-if="CountersignatureFlag" type="primary" @click="countersignatureSave(2)">保存并跳转</el-button>
  581. </el-footer>
  582. </el-tab-pane>
  583. </el-tabs>
  584. </el-dialog>
  585. <!-- ECN种类模态框 -->
  586. <el-dialog title="ECN种类" :close-on-click-modal="false" v-drag :visible.sync="EcnTypeModalFlag" width="900px">
  587. <el-form ref="dataForm" label-position="right">
  588. <el-row v-for="(item, index) in form" :key="index" style="margin-top: 10px">
  589. <el-col :span="8">
  590. <el-form-item :prop="'input.'+index+'.value'">
  591. <el-checkbox v-model="item.flag" @change="(val)=>ecnTypeHeaderChange(val,index)" :indeterminate="item.list.filter(a => a.flag === 'Y').length !== 0 && item.list.filter(a => a.flag === 'Y').length !== item.list.length" true-label="Y">{{item.value}}</el-checkbox>
  592. </el-form-item>
  593. </el-col>
  594. <el-col :span="16">
  595. <div v-for="i in item.list">
  596. <el-form-item :prop="'input.'+index+'.value'">
  597. <el-checkbox v-model="i.flag" @change="(val)=>ecnTypeDetailChange(val,index)" true-label="Y">{{i.value}}</el-checkbox>
  598. </el-form-item>
  599. </div>
  600. </el-col>
  601. </el-row>
  602. </el-form>
  603. <el-footer style="height:30px;text-align:center">
  604. <el-button type="primary" @click="saveEcnTypeData">保存</el-button>
  605. <el-button type="primary" @click="EcnTypeModalFlag = false">关闭</el-button>
  606. </el-footer>
  607. </el-dialog>
  608. <!-- ECN模板属性清单 -->
  609. <el-dialog title="属性清单" :close-on-click-modal="false" v-drag :visible.sync="chooseModelFlag" width="820px">
  610. <div class="rq">
  611. <el-form :inline="true" label-position="top" :model="chooseModelData">
  612. <el-form-item :label="'模板'">
  613. <el-select v-model="chooseModelData.codeNo" placeholder="请选择" style="width: 120px">
  614. <el-option
  615. v-for = "i in modelList"
  616. :key = "i.codeNo"
  617. :label = "i.codeDesc"
  618. :value = "i.codeNo">
  619. </el-option>
  620. </el-select>
  621. </el-form-item>
  622. <el-form-item label="属性编码">
  623. <el-input v-model="chooseModelData.itemNo" clearable style="width: 120px"></el-input>
  624. </el-form-item>
  625. <el-form-item label="属性名称">
  626. <el-input v-model="chooseModelData.itemDesc" clearable style="width: 120px"></el-input>
  627. </el-form-item>
  628. <el-form-item :label="' '">
  629. <el-button type="primary" @click="searchItemList()">查询</el-button>
  630. </el-form-item>
  631. </el-form>
  632. <el-table
  633. :height="300"
  634. :data="itemList"
  635. ref="itemTable"
  636. @row-click="itemClickRow"
  637. @selection-change="selectionItem"
  638. border
  639. style="width: 100%;">
  640. <el-table-column
  641. type="selection"
  642. header-align="center"
  643. align="center"
  644. width="50">
  645. </el-table-column>
  646. <el-table-column
  647. v-for="(item,index) in columnItemList" :key="index"
  648. :sortable="item.columnSortable"
  649. :prop="item.columnProp"
  650. :header-align="item.headerAlign"
  651. :show-overflow-tooltip="item.showOverflowTooltip"
  652. :align="item.align"
  653. :fixed="item.fixed==''?false:item.fixed"
  654. :min-width="item.columnWidth"
  655. :label="item.columnLabel">
  656. <template slot-scope="scope">
  657. <span v-if="!item.columnHidden">{{ scope.row[item.columnProp] }}</span>
  658. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  659. </template>
  660. </el-table-column>
  661. </el-table>
  662. </div>
  663. <el-footer style="height:40px;margin-top: 20px;text-align:center">
  664. <el-button type="primary" @click="confirmItem">确认</el-button>
  665. <el-button type="primary" @click="chooseModelFlag = false">关闭</el-button>
  666. </el-footer>
  667. </el-dialog>
  668. <!-- ECN模板属性清单 -->
  669. <el-dialog title="属性清单" :close-on-click-modal="false" v-drag :visible.sync="chooseModelFlag2" width="820px">
  670. <div class="rq">
  671. <el-form :inline="true" label-position="top" :model="chooseModelData2">
  672. <el-form-item :label="'模板'">
  673. <el-select v-model="chooseModelData2.codeNo" placeholder="请选择" style="width: 120px">
  674. <el-option
  675. v-for = "i in modelList2"
  676. :key = "i.codeNo"
  677. :label = "i.codeDesc"
  678. :value = "i.codeNo">
  679. </el-option>
  680. </el-select>
  681. </el-form-item>
  682. <el-form-item label="属性编码">
  683. <el-input v-model="chooseModelData2.itemNo" clearable style="width: 120px"></el-input>
  684. </el-form-item>
  685. <el-form-item label="属性名称">
  686. <el-input v-model="chooseModelData2.itemDesc" clearable style="width: 120px"></el-input>
  687. </el-form-item>
  688. <el-form-item :label="' '">
  689. <el-button type="primary" @click="searchItemList2">查询</el-button>
  690. </el-form-item>
  691. </el-form>
  692. <el-table
  693. :height="300"
  694. :data="itemList2"
  695. ref="itemTable2"
  696. @row-click="itemClickRow2"
  697. @selection-change="selectionItem2"
  698. border
  699. style="width: 100%;">
  700. <el-table-column
  701. type="selection"
  702. header-align="center"
  703. align="center"
  704. width="50">
  705. </el-table-column>
  706. <el-table-column
  707. v-for="(item,index) in columnItemList2" :key="index"
  708. :sortable="item.columnSortable"
  709. :prop="item.columnProp"
  710. :header-align="item.headerAlign"
  711. :show-overflow-tooltip="item.showOverflowTooltip"
  712. :align="item.align"
  713. :fixed="item.fixed==''?false:item.fixed"
  714. :min-width="item.columnWidth"
  715. :label="item.columnLabel">
  716. <template slot-scope="scope">
  717. <span v-if="!item.columnHidden">{{ scope.row[item.columnProp] }}</span>
  718. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  719. </template>
  720. </el-table-column>
  721. </el-table>
  722. </div>
  723. <el-footer style="height:40px;margin-top: 20px;text-align:center">
  724. <el-button type="primary" @click="confirmItem2">确认</el-button>
  725. <el-button type="primary" @click="chooseModelFlag2 = false">关闭</el-button>
  726. </el-footer>
  727. </el-dialog>
  728. <!-- 会签模板属性清单 -->
  729. <el-dialog title="属性清单" :close-on-click-modal="false" v-drag :visible.sync="chooseCSModelFlag" width="820px">
  730. <div class="rq">
  731. <el-form :inline="true" label-position="top" :model="chooseCSModelData">
  732. <el-form-item :label="'模板'">
  733. <el-select value="roleName" v-model="chooseCSModelData.codeNo" placeholder="请选择" style="width: 120px">
  734. <el-option
  735. v-for = "i in modelCSList"
  736. :key = "i.codeNo"
  737. :label = "i.codeDesc"
  738. :value = "i.codeNo">
  739. </el-option>
  740. </el-select>
  741. </el-form-item>
  742. <el-form-item label="属性编码">
  743. <el-input v-model="chooseCSModelData.itemNo" clearable style="width: 120px"></el-input>
  744. </el-form-item>
  745. <el-form-item label="属性名称">
  746. <el-input v-model="chooseCSModelData.itemDesc" clearable style="width: 120px"></el-input>
  747. </el-form-item>
  748. <el-form-item :label="' '">
  749. <el-button type="primary" @click="searchCSItemList()">查询</el-button>
  750. </el-form-item>
  751. </el-form>
  752. <el-table
  753. :height="300"
  754. :data="itemCSList"
  755. ref="itemCSTable"
  756. @row-click="itemCSClickRow"
  757. @selection-change="selectionCSItem"
  758. border
  759. style="width: 100%;">
  760. <el-table-column
  761. type="selection"
  762. header-align="center"
  763. align="center"
  764. width="50">
  765. </el-table-column>
  766. <el-table-column
  767. v-for="(item,index) in columnCSItemList" :key="index"
  768. :sortable="item.columnSortable"
  769. :prop="item.columnProp"
  770. :header-align="item.headerAlign"
  771. :show-overflow-tooltip="item.showOverflowTooltip"
  772. :align="item.align"
  773. :fixed="item.fixed==''?false:item.fixed"
  774. :min-width="item.columnWidth"
  775. :label="item.columnLabel">
  776. <template slot-scope="scope">
  777. <span v-if="!item.columnHidden">{{ scope.row[item.columnProp] }}</span>
  778. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" style="width: 100px; height: 80px"/></span>
  779. </template>
  780. </el-table-column>
  781. </el-table>
  782. </div>
  783. <el-footer style="height:40px;margin-top: 20px;text-align:center">
  784. <el-button type="primary" @click="confirmCSItem">确认</el-button>
  785. <el-button type="primary" @click="chooseCSModelFlag = false">关闭</el-button>
  786. </el-footer>
  787. </el-dialog>
  788. <ChooseList ref="baseList" @getBaseData="getBaseData"></ChooseList>
  789. <!-- 上传文件的modal -->
  790. <changeUploadFile ref="changeUploadFile" @refreshPageTables="getFileData" v-drag></changeUploadFile>
  791. <upload-file-list ref="changeRef" v-if="modalFlag" folder="change" title="工程变更文件上传" :upload-status="true" :label="'变更单号:'" :file-list.sync="fileData.file" :no="modalData.changeNo" :upload-dialog.sync="uploadDialog"></upload-file-list>
  792. </div>
  793. </template>
  794. <script>
  795. import {
  796. technicalSpecificationSearch, // 获取技术参数卡列表
  797. getDepartmentByUserName, // 根据用户编码获得用户部门
  798. changeRequestSave, // 新增变更申请
  799. getChangeNo, // 获取申请单号
  800. deleteChangeFiles, // 根据变更单号删除文件,
  801. costImpactSave, // 新增库存成本影响
  802. executionSave, // 新增执行信息
  803. getEcnTypeData, // 查询ECN种类数据
  804. getEcnModel, // 查询ECN的模板
  805. getItemList, // 查询模板属性
  806. countersignatureSave, // 新增会签信息
  807. getBuBySite, // 根据site查bu
  808. } from "@/api/changeManagement/changeManagement.js"
  809. import {getChooselistData, verifyData} from "@/api/chooselist/chooselist.js"
  810. import ChooseList from '@/views/modules/common/Chooselist'
  811. import {uploadFile} from '@/api/oss/oss.js'
  812. import {uploadFileList} from "../../../api/test/testInformation"
  813. import DictDataSelect from '../sys/dict-data-select.vue'
  814. import changeUploadFile from "../base/upload_file.vue"
  815. import dayjs from "dayjs"
  816. import UploadFileList from "../common/uploadFileList.vue"
  817. export default {
  818. components: {
  819. UploadFileList,
  820. changeUploadFile,
  821. DictDataSelect,
  822. ChooseList
  823. },
  824. watch: {
  825. modalData: {
  826. deep: true,
  827. handler: function (newV, oldV) {
  828. if (this.modalData.tpEngineerId === '' || this.modalData.tpEngineerId == null) {
  829. this.modalData.tpEngineerName = ''
  830. }
  831. if (this.modalData.industrialEngineerId === '' || this.modalData.industrialEngineerId == null) {
  832. this.modalData.industrialEngineerName = ''
  833. }
  834. if (this.modalData.cqcOperatorId === '' || this.modalData.cqcOperatorId == null) {
  835. this.modalData.cqcOperatorName = ''
  836. }
  837. if (this.modalData.faiOperatorId === '' || this.modalData.faiOperatorId == null) {
  838. this.modalData.faiOperatorName = ''
  839. }
  840. }
  841. },
  842. },
  843. data() {
  844. return {
  845. uploadDialog: false,
  846. form: [],
  847. buList: [],
  848. // 导出
  849. exportData: [],
  850. exportName: '工程变更申请' + this.dayjs().format('YYYYMMDDHHmmss'),
  851. exportHeader: ['工程变更申请'],
  852. exportFooter: [],
  853. resultList: [],
  854. // ======== 行高 ========
  855. height: 200,
  856. // ======== 分页 ========
  857. pageIndex: 1,
  858. pageSize: 50,
  859. totalPage: 0,
  860. activeName: 'basicInformation',
  861. tempPartRow: {},
  862. tempExecutorRow: {},
  863. changeTitle: '',
  864. // 条件查询
  865. searchData: {
  866. site: this.$store.state.user.site,
  867. partNo: '',
  868. partDesc: '',
  869. customerId: '',
  870. customerDesc: '',
  871. projectId: '',
  872. projectDesc: '',
  873. codeNo: '',
  874. buNo: '',
  875. page: 1,
  876. limit: 10
  877. },
  878. // ======== 数据对象 ========
  879. modalData: {
  880. site: this.$store.state.user.site,
  881. changeNo: '',
  882. applicantId: '',
  883. applicantName: '',
  884. applicationDepartmentId: '',
  885. applicationDepartmentName: '',
  886. applyDate: '',
  887. changeImpact: '',
  888. changeImpactDesc: '',
  889. ecnStage: '',
  890. changeType: '',
  891. tpEngineerId: '',
  892. tpEngineerName: '',
  893. changePhaseInDate: '',
  894. dfIsProduct: '',
  895. printing: '',
  896. manufacturingCostIsChange: '',
  897. changeRequestDesc: '',
  898. isReQuote: '',
  899. ulCertificationRequirements: '',
  900. ulContinueToMeetDemand: '',
  901. gpCertificationRequirements: '',
  902. gpContinueToMeetDemand: '',
  903. createBy: '',
  904. detailList: [],
  905. ecnTypeData: [],
  906. industrialEngineerId: '',
  907. industrialEngineerName: '',
  908. changeStatus: '',
  909. ecnType: '',
  910. cqcOperatorId: '',
  911. cqcOperatorName: '',
  912. faiOperatorId: '',
  913. faiOperatorName: ''
  914. },
  915. costImpactData: {
  916. site: this.$store.state.user.site,
  917. changeNo: '',
  918. productionProductFlag: '',
  919. inventoryProductFlag: '',
  920. newOrderFlag: '',
  921. affectedFlag: '',
  922. productionProductNumber: '',
  923. productionProductOpinions: '',
  924. productionProductScrapAmount: 0,
  925. productionProductRemark: '',
  926. productionProductExecutor: '',
  927. productionProductExecutorName: '',
  928. inventoryProductNumber: '',
  929. inventoryProductOpinions: '',
  930. inventoryProductScrapAmount: 0,
  931. inventoryProductRemark: '',
  932. inventoryProductExecutor: '',
  933. inventoryProductExecutorName: '',
  934. newOrderNumber: '',
  935. affectedNumber: '',
  936. affectedOpinions: '',
  937. affectedScrapAmount: 0,
  938. affectedRemark: '',
  939. affectedExecutor: '',
  940. affectedExecutorName: '',
  941. changeTotalCost: '',
  942. remark: '',
  943. createBy: '',
  944. updateBy: ''
  945. },
  946. executionInfoData: {
  947. site: this.$store.state.user.site,
  948. changeNo: '',
  949. originalFilmNo: '',
  950. newFilmNo: '',
  951. originalDieCuttingRuleNo: '',
  952. newDieCuttingRuleNo: '',
  953. originalStencilNo: '',
  954. newStencilNo: '',
  955. executionDate: '',
  956. createBy: '',
  957. updateBy: '',
  958. chooseItemList: [],
  959. chooseItemList2: [],
  960. },
  961. countersignatureData: {
  962. site: this.$store.state.user.site,
  963. changeNo: '',
  964. createBy: '',
  965. updateBy: '',
  966. chooseCSItemList: []
  967. },
  968. chooseModelData: {
  969. site: this.$store.state.user.site,
  970. functionType: 'ECN',
  971. itemNo: '',
  972. itemDesc: '',
  973. codeNo: ''
  974. },
  975. chooseModelData2: {
  976. site: this.$store.state.user.site,
  977. functionType: 'ECN',
  978. itemNo: '',
  979. itemDesc: '',
  980. codeNo: ''
  981. },
  982. chooseCSModelData: {
  983. site: this.$store.state.user.site,
  984. functionType: 'ECN',
  985. itemNo: '',
  986. itemDesc: '',
  987. codeNo: ''
  988. },
  989. fileData: {
  990. file: [],
  991. orderRef1: '',
  992. orderRef2: '',
  993. fileRemark: '',
  994. folder: ''
  995. },
  996. // ======== 数据列表 ========
  997. dataList: [],
  998. chooseDataList: [],
  999. fileList: [],
  1000. modelList: [],
  1001. modelList2: [],
  1002. modelCSList: [],
  1003. itemList: [],
  1004. itemList2: [],
  1005. itemCSList: [],
  1006. chooseItemList: [],
  1007. chooseItemList2: [],
  1008. chooseCSItemList: [],
  1009. // ======== 列表表头 ========
  1010. columnList: [
  1011. {
  1012. userId: this.$store.state.user.name,
  1013. functionId: 108001,
  1014. serialNumber: '108001Table1Site',
  1015. tableId: '108001Table1',
  1016. tableName: '技术参数卡',
  1017. columnProp: 'site',
  1018. headerAlign: 'center',
  1019. align: 'center',
  1020. columnLabel: 'Site',
  1021. columnHidden: false,
  1022. columnImage: false,
  1023. status: true,
  1024. fixed: '',
  1025. columnWidth: 60
  1026. },
  1027. {
  1028. userId: this.$store.state.user.name,
  1029. functionId: 108001,
  1030. serialNumber: '108001Table1BuNo',
  1031. tableId: '108001Table1',
  1032. tableName: '技术参数卡',
  1033. columnProp: 'buNo',
  1034. headerAlign: 'center',
  1035. align: 'center',
  1036. columnLabel: 'BU',
  1037. columnHidden: false,
  1038. columnImage: false,
  1039. status: true,
  1040. fixed: '',
  1041. columnWidth: 80
  1042. },
  1043. {
  1044. userId: this.$store.state.user.name,
  1045. functionId: 108001,
  1046. serialNumber: '108001Table1PartNo',
  1047. tableId: '108001Table1',
  1048. tableName: '技术参数卡',
  1049. columnProp: 'partNo',
  1050. headerAlign: 'center',
  1051. align: 'center',
  1052. columnLabel: '正式物料编码',
  1053. columnHidden: false,
  1054. columnImage: false,
  1055. status: true,
  1056. fixed: '',
  1057. columnWidth: 120
  1058. },
  1059. {
  1060. userId: this.$store.state.user.name,
  1061. functionId: 108001,
  1062. serialNumber: '108001Table1PartDesc',
  1063. tableId: '108001Table1',
  1064. tableName: '技术参数卡',
  1065. columnProp: 'partDesc',
  1066. headerAlign: 'center',
  1067. align: 'left',
  1068. columnLabel: '物料名称',
  1069. columnHidden: false,
  1070. columnImage: false,
  1071. status: true,
  1072. fixed: '',
  1073. columnWidth: 180
  1074. },
  1075. {
  1076. userId: this.$store.state.user.name,
  1077. functionId: 108001,
  1078. serialNumber: '108001Table1ProjectId',
  1079. tableId: '108001Table1',
  1080. tableName: '技术参数卡',
  1081. columnProp: 'projectId',
  1082. headerAlign: 'center',
  1083. align: 'center',
  1084. columnLabel: '项目编码',
  1085. columnHidden: false,
  1086. columnImage: false,
  1087. status: true,
  1088. fixed: '',
  1089. columnWidth: 120
  1090. },
  1091. {
  1092. userId: this.$store.state.user.name,
  1093. functionId: 108001,
  1094. serialNumber: '108001Table1ProjectDesc',
  1095. tableId: '108001Table1',
  1096. tableName: '技术参数卡',
  1097. columnProp: 'projectDesc',
  1098. headerAlign: 'center',
  1099. align: 'left',
  1100. columnLabel: '项目名称',
  1101. columnHidden: false,
  1102. columnImage: false,
  1103. status: true,
  1104. fixed: '',
  1105. columnWidth: 180
  1106. },
  1107. {
  1108. userId: this.$store.state.user.name,
  1109. functionId: 108001,
  1110. serialNumber: '108001Table1CustomerId',
  1111. tableId: '108001Table1',
  1112. tableName: '技术参数卡',
  1113. columnProp: 'customerId',
  1114. headerAlign: 'center',
  1115. align: 'center',
  1116. columnLabel: '客户编码',
  1117. columnHidden: false,
  1118. columnImage: false,
  1119. status: true,
  1120. fixed: '',
  1121. columnWidth: 120
  1122. },
  1123. {
  1124. userId: this.$store.state.user.name,
  1125. functionId: 108001,
  1126. serialNumber: '108001Table1CustomerDesc',
  1127. tableId: '108001Table1',
  1128. tableName: '技术参数卡',
  1129. columnProp: 'customerDesc',
  1130. headerAlign: 'center',
  1131. align: 'left',
  1132. columnLabel: '客户名称',
  1133. columnHidden: false,
  1134. columnImage: false,
  1135. status: true,
  1136. fixed: '',
  1137. columnWidth: 180
  1138. },
  1139. {
  1140. userId: this.$store.state.user.name,
  1141. functionId: 108001,
  1142. serialNumber: '108001Table1CodeNo',
  1143. tableId: '108001Table1',
  1144. tableName: '技术参数卡',
  1145. columnProp: 'codeNo',
  1146. headerAlign: 'center',
  1147. align: 'center',
  1148. columnLabel: '技术参数卡',
  1149. columnHidden: false,
  1150. columnImage: false,
  1151. status: true,
  1152. fixed: '',
  1153. columnWidth: 120
  1154. },
  1155. {
  1156. userId: this.$store.state.user.name,
  1157. functionId: 108001,
  1158. serialNumber: '108001Table1CodeNo',
  1159. tableId: '108001Table1',
  1160. tableName: '技术参数卡',
  1161. columnProp: 'ecnFlag',
  1162. headerAlign: 'center',
  1163. align: 'center',
  1164. columnLabel: '状态',
  1165. columnHidden: false,
  1166. columnImage: false,
  1167. status: true,
  1168. fixed: '',
  1169. columnWidth: 100
  1170. },
  1171. {
  1172. userId: this.$store.state.user.name,
  1173. functionId: 108001,
  1174. serialNumber: '108001Table1RevNo',
  1175. tableId: '108001Table1',
  1176. tableName: '技术参数卡',
  1177. columnProp: 'revNo',
  1178. headerAlign: 'center',
  1179. align: 'center',
  1180. columnLabel: '版本号',
  1181. columnHidden: false,
  1182. columnImage: false,
  1183. status: true,
  1184. fixed: '',
  1185. columnWidth: 80
  1186. },
  1187. ],
  1188. columnChooseDataList: [
  1189. {
  1190. userId: this.$store.state.user.name,
  1191. functionId: 108001,
  1192. serialNumber: '108001Table2PartNo',
  1193. tableId: '108001Table2',
  1194. tableName: '所选变更列表',
  1195. columnProp: 'partNo',
  1196. headerAlign: 'center',
  1197. align: 'center',
  1198. columnLabel: '正式物料编码',
  1199. columnHidden: false,
  1200. columnImage: false,
  1201. status: true,
  1202. fixed: '',
  1203. columnWidth: 100
  1204. },
  1205. {
  1206. userId: this.$store.state.user.name,
  1207. functionId: 108001,
  1208. serialNumber: '108001Table2PartDesc',
  1209. tableId: '108001Table2',
  1210. tableName: '所选变更列表',
  1211. columnProp: 'partDesc',
  1212. headerAlign: 'center',
  1213. align: 'left',
  1214. columnLabel: '物料描述',
  1215. columnHidden: false,
  1216. columnImage: false,
  1217. status: true,
  1218. fixed: '',
  1219. columnWidth: 180
  1220. },
  1221. {
  1222. userId: this.$store.state.user.name,
  1223. functionId: 108001,
  1224. serialNumber: '108001Table2DrawingNo',
  1225. tableId: '108001Table2',
  1226. tableName: '所选变更列表',
  1227. columnProp: 'drawingNo',
  1228. headerAlign: 'center',
  1229. align: 'center',
  1230. columnLabel: '图纸编码',
  1231. columnHidden: false,
  1232. columnImage: false,
  1233. status: true,
  1234. fixed: '',
  1235. columnWidth: 90
  1236. },
  1237. {
  1238. userId: this.$store.state.user.name,
  1239. functionId: 108001,
  1240. serialNumber: '108001Table2DraftNo',
  1241. tableId: '108001Table2',
  1242. tableName: '所选变更列表',
  1243. columnProp: 'draftNo',
  1244. headerAlign: 'center',
  1245. align: 'center',
  1246. columnLabel: '图稿编码',
  1247. columnHidden: false,
  1248. columnImage: false,
  1249. status: true,
  1250. fixed: '',
  1251. columnWidth: 90
  1252. },
  1253. ],
  1254. columnChooseItemList: [
  1255. {
  1256. userId: this.$store.state.user.name,
  1257. functionId: 108001,
  1258. serialNumber: '108001Table3ItemNo',
  1259. tableId: '108001Table3',
  1260. tableName: '执行属性表',
  1261. columnProp: 'itemNo',
  1262. headerAlign: 'center',
  1263. align: 'center',
  1264. columnLabel: '属性编码',
  1265. columnHidden: false,
  1266. columnImage: false,
  1267. status: true,
  1268. fixed: '',
  1269. columnWidth: 80
  1270. },
  1271. {
  1272. userId: this.$store.state.user.name,
  1273. functionId: 108001,
  1274. serialNumber: '108001Table3ItemDesc',
  1275. tableId: '108001Table3',
  1276. tableName: '执行属性表',
  1277. columnProp: 'itemDesc',
  1278. headerAlign: 'center',
  1279. align: 'center',
  1280. columnLabel: '属性名称',
  1281. columnHidden: false,
  1282. columnImage: false,
  1283. status: true,
  1284. fixed: '',
  1285. columnWidth: 150
  1286. },
  1287. // {
  1288. // userId: this.$store.state.user.name,
  1289. // functionId: 108001,
  1290. // serialNumber: '108001Table3ExecuteFlag',
  1291. // tableId: '108001Table3',
  1292. // tableName: '执行属性表',
  1293. // columnProp: 'executeFlag',
  1294. // headerAlign: 'center',
  1295. // align: 'center',
  1296. // columnLabel: '是否执行',
  1297. // columnHidden: false,
  1298. // columnImage: false,
  1299. // status: true,
  1300. // fixed: '',
  1301. // columnWidth: 80
  1302. // },
  1303. // {
  1304. // userId: this.$store.state.user.name,
  1305. // functionId: 108001,
  1306. // serialNumber: '108001Table3Executor',
  1307. // tableId: '108001Table3',
  1308. // tableName: '执行属性表',
  1309. // columnProp: 'executor',
  1310. // headerAlign: 'center',
  1311. // align: 'center',
  1312. // columnLabel: '执行人',
  1313. // columnHidden: false,
  1314. // columnImage: false,
  1315. // status: true,
  1316. // fixed: '',
  1317. // columnWidth: 100
  1318. // },
  1319. {
  1320. userId: this.$store.state.user.name,
  1321. functionId: 108001,
  1322. serialNumber: '108001Table3ExecuteDate',
  1323. tableId: '108001Table3',
  1324. tableName: '执行属性表',
  1325. columnProp: 'itemExecutionDate',
  1326. headerAlign: 'center',
  1327. align: 'center',
  1328. columnLabel: '执行时间',
  1329. columnHidden: false,
  1330. columnImage: false,
  1331. status: true,
  1332. fixed: '',
  1333. columnWidth: 130
  1334. }
  1335. ],
  1336. columnChooseItemList2: [
  1337. {
  1338. userId: this.$store.state.user.name,
  1339. functionId: 108001,
  1340. serialNumber: '108001Table7ItemNo',
  1341. tableId: '108001Table7',
  1342. tableName: '可行性评估属性表',
  1343. columnProp: 'itemNo',
  1344. headerAlign: 'center',
  1345. align: 'center',
  1346. columnLabel: '属性编码',
  1347. columnHidden: false,
  1348. columnImage: false,
  1349. status: true,
  1350. fixed: '',
  1351. columnWidth: 80
  1352. },
  1353. {
  1354. userId: this.$store.state.user.name,
  1355. functionId: 108001,
  1356. serialNumber: '108001Table7ItemDesc',
  1357. tableId: '108001Table7',
  1358. tableName: '可行性评估属性表',
  1359. columnProp: 'itemDesc',
  1360. headerAlign: 'center',
  1361. align: 'center',
  1362. columnLabel: '属性名称',
  1363. columnHidden: false,
  1364. columnImage: false,
  1365. status: true,
  1366. fixed: '',
  1367. columnWidth: 150
  1368. },
  1369. // {
  1370. // userId: this.$store.state.user.name,
  1371. // functionId: 108001,
  1372. // serialNumber: '108001Table7ExecuteFlag',
  1373. // tableId: '108001Table7',
  1374. // tableName: '可行性评估属性表',
  1375. // columnProp: 'executeFlag',
  1376. // headerAlign: 'center',
  1377. // align: 'center',
  1378. // columnLabel: '是否执行',
  1379. // columnHidden: false,
  1380. // columnImage: false,
  1381. // status: true,
  1382. // fixed: '',
  1383. // columnWidth: 80
  1384. // },
  1385. // {
  1386. // userId: this.$store.state.user.name,
  1387. // functionId: 108001,
  1388. // serialNumber: '108001Table7Executor',
  1389. // tableId: '108001Table7',
  1390. // tableName: '可行性评估属性表',
  1391. // columnProp: 'executor',
  1392. // headerAlign: 'center',
  1393. // align: 'center',
  1394. // columnLabel: '执行人',
  1395. // columnHidden: false,
  1396. // columnImage: false,
  1397. // status: true,
  1398. // fixed: '',
  1399. // columnWidth: 100
  1400. // },{
  1401. // userId: this.$store.state.user.name,
  1402. // functionId: 108001,
  1403. // serialNumber: '108001Table7ExecuteDate',
  1404. // tableId: '108001Table7',
  1405. // tableName: '可行性评估属性表',
  1406. // columnProp: 'itemExecutionDate',
  1407. // headerAlign: 'center',
  1408. // align: 'center',
  1409. // columnLabel: '执行时间',
  1410. // columnHidden: false,
  1411. // columnImage: false,
  1412. // status: true,
  1413. // fixed: '',
  1414. // columnWidth: 150
  1415. // },
  1416. ],
  1417. columnChooseCSItemList: [
  1418. {
  1419. userId: this.$store.state.user.name,
  1420. functionId: 108001,
  1421. serialNumber: '108001Table6ItemNo',
  1422. tableId: '108001Table6',
  1423. tableName: '执行属性表',
  1424. columnProp: 'itemNo',
  1425. headerAlign: 'center',
  1426. align: 'center',
  1427. columnLabel: '属性编码',
  1428. columnHidden: false,
  1429. columnImage: false,
  1430. status: true,
  1431. fixed: '',
  1432. columnWidth: 80
  1433. },
  1434. {
  1435. userId: this.$store.state.user.name,
  1436. functionId: 108001,
  1437. serialNumber: '108001Table6ItemDesc',
  1438. tableId: '108001Table6',
  1439. tableName: '执行属性表',
  1440. columnProp: 'itemDesc',
  1441. headerAlign: 'center',
  1442. align: 'center',
  1443. columnLabel: '属性名称',
  1444. columnHidden: false,
  1445. columnImage: false,
  1446. status: true,
  1447. fixed: '',
  1448. columnWidth: 150
  1449. },
  1450. {
  1451. userId: this.$store.state.user.name,
  1452. functionId: 108001,
  1453. serialNumber: '108001Table6ExecuteFlag',
  1454. tableId: '108001Table6',
  1455. tableName: '执行属性表',
  1456. columnProp: 'executeFlag',
  1457. headerAlign: 'center',
  1458. align: 'center',
  1459. columnLabel: '是否执行',
  1460. columnHidden: false,
  1461. columnImage: false,
  1462. status: true,
  1463. fixed: '',
  1464. columnWidth: 80
  1465. },
  1466. {
  1467. userId: this.$store.state.user.name,
  1468. functionId: 108001,
  1469. serialNumber: '108001Table6Executor',
  1470. tableId: '108001Table6',
  1471. tableName: '执行属性表',
  1472. columnProp: 'executor',
  1473. headerAlign: 'center',
  1474. align: 'center',
  1475. columnLabel: '执行人',
  1476. columnHidden: false,
  1477. columnImage: false,
  1478. status: true,
  1479. fixed: '',
  1480. columnWidth: 100
  1481. },{
  1482. userId: this.$store.state.user.name,
  1483. functionId: 108001,
  1484. serialNumber: '108001Table6ExecuteDate',
  1485. tableId: '108001Table6',
  1486. tableName: '执行属性表',
  1487. columnProp: 'itemExecutionDate',
  1488. headerAlign: 'center',
  1489. align: 'center',
  1490. columnLabel: '执行时间',
  1491. columnHidden: false,
  1492. columnImage: false,
  1493. status: true,
  1494. fixed: '',
  1495. columnWidth: 150
  1496. },
  1497. ],
  1498. columnItemList: [
  1499. {
  1500. columnProp: 'itemNo',
  1501. headerAlign: 'center',
  1502. align: 'center',
  1503. columnLabel: '属性编码',
  1504. columnHidden: false,
  1505. columnImage: false,
  1506. status: true,
  1507. fixed: '',
  1508. columnWidth: 80
  1509. },
  1510. {
  1511. columnProp: 'itemDesc',
  1512. headerAlign: 'center',
  1513. align: 'center',
  1514. columnLabel: '属性名称',
  1515. columnHidden: false,
  1516. columnImage: false,
  1517. status: true,
  1518. fixed: '',
  1519. columnWidth: 150
  1520. },
  1521. ],
  1522. columnItemList2: [
  1523. {
  1524. columnProp: 'itemNo',
  1525. headerAlign: 'center',
  1526. align: 'center',
  1527. columnLabel: '属性编码',
  1528. columnHidden: false,
  1529. columnImage: false,
  1530. status: true,
  1531. fixed: '',
  1532. columnWidth: 80
  1533. },
  1534. {
  1535. columnProp: 'itemDesc',
  1536. headerAlign: 'center',
  1537. align: 'center',
  1538. columnLabel: '属性名称',
  1539. columnHidden: false,
  1540. columnImage: false,
  1541. status: true,
  1542. fixed: '',
  1543. columnWidth: 150
  1544. },
  1545. ],
  1546. columnCSItemList: [
  1547. {
  1548. userId: this.$store.state.user.name,
  1549. functionId: 108001,
  1550. serialNumber: '108001Table5ItemNo',
  1551. tableId: '108001Table5',
  1552. tableName: '执行属性表',
  1553. columnProp: 'itemNo',
  1554. headerAlign: 'center',
  1555. align: 'center',
  1556. columnLabel: '属性编码',
  1557. columnHidden: false,
  1558. columnImage: false,
  1559. status: true,
  1560. fixed: '',
  1561. columnWidth: 80
  1562. },
  1563. {
  1564. userId: this.$store.state.user.name,
  1565. functionId: 108001,
  1566. serialNumber: '108001Table5ItemDesc',
  1567. tableId: '108001Table5',
  1568. tableName: '执行属性表',
  1569. columnProp: 'itemDesc',
  1570. headerAlign: 'center',
  1571. align: 'center',
  1572. columnLabel: '属性名称',
  1573. columnHidden: false,
  1574. columnImage: false,
  1575. status: true,
  1576. fixed: '',
  1577. columnWidth: 150
  1578. },
  1579. ],
  1580. // ======== 必填规则 ========
  1581. rules: {
  1582. applicantId: [
  1583. {
  1584. required: true,
  1585. message: ' ',
  1586. trigger: ['blur','change']
  1587. }
  1588. ],
  1589. applyDate: [
  1590. {
  1591. required: true,
  1592. message: ' ',
  1593. trigger: ['blur','change']
  1594. }
  1595. ],
  1596. changeImpact: [
  1597. {
  1598. required: true,
  1599. message: ' ',
  1600. trigger: ['blur','change']
  1601. }
  1602. ],
  1603. changeImpactDesc: [
  1604. {
  1605. required: true,
  1606. message: ' ',
  1607. trigger: ['blur','change']
  1608. }
  1609. ],
  1610. ecnStage: [
  1611. {
  1612. required: true,
  1613. message: ' ',
  1614. trigger: ['blur','change']
  1615. }
  1616. ],
  1617. changeType: [
  1618. {
  1619. required: true,
  1620. message: ' ',
  1621. trigger: ['blur','change']
  1622. }
  1623. ],
  1624. tpEngineerId: [
  1625. {
  1626. required: true,
  1627. message: ' ',
  1628. trigger: ['blur','change']
  1629. }
  1630. ],
  1631. changePhaseInDate: [
  1632. {
  1633. required: true,
  1634. message: ' ',
  1635. trigger: ['blur','change']
  1636. }
  1637. ],
  1638. dfIsProduct: [
  1639. {
  1640. required: true,
  1641. message: ' ',
  1642. trigger: ['blur','change']
  1643. }
  1644. ],
  1645. printing: [
  1646. {
  1647. required: true,
  1648. message: ' ',
  1649. trigger: ['blur','change']
  1650. }
  1651. ],
  1652. manufacturingCostIsChange: [
  1653. {
  1654. required: true,
  1655. message: ' ',
  1656. trigger: ['blur','change']
  1657. }
  1658. ],
  1659. changeRequestDesc: [
  1660. {
  1661. required: true,
  1662. message: ' ',
  1663. trigger: ['blur','change']
  1664. }
  1665. ],
  1666. isReQuote: [
  1667. {
  1668. required: true,
  1669. message: ' ',
  1670. trigger: ['blur','change']
  1671. }
  1672. ],
  1673. ulCertificationRequirements: [
  1674. {
  1675. required: true,
  1676. message: ' ',
  1677. trigger: ['blur','change']
  1678. }
  1679. ],
  1680. ulContinueToMeetDemand: [
  1681. {
  1682. required: true,
  1683. message: ' ',
  1684. trigger: ['blur','change']
  1685. }
  1686. ],
  1687. gpCertificationRequirements: [
  1688. {
  1689. required: true,
  1690. message: ' ',
  1691. trigger: ['blur','change']
  1692. }
  1693. ],
  1694. gpContinueToMeetDemand: [
  1695. {
  1696. required: true,
  1697. message: ' ',
  1698. trigger: ['blur','change']
  1699. }
  1700. ],
  1701. ecnType: [
  1702. {
  1703. required: true,
  1704. message: ' ',
  1705. trigger: ['blur','change']
  1706. }
  1707. ],
  1708. },
  1709. // ======== 复选数据集 ========
  1710. dataSelections: [],
  1711. itemSelections: [],
  1712. itemSelections2: [],
  1713. itemCSSelections: [],
  1714. // ======== 模态框开关控制 ========
  1715. modalFlag: false,
  1716. modalDisableFlag: false,
  1717. EcnTypeModalFlag: false,
  1718. basicInformationFlag: false,
  1719. InventoryCostImpactFlag: false,
  1720. actionInformationFlag: false,
  1721. chooseModelFlag: false,
  1722. chooseModelFlag2: false,
  1723. chooseCSModelFlag: false,
  1724. CountersignatureFlag: false,
  1725. }
  1726. },
  1727. created () {
  1728. this.getDataList()
  1729. this.getEcnModel()
  1730. this.getEcnModel2()
  1731. this.getEcnCSModel()
  1732. this.getBuBySite()
  1733. },
  1734. mounted() {
  1735. this.$nextTick(() => {
  1736. this.height = window.innerHeight - 180
  1737. })
  1738. },
  1739. computed:{
  1740. totalCost: {
  1741. get () {
  1742. let total = 0
  1743. if (this.costImpactData.productionProductFlag === 'Y') {
  1744. total += +this.costImpactData.productionProductScrapAmount
  1745. }
  1746. if (this.costImpactData.inventoryProductFlag === 'Y') {
  1747. total += +this.costImpactData.inventoryProductScrapAmount
  1748. }
  1749. if (this.costImpactData.affectedFlag === 'Y') {
  1750. total += +this.costImpactData.affectedScrapAmount
  1751. }
  1752. return total
  1753. }
  1754. }
  1755. },
  1756. methods: {
  1757. // 获取用户的bu
  1758. getBuBySite () {
  1759. let tempData = {
  1760. site: this.$store.state.user.site,
  1761. }
  1762. getBuBySite(tempData).then(({data}) => {
  1763. if (data.code === 0) {
  1764. this.buList = data.rows
  1765. }
  1766. })
  1767. },
  1768. // ======= 正则校验 =======
  1769. handleInput (value, type) {
  1770. // 大于等于0,且只能输入16位小数
  1771. let val = value.replace(/^\D*([0-9]\d*\.?\d{0,16})?.*$/,'$1')
  1772. if (val === null || val === undefined || val === '') {
  1773. val = 0
  1774. }
  1775. if (type === 1) {
  1776. this.costImpactData.productionProductScrapAmount = val
  1777. } else if (type === 2) {
  1778. this.costImpactData.inventoryProductScrapAmount = val
  1779. } else if (type === 3) {
  1780. this.costImpactData.affectedScrapAmount = val
  1781. }
  1782. },
  1783. partInput (row, val) {
  1784. row.newPartNo = val.toUpperCase()
  1785. },
  1786. executorInput (row, val) {
  1787. row.executor = val.toUpperCase()
  1788. },
  1789. choosePartNo (row) {
  1790. this.tempPartRow = row
  1791. // if (!this.tempPartRow.newPartNo) {
  1792. // this.tempPartRow.newPartNo = ''
  1793. // }
  1794. this.getBaseList(133)
  1795. },
  1796. chooseExecutor (row) {
  1797. this.tempExecutorRow = row
  1798. // if (this.tempExecutorRow.executor == null) {
  1799. // this.tempExecutorRow.executor = ''
  1800. // }
  1801. this.getBaseList(103, 7)
  1802. },
  1803. ecnTypeHeaderChange (val,index) {
  1804. if (val === 'Y') {
  1805. for (let i = 0; i < this.form[index].list.length; i++) {
  1806. this.form[index].list[i].flag = 'Y'
  1807. }
  1808. } else {
  1809. for (let i = 0; i < this.form[index].list.length; i++) {
  1810. this.form[index].list[i].flag = 'N'
  1811. }
  1812. }
  1813. },
  1814. ecnTypeDetailChange (val,index) {
  1815. if (this.form[index].list.every(x => x.flag === 'Y')) {
  1816. this.form[index].flag = 'Y'
  1817. }else {
  1818. this.form[index].flag = 'N'
  1819. }
  1820. },
  1821. selectFlag (row) {
  1822. if (row.ecnFlag === '变更中') {
  1823. return false
  1824. } else {
  1825. return true
  1826. }
  1827. },
  1828. //每页数
  1829. sizeChangeHandle (val) {
  1830. this.pageSize = val
  1831. this.pageIndex = 1
  1832. this.getDataList()
  1833. },
  1834. // 当前页
  1835. currentChangeHandle (val) {
  1836. this.pageIndex = val
  1837. this.getDataList()
  1838. },
  1839. // 获取数据列表
  1840. getDataList () {
  1841. this.searchData.limit = this.pageSize
  1842. this.searchData.page = this.pageIndex
  1843. technicalSpecificationSearch(this.searchData).then(({data}) => {
  1844. if (data.code === 0) {
  1845. this.dataList = data.page.list
  1846. this.pageIndex = data.page.currPage
  1847. this.pageSize = data.page.pageSize
  1848. this.totalPage = data.page.totalCount
  1849. this.$refs.selectDiv.setLengthAll( this.dataList.length)
  1850. }
  1851. })
  1852. },
  1853. // 复选物料信息
  1854. selectionData (val) {
  1855. this.dataSelections = val
  1856. this.$refs.selectDiv.setLengthselected(this.dataSelections.length)
  1857. },
  1858. // 页签切换
  1859. refreshCurrentTabTable () {
  1860. },
  1861. // 变更申请模态框
  1862. changeModel () {
  1863. if (this.dataSelections.length === 0) {
  1864. this.$message.warning('请选择要变更的技术参数卡!')
  1865. return
  1866. }
  1867. // 获取申请单号
  1868. let tempData = {
  1869. site: this.$store.state.user.site,
  1870. transType: 'change_no'
  1871. }
  1872. getChangeNo(tempData).then(({data}) => {
  1873. if (data.code === 0) {
  1874. this.modalData = {
  1875. site: this.$store.state.user.site,
  1876. changeNo: data.changeNo,
  1877. applicantId: this.$store.state.user.name,
  1878. applicantName: this.$store.state.user.userDisplay,
  1879. applicationDepartmentId: '',
  1880. applicationDepartmentName: '',
  1881. applyDate: new Date(+ new Date() + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, ''),
  1882. changeImpact: '',
  1883. changeImpactDesc: '',
  1884. ecnStage: '',
  1885. changeType: '',
  1886. tpEngineerId: '',
  1887. tpEngineerName: '',
  1888. changePhaseInDate: new Date(+ new Date() + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, ''),
  1889. dfIsProduct: '',
  1890. printing: '',
  1891. manufacturingCostIsChange: '',
  1892. changeRequestDesc: '',
  1893. isReQuote: '',
  1894. ulCertificationRequirements: '',
  1895. ulContinueToMeetDemand: '',
  1896. gpCertificationRequirements: '',
  1897. gpContinueToMeetDemand: '',
  1898. createBy: this.$store.state.user.name,
  1899. detailList: [],
  1900. ecnTypeData: [],
  1901. industrialEngineerId: '',
  1902. industrialEngineerName: '',
  1903. changeStatus: '草稿',
  1904. ecnType: '',
  1905. cqcOperatorId: '',
  1906. cqcOperatorName: '',
  1907. faiOperatorId: '',
  1908. faiOperatorName: ''
  1909. }
  1910. this.changeTitle = '变更申请-' + this.modalData.changeNo
  1911. this.costImpactData = {
  1912. site: this.$store.state.user.site,
  1913. changeNo: data.changeNo,
  1914. productionProductFlag: '',
  1915. inventoryProductFlag: '',
  1916. newOrderFlag: '',
  1917. affectedFlag: '',
  1918. productionProductNumber: '',
  1919. productionProductOpinions: '',
  1920. productionProductScrapAmount: 0,
  1921. productionProductRemark: '',
  1922. productionProductExecutor: '',
  1923. productionProductExecutorName: '',
  1924. inventoryProductNumber: '',
  1925. inventoryProductOpinions: '',
  1926. inventoryProductScrapAmount: 0,
  1927. inventoryProductRemark: '',
  1928. inventoryProductExecutor: '',
  1929. inventoryProductExecutorName: '',
  1930. newOrderNumber: '',
  1931. affectedNumber: '',
  1932. affectedOpinions: '',
  1933. affectedScrapAmount: 0,
  1934. affectedRemark: '',
  1935. affectedExecutor: '',
  1936. affectedExecutorName: '',
  1937. changeTotalCost: '',
  1938. remark: '',
  1939. createBy: this.$store.state.user.name,
  1940. }
  1941. this.executionInfoData = {
  1942. site: this.$store.state.user.site,
  1943. changeNo: data.changeNo,
  1944. originalFilmNo: '',
  1945. newFilmNo: '',
  1946. originalDieCuttingRuleNo: '',
  1947. newDieCuttingRuleNo: '',
  1948. originalStencilNo: '',
  1949. newStencilNo: '',
  1950. executionDate: new Date(+ new Date() + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, ''),
  1951. createBy: this.$store.state.user.name,
  1952. chooseItemList: [],
  1953. chooseItemList2: []
  1954. }
  1955. this.countersignatureData = {
  1956. site: this.$store.state.user.site,
  1957. changeNo: data.changeNo,
  1958. createBy: this.$store.state.user.name,
  1959. chooseCSItemList: []
  1960. }
  1961. this.fileData = {
  1962. file: [],
  1963. orderRef1: '',
  1964. orderRef2: '',
  1965. fileRemark: '',
  1966. folder: ''
  1967. }
  1968. this.chooseItemList = []
  1969. this.chooseItemList2 = []
  1970. this.getDepartmentByUserName()
  1971. this.getEcnTypeData() // 获取ECN种类
  1972. this.chooseDataList = this.dataSelections
  1973. this.activeName = 'basicInformation'
  1974. this.modalFlag = true
  1975. this.modalDisableFlag = false
  1976. this.basicInformationFlag = true
  1977. this.InventoryCostImpactFlag = true
  1978. this.actionInformationFlag = true
  1979. this.CountersignatureFlag = true
  1980. } else {
  1981. this.$alert(data.msg, '错误', {
  1982. confirmButtonText: '确定'
  1983. })
  1984. }
  1985. })
  1986. },
  1987. // 删除变更申请模态框
  1988. closeModalFlag () {
  1989. // deleteChangeFiles(this.modalData).then(({data}) => {
  1990. // if (data && data.code === 0) {
  1991. // this.getDataList()
  1992. // this.modalFlag = false
  1993. // } else {
  1994. // this.$alert(data.msg, '错误', {
  1995. // confirmButtonText: '确定'
  1996. // })
  1997. // }
  1998. // })
  1999. this.modalFlag = false
  2000. },
  2001. // 跳转变更申请
  2002. toMenu () {
  2003. if (this.$router.resolve(`/changeManagement-changeRecord`).resolved.name === '404') {
  2004. this.$alert('权限不足,访问失败', '警告', {confirmButtonText: '确定'})
  2005. } else {
  2006. this.$router.push({name:`changeManagement-changeRecord`,params:{changeNo: this.modalData.changeNo}})
  2007. }
  2008. },
  2009. // 新增变更申请
  2010. saveData (type) {
  2011. if (this.modalData.applicantId === '' || this.modalData.applicantId == null) {
  2012. this.$message.warning('请选择申请人员!')
  2013. return
  2014. }
  2015. if (this.modalData.applyDate === '' || this.modalData.applyDate == null) {
  2016. this.$message.warning('请选择申请日期!')
  2017. return
  2018. }
  2019. // if (this.modalData.changeImpact === '' || this.modalData.changeImpact == null) {
  2020. // this.$message.warning('请选择ECN变更影响!')
  2021. // return
  2022. // }
  2023. // if ((this.modalData.changeImpactDesc === '' || this.modalData.changeImpactDesc == null) && this.modalData.changeImpact === 'Yes') {
  2024. // this.$message.warning('请填写变更影响描述!')
  2025. // return
  2026. // }
  2027. if (this.modalData.ecnStage === '' || this.modalData.ecnStage == null) {
  2028. this.$message.warning('请选择ECN阶段!')
  2029. return
  2030. }
  2031. if (this.modalData.changeType === '' || this.modalData.changeType == null) {
  2032. this.$message.warning('请选择变更类别!')
  2033. return
  2034. }
  2035. if (this.modalData.ecnType === '' || this.modalData.ecnType == null) {
  2036. this.$message.warning('请选择ECN种类!')
  2037. return
  2038. }
  2039. if (this.form.length === 0) {
  2040. this.$message.warning('请选择ECN种类!')
  2041. return
  2042. }
  2043. if (this.modalData.tpEngineerId === '' || this.modalData.tpEngineerId == null) {
  2044. this.$message.warning('请选择审批人员!')
  2045. return
  2046. }
  2047. if (this.modalData.changePhaseInDate === '' || this.modalData.changePhaseInDate == null) {
  2048. this.$message.warning('请选择变更生效日期!')
  2049. return
  2050. }
  2051. if (this.modalData.dfIsProduct === '' || this.modalData.dfIsProduct == null) {
  2052. this.$message.warning('请选择是否DF产品!')
  2053. return
  2054. }
  2055. if ((this.modalData.industrialEngineerId === '' || this.modalData.industrialEngineerId == null) && this.modalData.dfIsProduct === 'Y') {
  2056. this.$message.warning('请选择I/E!')
  2057. return
  2058. }
  2059. if (this.modalData.changeRequestDesc === '' || this.modalData.changeRequestDesc == null) {
  2060. this.$message.warning('请填写变更要求描述!')
  2061. return
  2062. }
  2063. if (this.modalData.printing === '' || this.modalData.printing == null) {
  2064. this.$message.warning('请选择印刷方式!')
  2065. return
  2066. }
  2067. if ((this.modalData.cqcOperatorId === '' || this.modalData.cqcOperatorId == null) && (this.modalData.faiOperatorId === '' || this.modalData.faiOperatorId == null)) {
  2068. this.$message.warning('请选择CQC或者FAI人员!')
  2069. return
  2070. }
  2071. // if (this.modalData.cqcOperatorId !== '' && this.modalData.cqcOperatorId != null && this.modalData.faiOperatorId !== '' && this.modalData.faiOperatorId != null) {
  2072. // this.$message.warning('CQC和FAI人员只能选一个!')
  2073. // return
  2074. // }
  2075. this.modalData.detailList = this.chooseDataList
  2076. this.modalData.ecnTypeData = this.form
  2077. this.fileData.orderRef1 = this.modalData.site
  2078. this.fileData.orderRef2 = this.modalData.changeNo
  2079. this.fileData.fileRemark = this.$refs.changeRef.fileRemark
  2080. this.fileData.folder = 'change'
  2081. changeRequestSave(this.modalData).then(({data}) => {
  2082. if (data && data.code === 0) {
  2083. if (this.fileData.file.length > 0) { // 上传文件
  2084. let tempData = new FormData()
  2085. for (let i in this.fileData) {
  2086. if (i === 'file') {
  2087. for (let j = 0; j < this.fileData.file.length; j++) {
  2088. tempData.append("file", this.fileData.file[j].raw)
  2089. }
  2090. continue
  2091. }
  2092. tempData.append(i, this.fileData[i])
  2093. }
  2094. uploadFileList("/upload/test",tempData).then(({data}) => {
  2095. if (data.code !== 0) {
  2096. this.$message.warning(data.msg)
  2097. }
  2098. })
  2099. }
  2100. this.getDataList()
  2101. this.basicInformationFlag = false
  2102. this.$message({
  2103. message: '操作成功',
  2104. type: 'success',
  2105. duration: 1500,
  2106. onClose: () => {}
  2107. })
  2108. if (type === 2) { // 保存并跳转
  2109. this.modalFlag = false
  2110. this.toMenu()
  2111. }
  2112. } else {
  2113. this.$alert(data.msg, '错误', {
  2114. confirmButtonText: '确定'
  2115. })
  2116. }
  2117. })
  2118. },
  2119. // 新增库存成本影响
  2120. inventoryCostImpactSave (type) {
  2121. if (this.costImpactData.productionProductFlag === 'Y') { // 在生产品
  2122. if (this.costImpactData.productionProductNumber == null || this.costImpactData.productionProductNumber === '') {
  2123. this.$message.warning('请填写在生产品数量!')
  2124. return
  2125. }
  2126. if (this.costImpactData.productionProductNumber <= 0) {
  2127. this.$message.warning('在生产品数量不能小于等于0!')
  2128. return
  2129. }
  2130. if (this.costImpactData.productionProductOpinions == null || this.costImpactData.productionProductOpinions === '') {
  2131. this.$message.warning('请填写在生产品处理意见!')
  2132. return
  2133. }
  2134. if (this.costImpactData.productionProductScrapAmount === 0) {
  2135. this.$message.warning('请填写在生产品报废金额!')
  2136. return
  2137. }
  2138. if (this.costImpactData.productionProductExecutor == null || this.costImpactData.productionProductExecutor === '') {
  2139. this.$message.warning('请填写在生产品执行人!')
  2140. return
  2141. }
  2142. }
  2143. if (this.costImpactData.inventoryProductFlag === 'Y') { // 成品库存
  2144. if (this.costImpactData.inventoryProductNumber == null || this.costImpactData.inventoryProductNumber === '') {
  2145. this.$message.warning('请填写成品库存数量!')
  2146. return
  2147. }
  2148. if (this.costImpactData.inventoryProductNumber <= 0) {
  2149. this.$message.warning('成品库存数量不能小于等于0!')
  2150. return
  2151. }
  2152. if (this.costImpactData.inventoryProductOpinions == null || this.costImpactData.inventoryProductOpinions === '') {
  2153. this.$message.warning('请填写成品库存处理意见!')
  2154. return
  2155. }
  2156. if (this.costImpactData.inventoryProductScrapAmount === 0) {
  2157. this.$message.warning('请填写成品库存报废金额!')
  2158. return
  2159. }
  2160. if (this.costImpactData.inventoryProductExecutor == null || this.costImpactData.inventoryProductExecutor === '') {
  2161. this.$message.warning('请填写成品库存执行人!')
  2162. return
  2163. }
  2164. }
  2165. if (this.costImpactData.newOrderFlag === 'Y') { // 新订单
  2166. if (this.costImpactData.newOrderNumber == null || this.costImpactData.newOrderNumber === '') {
  2167. this.$message.warning('请填写新订单数量!')
  2168. return
  2169. }
  2170. if (this.costImpactData.newOrderNumber <= 0) {
  2171. this.$message.warning('新订单数量不能小于等于0!')
  2172. return
  2173. }
  2174. }
  2175. if (this.costImpactData.affectedFlag === 'Y') { // 影响的原材料及其库存量
  2176. if (this.costImpactData.affectedNumber == null || this.costImpactData.affectedNumber === '') {
  2177. this.$message.warning('请填写影响的原材料及其库存量数量!')
  2178. return
  2179. }
  2180. if (this.costImpactData.affectedNumber <= 0) {
  2181. this.$message.warning('影响的原材料及其库存量数量不能小于等于0!')
  2182. return
  2183. }
  2184. if (this.costImpactData.affectedOpinions == null || this.costImpactData.affectedOpinions === '') {
  2185. this.$message.warning('请填写影响的原材料及其库存量处理意见!')
  2186. return
  2187. }
  2188. if (this.costImpactData.affectedScrapAmount === 0) {
  2189. this.$message.warning('请填写影响的原材料及其库存量报废金额!')
  2190. return
  2191. }
  2192. if (this.costImpactData.affectedExecutor == null || this.costImpactData.affectedExecutor === '') {
  2193. this.$message.warning('请填写影响的原材料及其库存量执行人!')
  2194. return
  2195. }
  2196. }
  2197. this.costImpactData.changeTotalCost = this.totalCost
  2198. costImpactSave(this.costImpactData).then(({data}) => {
  2199. if (data && data.code === 0) {
  2200. this.InventoryCostImpactFlag = false
  2201. this.getDataList()
  2202. this.$message({
  2203. message: '操作成功',
  2204. type: 'success',
  2205. duration: 1500,
  2206. onClose: () => {}
  2207. })
  2208. if (type === 2) { // 保存并跳转
  2209. this.modalFlag = false
  2210. this.toMenu()
  2211. }
  2212. } else {
  2213. this.$alert(data.msg, '错误', {
  2214. confirmButtonText: '确定'
  2215. })
  2216. }
  2217. })
  2218. },
  2219. // 新增执行信息
  2220. executionInformationSave (type) {
  2221. if (this.chooseItemList.length === 0) {
  2222. this.$message.warning('请选择模板属性!')
  2223. return;
  2224. } else {
  2225. this.executionInfoData.chooseItemList = this.chooseItemList
  2226. }
  2227. if (this.chooseItemList2.length === 0) {
  2228. this.$message.warning('请选择可行性评估模板属性!')
  2229. return;
  2230. } else {
  2231. this.executionInfoData.chooseItemList2 = this.chooseItemList2
  2232. }
  2233. if (this.executionInfoData.originalDieCuttingRuleNo == null || this.executionInfoData.originalDieCuttingRuleNo === '') {
  2234. this.$message.warning('请填写原啤刀编号!')
  2235. return;
  2236. }
  2237. if (this.executionInfoData.newDieCuttingRuleNo == null || this.executionInfoData.newDieCuttingRuleNo === '') {
  2238. this.$message.warning('请填写新啤刀编号!')
  2239. return;
  2240. }
  2241. if (this.executionInfoData.originalStencilNo == null || this.executionInfoData.originalStencilNo === '') {
  2242. this.$message.warning('请填写原网板/印版编号!')
  2243. return;
  2244. }
  2245. if (this.executionInfoData.newStencilNo == null || this.executionInfoData.newStencilNo === '') {
  2246. this.$message.warning('请填写新网板/印版编号!')
  2247. return;
  2248. }
  2249. if (this.executionInfoData.executionDate == null || this.executionInfoData.executionDate === '') {
  2250. this.$message.warning('请选择ECN执行日期!')
  2251. return;
  2252. }
  2253. executionSave(this.executionInfoData).then(({data}) => {
  2254. if (data && data.code === 0) {
  2255. this.actionInformationFlag = false
  2256. this.getDataList()
  2257. this.$message({
  2258. message: '操作成功',
  2259. type: 'success',
  2260. duration: 1500,
  2261. onClose: () => {}
  2262. })
  2263. if (type === 2) { // 保存并跳转
  2264. this.modalFlag = false
  2265. this.toMenu()
  2266. }
  2267. } else {
  2268. this.$alert(data.msg, '错误', {
  2269. confirmButtonText: '确定'
  2270. })
  2271. }
  2272. })
  2273. },
  2274. // 删除所选技术参数卡
  2275. deleteChooseDataModal (row) {
  2276. this.$confirm(`是否删除该技术参数卡的变更?`, '提示', {
  2277. confirmButtonText: '确定',
  2278. cancelButtonText: '取消',
  2279. type: 'warning'
  2280. }).then(() => {
  2281. this.chooseDataList = this.chooseDataList.filter(a => {
  2282. return a.codeNo !== row.codeNo
  2283. })
  2284. })
  2285. },
  2286. // 根据人员编码查人员部门
  2287. getDepartmentByUserName () {
  2288. let tempData = {
  2289. site: this.$store.state.user.site,
  2290. username: this.modalData.applicantId
  2291. }
  2292. getDepartmentByUserName(tempData).then(({data}) => {
  2293. if (data.code === 0) {
  2294. this.modalData.applicationDepartmentId = data.rows[0].departmentNo
  2295. this.modalData.applicationDepartmentName = data.rows[0].departmentName
  2296. }
  2297. })
  2298. },
  2299. // 回车换行
  2300. focusNextInput (index, type) {
  2301. let aaa = ''
  2302. if (this.chooseDataList.length - 1 === index) {
  2303. aaa = `${type}0`
  2304. } else {
  2305. aaa = `${type}${index + 1}`
  2306. }
  2307. this.$nextTick(() => {
  2308. this.$refs[aaa].focus()
  2309. })
  2310. },
  2311. // 上传文件
  2312. uploadFileModal () {
  2313. let currentData = {
  2314. titleCon: '工程变更文件上传',
  2315. site: this.modalData.site,
  2316. createBy: this.$store.state.user.name,
  2317. dataNo: this.modalData.changeNo,
  2318. fileRemark: '',
  2319. folder: 'change',
  2320. file: []
  2321. }
  2322. this.uploadDialog = true
  2323. //打开组件 去做新增业务
  2324. // this.$nextTick(() => {
  2325. // this.$refs.changeUploadFile.init(currentData)
  2326. // })
  2327. },
  2328. // 得到保存的文件对象
  2329. getFileData (fData) {
  2330. this.fileData = {
  2331. file: fData.file,
  2332. orderRef1: fData.site,
  2333. orderRef2: fData.dataNo,
  2334. fileRemark: fData.fileRemark,
  2335. folder: fData.folder
  2336. }
  2337. },
  2338. // 选择ECN种类模态框
  2339. chooseEcnTypeModal () {
  2340. this.EcnTypeModalFlag = true
  2341. },
  2342. // 查询ECN种类数据
  2343. getEcnTypeData () {
  2344. let tempData = {
  2345. site: this.$store.state.user.site
  2346. }
  2347. getEcnTypeData(tempData).then(({data}) => {
  2348. if (data.code === 0) {
  2349. this.form = data.rows
  2350. }
  2351. })
  2352. },
  2353. // 保存ECN种类
  2354. saveEcnTypeData () {
  2355. this.$message({
  2356. message: '操作成功',
  2357. type: 'success',
  2358. duration: 1500,
  2359. onClose: () => {}
  2360. })
  2361. this.EcnTypeModalFlag = false
  2362. },
  2363. // 选择模板属性
  2364. chooseModel () {
  2365. this.chooseModelData = {
  2366. site: this.$store.state.user.site,
  2367. itemNo: '',
  2368. itemDesc: '',
  2369. functionType: 'ECN',
  2370. codeNo: this.modelList.length > 0 ? this.modelList[0].codeNo : ''
  2371. }
  2372. // 先清空缓存选中
  2373. // this.$nextTick(() => this.$refs.itemTable.clearSelection())
  2374. getItemList(this.chooseModelData).then(({data}) => {
  2375. if (data && data.code === 0) {
  2376. this.itemList = data.rows
  2377. this.itemList.forEach(val => {
  2378. // 回显选中
  2379. if (this.chooseItemList.map(val => val.itemNo).includes(val.itemNo)) {
  2380. this.$nextTick(() => this.$refs.itemTable.toggleRowSelection(val, true))
  2381. }
  2382. })
  2383. } else {
  2384. this.$alert(data.msg, '错误', {
  2385. confirmButtonText: '确定'
  2386. })
  2387. }
  2388. })
  2389. this.chooseModelFlag = true
  2390. },
  2391. // 选择模板属性
  2392. chooseFeasibilityAssessmentModel () {
  2393. this.chooseModelData2 = {
  2394. site: this.$store.state.user.site,
  2395. itemNo: '',
  2396. itemDesc: '',
  2397. functionType: 'ECN',
  2398. codeNo: this.modelList2.length > 0 ? this.modelList2[0].codeNo : ''
  2399. }
  2400. // 先清空缓存选中
  2401. //this.$nextTick(() => this.$refs.itemTable2.clearSelection())
  2402. getItemList(this.chooseModelData2).then(({data}) => {
  2403. if (data && data.code === 0) {
  2404. this.itemList2 = data.rows
  2405. this.itemList2.forEach(val => {
  2406. // 回显选中
  2407. if (this.chooseItemList2.map(val => val.itemNo).includes(val.itemNo)) {
  2408. this.$nextTick(() => this.$refs.itemTable2.toggleRowSelection(val, true))
  2409. }
  2410. })
  2411. } else {
  2412. this.$alert(data.msg, '错误', {
  2413. confirmButtonText: '确定'
  2414. })
  2415. }
  2416. })
  2417. this.chooseModelFlag2 = true
  2418. },
  2419. // 查询属性
  2420. searchItemList () {
  2421. getItemList(this.chooseModelData).then(({data}) => {
  2422. if (data.code === 0) {
  2423. this.itemList = data.rows
  2424. }
  2425. })
  2426. },
  2427. // 查询属性
  2428. searchItemList2 () {
  2429. getItemList(this.chooseModelData2).then(({data}) => {
  2430. if (data.code === 0) {
  2431. this.itemList2 = data.rows
  2432. }
  2433. })
  2434. },
  2435. // 单机选择
  2436. itemClickRow (row) {
  2437. this.$refs.itemTable.toggleRowSelection(row)
  2438. },
  2439. // 复选属性
  2440. selectionItem (val) {
  2441. this.itemSelections = val
  2442. },
  2443. // 单机选择
  2444. itemClickRow2 (row) {
  2445. this.$refs.itemTable2.toggleRowSelection(row)
  2446. },
  2447. // 复选属性
  2448. selectionItem2 (val) {
  2449. this.itemSelections2 = val
  2450. },
  2451. // 确认多选属性
  2452. confirmItem () {
  2453. if (this.itemSelections.length === 0) {
  2454. this.$message.warning("请勾选属性!")
  2455. return
  2456. }
  2457. // 临时集合
  2458. let temp = []
  2459. // 首先,遍历a,检查每个对象的名字是否在b中也存在
  2460. this.chooseItemList.forEach(itemA => {
  2461. if (this.itemSelections.some(itemB => itemB.itemNo === itemA.itemNo)) {
  2462. // 如果存在,则将a中的对象添加到结果中(这里直接用a的原对象,因为要求是保留a中对象)
  2463. temp.push(itemA)
  2464. }
  2465. })
  2466. // 然后,遍历b,检查是否有对象的名字不在结果中已存在的名字中
  2467. this.itemSelections.forEach(itemB => {
  2468. if (!temp.some(itemR => itemR.itemNo === itemB.itemNo)) {
  2469. // 如果b中的对象名字不在结果中,则添加到结果中
  2470. temp.push(itemB)
  2471. }
  2472. })
  2473. this.chooseItemList = temp
  2474. this.chooseModelFlag = false
  2475. },
  2476. // 确认多选属性
  2477. confirmItem2 () {
  2478. if (this.itemSelections2.length === 0) {
  2479. this.$message.warning("请勾选属性!")
  2480. return
  2481. }
  2482. // 临时集合
  2483. let temp = []
  2484. // 首先,遍历a,检查每个对象的名字是否在b中也存在
  2485. this.chooseItemList2.forEach(itemA => {
  2486. if (this.itemSelections2.some(itemB => itemB.itemNo === itemA.itemNo)) {
  2487. // 如果存在,则将a中的对象添加到结果中(这里直接用a的原对象,因为要求是保留a中对象)
  2488. temp.push(itemA)
  2489. }
  2490. })
  2491. // 然后,遍历b,检查是否有对象的名字不在结果中已存在的名字中
  2492. this.itemSelections2.forEach(itemB => {
  2493. if (!temp.some(itemR => itemR.itemNo === itemB.itemNo)) {
  2494. // 如果b中的对象名字不在结果中,则添加到结果中
  2495. temp.push(itemB)
  2496. }
  2497. })
  2498. this.chooseItemList2 = temp
  2499. this.chooseModelFlag2 = false
  2500. },
  2501. // 执行所选属性
  2502. executeModal (row) {
  2503. row.executeFlag = 'Y'
  2504. row.itemExecutionDate = new Date(+ new Date() + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, '')
  2505. // row.executor = this.$store.state.user.name
  2506. },
  2507. // 执行所选属性
  2508. executeModal2 (row) {
  2509. row.executeFlag = 'Y'
  2510. row.itemExecutionDate = new Date(+ new Date() + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, '')
  2511. row.executor = this.$store.state.user.name
  2512. },
  2513. // 查询ECN的模板
  2514. getEcnModel () {
  2515. let tempData = {
  2516. site: this.$store.state.user.site,
  2517. functionType: 'ECN',
  2518. codeNo: 'E001'
  2519. }
  2520. getEcnModel(tempData).then(({data}) => {
  2521. if (data.code === 0) {
  2522. this.modelList = data.rows
  2523. }
  2524. })
  2525. },
  2526. // 查询ECN的评估模板
  2527. getEcnModel2 () {
  2528. let tempData = {
  2529. site: this.$store.state.user.site,
  2530. functionType: 'ECN',
  2531. codeNo: 'E002'
  2532. }
  2533. getEcnModel(tempData).then(({data}) => {
  2534. if (data.code === 0) {
  2535. this.modelList2 = data.rows
  2536. }
  2537. })
  2538. },
  2539. // 查询会签的模板
  2540. getEcnCSModel () {
  2541. let tempData = {
  2542. site: this.$store.state.user.site,
  2543. functionType: 'ECN',
  2544. codeNo: 'E003'
  2545. }
  2546. getEcnModel(tempData).then(({data}) => {
  2547. if (data.code === 0) {
  2548. this.modelCSList = data.rows
  2549. }
  2550. })
  2551. },
  2552. // 选择会签模板属性
  2553. chooseCSModel () {
  2554. this.chooseCSModelData = {
  2555. site: this.$store.state.user.site,
  2556. itemNo: '',
  2557. itemDesc: '',
  2558. functionType: 'ECN',
  2559. codeNo: this.modelCSList.length > 0 ? this.modelCSList[0].codeNo : ''
  2560. }
  2561. // 先清空缓存选中
  2562. // this.$nextTick(() => this.$refs.itemCSTable.clearSelection())
  2563. // 查询所有属性
  2564. getItemList(this.chooseCSModelData).then(({data}) => {
  2565. if (data && data.code === 0) {
  2566. this.itemCSList = data.rows
  2567. this.itemCSList.forEach(val => {
  2568. // 回显选中的部门
  2569. if (this.chooseCSItemList.map(val => val.itemNo).includes(val.itemNo)) {
  2570. this.$nextTick(() => this.$refs.itemCSTable.toggleRowSelection(val, true))
  2571. }
  2572. })
  2573. } else {
  2574. this.$alert(data.msg, '错误', {
  2575. confirmButtonText: '确定'
  2576. })
  2577. }
  2578. })
  2579. this.chooseCSModelFlag = true
  2580. },
  2581. // 查询CS属性
  2582. searchCSItemList () {
  2583. getItemList(this.chooseCSModelData).then(({data}) => {
  2584. if (data.code === 0) {
  2585. this.itemCSList = data.rows
  2586. }
  2587. })
  2588. },
  2589. // 单击选择
  2590. itemCSClickRow (row) {
  2591. this.$refs.itemCSTable.toggleRowSelection(row)
  2592. },
  2593. // 复选CS属性
  2594. selectionCSItem (val) {
  2595. this.itemCSSelections = val
  2596. },
  2597. // 确认多选CS属性
  2598. confirmCSItem () {
  2599. if (this.itemCSSelections.length === 0) {
  2600. this.$message.warning("请勾选属性!")
  2601. return
  2602. }
  2603. // 临时集合
  2604. let temp = []
  2605. // 首先,遍历a,检查每个对象的名字是否在b中也存在
  2606. this.chooseCSItemList.forEach(itemA => {
  2607. if (this.itemCSSelections.some(itemB => itemB.itemNo === itemA.itemNo)) {
  2608. // 如果存在,则将a中的对象添加到结果中(这里直接用a的原对象,因为要求是保留a中对象)
  2609. temp.push(itemA)
  2610. }
  2611. })
  2612. // 然后,遍历b,检查是否有对象的名字不在结果中已存在的名字中
  2613. this.itemCSSelections.forEach(itemB => {
  2614. if (!temp.some(itemR => itemR.itemNo === itemB.itemNo)) {
  2615. // 如果b中的对象名字不在结果中,则添加到结果中
  2616. temp.push(itemB)
  2617. }
  2618. })
  2619. this.chooseCSItemList = temp
  2620. this.chooseCSModelFlag = false
  2621. },
  2622. // 执行所选属性
  2623. executeCSModal (row) {
  2624. row.executeFlag = 'Y'
  2625. row.itemExecutionDate = new Date(+ new Date() + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, '')
  2626. row.executor = this.$store.state.user.name
  2627. },
  2628. // 新增会签信息
  2629. countersignatureSave (type) {
  2630. if (this.chooseCSItemList.length === 0) {
  2631. this.$message.warning('请选择模板属性!')
  2632. return;
  2633. } else {
  2634. this.countersignatureData.chooseCSItemList = this.chooseCSItemList
  2635. }
  2636. countersignatureSave(this.countersignatureData).then(({data}) => {
  2637. if (data && data.code === 0) {
  2638. this.CountersignatureFlag = false
  2639. this.getDataList()
  2640. this.$message({
  2641. message: '操作成功',
  2642. type: 'success',
  2643. duration: 1500,
  2644. onClose: () => {}
  2645. })
  2646. if (type === 2) {
  2647. this.modalFlag = false
  2648. this.toMenu()
  2649. }
  2650. } else {
  2651. this.$alert(data.msg, '错误', {
  2652. confirmButtonText: '确定'
  2653. })
  2654. }
  2655. })
  2656. },
  2657. // 获取基础数据列表S
  2658. getBaseList (val, type) {
  2659. this.tagNo = val
  2660. this.tagNo1 = type
  2661. this.$nextTick(() => {
  2662. let strVal = ''
  2663. let conSql = ''
  2664. if (val === 103) {
  2665. if (type === 1) {
  2666. strVal = this.modalData.applicantId
  2667. } else if (type === 3) {
  2668. if (this.costImpactData.productionProductFlag !== 'Y') {
  2669. return
  2670. } else {
  2671. strVal = this.costImpactData.productionProductExecutor
  2672. }
  2673. } else if (type === 4) {
  2674. if (this.costImpactData.inventoryProductFlag !== 'Y') {
  2675. return
  2676. } else {
  2677. strVal = this.costImpactData.inventoryProductExecutor
  2678. }
  2679. } else if (type === 5) {
  2680. if (this.costImpactData.affectedFlag !== 'Y') {
  2681. return
  2682. } else {
  2683. strVal = this.costImpactData.affectedExecutor
  2684. }
  2685. } else if (type === 7) {
  2686. strVal = this.tempExecutorRow.executor
  2687. }
  2688. }
  2689. if (val === 133) {
  2690. strVal = this.tempPartRow.newPartNo
  2691. }
  2692. if (val === 2005) {
  2693. strVal = this.modalData.tpEngineerId
  2694. conSql = " and b.site = '" + this.$store.state.user.site + "'"
  2695. }
  2696. if (val === 2006) {
  2697. strVal = this.modalData.industrialEngineerId
  2698. conSql = " and b.site = '" + this.$store.state.user.site + "'"
  2699. }
  2700. if (val === 2007) {
  2701. strVal = this.modalData.cqcOperatorId
  2702. conSql = " and b.site = '" + this.$store.state.user.site + "'"
  2703. }
  2704. if (val === 2008) {
  2705. strVal = this.modalData.faiOperatorId
  2706. conSql = " and b.site = '" + this.$store.state.user.site + "'"
  2707. }
  2708. this.$refs.baseList.init(val, strVal, conSql)
  2709. })
  2710. },
  2711. // 列表方法的回调
  2712. getBaseData (val) {
  2713. if (this.tagNo === 103) {
  2714. if (this.tagNo1 === 1) {
  2715. this.modalData.applicantId = val.username
  2716. this.modalData.applicantName = val.user_display
  2717. this.getDepartmentByUserName()
  2718. } else if (this.tagNo1 === 3) {
  2719. this.costImpactData.productionProductExecutor = val.username
  2720. this.costImpactData.productionProductExecutorName = val.user_display
  2721. //this.$set(this.costImpactData,'productionProductExecutorName',val.user_display)
  2722. } else if (this.tagNo1 === 4) {
  2723. this.costImpactData.inventoryProductExecutor = val.username
  2724. this.costImpactData.inventoryProductExecutorName = val.user_display
  2725. //this.$set(this.costImpactData,'inventoryProductExecutorName',val.user_display)
  2726. } else if (this.tagNo1 === 5) {
  2727. this.costImpactData.affectedExecutor = val.username
  2728. this.costImpactData.affectedExecutorName = val.user_display
  2729. //this.$set(this.costImpactData,'affectedExecutorName',val.user_display)
  2730. } else if (this.tagNo1 === 7) {
  2731. this.$set(this.tempExecutorRow,'executor',val.username)
  2732. }
  2733. }
  2734. if (this.tagNo === 133) {
  2735. //this.tempPartRow.newPartNo = val.part_no
  2736. this.$set(this.tempPartRow,'newPartNo',val.part_no)
  2737. }
  2738. if (this.tagNo === 2005) {
  2739. this.modalData.tpEngineerId = val.username
  2740. this.modalData.tpEngineerName = val.user_display
  2741. }
  2742. if (this.tagNo === 2006) {
  2743. this.modalData.industrialEngineerId = val.username
  2744. this.modalData.industrialEngineerName = val.user_display
  2745. }
  2746. if (this.tagNo === 2007) {
  2747. this.modalData.cqcOperatorId = val.username
  2748. this.modalData.cqcOperatorName = val.user_display
  2749. }
  2750. if (this.tagNo === 2008) {
  2751. this.modalData.faiOperatorId = val.username
  2752. this.modalData.faiOperatorName = val.user_display
  2753. }
  2754. },
  2755. // 申请人输入校验
  2756. applicantBlur (tagNo) {
  2757. if (this.modalData.applicantId != null && this.modalData.applicantId !== '') {
  2758. let tempData = {
  2759. tagno: tagNo,
  2760. conditionSql: " and username = '" + this.modalData.applicantId + "'" + " and site = '" + this.modalData.site + "'"
  2761. }
  2762. verifyData(tempData).then(({data}) => {
  2763. if (data && data.code === 0) {
  2764. if (data.baseListData.length > 0) {
  2765. this.modalData.applicantId = data.baseListData[0].username
  2766. this.modalData.applicantName = data.baseListData[0].user_display
  2767. this.getDepartmentByUserName()
  2768. return
  2769. }
  2770. }
  2771. })
  2772. }
  2773. this.modalData.applicantName = ''
  2774. this.modalData.applicationDepartmentId = ''
  2775. this.modalData.applicationDepartmentName = ''
  2776. },
  2777. // 审批人员输入校验
  2778. tpEngineerBlur (tagNo) {
  2779. if (this.modalData.tpEngineerId != null && this.modalData.tpEngineerId !== '') {
  2780. let tempData = {
  2781. tagno: tagNo,
  2782. conditionSql: " and a.username = '" + this.modalData.tpEngineerId + "'" + " and b.site = '" + this.modalData.site + "'"
  2783. }
  2784. verifyData(tempData).then(({data}) => {
  2785. if (data && data.code === 0) {
  2786. if (data.baseListData.length > 0) {
  2787. this.modalData.tpEngineerId = data.baseListData[0].username
  2788. this.modalData.tpEngineerName = data.baseListData[0].user_display
  2789. return
  2790. }
  2791. }
  2792. })
  2793. }
  2794. this.modalData.tpEngineerName = ''
  2795. },
  2796. // I/E输入校验
  2797. industrialEngineerBlur (tagNo) {
  2798. if (this.modalData.industrialEngineerId != null && this.modalData.industrialEngineerId !== '') {
  2799. let tempData = {
  2800. tagno: tagNo,
  2801. conditionSql: " and a.username = '" + this.modalData.industrialEngineerId + "'" + " and b.site = '" + this.modalData.site + "'"
  2802. }
  2803. verifyData(tempData).then(({data}) => {
  2804. if (data && data.code === 0) {
  2805. if (data.baseListData.length > 0) {
  2806. this.modalData.industrialEngineerId = data.baseListData[0].username
  2807. this.modalData.industrialEngineerName = data.baseListData[0].user_display
  2808. return
  2809. }
  2810. }
  2811. })
  2812. }
  2813. this.modalData.industrialEngineerName = ''
  2814. },
  2815. // CQC输入校验
  2816. cqcOperatorBlur (tagNo) {
  2817. if (this.modalData.cqcOperatorId != null && this.modalData.cqcOperatorId !== '') {
  2818. let tempData = {
  2819. tagno: tagNo,
  2820. conditionSql: " and a.username = '" + this.modalData.cqcOperatorId + "'" + " and b.site = '" + this.modalData.site + "'"
  2821. }
  2822. verifyData(tempData).then(({data}) => {
  2823. if (data && data.code === 0) {
  2824. if (data.baseListData.length > 0) {
  2825. this.modalData.cqcOperatorId = data.baseListData[0].username
  2826. this.modalData.cqcOperatorName = data.baseListData[0].user_display
  2827. return
  2828. }
  2829. }
  2830. })
  2831. }
  2832. this.modalData.cqcOperatorName = ''
  2833. },
  2834. // FAI输入校验
  2835. faiOperatorBlur (tagNo) {
  2836. if (this.modalData.faiOperatorId != null && this.modalData.faiOperatorId !== '') {
  2837. let tempData = {
  2838. tagno: tagNo,
  2839. conditionSql: " and a.username = '" + this.modalData.faiOperatorId + "'" + " and b.site = '" + this.modalData.site + "'"
  2840. }
  2841. verifyData(tempData).then(({data}) => {
  2842. if (data && data.code === 0) {
  2843. if (data.baseListData.length > 0) {
  2844. this.modalData.faiOperatorId = data.baseListData[0].username
  2845. this.modalData.faiOperatorName = data.baseListData[0].user_display
  2846. return
  2847. }
  2848. }
  2849. })
  2850. }
  2851. this.modalData.faiOperatorName = ''
  2852. },
  2853. // ======== 导出相关方法 ========
  2854. /**
  2855. * 导出excel
  2856. */
  2857. async createExportData () {
  2858. this.searchData.limit = -1
  2859. this.searchData.page = 1
  2860. await technicalSpecificationSearch(this.searchData).then(({data}) => {
  2861. this.resultList = data.page.list
  2862. })
  2863. return this.resultList
  2864. },
  2865. startDownload () {},
  2866. finishDownload () {},
  2867. fields () {
  2868. let json = '{'
  2869. this.columnList.forEach((item, index) => {
  2870. if (index == this.columnList.length - 1) {
  2871. json += '"' + item.columnLabel + '"' + ':' + '"' + item.columnProp + '"'
  2872. } else {
  2873. json += '"' + item.columnLabel + '"' + ':' + '"' + item.columnProp + '"' + ','
  2874. }
  2875. })
  2876. json += '}'
  2877. let s = eval('(' + json + ')')
  2878. return s
  2879. }
  2880. }
  2881. }
  2882. </script>
  2883. <style scoped lang="scss">
  2884. .numInput /deep/ .el-input__inner{
  2885. text-align: right;
  2886. }
  2887. /deep/ .inlineNumber input::-webkit-outer-spin-button,
  2888. /deep/ .inlineNumber input::-webkit-inner-spin-button {
  2889. -webkit-appearance: none;
  2890. }
  2891. /deep/ .inlineNumber input[type="number"]{
  2892. -moz-appearance: textfield;
  2893. padding-right: 5px !important;
  2894. }
  2895. </style>