123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971 |
- <template>
- <div class="borderless" v-loading="pageLoading">
- <div class="customer-head">
- <div class="customer-back">
- <el-button type="danger" style="border: none;background: none;color: red" icon="el-icon-arrow-left"
- @click="backToList">返回列表
- </el-button>
- </div>
- <div class="add-customer-btn">
- <el-button size="small" type="success" style="margin-right: 8px"
- :loading="saveLoading" @click="editHandle">提取利润及放单
- </el-button>
- <el-button size="small" type="warning" plain style="margin-right: 8px"
- :loading="saveLoading" @click="editHandle">撤销确认
- </el-button>
- <el-button size="small" type="primary" style="margin-right: 8px" v-if="editSave"
- :loading="saveLoading" @click="editHandle">编 辑
- </el-button>
- <el-button size="small" type="primary" style="margin-right: 8px" v-else
- :loading="saveLoading" @click="editCustomer">保 存
- </el-button>
- </div>
- </div>
- <div style="margin: 55px 5px 0px 5px;'">
- <el-card class="box-card">
- <el-form :model="form" ref="form" label-width="90px" class="demo-ruleForm">
- <el-row>
- <el-row>
- <el-col :span="5">
- <el-form-item label="对账单号" prop="checkNo">
- <el-input style="width: 100%;" v-model="form.billNo"
- size="small" autocomplete="off"
- :disabled="true"
- clearable placeholder="请输入对账单号" >
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="对账日期" prop="billDate">
- <el-date-picker v-model="form.billDate" clearable
- style="width: 100%;"
- type="date" size="small"
- :disabled="editSave"
- value-format="yyyy-MM-dd HH:mm"
- placeholder="选择对账日期">
- </el-date-picker>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="限定金额" prop="billDate">
- <el-input style="width: 100%;" v-model="form.limitedAmount"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入对账单号" >
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="备注" prop="remarks" >
- <el-input style="width: 100%;" v-model="form.remarks"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入备注" >
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="4">
- <el-form-item label="审核" prop="isApproved" label-width="50px">
- <search-query :datalist="allyesnoData"
- :selectValue="form.isApproved"
- :clearable="true"
- :disabled="editSave"
- :buttonIf="false"
- :forParameter="{ key:'dictKey', label:'dictValue', value:'dictKey'}"
- @corpChange="corpChange($event,'isApproved')"
- @corpFocus="allyesnoWorkDictsfun" >
- </search-query>
- </el-form-item>
- </el-col>
- <el-col :span="10">
- <el-form-item label="对账单位" prop="corpCnName">
- <el-col :span="10">
- <search-query :datalist="corpData"
- :selectValue="form.corpCnName"
- :clearable="true"
- :disabled="editSave"
- :filterable="true"
- :remote="true"
- :buttonIf="false"
- :forParameter="{ key:'id', label:'cnName', value:'cnName'}"
- @corpChange="corpChange($event,'corpCnName')"
- @remoteMethod="corpBcorpsListfun"
- @corpFocus="corpBcorpsListfun" >
- </search-query>
- </el-col>
- <el-col :span="10">
- <span style="padding-left: 20px"></span>
- <el-input style="width: 100%;" v-model="form.corpEnName"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入" >
- </el-input>
- </el-col>
- <el-col :span="4">
- <el-checkbox style="width: 100%;text-align: right" size="medium"
- :true-label="1" :false-label="0"
- :disabled="editSave"
- v-model="form.corpIsSigned">已签约
- </el-checkbox>
- </el-col>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="协议签订人" prop="corpAccRemarks">
- <el-input style="width: 100%;" v-model="form.corpAccRemarks"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入协议签订人" >
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="账期备注" prop="corpAccRemarks">
- <el-input style="width: 100%;" v-model="form.corpAccRemarks"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入账期备注" >
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="4">
- <el-form-item label="签收" prop="isSignfor" label-width="50px">
- <search-query :datalist="allyesnoData"
- :selectValue="form.isSignfor"
- :clearable="true"
- :disabled="editSave"
- :buttonIf="false"
- :forParameter="{ key:'dictKey', label:'dictValue', value:'dictKey'}"
- @corpChange="corpChange($event,'isSignfor')"
- @corpFocus="allyesnoWorkDictsfun" >
- </search-query>
- </el-form-item>
- </el-col>
- </el-row>
- <expand :showBtn="true" :showSpan="true">
- <el-row>
- <el-col :span="5">
- <el-form-item label="收 / 付" prop="dc">
- <search-query :datalist="dcData"
- :selectValue="form.dc"
- :clearable="true"
- :disabled="editSave"
- :buttonIf="false"
- @corpChange="corpChange($event,'dc')">
- </search-query>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="币别" prop="curCode">
- <search-query :datalist="curCodeData"
- :selectValue="form.curCode"
- :clearable="true"
- :disabled="editSave"
- :buttonIf="false"
- :filterable="true"
- :remote="true"
- :forParameter="{ key:'id', label:'code', value:'code'}"
- @corpChange="corpChange($event,'curCode')"
- @remoteMethod="getRateListfun"
- @corpFocus="getRateListfun" >
- </search-query>
- </el-form-item>
- </el-col>
- <el-col :span="10">
- <el-form-item label="业务来源" prop="srcType">
- <el-col :span="10">
- <search-query :datalist="srcTypeData"
- :selectValue="form.srcType"
- :clearable="true"
- :disabled="editSave"
- :buttonIf="false"
- @corpChange="corpChange($event,'srcType')">
- </search-query>
- </el-col>
- <el-col :span="13" :offset="1">
- <search-query :datalist="srcData"
- :selectValue="form.srcCnName"
- :clearable="true"
- :disabled="editSave"
- :buttonIf="false"
- :filterable="true"
- :remote="true"
- :forParameter="srcforParameter"
- @corpChange="corpChange($event,'srcCnName')"
- @remoteMethod="salesuserGetListfun">
- </search-query>
- </el-col>
- </el-form-item>
- </el-col>
- <el-col :span="4">
- <el-form-item label="销账" prop="isCleared" label-width="50px">
- <search-query :datalist="allyesnoData"
- :selectValue="form.isCleared"
- :clearable="true"
- :disabled="editSave"
- :buttonIf="false"
- :forParameter="{ key:'dictKey', label:'dictValue', value:'dictKey'}"
- @corpChange="corpChange($event,'isCleared')"
- @corpFocus="allyesnoWorkDictsfun" >
- </search-query>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="JOB NO" prop="businessNo">
- <el-input style="width: 100%;" v-model="form.businessNo"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入JOB NO" >
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="ACCT NO" prop="accountNo">
- <el-input style="width: 100%;" v-model="form.accountNo"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入ACCT NO" >
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="MBL NO" prop="mblno">
- <el-input style="width: 100%;" v-model="form.mblno"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入MBL NO" >
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="HBL NO" prop="hblno">
- <el-input style="width: 100%;" v-model="form.hblno"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入HBL NO" >
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="4">
- <el-form-item label="对账" prop="isChecked" label-width="50px">
- <search-query :datalist="allyesnoData"
- :selectValue="form.isChecked"
- :clearable="true"
- :disabled="editSave"
- :buttonIf="false"
- :forParameter="{ key:'dictKey', label:'dictValue', value:'dictKey'}"
- @corpChange="corpChange($event,'isChecked')"
- @corpFocus="allyesnoWorkDictsfun" >
- </search-query>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="财务日期" prop="etd">
- <el-date-picker
- v-model="form.accountDate"
- type="datetimerange"
- range-separator="至"
- start-placeholder="开始日期"
- end-placeholder="结束日期"
- style="width: 100%;"
- size="small"
- :disabled="editSave"
- format="yyyy-MM-dd"
- value-format="yyyy-MM-dd"
- placeholder="选择财务日期">
- </el-date-picker>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="审核期间" prop="etd">
- <el-date-picker
- v-model="form.approvedDate"
- type="datetimerange"
- range-separator="至"
- start-placeholder="开始日期"
- end-placeholder="结束日期"
- style="width: 100%;"
- size="small"
- :disabled="editSave"
- format="yyyy-MM-dd"
- value-format="yyyy-MM-dd"
- placeholder="选择对账日期">
- </el-date-picker>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="查询金额" prop="queryAmount">
- <el-input style="width: 100%;" v-model="form.queryAmount"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入查询金额" >
- </el-input>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="业务类型" prop="businessType" >
- <search-query :datalist="businessTypeData"
- :selectValue="form.businessType"
- :clearable="true"
- :disabled="editSave"
- :buttonIf="false"
- @corpChange="corpChange($event,'businessType')">
- </search-query>
- </el-form-item>
- </el-col>
- <el-col :span="4">
- <el-form-item label="发票" prop="isChecked" label-width="50px">
- <search-query :datalist="isInvoiceData"
- :selectValue="form.isInvoice"
- :clearable="true"
- :disabled="editSave"
- :buttonIf="false"
- :forParameter="{ key:'dictKey', label:'dictValue', value:'dictKey'}"
- @corpChange="corpChange($event,'isInvoice')"
- @corpFocus="invoiceWorkDictsfun" >
- </search-query>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="船 名" prop="vesselCnName" >
- <el-input style="width: 100%;" v-model="form.vesselCnName"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请选择船名" ></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="航 次" prop="voyageNo" >
- <el-input style="width: 100%;" v-model="form.voyageNo"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请选择航次" ></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="三检单号" prop="threeInspectionsNo" >
- <el-input style="width: 100%;" v-model="form.threeInspectionsNo"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入三检单号" ></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="预收帐款" prop="receivableAdvance" >
- <el-input style="width: 100%;" v-model="form.receivableAdvance"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入预收帐款" ></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="4">
- <el-form-item label="发票号" prop="invoiceNo" label-width="50px">
- <el-input style="width: 100%;" v-model="form.invoiceNo"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入发票号" ></el-input>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="操作员" prop="updateUserName" >
- <search-query :datalist="updateUserData"
- :selectValue="form.updateUserName"
- :clearable="true"
- :disabled="editSave"
- :buttonIf="false"
- :filterable="true"
- :remote="true"
- :forParameter="{ key:'id', label:'name', value:'name'}"
- @corpChange="corpChange($event,'updateUserName')"
- @remoteMethod="updateUserUserGetListfun"
- @corpFocus="updateUserUserGetListfun" >
- </search-query>
- </el-form-item>
- </el-col>
- <el-col :span="5">
- <el-form-item label="BKNO" prop="bookingNo" >
- <el-input style="width: 100%;" v-model="form.bookingNo"
- size="small" autocomplete="off"
- :disabled="editSave"
- clearable placeholder="请输入BKNO" ></el-input>
- </el-form-item>
- </el-col>
- </el-row>
- </expand>
- <el-row>
- <el-col span="24">
- <div style="text-align: right">
- <el-button size="small" type="" style="margin-right: 8px"
- :loading="saveLoading" @click="ResetFilter">重置条件
- </el-button>
- <el-button size="small" type="primary" style="margin-right: 8px"
- :loading="saveLoading" @click="finstlbillslistAccBillV1fun" >检 索
- </el-button>
- </div>
- </el-col>
- </el-row>
- </el-row>
- </el-form>
- </el-card>
- <el-card style="margin-top: 10px">
- <el-row>
- <el-col :span="4">
- <div class="bottomFlex" style="justify-content: space-around">
- <div style="text-align: center">
- <div class="weightfont">¥</div>
- <div>RMB</div>
- </div>
- <div>
- <div style="color: #81B337">
- <span>应收:</span>
- <span class="weightnum">¥0元</span>
- </div>
- <div style="color: #6BBCD1">
- <span>应付:</span>
- <span class="weightnum">¥0元</span>
- </div>
- </div>
- </div>
- </el-col>
- <el-col :span="4">
- <div class="bottomFlex" style="justify-content: space-around">
- <div style="text-align: center">
- <div class="weightfont">$</div>
- <div>USD</div>
- </div>
- <div>
- <div style="color: #81B337">
- <span>应收:</span>
- <span class="weightnum">$0元</span>
- </div>
- <div style="color: #6BBCD1">
- <span>应付:</span>
- <span class="weightnum">$0元</span>
- </div>
- </div>
- </div>
- </el-col>
- <el-col :span="4">
- <div class="bottomFlex" style="justify-content: space-around">
- <div style="text-align: center">
- <div class="weightfont">¥</div>
- <div>税后RMB</div>
- </div>
- <div>
- <div style="color: #81B337">
- <span>应收:</span>
- <span class="weightnum">¥0元</span>
- </div>
- <div style="color: #6BBCD1">
- <span>应付:</span>
- <span class="weightnum">¥0元</span>
- </div>
- </div>
- </div>
- </el-col>
- <el-col :span="4">
- <div class="bottomFlex" style="justify-content: space-around">
- <div style="text-align: center">
- <div class="weightfont">$</div>
- <div>税后USD</div>
- </div>
- <div>
- <div style="color: #81B337">
- <span>应收:</span>
- <span class="weightnum">$0元</span>
- </div>
- <div style="color: #6BBCD1">
- <span>应付:</span>
- <span class="weightnum">$0元</span>
- </div>
- </div>
- </div>
- </el-col>
- <el-col :span="8">
- <div style="text-align: right">
- <el-button size="small" type="primary" style="margin-right: 8px"
- :loading="saveLoading" @click="editHandle">计算合计值
- </el-button>
- <el-button size="small" type="primary" style="margin-right: 8px" :disabled="!form.id"
- :loading="saveLoading" @click="ConfirmReceiptfun">批量签收
- </el-button>
- <el-button size="small" type="danger" style="margin-right: 8px" :disabled="!form.id"
- :loading="saveLoading" @click="RevokeReceiptfun">撤销签收
- </el-button>
- </div>
- </el-col>
- </el-row>
- </el-card>
- <el-card style="margin-top: 10px">
- <div style="margin-bottom: 10px">
- <el-button size="small" type="primary" style="margin-right: 8px" :disabled="editSave"
- :loading="saveLoading" @click="Confirminvoicefun">确认发票
- </el-button>
- <el-button size="small" type="primary" style="margin-right: 8px"
- :loading="saveLoading" @click="editHandle">批量确认发票
- </el-button>
- <el-button size="small" type="primary" style="margin-right: 8px"
- :loading="saveLoading" @click="editHandle">不开发票
- </el-button>
- <el-button size="small" type="primary" style="margin-right: 8px"
- :loading="saveLoading" @click="editHandle">批量不开发票
- </el-button>
- <el-button size="small" type="info" style="margin-right: 8px" :disabled="editSave"
- :loading="saveLoading" @click="SelectedRows">确认选定行
- </el-button>
- <!--<el-button size="small" type="primary" style="margin-right: 8px"-->
- <!-- :loading="saveLoading" @click="editHandle">选择操作行-->
- <!--</el-button>-->
- </div>
- <finstlbillsitems :tableData="tableData" @handleSelectionChange="handleSelectionChange"></finstlbillsitems>
- </el-card>
- </div>
- </div>
- </template>
- <script>
- import SearchQuery from "@/components/iosbasic-data/searchquery.vue";
- import {getWorkDicts} from "@/api/system/dictbiz";
- import {getRateList} from "@/api/iosBasicData/rateManagement";
- import {getList as userGetList} from '@/api/system/user'
- import {getBvesselsList} from "@/api/iosBasicData/bvessels";
- import {getBcorpslistByType} from "@/api/iosBasicData/bcorps";
- import {getDeptLazyTree} from "@/api/system/dept";
- import {
- finstlbillsConfirmSignFor,
- finstlbillsDetail,
- finstlbillslistAccBillV1, finstlbillsRevokeSignFor,
- finstlbillsSubmit
- } from '@/api/iosBasicData/finstlbills'
- import expand from "@/components/basic-container/expand.vue";
- import finstlbillsitems from "@/views/iosBasicData/finstlbills/assembly/finstlbillsitems.vue";
- export default {
- components: {SearchQuery,expand,finstlbillsitems},
- props:{
- // 编辑还是保存
- editSave:{
- type:Boolean,
- default:true
- }
- },
- data(){
- return {
- tableData:[],
- pageLoading:false, // 全屏加载动画
- saveLoading:false, // 按钮动画
- // 绑定的数据
- form:{
- },
- handleSelectionData:[], // 表格选择的数据
- corpData:[], // 对账单位 数据
- allyesnoData:[], // 全部是否字典数据
- isInvoiceData:[],// 发票字典
- // 收 / 付
- dcData:[
- {
- label:'Debit',
- value: 'D'
- },{
- label:'Credit',
- value: 'C'
- }
- ],
- curCodeData:[],// 币别
- updateUserData:[], // 操作员
- srcTypeData:[
- {
- label:'公司',
- value:'OWN'
- },
- {
- label:'代理',
- value:'AGENT'
- },
- {
- label:'业务员',
- value:'SALES'
- }
- ], // 业务来源
- srcData:[], // 业务来源数据
- srcforParameter:{},
- // 业务类型
- businessTypeData:[
- {
- label:'海运出口',
- value:'SE'
- },{
- label:'海运进口',
- value:'SI'
- }
- ],
- }
- },
- created() {
- this.allyesnoWorkDictsfun() // 获取 字典数据
- this.invoiceWorkDictsfun() // 获取 发票的数据
- },
- methods:{
- // 下拉回调
- corpChange(value,name){
- // 对账单位
- if (name == 'corpCnName') {
- if (!value) {
- this.$set(this.form,'corpId','')
- this.$set(this.form,'corpCnName','')
- this.$set(this.form,'corpEnName','')
- this.$set(this.form,'corpArgreementNo','')
- }
- for(let item of this.corpData) {
- if (item.cnName == value) {
- this.$set(this.form,'corpId',item.id)
- this.$set(this.form,'corpCnName',item.cnName)
- this.$set(this.form,'corpEnName',item.enName)
- this.$set(this.form,'corpArgreementNo',item.enName)
- }
- }
- }
- // 业务来源
- else if (name == 'srcType') {
- if (!value) {
- this.$set(this.form,'srcType','')
- return;
- }
- this.$set(this.form,name,value)
- if (value == 'OWN') {
- this.srcforParameter = { key:'id', label:'title', value:'title'}
- this.ownDeptLazyTreefun()
- }else if (value == 'AGENT') {
- this.srcforParameter = { key:'id', label:'cnName', value:'cnName'}
- this.srcBcorpsListfun()
- }else if (value == 'SALES') {
- this.srcforParameter = { key:'id', label:'name', value:'name'}
- this.salesuserGetListfun()
- }else {}
- }
- // 业务来源选择
- else if (name == 'srcCnName') {
- if (!value) {
- this.$set(this.form,'srcId','')
- this.$set(this.form,'srcCnName','')
- this.$set(this.form,'srcEnName','')
- return
- }
- for (let item of this.srcData) {
- if (item[this.srcforParameter.value] == value) {
- if (this.form.srcType == 'OWN') {
- // 公司
- this.$set(this.form,'srcId',item.id)
- this.$set(this.form,'srcCnName',item.title)
- this.$set(this.form,'srcEnName',item.title)
- }
- else if (this.form.srcType == 'SALES') {
- // 业务员
- this.$set(this.form,'srcId',item.id)
- this.$set(this.form,'srcCnName',item.name)
- this.$set(this.form,'srcEnName',item.name)
- }else if (this.form.srcType == 'AGENT') {
- // 代理
- this.$set(this.form,'srcId',item.id)
- this.$set(this.form,'srcCnName',item.cnName)
- this.$set(this.form,'srcEnName',item.enName)
- }else {}
- }
- }
- }
- // 操作员
- else if (name == 'updateUserName') {
- for (let item of this.updateUserData) {
- if (item.name == value) {
- this.$set(this.form,'updateUser',item.id)
- this.$set(this.form,'updateUserName',item.name)
- }
- }
- }
- else {
- this.$set(this.form,name,value)
- }
- },
- // 编辑
- editHandle(){
- this.editSave = false
- },
- // 保存
- editCustomer(){
- // 对账单位
- if (!this.form.corpId) {
- this.$message.warning('请选择对账单位');
- return
- }
- // 业务类型
- if (!this.form.businessType) {
- this.$message.warning('请选择业务类型');
- return
- }
- // 是否选择从表数据
- if (this.handleSelectionData.length == 0) {
- this.$message.warning('请选择对账数据');
- return;
- }
- this.saveLoading = true // 加载动画
- this.form.billNoFormat = 'HYDZ'
- this.form.businessTypeCode = 'HYDZ'
- this.form.finStlBillsItemsList = this.handleSelectionData.map((item,index)=>{
- item.lineNo = index
- item.pType = item.businessType
- item.accBillId = item.id
- item.accBillNo = item.billNo
- item.accDate = item.billDate
- delete item.businessType
- delete item.id
- delete item.billNo
- delete item.billDate
- return item
- })
- finstlbillsSubmit(this.form).then(res=>{
- this.saveLoading = false
- this.$message.success('操作成功');
- this.finstlbillsDetailfun(res.data.data.id)
- })
- },
- // 详情接口
- finstlbillsDetailfun(id){
- this.pageLoading = true
- finstlbillsDetail(id).then(res=>{
- this.form = res.data.data
- this.tableData = this.form.finStlBillsItemsList
- this.form.isSignfor = this.form.isSignfor + ''
- this.form.isApproved = this.form.isApproved + ''
- this.form.isCleared = this.form.isCleared + ''
- this.form.isChecked = this.form.isChecked + ''
- this.form.isInvoice = this.form.isInvoice + ''
- this.pageLoading = false
- })
- },
- // 重置条件
- ResetFilter(){
- this.form = {}
- },
- // 检索接口
- finstlbillslistAccBillV1fun(){
- delete this.form.id
- for(let i in this.form) {
- console.log(i,737)
- }
- // let obj = JSON.parse(JSON.stringify(this.form))
- let obj = {}
- obj.auditStatus = this.form.isApproved // 审核状态 0 新建费用 1 已请核 2 审核中 3 驳回 4 通过
- obj.corpCnName = this.form.corpId // 对账单位
- obj.isSignfor = this.form.isSignfor // 是否已签收(0 否 1是)
- obj.dc = this.form.dc // 收付 D=收 C=付
- obj.curCode = this.form.curCode // 币别
- obj.srcType = this.form.srcType // 业务来源
- obj.srcCnName = this.form.srcId // 业务员id
- obj.isCleared = this.form.isCleared // 是否销账(0 未销账 3 部分销账 9 销账)
- obj.accBillNo = this.form.accountNo // 账单编号 ACCT NO
- obj.billNo = this.form.businessNo // 单据编号 JOB NO
- obj.mblno = this.form.mblno // MB/L NO
- obj.hblno = this.form.hblno // HB/L NO
- obj.isChecked = this.form.isChecked // 是否对账(0 未对账 1 已对账)
- obj.queryAmount = this.form.queryAmount // 查询金额
- obj.businessType = this.form.businessType // 业务类型
- obj.invoiceStatus = this.form.isInvoice // 发票状态 0 = 未开 9=已开 2 待开 3 不开
- obj.vesselCnName = this.form.vesselCnName // 中文船名
- obj.invoiceNo = this.form.invoiceNo // 发票号
- obj.bookingNo = this.form.bookingNo // 订舱号 BKNO
- obj.createUserName = this.form.updateUser // 操作员id
- obj.receivableAdvance = this.form.receivableAdvance // 预收帐款
- obj.threeInspectionsNo = this.form.threeInspectionsNo // 三检单号
- obj.voyageNo = this.form.voyageNo // 航次
- // 审核期间
- if (this.form.approvedDate) {
- obj.approveTimeList = this.form.approvedDate
- }
- // 财务期间
- if (this.form.accountDate) {
- obj.billDateList = this.form.accountDate
- }
- console.log(obj,754)
- // return
- finstlbillslistAccBillV1(obj).then(res=>{
- this.tableData = res.data.data.map(item=>{
- return item
- })
- })
- },
- // 确认发票
- Confirminvoicefun(){
- },
- // 确认签收
- ConfirmReceiptfun(){
- if (this.handleSelectionData.length === 0) {
- this.$message.warning("请选择至少一条数据");
- return;
- }
- for (let item of this.handleSelectionData) {
- if (item.isSignfor == 1) {
- this.$message.warning('请选择未签收的数据');
- return;
- }
- }
- this.$confirm("确定将选择数据签收?", {
- confirmButtonText: "确定",
- cancelButtonText: "取消",
- type: "warning"
- }).then(()=>{
- this.finstlbillsConfirmSignForfun()
- })
- },
- // 撤销签收
- RevokeReceiptfun(){
- if (this.handleSelectionData.length === 0) {
- this.$message.warning("请选择至少一条数据");
- return;
- }
- this.$confirm("确定将选择数据撤销签收?", {
- confirmButtonText: "确定",
- cancelButtonText: "取消",
- type: "warning"
- }).then(()=>{
- this.finstlbillsRevokeSignForfun()
- })
- },
- // 确认选定行
- SelectedRows(){
- this.editCustomer()
- },
- // 下面表格多选
- handleSelectionChange(arr){
- this.handleSelectionData = arr
- },
- //返回列表
- backToList() {
- this.$emit('goBack')
- },
- // 请求的接口
- // 确认签收接口
- finstlbillsConfirmSignForfun(){
- this.form.billNoFormat = 'HYDZ'
- this.form.businessTypeCode = 'HYDZ'
- this.form.finStlBillsItemsList = this.handleSelectionData.map((item,index)=>{
- item.lineNo = index
- item.pType = item.businessType
- item.accBillId = item.id
- item.accBillNo = item.billNo
- item.accDate = item.billDate
- delete item.businessType
- delete item.billNo
- delete item.billDate
- return item
- })
- finstlbillsConfirmSignFor(this.form).then(res=>{
- this.$message.success('操作成功');
- this.finstlbillsDetailfun(res.data.data.id)
- })
- },
- // 撤销签收接口
- finstlbillsRevokeSignForfun(){
- this.form.billNoFormat = 'HYDZ'
- this.form.businessTypeCode = 'HYDZ'
- this.form.finStlBillsItemsList = this.handleSelectionData.map((item,index)=>{
- item.lineNo = index
- item.pType = item.businessType
- item.accBillId = item.id
- item.accBillNo = item.billNo
- item.accDate = item.billDate
- delete item.businessType
- delete item.billNo
- delete item.billDate
- return item
- })
- finstlbillsRevokeSignFor(this.form).then(res=>{
- this.$message.success('操作成功');
- this.finstlbillsDetailfun(res.data.data.id)
- })
- },
- // 获取 全部是否 接口
- allyesnoWorkDictsfun(){
- getWorkDicts('all_yes_no').then(res=>{
- this.allyesnoData = res.data.data;
- })
- },
- // 销账字段数据
- // 获取发票的字典数据
- invoiceWorkDictsfun(){
- getWorkDicts('invoice_los').then(res=>{
- this.isInvoiceData = res.data.data;
- })
- },
- // 获取币别数据
- getRateListfun(cnName){
- getRateList({current:1,size:10,cnName}).then(res=>{
- this.curCodeData = res.data.data.records
- })
- },
- // 获取操作员数据
- updateUserUserGetListfun(account){
- userGetList(1,10,{account}).then(res=>{
- this.updateUserData = res.data.data.records
- })
- },
- // 获取公司名称 用户管理左侧
- ownDeptLazyTreefun(){
- getDeptLazyTree(0).then(res=>{
- this.srcData = res.data.data
- })
- },
- // 获取业务来源代理数据
- srcBcorpsListfun(cnName){
- let corpType = '1712285382575398914,1712285645314990082,1712285842321448962,1712286433378574338'
- getBcorpslistByType(1,10,{cnName,corpType}).then(res=>{
- this.srcData = res.data.data.records
- })
- },
- // 获取业务员数据
- salesuserGetListfun(account = undefined,type = false,){
- userGetList(1,10,{account}).then(res=>{
- this.srcData = res.data.data.records
- })
- },
- // 获取对账单位数据
- corpBcorpsListfun(cnName){
- getBcorpslistByType(1,10,{cnName}).then(res=>{
- this.corpData = res.data.data.records
- })
- },
- }
- }
- </script>
- <style scoped>
- ::v-deep.el-form-item {
- margin-bottom: 0;
- }
- .bottomFlex {
- display: flex;
- align-items: center;
- }
- .weightfont {
- font-size: 20px;
- font-weight: bold;
- }
- .weightnum {
- font-size: 15px;
- font-weight: 500;
- }
- </style>
|