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.

780 lines
26 KiB

1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
11 months ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
11 months ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
11 months ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
8 months ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
8 months ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
  1. <script>
  2. import {getSiteAndBuByUserName} from "../../../api/qc/qc";
  3. import {queryQuoteDetailById, queryQuoteDetailReport, updateQuoteDetail} from "../../../api/quote/quoteDetail";
  4. import {getItemListByInquiryPartAndCodeNo} from "../../../api/inquiry/inquiryDetail";
  5. import BreakdownCost from "./detail/breakdownCost.vue";
  6. import BuSelect from "../../../components/selector/select/BuSelect.vue";
  7. import {queryPropertyTemplate} from "../../../api/property/template";
  8. import {queryPropertyTemplateDetailAvailableList} from "../../../api/property/templateDetail";
  9. import {againQuote} from "../../../api/quote/quote";
  10. import QuoteDetailTool from "./detail/primary/quoteDetailTool.vue";
  11. import QuoteDetailBom from "./detail/primary/quoteDetailBom.vue";
  12. import QuoteDetailOther from "./detail/primary/quoteDetailOther.vue";
  13. import QuoteDetailCost from "./detail/primary/quoteDetailCost.vue";
  14. import QuoteDetailRouting from "./detail/primary/quoteDetailRouting.vue";
  15. import TpCost from "./detail/tpCost.vue";
  16. import {getTableDefaultListLanguage, getTableUserListLanguage, updateColumnSize} from "../../../api/table";
  17. export default {
  18. name: "quoteDetailReport",
  19. components: {
  20. TpCost,
  21. QuoteDetailRouting,
  22. QuoteDetailCost,
  23. QuoteDetailOther,
  24. QuoteDetailBom,
  25. QuoteDetailTool,
  26. BuSelect,
  27. BreakdownCost
  28. },
  29. props: {
  30. height: {
  31. type: [String, Number],
  32. default: "38vh"
  33. }
  34. },
  35. data() {
  36. return {
  37. queryForm: {
  38. buId: '',
  39. customerNo: '',
  40. customerDesc: '',
  41. partNo: '',
  42. partDesc: '',
  43. quoteVersionNo: '',
  44. },
  45. no: 1,
  46. size: 20,
  47. total: 0,
  48. dataList: [],
  49. queryLoading: false,
  50. userBuList: [],
  51. columns: [
  52. {
  53. userId: this.$store.state.user.name,
  54. functionId: 5013,
  55. serialNumber: '5011Table1BuDesc',
  56. tableId: '5013Table1',
  57. tableName: '报价信息表',
  58. columnProp: 'buDesc',
  59. headerAlign: 'center',
  60. align: 'center',
  61. columnLabel: 'BU',
  62. columnHidden: false,
  63. columnImage: false,
  64. columnSortable: false,
  65. sortLv: 0,
  66. status: true,
  67. fixed: '',
  68. columnWidth: 80
  69. },
  70. {
  71. userId: this.$store.state.user.name,
  72. functionId: 5013,
  73. serialNumber: '5011Table1QuoteVersionNo',
  74. tableId: '5013Table1',
  75. tableName: '报价信息表',
  76. columnProp: 'quoteVersionNo',
  77. headerAlign: 'center',
  78. align: 'center',
  79. columnLabel: '报价单',
  80. columnHidden: false,
  81. columnImage: false,
  82. columnSortable: false,
  83. sortLv: 0,
  84. status: true,
  85. fixed: '',
  86. columnWidth: 140
  87. },
  88. {
  89. userId: this.$store.state.user.name,
  90. functionId: 5013,
  91. serialNumber: '5011Table1CustomerNo',
  92. tableId: '5013Table1',
  93. tableName: '报价信息表',
  94. columnProp: 'customerNo',
  95. headerAlign: 'center',
  96. align: 'center',
  97. columnLabel: '客户编码',
  98. columnHidden: false,
  99. columnImage: false,
  100. columnSortable: false,
  101. sortLv: 0,
  102. status: true,
  103. fixed: '',
  104. columnWidth: 80
  105. },
  106. {
  107. userId: this.$store.state.user.name,
  108. functionId: 5013,
  109. serialNumber: '5011Table1CustomerDesc',
  110. tableId: '5013Table1',
  111. tableName: '报价信息表',
  112. columnProp: 'customerDesc',
  113. headerAlign: 'center',
  114. align: 'center',
  115. columnLabel: '客户名称',
  116. columnHidden: false,
  117. columnImage: false,
  118. columnSortable: false,
  119. sortLv: 0,
  120. status: true,
  121. fixed: '',
  122. columnWidth: 140
  123. },
  124. {
  125. userId: this.$store.state.user.name,
  126. functionId: 5013,
  127. serialNumber: '5011Table1QuoteDate',
  128. tableId: '5013Table1',
  129. tableName: '报价信息表',
  130. columnProp: 'quoteDate',
  131. headerAlign: 'center',
  132. align: 'center',
  133. columnLabel: '报价日期',
  134. columnHidden: false,
  135. columnImage: false,
  136. columnSortable: false,
  137. sortLv: 0,
  138. status: true,
  139. fixed: '',
  140. columnWidth: 120
  141. }, {
  142. userId: this.$store.state.user.name,
  143. functionId: 5013,
  144. serialNumber: '5011Table1CustomerInquiryNo',
  145. tableId: '5013Table1',
  146. tableName: '报价信息表',
  147. columnProp: 'customerInquiryNo',
  148. headerAlign: 'center',
  149. align: 'center',
  150. columnLabel: '客户询价单号',
  151. columnHidden: false,
  152. columnImage: false,
  153. columnSortable: false,
  154. sortLv: 0,
  155. status: true,
  156. fixed: '',
  157. columnWidth: 100
  158. },
  159. {
  160. userId: this.$store.state.user.name,
  161. functionId: 5013,
  162. serialNumber: '5011Table1PartNo',
  163. tableId: '5013Table1',
  164. tableName: '报价信息表',
  165. columnProp: 'partNo',
  166. headerAlign: 'center',
  167. align: 'center',
  168. columnLabel: '物料编码',
  169. columnHidden: false,
  170. columnImage: false,
  171. columnSortable: false,
  172. sortLv: 0,
  173. status: true,
  174. fixed: '',
  175. columnWidth: 100
  176. },
  177. {
  178. userId: this.$store.state.user.name,
  179. functionId: 5013,
  180. serialNumber: '5011Table1PartDesc',
  181. tableId: '5013Table1',
  182. tableName: '报价信息表',
  183. columnProp: 'partDesc',
  184. headerAlign: 'center',
  185. align: 'center',
  186. columnLabel: '物料描述',
  187. columnHidden: false,
  188. columnImage: false,
  189. columnSortable: false,
  190. sortLv: 0,
  191. status: true,
  192. fixed: '',
  193. columnWidth: 240
  194. },
  195. {
  196. userId: this.$store.state.user.name,
  197. functionId: 5013,
  198. serialNumber: '5011Table1Status',
  199. tableId: '5013Table1',
  200. tableName: '报价信息表',
  201. columnProp: 'status',
  202. headerAlign: 'center',
  203. align: 'center',
  204. columnLabel: '状态',
  205. columnHidden: false,
  206. columnImage: false,
  207. columnSortable: false,
  208. sortLv: 0,
  209. status: true,
  210. fixed: '',
  211. columnWidth: 80
  212. },
  213. {
  214. userId: this.$store.state.user.name,
  215. functionId: 5013,
  216. serialNumber: '5011Table1CreateDate',
  217. tableId: '5013Table1',
  218. tableName: '报价信息表',
  219. columnProp: 'createDate',
  220. headerAlign: 'center',
  221. align: 'center',
  222. columnLabel: '创建日期',
  223. columnHidden: false,
  224. columnImage: false,
  225. columnSortable: false,
  226. sortLv: 0,
  227. status: true,
  228. fixed: '',
  229. columnWidth: 130
  230. },
  231. {
  232. userId: this.$store.state.user.name,
  233. functionId: 5013,
  234. serialNumber: '5011Table1CreateBy',
  235. tableId: '5013Table1',
  236. tableName: '报价信息表',
  237. columnProp: 'createBy',
  238. headerAlign: 'center',
  239. align: 'center',
  240. columnLabel: '创建人',
  241. columnHidden: false,
  242. columnImage: false,
  243. columnSortable: false,
  244. sortLv: 0,
  245. status: true,
  246. fixed: '',
  247. columnWidth: 100
  248. },
  249. {
  250. userId: this.$store.state.user.name,
  251. functionId: 5013,
  252. serialNumber: '5011Table1Site',
  253. tableId: '5013Table1',
  254. tableName: '报价信息表',
  255. columnProp: 'site',
  256. headerAlign: 'center',
  257. align: 'center',
  258. columnLabel: '工厂编码',
  259. columnHidden: false,
  260. columnImage: false,
  261. columnSortable: false,
  262. sortLv: 0,
  263. status: true,
  264. fixed: '',
  265. columnWidth: 80
  266. },
  267. ],
  268. currentRow: {},
  269. activeName: 'detail',
  270. inquiryDataList: [],
  271. queryPropertyLoading: false,
  272. propertyVisible: false,
  273. propertyList: [],
  274. currentProperty: {
  275. id: undefined,
  276. codeNo: '',
  277. codeDesc: '',
  278. },
  279. propertyItemList: [],
  280. count: 0,
  281. }
  282. },
  283. methods: {
  284. // 动态列开始 获取 用户保存的 格式列
  285. async getTableUserColumn(tableId, columnId) {
  286. let queryTableUser = {
  287. userId: this.$store.state.user.name,
  288. functionId: this.$route.meta.menuId,
  289. tableId: tableId,
  290. status: true,
  291. languageCode: this.$i18n.locale
  292. }
  293. await getTableUserListLanguage(queryTableUser).then(({data}) => {
  294. if (data.rows.length > 0) {
  295. switch (columnId) {
  296. case 1:
  297. this.columns = data.rows
  298. break;
  299. }
  300. } else {
  301. this.getColumnList(tableId, columnId)
  302. }
  303. })
  304. },
  305. // 获取 tableDefault 列
  306. async getColumnList (tableId, columnId) {
  307. let queryTable= {
  308. functionId: this.$route.meta.menuId,
  309. tableId: tableId,
  310. languageCode: this.$i18n.locale
  311. }
  312. await getTableDefaultListLanguage(queryTable).then(({data}) => {
  313. if (!data.rows.length === 0) {
  314. switch (columnId) {
  315. case 1:
  316. this.columns = data.rows
  317. break;
  318. }
  319. }
  320. })
  321. },
  322. handleColumnResize(newWidth, oldWidth, column, event){
  323. let inData= this.columnList.filter(item => item.columnProp === column.property)[0]
  324. inData.columnWidth=newWidth
  325. updateColumnSize(inData).then(({data}) => {
  326. if (data.code === 0) {
  327. console.log("栏位宽度保存成功!")
  328. }
  329. })
  330. },
  331. getSiteAndBuByUserName() {
  332. let tempData = {
  333. username: this.$store.state.user.name,
  334. }
  335. getSiteAndBuByUserName(tempData).then(({data}) => {
  336. if (data.code === 0) {
  337. this.userBuList = data.rows
  338. }
  339. })
  340. },
  341. handleQuery() {
  342. let list = [];
  343. if (this.propertyItemList.length > 0) {
  344. list = this.propertyItemList.filter(item => item.textValue || item.numValue);
  345. }
  346. let params = {
  347. ...this.queryForm,
  348. no: this.no,
  349. size: this.size,
  350. codeId: this.currentProperty.id,
  351. list,
  352. }
  353. this.queryLoading = true
  354. queryQuoteDetailReport(params).then(({data}) => {
  355. if (data && data.code === 0) {
  356. this.dataList = data.rows
  357. this.total = data.total
  358. if (this.total === 0) {
  359. this.currentRow = {}
  360. } else if (this.currentRow.id !== undefined) {
  361. // this.currentRow = {}
  362. } else {
  363. this.currentRow = this.dataList[0]
  364. }
  365. } else {
  366. this.$message.warning(data.msg)
  367. }
  368. this.queryLoading = false
  369. }).catch((error) => {
  370. this.$message.error(error)
  371. this.queryLoading = false
  372. })
  373. },
  374. handleRowClick(row) {
  375. this.currentRow = {...row}
  376. },
  377. rowStyle({row}) {
  378. if (this.currentRow && this.currentRow.id === row.id) {
  379. return {'background-color': '#E8F7F6'};
  380. } else {
  381. return {}
  382. }
  383. },
  384. handleSizeChange(val) {
  385. this.size = val
  386. this.handleQuery()
  387. },
  388. handlePageChange(val) {
  389. this.no = val
  390. this.handleQuery()
  391. },
  392. handleQueryInquiryProperties() {
  393. if (this.currentRow.id === undefined) {
  394. this.inquiryDataList = []
  395. return
  396. }
  397. let params = {
  398. inquiryPartId: this.currentRow.rfqDetailId,
  399. buNo: this.currentRow.buNo,
  400. site: this.currentRow.site,
  401. recordType: 'PRICECHECK',
  402. }
  403. this.queryPropertyLoading = true
  404. getItemListByInquiryPartAndCodeNo(params).then(({data}) => {
  405. if (data && data.code === 0) {
  406. this.inquiryDataList = data.rows
  407. } else {
  408. this.$message.warning(data.msg)
  409. }
  410. this.queryPropertyLoading = false
  411. }).catch((error) => {
  412. this.$message.error(error)
  413. this.queryPropertyLoading = false
  414. })
  415. },
  416. handleClickProperty() {
  417. if (!this.queryForm.buId) {
  418. this.$message.warning('请先选择BU')
  419. return
  420. }
  421. // this.handleQueryProperty();
  422. this.propertyVisible = true;
  423. },
  424. handleQueryProperty() {
  425. let params = {
  426. buId: this.queryForm.buId,
  427. createBy: this.$store.state.user.name,
  428. functionType: 'IP'
  429. }
  430. queryPropertyTemplate(params).then(({data}) => {
  431. if (data && data.code === 0) {
  432. this.propertyList = data.rows
  433. if (this.propertyList.length > 0) {
  434. this.currentProperty.id = this.propertyList[0].id
  435. this.currentProperty.codeNo = this.propertyList[0].codeNo
  436. }
  437. } else {
  438. this.$message.warning(data.msg)
  439. }
  440. }).catch((error) => {
  441. this.$message.error(error)
  442. })
  443. },
  444. handleQueryPropertyTemplateDetailAvailableList() {
  445. let params = {
  446. headerId: this.currentProperty.id,
  447. }
  448. this.propertyItemList = []
  449. queryPropertyTemplateDetailAvailableList(params).then(({data}) => {
  450. if (data && data.code === 0) {
  451. this.propertyItemList = data.rows
  452. } else {
  453. this.$message.warning(data.msg)
  454. }
  455. }).catch((error) => {
  456. this.$message.error(error)
  457. })
  458. },
  459. },
  460. created() {
  461. this.getSiteAndBuByUserName();
  462. this.getTableUserColumn(this.$route.meta.menuId+'table1',1)
  463. },
  464. activated() {
  465. if (this.$route.params.type && this.$route.params.type === 'quote'){
  466. this.queryForm.quoteVersionNo = this.$route.params.quoteVersionNo;
  467. this.count++
  468. this.handleQuery();
  469. }
  470. if (this.count === 0){
  471. this.handleQuery();
  472. }
  473. },
  474. watch: {
  475. currentRow(newVal, oldVal) {
  476. if (newVal) {
  477. this.handleQueryInquiryProperties()
  478. }
  479. },
  480. 'queryForm.buId'(newVal, oldVal) {
  481. this.currentProperty.id = undefined
  482. this.currentProperty.codeNo = ''
  483. this.propertyItemList = []
  484. if (newVal) {
  485. this.handleQueryProperty();
  486. }
  487. },
  488. 'currentProperty.id'(newVal, oldVal) {
  489. if (newVal) {
  490. this.handleQueryPropertyTemplateDetailAvailableList();
  491. }
  492. }
  493. }
  494. }
  495. </script>
  496. <template>
  497. <div>
  498. <div style="width: 1200px">
  499. <el-form :model="queryForm" label-position="top">
  500. <el-row :gutter="10">
  501. <el-col :span="3">
  502. <el-form-item label="BU">
  503. <bu-select v-model="queryForm.buId">
  504. <el-option label="全部" value=""></el-option>
  505. </bu-select>
  506. </el-form-item>
  507. </el-col>
  508. <el-col :span="3">
  509. <el-form-item label="报价单号">
  510. <el-input v-model="queryForm.quoteVersionNo"></el-input>
  511. </el-form-item>
  512. </el-col>
  513. <el-col :span="3">
  514. <el-form-item label="客户编码">
  515. <el-input v-model="queryForm.customerNo"></el-input>
  516. </el-form-item>
  517. </el-col>
  518. <el-col :span="3">
  519. <el-form-item label="客户名称">
  520. <el-input v-model="queryForm.customerDesc"></el-input>
  521. </el-form-item>
  522. </el-col>
  523. <el-col :span="3">
  524. <el-form-item label="产品编码">
  525. <el-input v-model="queryForm.partNo"></el-input>
  526. </el-form-item>
  527. </el-col>
  528. <el-col :span="6">
  529. <el-form-item label="产品描述">
  530. <el-input v-model="queryForm.partDesc"></el-input>
  531. </el-form-item>
  532. </el-col>
  533. <el-col :span="3">
  534. <el-form-item label=" ">
  535. <el-button type="primary" @click="handleClickProperty">属性</el-button>
  536. <el-button type="primary" @click="handleQuery">查询</el-button>
  537. </el-form-item>
  538. </el-col>
  539. </el-row>
  540. </el-form>
  541. </div>
  542. <el-table v-loading="queryLoading" :data="dataList" border :height="height" :row-style="rowStyle"
  543. @row-click="handleRowClick">
  544. <el-table-column
  545. v-for="(item,index) in columns" :key="index"
  546. :sortable="item.columnSortable"
  547. :prop="item.columnProp"
  548. :header-align="item.headerAlign"
  549. :show-overflow-tooltip="item.showOverflowTooltip"
  550. :align="item.align"
  551. :fixed="item.fixed===''?false:item.fixed"
  552. :min-width="item.columnWidth"
  553. :label="item.columnLabel">
  554. <template slot-scope="scope">
  555. <span v-if="!item.columnHidden">{{ scope.row[item.columnProp] }}</span>
  556. <span v-if="item.columnImage"><img :src="scope.row[item.columnProp]"
  557. style="width: 100px; height: 80px"/></span>
  558. </template>
  559. </el-table-column>
  560. </el-table>
  561. <el-pagination @size-change="handleSizeChange"
  562. @current-change="handlePageChange"
  563. :current-page="no"
  564. :page-sizes="[20, 50, 100, 200, 500]"
  565. :page-size="size"
  566. :total="total"
  567. layout="total,sizes, prev, pager, next, jumper">
  568. </el-pagination>
  569. <el-tabs v-model="activeName">
  570. <el-tab-pane label="详情" name="detail">
  571. <el-form :model="currentRow" label-position="top" style="width: 1000px">
  572. <el-row :gutter="10">
  573. <el-col :span="4">
  574. <el-form-item label="报价单号">
  575. <el-input v-model="currentRow.quoteVersionNo" readonly></el-input>
  576. </el-form-item>
  577. </el-col>
  578. <el-col :span="4">
  579. <el-form-item label="BU">
  580. <el-input v-model="currentRow.buDesc" readonly></el-input>
  581. </el-form-item>
  582. </el-col>
  583. <el-col :span="4">
  584. <el-form-item label="工厂编码">
  585. <el-input v-model="currentRow.site" readonly></el-input>
  586. </el-form-item>
  587. </el-col>
  588. </el-row>
  589. <el-row :gutter="10">
  590. <el-col :span="4">
  591. <el-form-item label="客户编码">
  592. <el-input v-model="currentRow.customerNo" readonly></el-input>
  593. </el-form-item>
  594. </el-col>
  595. <el-col :span="6">
  596. <el-form-item label="客户名称">
  597. <el-input v-model="currentRow.customerDesc" readonly></el-input>
  598. </el-form-item>
  599. </el-col>
  600. <el-col :span="4">
  601. <el-form-item label="状态">
  602. <el-input v-model="currentRow.status" readonly></el-input>
  603. </el-form-item>
  604. </el-col>
  605. <el-col :span="20">
  606. <el-form-item label="报价备注" class="auto" :show-message="false">
  607. <el-input type="textarea" v-model="currentRow.quoteRemark" resize="none" readonly></el-input>
  608. </el-form-item>
  609. </el-col>
  610. <el-col :span="20">
  611. <el-form-item label="报价详情备注" class="auto" :show-message="false">
  612. <el-input type="textarea" v-model="currentRow.remark" resize="none" readonly></el-input>
  613. </el-form-item>
  614. </el-col>
  615. </el-row>
  616. <el-row :gutter="10">
  617. <el-col :span="4">
  618. <el-form-item label="创建人">
  619. <el-input v-model="currentRow.createBy" readonly></el-input>
  620. </el-form-item>
  621. </el-col>
  622. <el-col :span="6">
  623. <el-form-item label="创建日期">
  624. <el-input v-model="currentRow.createDate" readonly></el-input>
  625. </el-form-item>
  626. </el-col>
  627. <el-col :span="4">
  628. <el-form-item label="最近更新人">
  629. <el-input v-model="currentRow.updateBy" readonly></el-input>
  630. </el-form-item>
  631. </el-col>
  632. <el-col :span="6">
  633. <el-form-item label="最近更新日期">
  634. <el-input v-model="currentRow.updateDate" readonly></el-input>
  635. </el-form-item>
  636. </el-col>
  637. </el-row>
  638. </el-form>
  639. </el-tab-pane>
  640. <el-tab-pane name="inquiry" label="询价单信息">
  641. <el-form :model="currentRow" label-position="top" style="width: 1000px">
  642. <el-row :gutter="10">
  643. <el-col :span="5">
  644. <el-form-item label="询价单号">
  645. <el-input v-model="currentRow.internalInquiryNo" readonly></el-input>
  646. </el-form-item>
  647. </el-col>
  648. <el-col :span="5">
  649. <el-form-item label="询价日期">
  650. <el-input v-model="currentRow.requestDate" readonly></el-input>
  651. </el-form-item>
  652. </el-col>
  653. <el-col :span="5">
  654. <el-form-item label="PJM">
  655. <el-input v-model="currentRow.requesterName" readonly></el-input>
  656. </el-form-item>
  657. </el-col>
  658. </el-row>
  659. <el-row :gutter="10">
  660. <el-col :span="5">
  661. <el-form-item label="客户询价单号">
  662. <el-input v-model="currentRow.customerInquiryNo" readonly></el-input>
  663. </el-form-item>
  664. </el-col>
  665. <el-col :span="5">
  666. <el-form-item label="要求报价日期">
  667. <el-input v-model="currentRow.requiredCompletionDate" readonly></el-input>
  668. </el-form-item>
  669. </el-col>
  670. <el-col :span="5">
  671. <el-form-item label="优先等级">
  672. <el-input v-model="currentRow.priorityLevel" readonly></el-input>
  673. </el-form-item>
  674. </el-col>
  675. <el-col :span="5">
  676. <el-form-item label="状态">
  677. <el-input v-model="currentRow.rfqStatus" readonly></el-input>
  678. </el-form-item>
  679. </el-col>
  680. <el-col :span="20">
  681. <el-form-item label="备注" class="auto" :show-message="false">
  682. <el-input type="textarea" v-model="currentRow.rfqRemark" resize="none" readonly></el-input>
  683. </el-form-item>
  684. </el-col>
  685. </el-row>
  686. </el-form>
  687. </el-tab-pane>
  688. <el-tab-pane name="property" label="询价单属性">
  689. <el-table :data="inquiryDataList" v-loading="queryPropertyLoading" height="36vh" border>
  690. <el-table-column label="属性编码" header-align="center" min-width="100" prop="itemNo"></el-table-column>
  691. <el-table-column label="属性名称" header-align="center" min-width="160" prop="itemDesc"></el-table-column>
  692. <el-table-column label="属性类型" header-align="center" min-width="80" prop="valueType"></el-table-column>
  693. <el-table-column label="属性值" header-align="center" min-width="100">
  694. <template slot-scope="scope">
  695. <span v-if="scope.row.valueType === '文本'">{{ scope.row.textValue }}</span>
  696. <span v-if="scope.row.valueType === '数字'">{{ scope.row.numValue }}</span>
  697. </template>
  698. </el-table-column>
  699. </el-table>
  700. </el-tab-pane>
  701. <el-tab-pane name="breakdown" label="Cost Breakdown">
  702. <breakdown-cost :quote-detail="currentRow" height="36vh"></breakdown-cost>
  703. </el-tab-pane>
  704. <el-tab-pane name="tp" label="TP">
  705. <tp-cost :quote-detail="currentRow" height="36vh"></tp-cost>
  706. </el-tab-pane>
  707. </el-tabs>
  708. <el-dialog title="属性详情" v-drag :visible.sync="propertyVisible" :close-on-click-modal="false" append-to-body
  709. width="800px">
  710. <el-form :model="currentProperty" label-position="top">
  711. <el-row :gutter="10">
  712. <el-col :span="4">
  713. <el-form-item label="BU">
  714. <bu-select v-model="queryForm.buId" disabled></bu-select>
  715. </el-form-item>
  716. </el-col>
  717. <el-col :span="8">
  718. <el-form-item label="属性模板">
  719. <el-select v-model="currentProperty.id" style="width: 100%;">
  720. <el-option v-for="item in propertyList" :key="item.id" :label="item.codeDesc" :value="item.id">
  721. <div style="float:left;">{{ item.codeDesc }}</div>
  722. <div style="float:right;">{{ item.codeNo }}</div>
  723. </el-option>
  724. </el-select>
  725. </el-form-item>
  726. </el-col>
  727. </el-row>
  728. </el-form>
  729. <div class="rq">
  730. <el-table :data="propertyItemList" border height="300px">
  731. <el-table-column label="属性编码" header-align="center" min-width="120" prop="itemNo"></el-table-column>
  732. <el-table-column label="属性名称" header-align="center" min-width="180" prop="itemDesc"></el-table-column>
  733. <el-table-column label="属性类型" header-align="center" align="center" min-width="80" prop="valueType"></el-table-column>
  734. <el-table-column label="属性值" header-align="center" min-width="140" prop="value">
  735. <template slot-scope="scope">
  736. <template v-if="scope.row.valueTypeDb==='T' && scope.row.valueChooseFlag==='Y'">
  737. <el-select v-model="scope.row['textValue']" placeholder="请选择" style="width: 100%" clearable>
  738. <el-option :label="available.availableValue" :value="available.availableValue" :key="available.id"
  739. v-for="(available) in scope.row.availableList"></el-option>
  740. </el-select>
  741. </template>
  742. <template v-else-if="scope.row.valueTypeDb==='N' && scope.row.valueChooseFlag==='Y'">
  743. <el-select v-model="scope.row['numValue']" placeholder="请选择" style="width: 100%" clearable>
  744. <el-option :label="available.availableValue" :value="available.availableValue" :key="available.id"
  745. v-for="(available) in scope.row.availableList"></el-option>
  746. </el-select>
  747. </template>
  748. <template v-else-if="scope.row.valueTypeDb==='T'">
  749. <el-input v-model="scope.row['textValue']"></el-input>
  750. </template>
  751. <template v-else-if="scope.row.valueTypeDb==='N'">
  752. <el-input-number style="width: 100%" :controls="false" :step="0"
  753. v-model="scope.row['numValue']"></el-input-number>
  754. </template>
  755. </template>
  756. </el-table-column>
  757. </el-table>
  758. </div>
  759. <div slot="footer" class="dialog-footer">
  760. <el-button type="primary" @click="propertyVisible = false"> </el-button>
  761. <el-button @click="propertyVisible = false"> </el-button>
  762. </div>
  763. </el-dialog>
  764. </div>
  765. </template>
  766. <style scoped>
  767. .auto /deep/ .el-form-item__content {
  768. height: auto;
  769. line-height: 1.5;
  770. }
  771. </style>