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.

686 lines
25 KiB

3 years ago
  1. <template>
  2. <div class="mode-config" style="padding: 5px">
  3. <el-form :inline="true" label-position="top" :model="searchData">
  4. <el-row>
  5. <el-col :span="24">
  6. <el-form-item label="客户编码">
  7. <el-input v-model="searchData.customerNo" placeholder="请输入内容" clearable style="width: 120px"/>
  8. </el-form-item>
  9. <el-form-item label="客户名称">
  10. <el-input v-model="searchData.customerName" placeholder="请输入内容" clearable style="width: 120px"/>
  11. </el-form-item>
  12. <el-form-item label="跟单员">
  13. <el-input v-model="searchData.trackerName" placeholder="请输入内容" clearable style="width: 120px"/>
  14. </el-form-item>
  15. <el-form-item label="报价单号">
  16. <el-input v-model="searchData.quotationNo" placeholder="请输入内容" clearable style="width: 120px"/>
  17. </el-form-item>
  18. <el-form-item label="客户询价单号">
  19. <el-input v-model="searchData.customerInquiryNo" placeholder="请输入内容" clearable style="width: 120px"/>
  20. </el-form-item>
  21. <el-form-item label="内部询价单号">
  22. <el-input v-model="searchData.internalInquiryNo" placeholder="请输入内容" clearable style="width: 120px"/>
  23. </el-form-item>
  24. <el-form-item label="状态">
  25. <el-select v-model="searchData.quotationStatus" placeholder="请选择" style="width: 120px">
  26. <el-option label="全部" value=""></el-option>
  27. <el-option label="草稿" value="草稿"></el-option>
  28. <el-option label="下达" value="下达"></el-option>
  29. </el-select>
  30. </el-form-item>
  31. </el-col>
  32. </el-row>
  33. <el-row>
  34. <el-col :span="24">
  35. <el-form-item label="项目编码">
  36. <el-input v-model="searchData.projectId" placeholder="请输入内容" clearable style="width: 120px"/>
  37. </el-form-item>
  38. <el-form-item label="项目名称">
  39. <el-input v-model="searchData.projectName" placeholder="请输入内容" clearable style="width: 120px"/>
  40. </el-form-item>
  41. <el-form-item label="销售员">
  42. <el-input v-model="searchData.quoterName" placeholder="请输入内容" size="large" clearable style="width: 120px;height: 28px"/>
  43. </el-form-item>
  44. <el-form-item label="报价日期">
  45. <el-date-picker
  46. style="width: 255px"
  47. v-model="searchData.dateValue"
  48. type="daterange"
  49. size="mini"
  50. format="yyyy/MM/dd"
  51. value-format="yyyy-MM-dd"
  52. range-separator="至"
  53. start-placeholder="开始日期"
  54. end-placeholder="结束日期"
  55. @change="changeDateRange"
  56. placeholder="选择日期">
  57. </el-date-picker>
  58. </el-form-item>
  59. <el-form-item label=" ">
  60. <el-button plain type="primary" @click="initData" @keyup.enter.native="initData">查询</el-button>
  61. <el-button type="primary" @click="insertDiaLogFlag = true">新增</el-button>
  62. </el-form-item>
  63. </el-col>
  64. </el-row>
  65. </el-form>
  66. <!-- 表格 和上述搜索框对应 -->
  67. <el-table :data="tableData" @row-click="rowClickQuotation" stripe border style="width: 100%;margin-top: 12px" :height="height">
  68. <el-table-column
  69. label="操作"
  70. align="center"
  71. fixed
  72. width="60">
  73. <template slot-scope="scope">
  74. <el-button type="text" style="padding: 0px 10px" size="small">下达</el-button>
  75. </template>
  76. </el-table-column>
  77. <el-table-column
  78. align="center"
  79. prop="quotationNo"
  80. label="报价单号"
  81. show-overflow-tooltip
  82. width="120">
  83. </el-table-column>
  84. <el-table-column
  85. align="center"
  86. prop="quotationDate"
  87. label="报价日期"
  88. show-overflow-tooltip
  89. width="120">
  90. </el-table-column>
  91. <el-table-column
  92. align="center"
  93. prop="customerNo"
  94. show-overflow-tooltip
  95. label="客户编码">
  96. </el-table-column>
  97. <el-table-column
  98. align="center"
  99. prop="customerName"
  100. show-overflow-tooltip
  101. label="客户名称">
  102. </el-table-column>
  103. <el-table-column
  104. align="center"
  105. prop="versionCode"
  106. show-overflow-tooltip
  107. label="版本号">
  108. </el-table-column>
  109. <el-table-column
  110. align="center"
  111. prop="projectId"
  112. show-overflow-tooltip
  113. label="项目编码">
  114. </el-table-column>
  115. <el-table-column
  116. align="center"
  117. prop="projectName"
  118. show-overflow-tooltip
  119. label="项目名称">
  120. </el-table-column>
  121. <el-table-column
  122. align="center"
  123. prop="quoterName"
  124. width="60"
  125. show-overflow-tooltip
  126. label="销售员">
  127. </el-table-column>
  128. <el-table-column
  129. align="center"
  130. prop="trackerName"
  131. width="60"
  132. show-overflow-tooltip
  133. label="跟单员">
  134. </el-table-column>
  135. <el-table-column
  136. align="center"
  137. prop="currency"
  138. width="60"
  139. show-overflow-tooltip
  140. label="货币">
  141. </el-table-column>
  142. <el-table-column
  143. align="center"
  144. prop="quotationStatus"
  145. show-overflow-tooltip
  146. width="60"
  147. label="状态">
  148. </el-table-column>
  149. <el-table-column
  150. align="center"
  151. prop="remark"
  152. show-overflow-tooltip
  153. width="60"
  154. label="备注">
  155. </el-table-column>
  156. <el-table-column
  157. align="center"
  158. prop="customerInquiryNo"
  159. show-overflow-tooltip
  160. label="客户询价单号">
  161. </el-table-column>
  162. <el-table-column
  163. align="center"
  164. prop="internalInquiryNo"
  165. show-overflow-tooltip
  166. label="内部询价单号">
  167. </el-table-column>
  168. </el-table>
  169. <!-- 分页插件 -->
  170. <el-pagination style="margin-top: 0px"
  171. @size-change="quotationHeaderSizeChange"
  172. @current-change="quotationHeaderCurrentChange"
  173. :current-page="no"
  174. :page-sizes="[20, 50, 100, 200, 500]"
  175. :page-size="size"
  176. :total="total"
  177. layout="total,sizes, prev, pager, next, jumper">
  178. </el-pagination>
  179. <!-- 标签页 -->
  180. <el-tabs v-model="activeTabName" @tab-click="handleClickTab"
  181. style="box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);border: 2px;min-height: 380px;margin-top: 5px;padding: 5px">
  182. <el-tab-pane label="明细" name="quotation_detail">
  183. <quotation-detail :quotation-header="quotationHeader"></quotation-detail>
  184. </el-tab-pane>
  185. <el-tab-pane label="审批" name="quotation_examine_and_approve">
  186. <quotation-examine-and-approve></quotation-examine-and-approve>
  187. </el-tab-pane>
  188. <el-tab-pane label="项目信息" name="quotation_project_information">
  189. <quotation-project-information></quotation-project-information>
  190. </el-tab-pane>
  191. <el-tab-pane label="客户信息" name="quotation_customer_information">
  192. <quotation-customer-information></quotation-customer-information>
  193. </el-tab-pane>
  194. <el-tab-pane label="客户联系人" name="quotation_customer_contact">
  195. <quotation-customer-contact></quotation-customer-contact>
  196. </el-tab-pane>
  197. </el-tabs>
  198. <!-- 新增弹框 -->
  199. <el-dialog title="新增报价" @close="closeInsertDialog" :close-on-click-modal="false" v-drag :visible.sync="insertDiaLogFlag" width="620px">
  200. <el-form :rules="rules" :inline="true" label-position="top" ref="insertQuotationForm" :model="insertData"
  201. label-width="120px">
  202. <el-row>
  203. <el-col :span="24">
  204. <el-form-item prop="internalInquiryNo">
  205. <span slot="label" style="" @click="quotationNoDialogFlag = true"><a herf="#">内部询价单号</a></span>
  206. <el-input v-model="insertData.internalInquiryNo" placeholder="请输入内容" clearable style="width: 280px"/>
  207. </el-form-item>
  208. <el-form-item label="客户询价单号" prop="customerInquiryNo">
  209. <el-input v-model="insertData.customerInquiryNo" placeholder="请输入内容" clearable style="width: 280px"/>
  210. </el-form-item>
  211. </el-col>
  212. <el-col :span="24">
  213. <el-form-item prop="customerNo">
  214. <span slot="label" style="" v-if="insertData.internalInquiryNo ==''" @click="getBaseList(102,1)"><a herf="#">客户编码</a></span>
  215. <span slot="label" style="" v-else><a herf="#">客户编码</a></span>
  216. <el-input v-model="insertData.customerNo" :disabled="insertData.internalInquiryNo !=''" placeholder="请输入内容" clearable style="width: 280px"/>
  217. </el-form-item>
  218. <el-form-item prop="customerName">
  219. <span slot="label" style="" v-if="insertData.internalInquiryNo ==''" @click="getBaseList(102,1)"><a herf="#">客户</a></span>
  220. <span slot="label" style="" v-else><a herf="#">客户</a></span>
  221. <el-input v-model="insertData.customerName" :disabled="insertData.internalInquiryNo !=''" placeholder="请输入内容" clearable style="width: 280px"/>
  222. </el-form-item>
  223. </el-col>
  224. <el-col :span="24">
  225. <el-form-item prop="projectId">
  226. <span slot="label" style="" v-if="insertData.internalInquiryNo ==''" @click="getBaseList(104,1)"><a herf="#">项目编码</a></span>
  227. <span slot="label" style="" v-else><a herf="#">项目编码</a></span>
  228. <el-input v-model="insertData.projectId" :disabled="insertData.internalInquiryNo !=''" placeholder="请输入内容" clearable style="width: 280px"/>
  229. </el-form-item>
  230. <el-form-item prop="projectName">
  231. <span slot="label" style="" v-if="insertData.internalInquiryNo ==''" @click="getBaseList(104,1)"><a herf="#">项目名称</a></span>
  232. <span slot="label" style="" v-else><a herf="#">项目名称</a></span>
  233. <el-input v-model="insertData.projectName" :disabled="insertData.internalInquiryNo !=''" placeholder="请输入内容" clearable style="width: 280px"/>
  234. </el-form-item>
  235. </el-col>
  236. <el-col :span="24">
  237. <el-form-item label="货币" prop="currency">
  238. <el-input v-model="insertData.currency" placeholder="请输入内容" size="large" clearable style="width: 280px"/>
  239. </el-form-item>
  240. <el-form-item label="报价日期" prop="quotationDate">
  241. <el-date-picker
  242. style="width: 280px"
  243. v-model="insertData.quotationDate"
  244. type="date"
  245. size="mini"
  246. format="yyyy/MM/dd"
  247. value-format="yyyy-MM-dd"
  248. placeholder="选择日期">
  249. </el-date-picker>
  250. </el-form-item>
  251. </el-col>
  252. <el-col>
  253. <el-form-item prop="quoter">
  254. <span slot="label" style="" v-if="insertData.internalInquiryNo ==''" @click="getBaseList(103,2)"><a herf="#">销售员</a></span>
  255. <span slot="label" style="" v-else><a herf="#">销售员</a></span>
  256. <el-input v-model="insertData.quoterName" :disabled="insertData.internalInquiryNo !=''" @clear="clearQuoter" placeholder="请输入内容" clearable style="width: 280px"/>
  257. </el-form-item>
  258. <el-form-item prop="tracker">
  259. <span slot="label" style="" v-if="insertData.internalInquiryNo ==''" @click="getBaseList(103,1)"><a herf="#">跟单员</a></span>
  260. <span slot="label" style="" v-else ><a herf="#">跟单员</a></span>
  261. <el-input v-model="insertData.trackerName" :disabled="insertData.internalInquiryNo !=''" @clear="clearTracker" placeholder="请输入内容" size="large" clearable style="width: 280px"/>
  262. </el-form-item>
  263. </el-col>
  264. <el-col :span="24">
  265. <el-form-item label="状态" prop="quotationStatus">
  266. <el-select v-model="insertData.quotationStatus" style="width: 280px" :disabled="insertData.internalInquiryNo !=''" clearable placeholder="请选择" >
  267. <el-option label="草稿" value="草稿"></el-option>
  268. <el-option label="下达" value="下达"></el-option>
  269. </el-select>
  270. </el-form-item>
  271. <el-form-item label=" ">
  272. <el-checkbox v-model="insertData.requireApproval" style="width: 23%" true-label="0" false-label="1" label="需要审批"></el-checkbox>
  273. <el-checkbox v-model="insertData.approvalStatus" style="width: 22%" true-label="已审批" false-label="未审批" label="是否审批"></el-checkbox>
  274. </el-form-item>
  275. </el-col>
  276. <el-col :span="24">
  277. <el-form-item label="备注" style="width: 100%;min-height: 70px">
  278. <el-input type="textarea" style="width: 100%" :show-word-limit="true" v-model="insertData.remark"/>
  279. </el-form-item>
  280. </el-col>
  281. </el-row>
  282. </el-form>
  283. <el-footer style="height:30px;margin-top: 20px;text-align:center">
  284. <el-button type="primary" @click="insertDiaLogFlag = false">关闭</el-button>
  285. <el-button type="primary" @click="insertQuotationHeader">保存</el-button>
  286. </el-footer>
  287. </el-dialog>
  288. <!--询价单号选择弹框-->
  289. <el-dialog title="内部询价单号"
  290. :close-on-click-modal="false" :close-on-press-escape="false"
  291. @close="closeQuotationNoDialog"
  292. @open="openQuotationNoDialog"
  293. :visible.sync="quotationNoDialogFlag"
  294. width="685px" v-drag>
  295. <el-form label-position="top"
  296. inline="inline"
  297. :model="quotationNoSearchData"
  298. size="mini"
  299. label-width="120px">
  300. <el-form-item label="询价单号">
  301. <el-input v-model="quotationNoSearchData.quotationNo" clearable/>
  302. </el-form-item>
  303. <el-form-item label=" ">
  304. <el-button type="primary" style="padding: 3px 12px" @click="searchQuotationData">查询</el-button>
  305. </el-form-item>
  306. </el-form>
  307. <el-table :data="quotationNoData" stripe border @cell-dblclick="dblclickQuotationNo">
  308. <el-table-column prop="quotationNo" label="询价单号">
  309. </el-table-column>
  310. <el-table-column prop="projectName" label="项目名称">
  311. </el-table-column>
  312. </el-table>
  313. <el-footer style="height:30px;margin-top: 20px;text-align:center">
  314. <el-button type="primary" @click="quotationNoDialogFlag = false">关闭</el-button>
  315. </el-footer>
  316. </el-dialog>
  317. <!-- chooseList模态框 -->
  318. <Chooselist ref="baseList" @getBaseData="getBaseData"></Chooselist>
  319. </div>
  320. </template>
  321. <script>
  322. import quotationDetail from "../../../components/quotation/sellForQuotation/quotationDetail.vue";
  323. import quotationExamineAndApprove from "../../../components/quotation/sellForQuotation/quotationExamineAndApprove.vue";
  324. import quotationProjectInformation from "../../../components/quotation/sellForQuotation/quotationProjectInformation.vue";
  325. import quotationCustomerInformation from "../../../components/quotation/sellForQuotation/quotationCustomerInformation.vue";
  326. import quotationCustomerContact from "../../../components/quotation/sellForQuotation/quotationCustomerContact.vue";
  327. import Chooselist from '@/views/modules/common/Chooselist';
  328. import {
  329. getQuotationHeaderByPage,
  330. insertQuotationHeader,
  331. } from '@/api/quotation/quotationHeader.js';
  332. import {
  333. searchQuotationByQuotationNo,
  334. } from '@/api/quotation/quotationInformation.js';
  335. export default {
  336. components:{
  337. Chooselist,
  338. quotationDetail,
  339. quotationExamineAndApprove,
  340. quotationProjectInformation,
  341. quotationCustomerInformation,
  342. quotationCustomerContact,
  343. },
  344. data () {
  345. return {
  346. // 搜索条件对象
  347. searchData:{
  348. site:this.$store.state.user.site,// 工厂编号
  349. customerNo:"", // 客户编码
  350. customer:"", // 客户名称
  351. tracker:"", // 跟单员
  352. quotationStatus:"", //状态
  353. projectId:"", // 项目编码
  354. projectName:"", // 项目名称
  355. quoterName:"", // 销售员
  356. startDate:"", // 开始日期
  357. endDate:"", // 结束日期
  358. dateValue:[],// 开始时间结束时间数组
  359. },
  360. tableData: [],// 查询的数据
  361. // 分页信息
  362. no:1,//页码
  363. size:20,//每页条数
  364. total:0,//总页数
  365. // 表格高度
  366. height:200,
  367. // 标签页
  368. activeTabName:"quotation_detail",
  369. //dialog 控制开关
  370. insertDiaLogFlag:false,
  371. quotationNoDialogFlag:false,
  372. // 新增对象
  373. insertData:{
  374. site:this.$store.state.user.site,
  375. quotationNo:"",//客户报价单号
  376. quotationDate:new Date(),//报价日期
  377. customerNo:"", // 客户编号
  378. customerName:"",//客户名称
  379. versionCode:"001",
  380. projectId:"",//项目编码
  381. projectName:"",//项目名称
  382. tracker:"",//跟单员
  383. quoter:"",//销售编号
  384. quoterName:"",//销售员
  385. trackerName:"",//跟单员
  386. currency:"",//货币
  387. quotationStatus:"草稿",//状态
  388. remark:"",//备注
  389. customerInquiryNo:"",//客户询价单号
  390. internalInquiryNo:"",//内部询价单号
  391. requireApproval:"",//需要审批
  392. approvalStatus:"",//审批状态
  393. createBy:this.$store.state.user.id,//当前登录账号
  394. createDate:new Date(),//当前时间
  395. },
  396. // 规则
  397. rules: {
  398. customerNo: [
  399. { required: true,message:' '},
  400. ],
  401. customerName: [
  402. { required: true,message:' '},
  403. ],
  404. projectId:[
  405. { required: true,message:' '}
  406. ],
  407. projectName:[
  408. { required: true,message:' '}
  409. ],
  410. tracker:[
  411. { required: true,message:' '}
  412. ],
  413. trackerName:[
  414. { required: true,message:' '}
  415. ],
  416. currency:[
  417. { required: true,message:' '}
  418. ],
  419. quoter:[
  420. { required: true,message:' '}
  421. ],
  422. quoterName:[
  423. { required: true,message:' '}
  424. ],
  425. quotationStatus:[
  426. { required: true,message:' '}
  427. ],
  428. quotationDate:[
  429. { required: true,message:' '}
  430. ],
  431. },
  432. // 参数 选择框
  433. tagNo1:"",
  434. tagNo:"",
  435. // 内部报价单搜索表单对象
  436. quotationNoSearchData:{
  437. quotationNo:"",//单号
  438. site:this.$store.state.user.site,//工厂编号
  439. },
  440. //内部报价单搜索表格数据对象
  441. quotationNoData:[],
  442. // 行对象
  443. quotationHeader:{},
  444. }
  445. },
  446. methods: {
  447. // 点击quotation行事件
  448. rowClickQuotation(row){
  449. this.quotationHeader = row;
  450. },
  451. // 搜索条件中的时间输入框 change事件
  452. changeDateRange(){
  453. this.searchData.startDate = this.searchData.dateValue[0];
  454. this.searchData.endDate = this.searchData.dateValue[1];
  455. },
  456. // 初始化数据
  457. initData(){
  458. let params = {
  459. no:this.no,
  460. size:this.size,
  461. site:this.$store.state.user.site,
  462. customerNo:this.searchData.customerNo,
  463. customerName:this.searchData.customerName,
  464. trackerName:this.searchData.trackerName,
  465. quotationNo:this.searchData.quotationNo,
  466. customerInquiryNo:this.searchData.customerInquiryNo,
  467. internalInquiryNo:this.searchData.internalInquiryNo,
  468. quotationStatus:this.searchData.quotationStatus,
  469. projectId:this.searchData.projectId,
  470. projectName:this.searchData.projectName,
  471. quoterName:this.searchData.quoterName,
  472. startDate:this.searchData.startDate,
  473. endDate: this.searchData.endDate,
  474. }
  475. getQuotationHeaderByPage(params).then(({data})=>{
  476. this.tableData = data.data.records;
  477. this.total = data.data.total;
  478. this.quotationHeader = this.tableData[0];
  479. })
  480. },
  481. // size 发送改变
  482. quotationHeaderSizeChange(val){
  483. this.size = val;
  484. this.initData();
  485. },
  486. // no发生改变
  487. quotationHeaderCurrentChange(val){
  488. this.no = val;
  489. this.initData();
  490. },
  491. // 新增QuotationHeader
  492. insertQuotationHeader(){
  493. // 校验
  494. this.$refs['insertQuotationForm'].validate((valid)=>{
  495. if (valid){
  496. // 请求
  497. insertQuotationHeader(this.insertData).then(({data})=>{
  498. console.log("回调结果:",data)
  499. // 返回提示
  500. if (data.code === 200){
  501. this.initData();
  502. this.insertDiaLogFlag = false;
  503. }
  504. this.$message.success(data.msg);
  505. })
  506. }else {
  507. this.$message.warning("校验未通过,必填项未填!");
  508. }
  509. })
  510. },
  511. // resetInsertData 重置新增对象
  512. resetInsertData(){
  513. this.insertData = {
  514. site:this.$store.state.user.site,
  515. quotationNo:"",//客户报价单号
  516. quotationDate:new Date(),//报价日期
  517. customerNo:"", // 客户编号
  518. customerName:"",//客户名称
  519. versionCode:"001",
  520. projectId:"",//项目编码
  521. projectName:"",//项目名称
  522. tracker:"",//跟单员
  523. quoter:"",//销售编号
  524. quoterName:"",//销售员
  525. trackerName:"",//跟单员
  526. currency:"",//货币
  527. quotationStatus:"草稿",//状态
  528. remark:"",//备注
  529. customerInquiryNo:"",//客户询价单号
  530. internalInquiryNo:"",//内部询价单号
  531. requireApproval:"",//需要审批
  532. approvalStatus:"",//审批状态
  533. createBy:this.$store.state.user.id,//当前登录账号
  534. createDate:new Date(),//当前时间
  535. }
  536. },
  537. // 销售员输入框清除事件
  538. clearQuoter(){
  539. this.insertData.quoter = "";
  540. this.insertData.quoterName = "";
  541. },
  542. // 跟单员输入框清除事件
  543. clearTracker(){
  544. this.insertData.tracker = "";
  545. this.insertData.trackerName = "";
  546. },
  547. // 新增弹框关闭事件
  548. closeInsertDialog(){
  549. this.resetInsertData();
  550. this.$refs['insertQuotationForm'].resetFields();
  551. },
  552. // 点击标签页
  553. handleClickTab(tab, event){
  554. },
  555. // ======== chooseList相关方法 ========
  556. /**
  557. * 获取基础数据列表S
  558. * @param val
  559. * @param type
  560. */
  561. getBaseList (val, type) {
  562. this.tagNo = val
  563. this.tagNo1 = type
  564. this.$nextTick(() => {
  565. let strVal = ''
  566. if (val === 102) {
  567. if(type === 1) {
  568. strVal = this.insertData.customerNo
  569. }
  570. }
  571. if (val === 103) {
  572. if(type === 1) {
  573. strVal = this.insertData.tracker
  574. }
  575. if(type === 2) {
  576. strVal = this.insertData.quoter
  577. }
  578. }
  579. if (val === 104) {
  580. if(type === 1) {
  581. strVal = this.insertData.projectId
  582. }
  583. }
  584. this.$refs.baseList.init(val, strVal)
  585. })
  586. },
  587. /**
  588. * 列表方法的回调
  589. * @param val
  590. */
  591. getBaseData (val) {
  592. if (this.tagNo === 102) {
  593. if(this.tagNo1 === 1) {
  594. this.insertData.customerNo = val.Customer_no
  595. this.insertData.customerName = val.Customer_desc
  596. }
  597. }
  598. if (this.tagNo === 103) {
  599. if(this.tagNo1 === 1) {
  600. this.insertData.tracker = val.username
  601. this.insertData.trackerName = val.user_display
  602. }
  603. if(this.tagNo1 === 2) {
  604. this.insertData.quoter = val.username
  605. this.insertData.quoterName = val.user_display
  606. }
  607. }
  608. if (this.tagNo === 104) {
  609. if(this.tagNo1 === 1) {
  610. this.insertData.projectId = val.project_id
  611. this.insertData.projectName = val.project_name
  612. }
  613. }
  614. },
  615. // 查询 内部报价单编号
  616. searchQuotationData(){
  617. searchQuotationByQuotationNo(this.quotationNoSearchData).then(({data})=>{
  618. this.quotationNoData = data.data;
  619. })
  620. },
  621. // 打开 内部报价单拟态框
  622. openQuotationNoDialog(){
  623. // 请求
  624. this.searchQuotationData();
  625. },
  626. // 关闭
  627. closeQuotationNoDialog(){
  628. this.quotationNoSearchData = {
  629. quotationNo:"",//单号
  630. site:this.$store.state.user.site,//工厂编号
  631. }
  632. },
  633. // 询价表双击事件
  634. dblclickQuotationNo(row){
  635. this.insertData.customerNo = row.customerNo
  636. this.insertData.customerName=row.customerDesc,//客户名称
  637. this.insertData.projectId=row.projectId,//项目编码
  638. this.insertData.projectName=row.projectName,//项目名称
  639. this.insertData.tracker=row.tracker,//跟单员
  640. this.insertData.quoter=row.quoter,//销售编号
  641. this.insertData.quoterName=row.quoterName,//销售员
  642. this.insertData.trackerName=row.trackerName,//跟单员
  643. this.insertData.quotationStatus=row.quotationStatus,//状态
  644. this.insertData.internalInquiryNo=row.quotationNo,//内部询价单号
  645. // 关闭弹框
  646. this.quotationNoDialogFlag = false;
  647. }
  648. },
  649. computed:{
  650. },
  651. mounted () {
  652. this.$nextTick(() => {
  653. this.height = window.innerHeight / 2 - 240;
  654. })
  655. },
  656. created () {
  657. this.initData();//初始化数据
  658. },
  659. }
  660. </script>
  661. <style scoped lang="scss">
  662. /deep/ .el-range-editor--mini.el-input__inner {
  663. height: 20px;
  664. }
  665. /deep/ .el-range-editor.el-input__inner{
  666. padding: 0px 10px;
  667. }
  668. /deep/ .el-date-editor .el-range-separator{
  669. width: auto;
  670. }
  671. /deep/ .el-input--mini .el-input__icon{
  672. line-height: 20px;
  673. }
  674. </style>