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.

275 lines
10 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
11 months 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 year 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. <el-tabs class="tabs" tab-position="left" style="height: 200px;" type="border-card" v-model="activeName" @tab-click="refreshCurrentTabTable">
  4. <el-tab-pane label="基本信息" name="baseInfo" >
  5. <basicInformation ref="basicInformation" ></basicInformation>
  6. </el-tab-pane>
  7. <!-- <el-tab-pane label="备注区" name="remarkPage" >-->
  8. <!-- <remarkPage ref="remarkPage" ></remarkPage>-->
  9. <!-- </el-tab-pane>-->
  10. <el-tab-pane label="客户信息" name="customerInfo" v-if="getPageIf('customerInfo')">
  11. <customerInfo ref="customerInfo" ></customerInfo>
  12. </el-tab-pane>
  13. <el-tab-pane label="包装信息" name="packageInfo" v-if="getPageIf('packageInfo')">
  14. <packageInfo ref="packageInfo"></packageInfo>
  15. </el-tab-pane>
  16. <el-tab-pane label="材料信息" name="bom" v-if="getPageIf('bom')">
  17. <bom ref="bom"></bom>
  18. </el-tab-pane>
  19. <el-tab-pane label="工艺信息" name="routing" v-if="getPageIf('routing')">
  20. <routing ref="routing"></routing>
  21. </el-tab-pane>
  22. <el-tab-pane label="图稿信息" name="drawing" v-if="getPageIf('drawing')">
  23. <drawing ref="drawing"></drawing>
  24. </el-tab-pane>
  25. <el-tab-pane label="FAI" name="fai" v-if="getPageIf('fai')">
  26. <fai ref="fai"></fai>
  27. </el-tab-pane>
  28. <el-tab-pane label="品质文件" name="qualityDocument" v-if="getPageIf('qualityDocument')">
  29. <qualityDocument ref="qualityDocument"></qualityDocument>
  30. </el-tab-pane>
  31. <!-- <el-tab-pane label="TP工程师填写信息" name="tpInfo" v-if="getPageIf('tpInfo')">-->
  32. <!-- <tpInfo ref="tpInfo"></tpInfo>-->
  33. <!-- </el-tab-pane>-->
  34. <!-- <el-tab-pane label="产品技术要求" name="technicalRequirement" v-if="getPageIf('technicalRequirement')">-->
  35. <!-- <technicalRequirement ref="technicalRequirement"></technicalRequirement>-->
  36. <!-- </el-tab-pane>-->
  37. <!-- <el-tab-pane label="PE确认信息" name="PEConfirm" v-if="getPageIf('PEConfirm')">-->
  38. <!-- <PEConfirm ref="PEConfirm"></PEConfirm>-->
  39. <!-- </el-tab-pane>-->
  40. <!-- <el-tab-pane label="文档控制" name="documentControl" v-if="getPageIf('documentControl')">-->
  41. <!-- <documentControl ref="documentControl"></documentControl>-->
  42. <!-- </el-tab-pane>-->
  43. <!-- <el-tab-pane label="产品工程师审核/确认" name="peReviewed" v-if="getPageIf('peReviewed')">-->
  44. <!-- <peReviewed ref="peReviewed"></peReviewed>-->
  45. <!-- </el-tab-pane>-->
  46. <!--&lt;!&ndash; 可能不要&ndash;&gt;-->
  47. <!-- <el-tab-pane label="报价专员确认信息" name="queteConfirm" v-if="getPageIf('queteConfirm')">-->
  48. <!-- <queteConfirm ref="queteConfirm"></queteConfirm>-->
  49. <!-- </el-tab-pane>-->
  50. <!-- <el-tab-pane label="CQE确认" name="cqeComfirm" v-if="getPageIf('cqeComfirm')">-->
  51. <!-- <cqeComfirm ref="cqeComfirm"></cqeComfirm>-->
  52. <!-- </el-tab-pane>-->
  53. </el-tabs>
  54. </div>
  55. </template>
  56. <script>
  57. import {
  58. getBMPageBase
  59. } from '@/api/sampleManagement/technicalSpecificationList.js'
  60. import basicInformation from "./com_tsd_basicInformation";/*組件*/
  61. import remarkPage from "./com_bm_remarkSlot.vue";/*备注*/
  62. import customerInfo from "./com_bm_customerInformation";/*客户信息*/
  63. import packageInfo from "./com_bm_packageInfo";/*包装信息*/
  64. import bom from "./com_bm_bom";/*BOM*/
  65. import routing from "./com_bm_routing";/*工艺*/
  66. import prepress from "./com_bm_prepress";/*组件*/
  67. import technicalRequirement from "./com_bm_demoSlot";/*组件*/
  68. import drawing from "./com_bm_demoSlot";/*组件*/
  69. import PEConfirm from "./com_bm_demoSlot";/*组件*/
  70. import overprinting from "./com_bm_demoSlot";/*组件*/
  71. import slitting from "./com_bm_demoSlot";/*组件*/
  72. import lamTemperature from "./com_bm_demoSlot";/*组件*/
  73. import cutting from "./com_bm_demoSlot";/*组件*/
  74. import packagePage from "./com_bm_demoSlot";/*组件*/
  75. import fqc from "./com_bm_demoSlot";/*组件*/
  76. import cqc from "./com_bm_demoSlot";/*组件*/
  77. import qualityDocument from "./com_bm_demoSlot";/*组件*/
  78. import documentControl from "./com_bm_demoSlot";/*组件*/
  79. import peReviewed from "./com_bm_demoSlot";/*组件*/
  80. import queteConfirm from "./com_bm_demoSlot";/*组件*/
  81. import fai from "./com_bm_demoSlot";/*组件*/
  82. import cqeComfirm from "./com_bm_demoSlot";/*组件*/
  83. import tpInfo from "./com_bm_tpInfo";/*组件*/
  84. import printOther from "./com_bm_printOther";/*组件*/
  85. import InkMixing from "./com_bm_inkMixing";/*组件*/
  86. import InkFormulation from "./com_bm_inkFormulation";/*组件*/
  87. import lamination from "./com_bm_lamination";/*组件*/
  88. import printing from "./com_bm_printing";/*组件*/
  89. import CNC from "./com_bm_cnc";
  90. import Cut from "./com_bm_cut";
  91. export default {
  92. name: "technicalSpecificationDetail",
  93. components: {
  94. basicInformation,
  95. customerInfo,
  96. packageInfo,
  97. bom,
  98. routing,
  99. technicalRequirement,
  100. drawing,
  101. PEConfirm,
  102. qualityDocument,
  103. documentControl,
  104. peReviewed,
  105. queteConfirm,
  106. fai,
  107. cqeComfirm,
  108. tpInfo,
  109. remarkPage,
  110. },
  111. data() {
  112. return {
  113. dataForm:{
  114. site:'',
  115. codeNo:'',
  116. buNo:'',
  117. username:this.$store.state.user.name,
  118. type:'',
  119. ifDisableFlag:false,
  120. fieldId:'',
  121. },
  122. pageRole:'',
  123. activeName:'baseInfo',
  124. }
  125. },
  126. mounted() {
  127. if(localStorage.getItem('tsfData')!=undefined){
  128. let data=JSON.parse(localStorage.getItem('tsfData'))
  129. this.dataForm.site=data.site
  130. this.dataForm.codeNo=data.codeNo
  131. this.dataForm.buNo=data.buNo
  132. this.dataForm.username=data.username
  133. localStorage.removeItem('tsfData');
  134. }
  135. this.$nextTick(() => {
  136. this.getPageRole()
  137. this.changeHeightAuto();
  138. this.getBaseInfoData();
  139. })
  140. },
  141. methods: {
  142. refreshCurrentTabTable(){
  143. this.dataForm.fieldId=this.activeName
  144. //先调整页面的高度
  145. this.changeHeightAuto()
  146. if (this.activeName == 'baseInfo') {
  147. this.getBaseInfoData();
  148. // }else if (this.activeName == 'remarkPage') {
  149. // this.changeHeight(800);
  150. // this.getRemarkSlot();
  151. }else if(this.activeName == 'customerInfo'){
  152. //有的页面要高一点
  153. this.changeHeight(800);
  154. this.getCustomerInfo();
  155. }else if(this.activeName == 'packageInfo'){
  156. this.getPackageInfo();
  157. }else if(this.activeName == 'bom'){
  158. this.getBom();
  159. }else if(this.activeName == 'routing'){
  160. this.changeHeight(2000);
  161. this.getRouting();
  162. }else if(this.activeName == 'technicalRequirement'){
  163. this.getTechnicalRequirement();
  164. }else if(this.activeName == 'PEConfirm'){
  165. this.getPEConfirm();
  166. }else if(this.activeName == 'drawing'){
  167. this.getDrawing();
  168. }else if(this.activeName == 'qualityDocument'){
  169. this.getQualityDocument();
  170. }else if(this.activeName == 'documentControl'){
  171. this.getDocumentControl();
  172. }else if(this.activeName == 'peReviewed'){
  173. this.getPeReviewed();
  174. }else if(this.activeName == 'queteConfirm'){
  175. this.getQueteConfirm();
  176. }else if(this.activeName == 'fai'){
  177. this.getFai();
  178. }else if(this.activeName == 'cqeComfirm'){
  179. this.getCqeComfirm();
  180. }else if(this.activeName == 'tpInfo'){
  181. this.changeHeight(800);
  182. this.getTpInfo();
  183. }
  184. },
  185. getBaseInfoData(){
  186. this.$refs.basicInformation.init(JSON.parse(JSON.stringify(this.dataForm)))
  187. },
  188. getRemarkSlot(){
  189. this.$refs.remarkPage.init(JSON.parse(JSON.stringify(this.dataForm)))
  190. },
  191. getCustomerInfo(){
  192. this.$refs.customerInfo.init(JSON.parse(JSON.stringify(this.dataForm)))
  193. },
  194. getPackageInfo(){
  195. this.$refs.packageInfo.init(JSON.parse(JSON.stringify(this.dataForm)))
  196. },
  197. getBom(){
  198. this.$refs.bom.init(JSON.parse(JSON.stringify(this.dataForm)))
  199. },
  200. getRouting(){
  201. this.$refs.routing.init(JSON.parse(JSON.stringify(this.dataForm)))
  202. },
  203. getTechnicalRequirement(){
  204. this.dataForm.type='technicalRequirement'
  205. this.$refs.technicalRequirement.init(JSON.parse(JSON.stringify(this.dataForm)))
  206. },
  207. getPEConfirm(){
  208. this.dataForm.type='PEConfirm'
  209. this.$refs.PEConfirm.init(JSON.parse(JSON.stringify(this.dataForm)))
  210. },
  211. getDrawing(){
  212. this.dataForm.type='drawing'
  213. this.$refs.drawing.init(JSON.parse(JSON.stringify(this.dataForm)))
  214. },
  215. getQualityDocument(){
  216. this.dataForm.type='qualityDocument'
  217. this.$refs.qualityDocument.init(JSON.parse(JSON.stringify(this.dataForm)))
  218. },
  219. getDocumentControl(){
  220. this.dataForm.type='documentControl'
  221. this.$refs.documentControl.init(JSON.parse(JSON.stringify(this.dataForm)))
  222. },
  223. getPeReviewed(){
  224. this.dataForm.type='peReviewed'
  225. this.$refs.peReviewed.init(JSON.parse(JSON.stringify(this.dataForm)))
  226. },
  227. getQueteConfirm(){
  228. this.dataForm.type='queteConfirm'
  229. this.$refs.queteConfirm.init(JSON.parse(JSON.stringify(this.dataForm)))
  230. },
  231. getFai(){
  232. this.dataForm.type='fai'
  233. this.$refs.fai.init(JSON.parse(JSON.stringify(this.dataForm)))
  234. },
  235. getCqeComfirm(){
  236. this.dataForm.type='cqeComfirm'
  237. this.$refs.cqeComfirm.init(JSON.parse(JSON.stringify(this.dataForm)))
  238. },
  239. getTpInfo(){
  240. this.dataForm.type='tpInfo'
  241. this.$refs.tpInfo.init(JSON.parse(JSON.stringify(this.dataForm)))
  242. },
  243. //看有没有这个页面的权限
  244. getPageRole(){
  245. getBMPageBase(this.dataForm).then(({data}) => {
  246. if (data && data.code === 0) {
  247. this.pageRole=data.row
  248. }
  249. })
  250. },
  251. getPageIf(key){
  252. return this.pageRole.indexOf(';'+key+';') !== -1 || false
  253. },
  254. changeHeight(height){
  255. var tabsElement = document.querySelector('.tabs');
  256. // tabsElement.style.minHeight = window.innerHeight+'px';
  257. tabsElement.style.minHeight = height +'px';
  258. },
  259. changeHeightAuto(){
  260. //页签大小铺满网页
  261. var tabsElement = document.querySelector('.tabs');
  262. tabsElement.style.minHeight = window.innerHeight+'px';
  263. }
  264. },
  265. }
  266. </script>
  267. <style >
  268. </style>