|  | @@ -13,10 +13,11 @@
 | 
	
		
			
				|  |  |                  <el-button size="small" style="margin-right: 8px" v-if="roleName.indexOf('admin') != -1"
 | 
	
		
			
				|  |  |                      :loading="saveLoading" :disabled="!form.id" @click="DesignreportDialog = true">报表设计
 | 
	
		
			
				|  |  |                  </el-button>
 | 
	
		
			
				|  |  | -                <el-button size="small" type="primary" style="margin-right: 8px" :disabled="!form.id || form.isCleared != 1"
 | 
	
		
			
				|  |  | -                    v-if="!form.voucherNo&&voucher==1" :loading="saveLoading" @click="generateVoucherfun">生成凭证
 | 
	
		
			
				|  |  | +                <el-button size="small" type="primary" style="margin-right: 8px"
 | 
	
		
			
				|  |  | +                    :disabled="!form.id || form.isCleared != 1" v-if="!form.voucherNo && voucher == 1"
 | 
	
		
			
				|  |  | +                    :loading="saveLoading" @click="generateVoucherfun">生成凭证
 | 
	
		
			
				|  |  |                  </el-button>
 | 
	
		
			
				|  |  | -                <span v-if="form.voucherNo&&voucher==1" style="font-size: 12px;margin-right: 8px;">已生成凭证</span>
 | 
	
		
			
				|  |  | +                <span v-if="form.voucherNo && voucher == 1" style="font-size: 12px;margin-right: 8px;">已生成凭证</span>
 | 
	
		
			
				|  |  |                  <el-button size="small" type="warning" plain style="margin-right: 8px" :disabled="!form.id || editPower"
 | 
	
		
			
				|  |  |                      v-if="form.isCleared == 1" :loading="saveLoading" @click="finstlbillsRevokeSettlementfun">撤销结算
 | 
	
		
			
				|  |  |                  </el-button>
 | 
	
	
		
			
				|  | @@ -61,16 +62,16 @@
 | 
	
		
			
				|  |  |                              </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 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="5">
 | 
	
		
			
				|  |  |                                  <el-form-item label="费用名称" prop="feeCnName">
 | 
	
		
			
				|  |  |                                      <dic-select v-model="form.feeCnName" placeholder="费用名称" key="id" label="cnName"
 | 
	
		
			
				|  |  | -                                         url="/blade-los/bfees/listAll" :filterable="true" :multiple="true" :collapseTags="true"
 | 
	
		
			
				|  |  | -                                        :disabled="editSave"></dic-select>
 | 
	
		
			
				|  |  | +                                        url="/blade-los/bfees/listAll" :filterable="true" :multiple="true"
 | 
	
		
			
				|  |  | +                                        :collapseTags="true" :disabled="editSave"></dic-select>
 | 
	
		
			
				|  |  |                                  </el-form-item>
 | 
	
		
			
				|  |  |                              </el-col>
 | 
	
		
			
				|  |  |                              <el-col :span="4">
 | 
	
	
		
			
				|  | @@ -109,8 +110,8 @@
 | 
	
		
			
				|  |  |                              <el-col :span="3">
 | 
	
		
			
				|  |  |                                  <el-form-item label="币别" prop="curCode">
 | 
	
		
			
				|  |  |                                      <search-query :datalist="curCodeData" :selectValue="form.curCode" :clearable="true"
 | 
	
		
			
				|  |  | -                                        :disabled="editSave || tableData.length > 0" :buttonIf="false" :filterable="true"
 | 
	
		
			
				|  |  | -                                        :remote="true" placeholder="请选择币别"
 | 
	
		
			
				|  |  | +                                        :disabled="editSave || tableData.length > 0" :buttonIf="false"
 | 
	
		
			
				|  |  | +                                        :filterable="true" :remote="true" placeholder="请选择币别"
 | 
	
		
			
				|  |  |                                          :forParameter="{ key: 'id', label: 'code', value: 'code' }"
 | 
	
		
			
				|  |  |                                          @corpChange="corpChange($event, 'curCode')" @remoteMethod="getRateListfun"
 | 
	
		
			
				|  |  |                                          @corpFocus="getRateListfun">
 | 
	
	
		
			
				|  | @@ -119,22 +120,24 @@
 | 
	
		
			
				|  |  |                              </el-col>
 | 
	
		
			
				|  |  |                              <el-col :span="5">
 | 
	
		
			
				|  |  |                                  <el-form-item label="业务编号" prop="businessNo">
 | 
	
		
			
				|  |  | -                                    <el-input style="width: 100%;" v-model="form.businessNo" size="small" autocomplete="off"
 | 
	
		
			
				|  |  | -                                        :disabled="editSave || tableData.length > 0" clearable placeholder="请输入业务编号">
 | 
	
		
			
				|  |  | +                                    <el-input style="width: 100%;" v-model="form.businessNo" size="small"
 | 
	
		
			
				|  |  | +                                        autocomplete="off" :disabled="editSave || tableData.length > 0" clearable
 | 
	
		
			
				|  |  | +                                        placeholder="请输入业务编号">
 | 
	
		
			
				|  |  |                                      </el-input>
 | 
	
		
			
				|  |  |                                  </el-form-item>
 | 
	
		
			
				|  |  |                              </el-col>
 | 
	
		
			
				|  |  |                              <el-col :span="5">
 | 
	
		
			
				|  |  |                                  <el-form-item label="来源单号" prop="requestNo">
 | 
	
		
			
				|  |  | -                                    <el-input style="width: 100%;" v-model="form.requestNo" size="small" autocomplete="off"
 | 
	
		
			
				|  |  | -                                        :disabled="true" clearable placeholder="请输入来源单号">
 | 
	
		
			
				|  |  | +                                    <el-input style="width: 100%;" v-model="form.requestNo" size="small"
 | 
	
		
			
				|  |  | +                                        autocomplete="off" :disabled="true" clearable placeholder="请输入来源单号">
 | 
	
		
			
				|  |  |                                      </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 || tableData.length > 0" clearable placeholder="请输入ACCT NO">
 | 
	
		
			
				|  |  | +                                    <el-input style="width: 100%;" v-model="form.accountNo" size="small"
 | 
	
		
			
				|  |  | +                                        autocomplete="off" :disabled="editSave || tableData.length > 0" clearable
 | 
	
		
			
				|  |  | +                                        placeholder="请输入ACCT NO">
 | 
	
		
			
				|  |  |                                      </el-input>
 | 
	
		
			
				|  |  |                                  </el-form-item>
 | 
	
		
			
				|  |  |                              </el-col>
 | 
	
	
		
			
				|  | @@ -154,8 +157,9 @@
 | 
	
		
			
				|  |  |                              </el-col>
 | 
	
		
			
				|  |  |                              <el-col :span="4">
 | 
	
		
			
				|  |  |                                  <el-form-item label="对账单号" prop="checkNo">
 | 
	
		
			
				|  |  | -                                    <el-input style="width: 100%;" v-model="form.checkNo" size="small" autocomplete="off"
 | 
	
		
			
				|  |  | -                                        :disabled="editSave || tableData.length > 0" clearable placeholder="请输入对账单号">
 | 
	
		
			
				|  |  | +                                    <el-input style="width: 100%;" v-model="form.checkNo" size="small"
 | 
	
		
			
				|  |  | +                                        autocomplete="off" :disabled="editSave || tableData.length > 0" clearable
 | 
	
		
			
				|  |  | +                                        placeholder="请输入对账单号">
 | 
	
		
			
				|  |  |                                      </el-input>
 | 
	
		
			
				|  |  |                                  </el-form-item>
 | 
	
		
			
				|  |  |                              </el-col>
 | 
	
	
		
			
				|  | @@ -277,7 +281,8 @@
 | 
	
		
			
				|  |  |          <el-dialog title="选择数据" class="el-dialogDeep" :visible.sync="retrievePopupsType" append-to-body width="70%"
 | 
	
		
			
				|  |  |              :close-on-click-modal="false">
 | 
	
		
			
				|  |  |              <div>
 | 
	
		
			
				|  |  | -                <avue-crud :option="retrievePopupsOption" :data="retrievePopupsData" ref="retrievePopupsRef" id="out-table">
 | 
	
		
			
				|  |  | +                <avue-crud :option="retrievePopupsOption" :data="retrievePopupsData" ref="retrievePopupsRef"
 | 
	
		
			
				|  |  | +                    id="out-table">
 | 
	
		
			
				|  |  |                      <template slot="menu" slot-scope="{ row }">
 | 
	
		
			
				|  |  |                          <el-button type="text" size="small" @click.stop="retrievePopupsSelect(row)">选择
 | 
	
		
			
				|  |  |                          </el-button>
 | 
	
	
		
			
				|  | @@ -293,8 +298,8 @@
 | 
	
		
			
				|  |  |          </el-dialog>
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |          <!--预览-->
 | 
	
		
			
				|  |  | -        <el-dialog title="打印" :visible.sync="selectPrintingDialog" append-to-body width="70%" :close-on-click-modal="false"
 | 
	
		
			
				|  |  | -            :destroy-on-close="true" :close-on-press-escape="false" v-dialog-drag>
 | 
	
		
			
				|  |  | +        <el-dialog title="打印" :visible.sync="selectPrintingDialog" append-to-body width="70%"
 | 
	
		
			
				|  |  | +            :close-on-click-modal="false" :destroy-on-close="true" :close-on-press-escape="false" v-dialog-drag>
 | 
	
		
			
				|  |  |              <div>
 | 
	
		
			
				|  |  |                  <reportformsList ref="reportformsList" @reportRadio="reportRadio"></reportformsList>
 | 
	
		
			
				|  |  |              </div>
 | 
	
	
		
			
				|  | @@ -330,11 +335,11 @@ import reportformsList from "@/views/iosBasicData/SeafreightExportF/bills/assemb
 | 
	
		
			
				|  |  |  import { getList as getreportsList, reportsGetReportData } from "@/api/iosBasicData/reports";
 | 
	
		
			
				|  |  |  import reportContainer from "@/views/iosBasicData/report-container/report-container.vue";
 | 
	
		
			
				|  |  |  import { generateFinStlBills } from "@/api/iosBasicData/fininvoices";
 | 
	
		
			
				|  |  | -import { dateFormat} from "@/util/date";
 | 
	
		
			
				|  |  | +import { dateFormat } from "@/util/date";
 | 
	
		
			
				|  |  |  import dicSelect from "@/components/dicSelect/main";
 | 
	
		
			
				|  |  | -import {isProcurement} from "@/api/basicData/configuration";
 | 
	
		
			
				|  |  | +import { isProcurement } from "@/api/basicData/configuration";
 | 
	
		
			
				|  |  |  export default {
 | 
	
		
			
				|  |  | -    components: { reportContainer, reportformsList, reports, SearchQuery, expand, finstlbillsitems,dicSelect },
 | 
	
		
			
				|  |  | +    components: { reportContainer, reportformsList, reports, SearchQuery, expand, finstlbillsitems, dicSelect },
 | 
	
		
			
				|  |  |      props: {
 | 
	
		
			
				|  |  |          // 编辑还是保存
 | 
	
		
			
				|  |  |          editSave: {
 | 
	
	
		
			
				|  | @@ -395,7 +400,7 @@ export default {
 | 
	
		
			
				|  |  |              // 绑定的数据
 | 
	
		
			
				|  |  |              form: {
 | 
	
		
			
				|  |  |                  dc: null,
 | 
	
		
			
				|  |  | -                billDate:dateFormat(new Date())
 | 
	
		
			
				|  |  | +                billDate: dateFormat(new Date())
 | 
	
		
			
				|  |  |              },
 | 
	
		
			
				|  |  |              handleSelectionData: [], // 表格选择的数据
 | 
	
		
			
				|  |  |              corpData: [], // 结算单位 数据
 | 
	
	
		
			
				|  | @@ -435,17 +440,22 @@ export default {
 | 
	
		
			
				|  |  |              roleName: [], // 当前的角色权限
 | 
	
		
			
				|  |  |              saberUserInfo: {}, // 当前登录人信息
 | 
	
		
			
				|  |  |              editPower: false, // 当前是否可以编辑
 | 
	
		
			
				|  |  | -            voucher:0,
 | 
	
		
			
				|  |  | +            voucher: 0,
 | 
	
		
			
				|  |  | +            auditing: 0
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  |      created() {
 | 
	
		
			
				|  |  |          this.roleName = localStorage.getItem('roleName').split(',')
 | 
	
		
			
				|  |  |          // 获取当前登录人个人信息
 | 
	
		
			
				|  |  |          this.saberUserInfo = JSON.parse(localStorage.getItem('saber-userInfo')).content
 | 
	
		
			
				|  |  | -        isProcurement({"param":"automatic.generate.voucher"}).then(res=>{
 | 
	
		
			
				|  |  | -                    // res.data.data === '1'
 | 
	
		
			
				|  |  | -                    this.voucher = res.data.data
 | 
	
		
			
				|  |  | -                })
 | 
	
		
			
				|  |  | +        isProcurement({ "param": "automatic.generate.voucher" }).then(res => {
 | 
	
		
			
				|  |  | +            // res.data.data === '1'
 | 
	
		
			
				|  |  | +            this.voucher = res.data.data
 | 
	
		
			
				|  |  | +        })
 | 
	
		
			
				|  |  | +        isProcurement({ "param": "whether.auditing" }).then(res => {
 | 
	
		
			
				|  |  | +            // res.data.data === '1'
 | 
	
		
			
				|  |  | +            this.auditing = res.data.data
 | 
	
		
			
				|  |  | +        })
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  |      methods: {
 | 
	
		
			
				|  |  |          // 打印
 | 
	
	
		
			
				|  | @@ -649,6 +659,19 @@ export default {
 | 
	
		
			
				|  |  |                          return;
 | 
	
		
			
				|  |  |                      }
 | 
	
		
			
				|  |  |                  }
 | 
	
		
			
				|  |  | +                if (type == '结算') {
 | 
	
		
			
				|  |  | +                    if (this.auditing == 1) {
 | 
	
		
			
				|  |  | +                        for (let [index, row] of this.tableData.entries()) {
 | 
	
		
			
				|  |  | +                            if (row.feeCnName == '增值税') {
 | 
	
		
			
				|  |  | +                                if (!row.taxInvoiceNumber || !row.taxInvoiceDate || !row.deductionTime) {
 | 
	
		
			
				|  |  | +                                    this.pageLoading = false
 | 
	
		
			
				|  |  | +                                    this.saveLoading = false
 | 
	
		
			
				|  |  | +                                    return this.$message.error("请完善第" + Number(index+ 1)  + "行增值税明细信息");
 | 
	
		
			
				|  |  | +                                }
 | 
	
		
			
				|  |  | +                            }
 | 
	
		
			
				|  |  | +                        }
 | 
	
		
			
				|  |  | +                    }
 | 
	
		
			
				|  |  | +                }
 | 
	
		
			
				|  |  |                  this.saveLoading = true // 打开按钮动画
 | 
	
		
			
				|  |  |                  if (this.form.estimatedTime) {
 | 
	
		
			
				|  |  |                      this.form.estimatedTime = this.form.estimatedTime + ' 00:00:00'
 | 
	
	
		
			
				|  | @@ -658,6 +681,7 @@ export default {
 | 
	
		
			
				|  |  |                  this.form.businessTypeCode = 'STL'
 | 
	
		
			
				|  |  |                  this.form.businessType = 'STL' // 结算单
 | 
	
		
			
				|  |  |                  this.form.businessTypes = Array.isArray(this.form.businessTypes) ? this.form.businessTypes.join(',') : this.form.businessTypes // 业务类型
 | 
	
		
			
				|  |  | +                console.log(this.form.feeCnName ,this.form.feeCnName.join(','))
 | 
	
		
			
				|  |  |                  this.form.feeCnName = this.form.feeCnName ? this.form.feeCnName.join(',') : ''
 | 
	
		
			
				|  |  |                  this.form.businessDateStart = this.form.businessDateStart ? this.form.businessDateStart.slice(0, 10) + ' 00:00:00' : null // 财务开始日期
 | 
	
		
			
				|  |  |                  this.form.businessDateEnd = this.form.businessDateEnd ? this.form.businessDateEnd.slice(0, 10) + ' 00:00:00' : null // 财务开始日期
 | 
	
	
		
			
				|  | @@ -723,6 +747,7 @@ export default {
 | 
	
		
			
				|  |  |                  }
 | 
	
		
			
				|  |  |                  // 判断是结算还是保存
 | 
	
		
			
				|  |  |                  if (type == '结算') {
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  |                      this.$confirm("确定进行结算操作?", {
 | 
	
		
			
				|  |  |                          confirmButtonText: "确定",
 | 
	
		
			
				|  |  |                          cancelButtonText: "取消",
 | 
	
	
		
			
				|  | @@ -748,7 +773,6 @@ export default {
 | 
	
		
			
				|  |  |                                      this.$set(item, 'amountNetUSD', item.amountNet)
 | 
	
		
			
				|  |  |                                      this.$set(item, 'stlTtlAmountNetUSD', item.stlTtlAmountNet)
 | 
	
		
			
				|  |  |                                      this.$set(item, 'stlTtlAmountUSD', item.stlTtlAmount)
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  |                                      this.$set(item, 'currentStlAmountNetUSD', item.currentStlAmountNet)
 | 
	
		
			
				|  |  |                                      this.$set(item, 'currentStlAmountUSD', item.currentStlAmount)
 | 
	
		
			
				|  |  |                                  }
 | 
	
	
		
			
				|  | @@ -786,7 +810,7 @@ export default {
 | 
	
		
			
				|  |  |                      this.editPower = false
 | 
	
		
			
				|  |  |                  }
 | 
	
		
			
				|  |  |                  this.form.businessTypes = this.form.businessTypes ? this.form.businessTypes.split(',') : [] // 业务类型转换成数组显示
 | 
	
		
			
				|  |  | -                  this.form.feeCnName = this.form.feeCnName ? this.form.feeCnName.split(',') : []
 | 
	
		
			
				|  |  | +                this.form.feeCnName = this.form.feeCnName ? this.form.feeCnName.split(',') : []
 | 
	
		
			
				|  |  |                  this.tableData = this.form.finStlBillsItemsList.map(item => {
 | 
	
		
			
				|  |  |                      item.stlTtlAmountNet = Number(item.stlTtlAmount) - (Number(item.stlTtlAmount) * (Number(item.taxRate) + Number(item.surchargeRate)))
 | 
	
		
			
				|  |  |                      item.currentStlAmountNet = Number(item.unsettledAmount) - (Number(item.unsettledAmount) * (Number(item.taxRate) + Number(item.surchargeRate)))
 | 
	
	
		
			
				|  | @@ -832,7 +856,7 @@ export default {
 | 
	
		
			
				|  |  |              }).then(res => {
 | 
	
		
			
				|  |  |                  this.form = res.data.data
 | 
	
		
			
				|  |  |                  this.form.businessTypes = this.form.businessTypes ? this.form.businessTypes.split(',') : [] // 业务类型转换成数组显示
 | 
	
		
			
				|  |  | -                  this.form.feeCnName = this.form.feeCnName ? this.form.feeCnName.split(',') : []
 | 
	
		
			
				|  |  | +                this.form.feeCnName = this.form.feeCnName ? this.form.feeCnName.split(',') : []
 | 
	
		
			
				|  |  |                  this.tableData = this.form.finStlBillsItemsList.map(item => {
 | 
	
		
			
				|  |  |                      item.stlTtlAmountNet = Number(item.stlTtlAmount) - (Number(item.stlTtlAmount) * (Number(item.taxRate) + Number(item.surchargeRate)))
 | 
	
		
			
				|  |  |                      item.currentStlAmountNet = Number(item.unsettledAmount) - (Number(item.unsettledAmount) * (Number(item.taxRate) + Number(item.surchargeRate)))
 | 
	
	
		
			
				|  | @@ -1087,7 +1111,7 @@ export default {
 | 
	
		
			
				|  |  |          finstlbillsConfirmSettlementfun() {
 | 
	
		
			
				|  |  |              this.pageLoading = true
 | 
	
		
			
				|  |  |              this.form.businessTypes = Array.isArray(this.form.businessTypes) ? this.form.businessTypes.join(',') : this.form.businessTypes // 业务类型
 | 
	
		
			
				|  |  | -            this.form.feeCnName = this.form.feeCnName ? this.form.feeCnName.join(',') : ''
 | 
	
		
			
				|  |  | +            // this.form.feeCnName = this.form.feeCnName ? this.form.feeCnName.join(',') : ''
 | 
	
		
			
				|  |  |              this.form.businessDateStart = this.form.businessDateStart ? this.form.businessDateStart.slice(0, 10) + ' 00:00:00' : null // 财务开始日期
 | 
	
		
			
				|  |  |              this.form.businessDateEnd = this.form.businessDateEnd ? this.form.businessDateEnd.slice(0, 10) + ' 00:00:00' : null // 财务开始日期
 | 
	
		
			
				|  |  |              this.form.billDate = this.form.billDate ? this.form.billDate.slice(0, 10) + ' 00:00:00' : null
 |