9 changed files with 2207 additions and 92 deletions
-
4src/api/auth/auth.js
-
2src/api/inquiry/inquiryApplication.js
-
2src/api/quote/quote.js
-
968src/views/modules/auth/authInfo.vue
-
194src/views/modules/auth/authInquiry.vue
-
1112src/views/modules/auth/authQuote.vue
-
10src/views/modules/eam/com_project_proof_record.vue
-
2src/views/modules/eam/eamProjectInfo.vue
-
5src/views/modules/eam/eamProjectPartInfo.vue
@ -0,0 +1,968 @@ |
|||||
|
<template> |
||||
|
<div class="mod-config"> |
||||
|
<!-- 查询条件 --> |
||||
|
<el-form :inline="true" label-position="top" :model="searchData" @keyup.enter.native="getDataList()"> |
||||
|
<el-form-item :label="'BU'"> |
||||
|
<el-select v-model="searchData.bu" placeholder="请选择" clearable style="width: 120px"> |
||||
|
<el-option |
||||
|
v-for = "i in userBuList" |
||||
|
:key = "i.buNo" |
||||
|
:label = "i.buDesc" |
||||
|
:value = "i.buNo"> |
||||
|
</el-option> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="询价单号"> |
||||
|
<el-input v-model="searchData.applicationNo" clearable style="width: 120px"></el-input> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="客户编码"> |
||||
|
<span style="cursor: pointer" slot="label" @click="getBaseList(509,2)"><a herf="#">客户编码</a></span> |
||||
|
<el-input v-model="searchData.customerNo" clearable style="width: 120px"></el-input> |
||||
|
</el-form-item> |
||||
|
<el-form-item :label="'客户名称'"> |
||||
|
<el-input v-model="searchData.customerDesc" clearable style="width: 120px"></el-input> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="客户询价单号"> |
||||
|
<el-input v-model="searchData.customerInquiryNo"></el-input> |
||||
|
</el-form-item> |
||||
|
<el-form-item :label="'报价专员'"> |
||||
|
<span style="cursor: pointer" slot="label" @click="getBaseList(2002,1)"><a herf="#">报价专员</a></span> |
||||
|
<el-input v-model="searchData.quoterName" clearable style="width: 120px"></el-input> |
||||
|
</el-form-item> |
||||
|
<el-form-item :label="' '"> |
||||
|
<el-button @click="getDataList()">查询</el-button> |
||||
|
<!-- <download-excel--> |
||||
|
<!-- :fields="fields()"--> |
||||
|
<!-- :data="exportData"--> |
||||
|
<!-- type="xls"--> |
||||
|
<!-- :name="exportName"--> |
||||
|
<!-- :header="exportHeader"--> |
||||
|
<!-- :footer="exportFooter"--> |
||||
|
<!-- :fetch="createExportData"--> |
||||
|
<!-- :before-generate="startDownload"--> |
||||
|
<!-- :before-finish="finishDownload"--> |
||||
|
<!-- worksheet="导出信息"--> |
||||
|
<!-- class="el-button el-button--primary el-button--medium">--> |
||||
|
<!-- {{ "导出" }}--> |
||||
|
<!-- </download-excel>--> |
||||
|
</el-form-item> |
||||
|
</el-form> |
||||
|
|
||||
|
<!-- 询价报价列表 --> |
||||
|
<el-table |
||||
|
height="35vh" |
||||
|
:data="dataList" |
||||
|
border |
||||
|
highlight-current-row |
||||
|
ref="mainTable" |
||||
|
@row-click="inquiryQuoteClickRow" |
||||
|
@current-change="changeCurrentRow" |
||||
|
v-loading="dataListLoading" |
||||
|
style="width: 100%;margin-top: 5px"> |
||||
|
<el-table-column |
||||
|
v-for="(item,index) in columnList" :key="index" |
||||
|
:sortable="item.columnSortable" |
||||
|
:prop="item.columnProp" |
||||
|
:header-align="item.headerAlign" |
||||
|
:align="item.align" |
||||
|
:fixed="item.fixed === ''?false:item.fixed" |
||||
|
:min-width="item.columnWidth" |
||||
|
:label="item.columnLabel"> |
||||
|
<template slot-scope="scope"> |
||||
|
<div v-if="item.columnProp !== 'status' && item.columnProp !== 'priorityLevel'"> |
||||
|
<span v-if="!item.columnHidden">{{ scope.row[item.columnProp] }}</span> |
||||
|
<span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" |
||||
|
style="width: 100px; height: 80px"/></span> |
||||
|
</div> |
||||
|
<div v-else-if="item.columnProp === 'status'"> |
||||
|
<span v-if="!item.columnHidden"> |
||||
|
<span v-if="scope.row.status === 'C'">草稿</span> |
||||
|
<span v-else-if="scope.row.status === 'B'">已下达</span> |
||||
|
<span v-else-if="scope.row.status === 'A'">已报价</span> |
||||
|
<span v-else>{{ scope.row.status }}</span> |
||||
|
</span> |
||||
|
<span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" |
||||
|
style="width: 100px; height: 80px"/></span> |
||||
|
</div> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
|
||||
|
<!-- 分页插件 --> |
||||
|
<el-pagination style="margin-top: 0px" |
||||
|
@size-change="sizeChangeHandle" |
||||
|
@current-change="currentChangeHandle" |
||||
|
:current-page="pageIndex" |
||||
|
:page-sizes="[20, 50, 100, 200, 500]" |
||||
|
:page-size="pageSize" |
||||
|
:total="totalPage" |
||||
|
layout="total, sizes, prev, pager, next, jumper"> |
||||
|
</el-pagination> |
||||
|
|
||||
|
<!-- 页签 --> |
||||
|
<el-tabs style="margin-top: 0px; width: 100%; height: 100%;" v-model="activeTable" class="customer-tab" type="border-card" @tab-click="tabClick"> |
||||
|
<!-- 详情页签 --> |
||||
|
<el-tab-pane label="审批信息" name="auth_info"> |
||||
|
<el-table |
||||
|
height="40vh" |
||||
|
:data="authInfoDataList" |
||||
|
border |
||||
|
highlight-current-row |
||||
|
ref="authInfoTable" |
||||
|
@row-click="authInfoClickRow" |
||||
|
@current-change="changeAuthInfoCurrentRow" |
||||
|
v-loading="dataListLoading" |
||||
|
style="width: 100%;margin-top: 5px"> |
||||
|
<el-table-column |
||||
|
v-for="(item,index) in columnAuthInfoList" :key="index" |
||||
|
:sortable="item.columnSortable" |
||||
|
:prop="item.columnProp" |
||||
|
:header-align="item.headerAlign" |
||||
|
:align="item.align" |
||||
|
:fixed="item.fixed === ''?false:item.fixed" |
||||
|
:min-width="item.columnWidth" |
||||
|
:label="item.columnLabel"> |
||||
|
<template slot-scope="scope"> |
||||
|
<span v-if="!item.columnHidden">{{ scope.row[item.columnProp] }}</span> |
||||
|
<span v-if="item.columnImage"><img :src="scope.row[item.columnProp]" |
||||
|
style="width: 100px; height: 80px"/></span> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
</el-table> |
||||
|
</el-tab-pane> |
||||
|
</el-tabs> |
||||
|
|
||||
|
<!-- chooseList模态框 --> |
||||
|
<Chooselist ref="baseList" @getBaseData="getBaseData"></Chooselist> |
||||
|
|
||||
|
</div> |
||||
|
</template> |
||||
|
<script> |
||||
|
import {searchAllInquiryQuoteInfo} from "@/api/inquiry/inquiryApplication"; |
||||
|
import {searchAuthInfo} from "../../../api/auth/auth"; |
||||
|
import DictDataSelect from "../sys/dict-data-select.vue"; |
||||
|
import quotationUpload from "../quote/quotation_upload.vue"; |
||||
|
import {getSiteAndBuByUserName} from "../../../api/qc/qc"; |
||||
|
import Chooselist from '@/views/modules/common/Chooselist_eam' |
||||
|
import {searchUserAuthInquiryApplicationInfo} from "../../../api/inquiry/inquiryApplication"; |
||||
|
|
||||
|
export default { |
||||
|
components: { |
||||
|
quotationUpload, |
||||
|
DictDataSelect, |
||||
|
Chooselist |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
// 导出 |
||||
|
exportData: [], |
||||
|
exportName: '询价申请' + this.dayjs().format('YYYYMMDDHHmmss'), |
||||
|
exportHeader: ['询价申请'], |
||||
|
exportFooter: [], |
||||
|
resultList: [], |
||||
|
userBuList: [], |
||||
|
uploadUrl: '/plm/quotationInformation/uploadExcel', |
||||
|
// ======== 行高 ======== |
||||
|
secondHeight: 200, |
||||
|
// ======== 分页 ======== |
||||
|
pageIndex: 1, |
||||
|
pageSize: 50, |
||||
|
totalPage: 0, |
||||
|
activeTable: 'auth_info', |
||||
|
// 条件查询 |
||||
|
searchData: { |
||||
|
userId: this.$store.state.user.id, |
||||
|
site: this.$store.state.user.site, |
||||
|
id: '', |
||||
|
customerNo: '', |
||||
|
customerDesc: '', |
||||
|
applicationNo: '', |
||||
|
rfqNo: '', |
||||
|
bu: '', |
||||
|
requestStartDate: '', |
||||
|
requestEndDate: '', |
||||
|
requiredCompletionStartDate: '', |
||||
|
requiredCompletionEndDate: '', |
||||
|
status: '', |
||||
|
quoterName: '', |
||||
|
requesterName: '', |
||||
|
priorityLevel: '', |
||||
|
orderRef1: 'XJ', |
||||
|
page: 1, |
||||
|
limit: 10, |
||||
|
menuId: this.$route.meta.menuId, |
||||
|
}, |
||||
|
// 其它 |
||||
|
dataListLoading: false, |
||||
|
// ======== 数据对象 ======== |
||||
|
modalData: { |
||||
|
flag: '', |
||||
|
title: '', |
||||
|
site: this.$store.state.user.site, |
||||
|
userName: this.$store.state.user.name, |
||||
|
id: '', |
||||
|
rfqNo: '', |
||||
|
customerNo: '', |
||||
|
customerDesc: '', |
||||
|
requestDate: '', |
||||
|
requester: '', |
||||
|
requesterName: '', |
||||
|
customerInquiryNo: '', |
||||
|
priorityLevel: '', |
||||
|
requiredCompletionDate: '', |
||||
|
quoter: '', |
||||
|
quoterName: '', |
||||
|
status: '', |
||||
|
remark: '', |
||||
|
createDate: '', |
||||
|
createBy: '', |
||||
|
updateDate: '', |
||||
|
updateBy: '', |
||||
|
authHistId: '', |
||||
|
approveResult: '', |
||||
|
authHistRemark: '', |
||||
|
canAuthFlag: '', |
||||
|
actAuthorizator: '', |
||||
|
strActAuthorizeDate: this.dayjs().format("YYYY-MM-DD HH:mm:ss"), |
||||
|
actAuthorizeDate: '' |
||||
|
}, |
||||
|
// ======== 数据列表 ======== |
||||
|
dataList: [], |
||||
|
authInfoDataList: [], |
||||
|
// ======== 列表表头 ======== |
||||
|
columnList: [ |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1BuDesc', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: 'buDesc', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: 'BU', |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
columnWidth: 80 |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1rfqNo', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: 'applicationNo', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '申请单号', |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
columnWidth: 120 |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1CustomerNo', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: 'customerNo', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '客户编码', |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
columnWidth: 100 |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1CustomerDesc', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: 'customerDesc', |
||||
|
headerAlign: 'center', |
||||
|
align: 'left', |
||||
|
columnLabel: '客户名称', |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
columnWidth: 120 |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1QuoterName', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: 'quoterName', |
||||
|
headerAlign: 'center', |
||||
|
align: 'left', |
||||
|
columnLabel: '报价专员', |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
columnWidth: 80 |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1CustomerInquiryNo', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: 'customerInquiryNo', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '客户询价单号', |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
columnWidth: 120 |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1Status', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: 'status', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '状态', |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
columnWidth: 100 |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1CreateBy', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: 'createBy', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '创建人', |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
columnWidth: 120 |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1CreateDate', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: 'createDate', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '创建时间', |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
columnWidth: 130 |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1UpdateBy', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: 'updateBy', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '更新人', |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
columnWidth: 120 |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1UpdateDate', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: 'updateDate', |
||||
|
headerAlign: 'center', |
||||
|
align: 'center', |
||||
|
columnLabel: '更新时间', |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
columnWidth: 130 |
||||
|
}, |
||||
|
], |
||||
|
columnAuthInfoList: [ |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1OrderRef1', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: "orderRef1", |
||||
|
headerAlign: "center", |
||||
|
align: "center", |
||||
|
columnLabel: "申请单号", |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1StepId', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: "stepId", |
||||
|
headerAlign: "center", |
||||
|
align: "center", |
||||
|
columnLabel: "审批步骤号", |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1NameDesc', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: "nameDesc", |
||||
|
headerAlign: "center", |
||||
|
align: "center", |
||||
|
columnLabel: "审批类型/审批人", |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: false |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1ActAuthorizatorDisplay', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: "actAuthorizatorDisplay", |
||||
|
headerAlign: "center", |
||||
|
align: "center", |
||||
|
columnLabel: "实际审批人", |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: false |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1ActAuthorizeDate', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: "actAuthorizeDate", |
||||
|
headerAlign: "center", |
||||
|
align: "center", |
||||
|
columnLabel: "审批时间", |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: false |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1ApproveResult', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: "approveResult", |
||||
|
headerAlign: "center", |
||||
|
align: "center", |
||||
|
columnLabel: "审批状态", |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
}, |
||||
|
{ |
||||
|
userId: this.$store.state.user.name, |
||||
|
functionId: 190007, |
||||
|
serialNumber: '190007Table1Remark', |
||||
|
tableId: '190007Table1', |
||||
|
tableName: '申请单信息表', |
||||
|
columnProp: "remark", |
||||
|
headerAlign: "center", |
||||
|
align: "center", |
||||
|
columnLabel: "审批备注", |
||||
|
columnHidden: false, |
||||
|
columnImage: false, |
||||
|
columnSortable: false, |
||||
|
sortLv: 0, |
||||
|
status: true, |
||||
|
fixed: '', |
||||
|
}, |
||||
|
], |
||||
|
// ======== 选中的当前行数据 ======== |
||||
|
inquiryQuoteCurrentRow: {}, |
||||
|
// ======== 模态框开关控制 ======== |
||||
|
modalFlag: false, |
||||
|
modalDisableFlag: false, |
||||
|
} |
||||
|
}, |
||||
|
mounted() { |
||||
|
this.$nextTick(() => { |
||||
|
/*第二个表格高度的动态调整*/ |
||||
|
this.height = window.innerHeight - 210; |
||||
|
}) |
||||
|
}, |
||||
|
created() { |
||||
|
this.getSiteAndBuByUserName() |
||||
|
this.getDataList() |
||||
|
}, |
||||
|
methods: { |
||||
|
// 获取用户的bu |
||||
|
getSiteAndBuByUserName() { |
||||
|
let tempData = { |
||||
|
username: this.$store.state.user.name, |
||||
|
} |
||||
|
getSiteAndBuByUserName(tempData).then(({data}) => { |
||||
|
if (data.code === 0) { |
||||
|
this.userBuList = data.rows |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// ======== 分页相关方法 ======== |
||||
|
/** |
||||
|
* 每页数 |
||||
|
* @param val |
||||
|
*/ |
||||
|
sizeChangeHandle(val) { |
||||
|
this.pageSize = val |
||||
|
this.pageIndex = 1 |
||||
|
this.getDataList() |
||||
|
}, |
||||
|
/** |
||||
|
* 当前页 |
||||
|
* @param val |
||||
|
*/ |
||||
|
currentChangeHandle(val) { |
||||
|
this.pageIndex = val |
||||
|
this.getDataList() |
||||
|
}, |
||||
|
|
||||
|
|
||||
|
// ======== 页签切换相关方法 ======== |
||||
|
/** |
||||
|
* 列表表格选择替换 |
||||
|
* @param tab |
||||
|
* @param event |
||||
|
*/ |
||||
|
tabClick(tab, event) { |
||||
|
// 刷新列表数据 |
||||
|
this.refreshCurrentTabTable() |
||||
|
}, |
||||
|
|
||||
|
// ======== 列表操作方法 ======== |
||||
|
/** |
||||
|
* 单机选中申请单信息 |
||||
|
* @param row |
||||
|
*/ |
||||
|
inquiryQuoteClickRow(row) { |
||||
|
this.inquiryQuoteCurrentRow = JSON.parse(JSON.stringify(row)) |
||||
|
}, |
||||
|
/** |
||||
|
* 单机选中申请单审批信息 |
||||
|
* @param row |
||||
|
*/ |
||||
|
authInfoClickRow(row) { |
||||
|
this.authInfoCurrentRow = JSON.parse(JSON.stringify(row)) |
||||
|
}, |
||||
|
/** |
||||
|
* 当前值发生变化的时候修改 |
||||
|
* @param row |
||||
|
* @param oldRow |
||||
|
*/ |
||||
|
changeCurrentRow(row, oldRow) { |
||||
|
// 判断是否是获取焦点的事件 |
||||
|
if (row) { |
||||
|
this.inquiryQuoteCurrentRow = JSON.parse(JSON.stringify(row)) |
||||
|
//刷新当前页表 |
||||
|
this.refreshCurrentTabTable() |
||||
|
} |
||||
|
}, |
||||
|
/** |
||||
|
* 当前值发生变化的时候修改 |
||||
|
* @param row |
||||
|
* @param oldRow |
||||
|
*/ |
||||
|
changeAuthInfoCurrentRow(row, oldRow) { |
||||
|
// 判断是否是获取焦点的事件 |
||||
|
if (row) { |
||||
|
this.authInfoCurrentRow = JSON.parse(JSON.stringify(row)) |
||||
|
} |
||||
|
}, |
||||
|
/** |
||||
|
* 刷新页签的table数据 |
||||
|
*/ |
||||
|
refreshCurrentTabTable() { |
||||
|
if (this.activeTable === 'auth_info') { |
||||
|
this.getAuthInfoDataList() |
||||
|
} |
||||
|
}, |
||||
|
|
||||
|
// ======== 列表数据刷新方法 ======== |
||||
|
/** |
||||
|
* 获取数据列表 |
||||
|
*/ |
||||
|
getDataList() { |
||||
|
this.searchData.limit = this.pageSize |
||||
|
this.searchData.page = this.pageIndex |
||||
|
searchAllInquiryQuoteInfo(this.searchData).then(({data}) => { |
||||
|
if (data.code === 0) { |
||||
|
this.dataList = data.page.list |
||||
|
this.pageIndex = data.page.currPage |
||||
|
this.pageSize = data.page.pageSize |
||||
|
this.totalPage = data.page.totalCount |
||||
|
this.dataList.forEach(item => { |
||||
|
if (item.groupDesc === '' || item.groupDesc === null) { |
||||
|
item.auth = item.userDisplay |
||||
|
} else { |
||||
|
item.auth = item.groupDesc |
||||
|
} |
||||
|
}) |
||||
|
//判断是否全部存在数据 |
||||
|
if (this.totalPage > 0) { |
||||
|
//设置选中行 |
||||
|
this.$refs.mainTable.setCurrentRow(this.dataList[0]) |
||||
|
this.refreshCurrentTabTable() //加载当前的页签的table |
||||
|
this.inquiryQuoteClickRow(this.dataList[0]) |
||||
|
} |
||||
|
} |
||||
|
this.dataListLoading = false |
||||
|
}) |
||||
|
}, |
||||
|
getAuthInfoDataList() { |
||||
|
let inData = { |
||||
|
orderRef1: this.inquiryQuoteCurrentRow.applicationNo, |
||||
|
site: this.$store.state.user.site, |
||||
|
orderRef2: this.inquiryQuoteCurrentRow.buNo, |
||||
|
} |
||||
|
searchAuthInfo(inData).then(({data}) => { |
||||
|
if (data.code === 0) { |
||||
|
this.authInfoDataList = data.rows |
||||
|
this.authInfoDataList.forEach(item => { |
||||
|
if (item.authTypeDb === 'G') { |
||||
|
item.nameDesc = '审批组' |
||||
|
} else { |
||||
|
item.nameDesc = '个人/'+item.authUserDisplay |
||||
|
} |
||||
|
if (item.approveResult === '' || item.approveResult === null) { |
||||
|
item.approveResult = '未审批' |
||||
|
} |
||||
|
}) |
||||
|
//判断是否全部存在数据 |
||||
|
if (this.authInfoDataList.length > 0) { |
||||
|
//设置选中行 |
||||
|
this.$refs.authInfoTable.setCurrentRow(this.authInfoDataList[0]) |
||||
|
this.authInfoClickRow(this.authInfoDataList[0]) |
||||
|
} |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// ======== chooseList相关方法 ======== |
||||
|
/** |
||||
|
* 获取基础数据列表S |
||||
|
* @param val |
||||
|
* @param type |
||||
|
*/ |
||||
|
getBaseList(val, type) { |
||||
|
this.tagNo = val |
||||
|
this.tagNo1 = type |
||||
|
this.$nextTick(() => { |
||||
|
let strVal = '' |
||||
|
let conSql = '' |
||||
|
if (val === 220) { |
||||
|
strVal = this.inquiryPartModalData.codeNo ? this.inquiryPartModalData.codeNo : '' |
||||
|
conSql =" and function_type = 'PRICECHECK'" + " and site = '" + this.inquiryPartModalData.bu.split('_')[0] + "'" + |
||||
|
" and bu_no = '" + this.inquiryPartModalData.bu.split('_')[1] + "'" |
||||
|
} |
||||
|
if (val === 509) { |
||||
|
if (type === 1) { |
||||
|
strVal = this.modalData.customerNo ? this.modalData.customerNo : '' |
||||
|
} |
||||
|
if (type === 2) { |
||||
|
strVal = this.searchData.customerNo ? this.searchData.customerNo : '' |
||||
|
} |
||||
|
} |
||||
|
if (val === 510) { |
||||
|
strVal = this.inquiryPartModalData.umId ? this.inquiryPartModalData.umId : '' |
||||
|
conSql = " and site = '" + this.inquiryPartModalData.bu.split('_')[0] + "'" |
||||
|
} |
||||
|
if (val === 2002) { |
||||
|
if (type === 1) { |
||||
|
strVal = this.searchData.quoterName ? this.searchData.quoterName : '' |
||||
|
conSql = " and b.site = '" + this.$store.state.user.site + "'" |
||||
|
} |
||||
|
if (type === 2) { |
||||
|
strVal = this.modalData.quoterName ? this.modalData.quoterName : '' |
||||
|
conSql = " and b.site = '" + this.$store.state.user.site + "'" |
||||
|
} |
||||
|
} |
||||
|
if (val === 2008) { |
||||
|
if (type === 1) { |
||||
|
strVal = this.searchData.requesterName ? this.searchData.requesterName : '' |
||||
|
conSql = " and b.site = '" + this.$store.state.user.site + "'" |
||||
|
} |
||||
|
if (type === 2) { |
||||
|
strVal = this.modalData.requesterName ? this.modalData.requesterName : '' |
||||
|
conSql = " and b.site = '" + this.$store.state.user.site + "'" |
||||
|
} |
||||
|
} |
||||
|
this.$refs.baseList.init(val, strVal, conSql) |
||||
|
}) |
||||
|
}, |
||||
|
/** |
||||
|
* 列表方法的回调 |
||||
|
* @param val |
||||
|
*/ |
||||
|
getBaseData(val) { |
||||
|
if (this.tagNo ===220) { |
||||
|
this.inquiryPartModalData.codeNo = val.code_no |
||||
|
this.inquiryPartModalData.codeDesc = val.code_desc |
||||
|
} |
||||
|
if (this.tagNo === 509) { |
||||
|
if (this.tagNo1 === 1) { |
||||
|
if (val.customer_no === this.modalData.customerNo) { |
||||
|
return |
||||
|
} |
||||
|
this.modalData.customerNo = val.customer_no |
||||
|
this.modalData.customerDesc = val.customer_desc |
||||
|
} |
||||
|
if (this.tagNo1 === 2) { |
||||
|
if (val.customer_no === this.searchData.customerNo) { |
||||
|
return |
||||
|
} |
||||
|
this.searchData.customerNo = val.customer_no |
||||
|
} |
||||
|
} |
||||
|
if (this.tagNo === 510) { |
||||
|
this.inquiryPartModalData.umId = val.UMID |
||||
|
this.inquiryPartModalData.umName = val.UMName |
||||
|
} |
||||
|
if (this.tagNo === 2002) { |
||||
|
if (this.tagNo1 === 1) { |
||||
|
this.searchData.quoter = val.username |
||||
|
this.searchData.quoterName = val.user_display |
||||
|
} |
||||
|
if (this.tagNo1 === 2) { |
||||
|
this.modalData.quoter = val.username |
||||
|
this.modalData.quoterName = val.user_display |
||||
|
} |
||||
|
} |
||||
|
if (this.tagNo === 2008) { |
||||
|
if (this.tagNo1 === 1) { |
||||
|
this.searchData.requester = val.username |
||||
|
this.searchData.requesterName = val.user_display |
||||
|
} |
||||
|
if (this.tagNo1 === 2) { |
||||
|
this.modalData.requester = val.username |
||||
|
this.modalData.requesterName = val.user_display |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
// ======== 导出相关方法 ======== |
||||
|
/** |
||||
|
* 导出excel |
||||
|
*/ |
||||
|
async createExportData() { |
||||
|
this.searchData.limit = -1 |
||||
|
this.searchData.page = 1 |
||||
|
await searchUserAuthInquiryApplicationInfo(this.searchData).then(({data}) => { |
||||
|
this.resultList = data.page.list |
||||
|
// 遍历dataList 取-后的值 |
||||
|
this.resultList.forEach((item) => { |
||||
|
if (item.status === 'A') { |
||||
|
item.status = '已报价' |
||||
|
} else if (item.status === 'B') { |
||||
|
item.status = '已下达' |
||||
|
} else if (item.status === 'C') { |
||||
|
item.status = '草稿' |
||||
|
} |
||||
|
if (item.priorityLevel === 'A') { |
||||
|
item.priorityLevel = '普通' |
||||
|
} else if (item.priorityLevel === ' B') { |
||||
|
item.priorityLevel = '重要' |
||||
|
} else if (item.priorityLevel === ' C') { |
||||
|
item.priorityLevel = '紧急' |
||||
|
} |
||||
|
}) |
||||
|
}) |
||||
|
return this.resultList |
||||
|
}, |
||||
|
startDownload() { |
||||
|
}, |
||||
|
finishDownload() { |
||||
|
}, |
||||
|
fields() { |
||||
|
let json = '{' |
||||
|
this.columnList.forEach((item, index) => { |
||||
|
if (index == this.columnList.length - 1) { |
||||
|
json += '"' + item.columnLabel + '"' + ':' + '"' + item.columnProp + '"' |
||||
|
} else { |
||||
|
json += '"' + item.columnLabel + '"' + ':' + '"' + item.columnProp + '"' + ',' |
||||
|
} |
||||
|
}) |
||||
|
json += '}' |
||||
|
let s = eval('(' + json + ')') |
||||
|
return s |
||||
|
}, |
||||
|
// ======== 导入相关方法 ======== |
||||
|
handleImportQuotation() { |
||||
|
let currentData = { |
||||
|
createBy: this.$store.state.user.name, |
||||
|
site: this.$store.state.user.site, |
||||
|
} |
||||
|
//打开组件 去做新增业务 |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs.quotationUpload.init(currentData) |
||||
|
}) |
||||
|
}, |
||||
|
rowStyle({row}) { |
||||
|
if (this.inquiryQuoteCurrentRow.id === row.id) { |
||||
|
return {'background-color': '#E8F7F6', cursor: 'pointer'}; |
||||
|
} |
||||
|
}, |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
<style scoped> |
||||
|
/deep/ .customer-tab .el-tabs__content { |
||||
|
padding: 0px !important; |
||||
|
height: 100%; |
||||
|
} |
||||
|
|
||||
|
/deep/ .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner { |
||||
|
background-color: #17B3A3; |
||||
|
border-color: #17B3A3; |
||||
|
} |
||||
|
|
||||
|
/deep/ .el-checkbox__input.is-disabled.is-checked .el-checkbox__inner::after { |
||||
|
border-color: #FFF |
||||
|
} |
||||
|
/deep/ .el-form-item--medium .el-form-item__content{ |
||||
|
height: auto; |
||||
|
} |
||||
|
|
||||
|
.el-input-number /deep/ .el-input__inner { |
||||
|
text-align: right; |
||||
|
padding-right: 5px !important; |
||||
|
} |
||||
|
|
||||
|
/deep/ .el-input .el-input--medium{ |
||||
|
line-height: 20px; |
||||
|
} |
||||
|
/deep/ .el-input-number .el-input--medium{ |
||||
|
line-height: 20px; |
||||
|
} |
||||
|
|
||||
|
/*table中input 修改样式*/ |
||||
|
/deep/ div.table-el-date { |
||||
|
padding: 0px 0px; |
||||
|
height: 25px !important; |
||||
|
} |
||||
|
|
||||
|
/*table中input*/ |
||||
|
div.table-el-date /deep/ input.el-input__inner{ |
||||
|
padding: 0px 0px; |
||||
|
height: 23px !important; |
||||
|
text-align: right; |
||||
|
} |
||||
|
|
||||
|
/* 特殊的样式*/ |
||||
|
/deep/ .el-table div.cell:has(.table-el-date) { |
||||
|
/* 直接作用于 <td> 元素 */ |
||||
|
padding: 0px; |
||||
|
height: 25px; |
||||
|
} |
||||
|
|
||||
|
.el-transfer-panel { |
||||
|
border: 2px solid #17b3a3; |
||||
|
border-radius: 4px; |
||||
|
overflow: hidden; |
||||
|
background: #fff; |
||||
|
display: inline-block; |
||||
|
vertical-align: middle; |
||||
|
width: 200px; |
||||
|
max-height: 100%; |
||||
|
-webkit-box-sizing: border-box; |
||||
|
box-sizing: border-box; |
||||
|
position: relative; |
||||
|
} |
||||
|
|
||||
|
.el-transfer-panel .el-transfer-panel__header { |
||||
|
height: 40px; |
||||
|
line-height: 40px; |
||||
|
background: #17b3a3; |
||||
|
margin: 0; |
||||
|
padding-left: 15px; |
||||
|
border-bottom: 1px solid #17b3a3; |
||||
|
-webkit-box-sizing: border-box; |
||||
|
box-sizing: border-box; |
||||
|
color: #000; |
||||
|
} |
||||
|
|
||||
|
.el-transfer-panel .el-transfer-panel__header .el-checkbox .el-checkbox__label { |
||||
|
font-size: 14px; |
||||
|
color: #303133; |
||||
|
font-weight: 400; |
||||
|
} |
||||
|
</style> |
||||
1112
src/views/modules/auth/authQuote.vue
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
Write
Preview
Loading…
Cancel
Save
Reference in new issue