Commit 8878a8b7 authored by youjie's avatar youjie

no message

parent 943f4778
......@@ -394,7 +394,13 @@
<el-button class="normalBtn" type="primary" @click="preservetransaction()">{{$t('pub.sureBtn')}}</el-button>
</div>
</el-dialog>
<!-- 修改汇率 -->
<editExchangeRate v-if="costmodeHL"
:hlData="trabeListHL"
@success="resetPageIndex(),
getPageList(),
costmodeHL=false"
@cancel="costmodeHL=false"></editExchangeRate>
<!-- 修改汇率
<el-dialog title="修改汇率" width="400px"
:visible.sync="costmodeHL" center >
<template v-for='(x,y) in trabeListHL'>
......@@ -419,7 +425,7 @@
<el-button class="hollowFixedBtn" @click="costmodeHL=false">{{$t('pub.cancelBtn')}}</el-button>
<el-button class="normalBtn" type="primary" @click="preservetransactionHL()">{{$t('pub.sureBtn')}}</el-button>
</div>
</el-dialog>
</el-dialog> -->
<!-- 修改手续费 -->
<template v-if="transactionTax">
<shouxufei :transTax="transTax"
......@@ -432,6 +438,7 @@ import myBill from "./FinancialSubmodule/BillModule.vue";
import myrbvBill from "./FinancialSubmodule/ReceivablesModule.vue";
import myhrBill from "./FinancialSubmodule/MergeBillModule.vue";
import shouxufei from "./components/shouxufei.vue";
import editExchangeRate from "./components/editExchangeRate.vue";
import Vue from 'vue'
// 自定义列组件
Vue.component('table-BranchName',{ //查看操作按钮
......@@ -1131,7 +1138,8 @@ export default {
},components: {
"my-Bill": myBill,
"my-RVB-Bill":myrbvBill,
shouxufei
shouxufei,
editExchangeRate
},mounted(){
let userInfo=this.getLocalStorage();
this.getCompanyMsg.RB_Group_Id= this.employeeMsg.GroupId = this.getDepartmentMsg.RB_Group_Id = userInfo.RB_Group_id; //集团ID
......@@ -1611,6 +1619,9 @@ export default {
this.transactionTax = false
},
showhuilv(row){
this.trabeListHL = row
this.costmodeHL = true
return
this.apipost('Financial_get_GetFinanceRate', {FinanceId:row.FrID}, res => {
if (res.data.resultCode == 1) {
this.trabeListHL = []
......
<style scoped>
@import '../../../assets/css/financia/editRate.css';
</style>
<template v-if="GetDetail.DetailList.length>0">
<div class="Receipt_box"
......@@ -50,14 +49,39 @@
<td height="26px"></td>
<td height="26px">{{benMoney}}</td>
</tr>
<tr v-if="GetDetail.CashierDetail&&GetDetail.CashierDetail.length&&(GetDetail.Type!=1|| GetDetail.Type!=5)">
<!-- <tr v-if="GetDetail.CashierDetail&&GetDetail.CashierDetail.length&&(GetDetail.Type!=1|| GetDetail.Type!=5)">
<td height="34px" class="">{{$t('tips.jiaoyifangshi')}}</td>
<td height="34px" colspan="2" class="_color_b">
<td height="34px" colspan="4" class="_color_b">
<template v-for="(item,index) in GetDetail.CashierDetail">
<p class=" clearfix"><span class="_bold">{{item.Alias}}-</span><span class="">{{item.TypeName}}-</span><span >{{item.AccountType==""?$t('fnc.no'):item.AccountType}}</span> {{item.BankNo?'-':''}} <span>{{item.BankNo}}</span>({{item.Money}})</p>
</template>
</td>
</tr>
</tr> -->
<tr v-if="GetDetail.CashierDetail&&GetDetail.CashierDetail.length&&(GetDetail.Type!=1|| GetDetail.Type!=5)">
<template v-for="(item,daIn) in GetDetail.CashierDetail">
<td height="34px" colspan="1" class="_color_b">
<p class=" clearfix"><span class="_bold">{{item.Alias}}-</span><span class="">{{item.TypeName}}-</span><span >{{item.AccountType==""?$t('fnc.no'):item.AccountType}}</span> {{item.BankNo?'-':''}} <span>{{item.BankNo}}</span>{{item.Money}}</p>
</td>
<td height="34px" class="">
<p class=" clearfix"><span class="_bold">{{item.CurrencyName}}</span></p>
</td>
<td height="34px" class="">
<el-input v-model="item.OriginalMoney" type="text"
class="w80 _border_b_1"
style="border-bottom: 1px solid #333;margin-bottom: 5px;"
@change="addList(item,1)"></el-input>
</td>
<td height="34px" class="">
<el-input v-model="item.Rate" type="text"
class="w80 _border_b_1"
style="border-bottom: 1px solid #333;margin-bottom: 5px;"
@change="addList(item,1)"></el-input>
</td>
<td height="34px" class="">
{{item.Money}}
</td>
</template>
</tr>
</table>
</div>
</template>
......@@ -99,6 +123,7 @@ export default {
printTime:'',
currentMoney:0,
benMoney:0,
benMoney2:0,
GetDetail:{}
}
},
......@@ -124,25 +149,42 @@ export default {
}
}
},
addList(t, i) { // 添加
t.Money = (t.Rate*100)* t.Money
t.Money = t.Money/100
this.calculation()
},
calculation(){
this.currentMoney = 0
this.benMoney = 0
this.GetDetail.DetailList.forEach(x=>{
x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100)
x.Money = (x.Rate*100)*x.OriginalMoney
x.Money = (x.Money/100).toFixed(2)
// x.Money = Math.round(x.Money * 100) / 100
addList(t, i) { // 添加
t.Money = (t.Rate*100)* t.Money
t.Money = t.Money/100
if(!i){
this.calculation()
}else{
this.calculation(i)
}
x.OriginalMoney = Math.round(x.OriginalMoney * 100) / 100
this.currentMoney += parseFloat(x.OriginalMoney);
this.benMoney += parseFloat(x.Money);
})
},
},
calculation(i){
if(!i){
this.currentMoney = 0
this.benMoney = 0
this.GetDetail.DetailList.forEach(x=>{
x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100)
x.Money = (x.Rate*100)*x.OriginalMoney
x.Money = (x.Money/100).toFixed(2)
// x.Money = Math.round(x.Money * 100) / 100
x.OriginalMoney = Math.round(x.OriginalMoney * 100) / 100
this.currentMoney += parseFloat(x.OriginalMoney);
this.benMoney += parseFloat(x.Money);
})
}else{
this.benMoney2 = 0
this.GetDetail.CashierDetail.forEach(x=>{
x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100)
x.Money = (x.Rate*100)*x.OriginalMoney
x.Money = (x.Money/100).toFixed(2)
x.OriginalMoney = Math.round(x.OriginalMoney * 100) / 100
this.benMoney2 += parseFloat(x.Money);
})
}
},
Financial_post_GetDetail(id){ //获取单据详情
if(!id) return
......@@ -268,7 +310,15 @@ export default {
watch: { // 监听参数变化
GetDetail: {
handler: function(val, oldVal) {
this.$emit('getList',val)
let isAmount = true
if(this.benMoney2>0){
if(this.benMoney2===this.benMoney){
isAmount = false
}else{
isAmount = true
}
}
this.$emit('getList',val,isAmount)
},
deep: true,
immediate: true
......
......@@ -2,8 +2,12 @@
@import '../../../assets/css/financia/editRate.css';
</style>
<template v-if="GetDetail.DetailList.length>0" >
<div class="Receipt_box" :class="[GetDetail.Type==1|| GetDetail.Type==5?'':'color_blur',isPrintPage?'_PrintPageStyle':'']" :style="{width:width,backgroundColor:color}" @click.stop v-loading='loading'>
<table class="Receipt_table" border="1" :class="[GetDetail.Type==1|| GetDetail.Type==5?'_border_color_r':'_border_color_b',isPrintPage?'_border_color_p':'']" :bordercolor="GetDetail.Type==1|| GetDetail.Type==5?'#c94052':'#106BAF'" style="border-collapse:collapse;">
<div class="Receipt_box"
:class="[GetDetail.Type==1|| GetDetail.Type==5?'':'color_blur',isPrintPage?'_PrintPageStyle':'']" :style="{width:width,backgroundColor:color}"
@click.stop v-loading='loading'>
<table class="Receipt_table" border="1"
:class="[GetDetail.Type==1|| GetDetail.Type==5?'_border_color_r':'_border_color_b',isPrintPage?'_border_color_p':'']" :bordercolor="GetDetail.Type==1|| GetDetail.Type==5?'#c94052':'#106BAF'"
style="border-collapse:collapse;width: 95%;">
<tr>
<th rowspan="2" width="150">{{$t('fnc.fyshuoming')}}</th>
<th rowspan="2" width="100">{{$t('hotel.hotel_Currency')}}</th>
......@@ -25,7 +29,7 @@
<el-input v-model="item.Rate" type="text"
class="w80 _border_b_1"
style="border-bottom: 1px solid #333;margin-bottom: 5px;"
@change="addList(item,daIn)"></el-input>
@change="addList(item)"></el-input>
</td>
<td height="26px" style="position: relative;">{{item.Money}}
<span v-if="!daIn&&GetDetail.DetailList.length>1"
......@@ -47,6 +51,31 @@
<td colspan="1">{{$t('fnc.shouxufei')}}<br/><span class="_font_size12">{{$t('fnc.khbweibi')}}</span></td>
<td colspan="2" class="_font_size12">{{GetDetail.Fee}}</td>
</tr>
<tr v-if="GetDetail.CashierDetail&&GetDetail.CashierDetail.length&&(GetDetail.Type!=1|| GetDetail.Type!=5)">
<template v-for="(item,daIn) in GetDetail.CashierDetail">
<td height="34px" colspan="1" class="_color_b">
<p class=" clearfix"><span class="_bold">{{item.Alias}}-</span><span class="">{{item.TypeName}}-</span><span >{{item.AccountType==""?$t('fnc.no'):item.AccountType}}</span> {{item.BankNo?'-':''}} <span>{{item.BankNo}}</span>{{item.Money}}</p>
</td>
<td height="34px" class="">
<p class=" clearfix"><span class="_bold">{{item.CurrencyName}}</span></p>
</td>
<td height="34px" class="">
<el-input v-model="item.OriginalMoney" type="text"
class="w80 _border_b_1"
style="border-bottom: 1px solid #333;margin-bottom: 5px;"
@change="addList(item,1)"></el-input>
</td>
<td height="34px" class="">
<el-input v-model="item.Rate" type="text"
class="w80 _border_b_1"
style="border-bottom: 1px solid #333;margin-bottom: 5px;"
@change="addList(item,1)"></el-input>
</td>
<td height="34px" class="">
{{item.Money}}
</td>
</template>
</tr>
</table>
</div>
</template>
......@@ -62,6 +91,7 @@ export default {
printTime:'',
currentMoney:0,
benMoney:0,
benMoney2:0,
GetDetail: {}
}
},
......@@ -89,21 +119,38 @@ export default {
addList(t, i) { // 添加
t.Money = (t.Rate*100)* t.Money
t.Money = t.Money/100
this.calculation()
if(!i){
this.calculation()
}else{
this.calculation(i)
}
},
calculation(){
this.currentMoney = 0
this.benMoney = 0
this.GetDetail.DetailList.forEach(x=>{
x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100)
x.Money = (x.Rate*100)*x.OriginalMoney
x.Money = (x.Money/100).toFixed(2)
// x.Money = Math.round(x.Money * 100) / 100
calculation(i){
if(!i){
this.currentMoney = 0
this.benMoney = 0
this.GetDetail.DetailList.forEach(x=>{
x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100)
x.Money = (x.Rate*100)*x.OriginalMoney
x.Money = (x.Money/100).toFixed(2)
// x.Money = Math.round(x.Money * 100) / 100
x.OriginalMoney = Math.round(x.OriginalMoney * 100) / 100
this.currentMoney += parseFloat(x.OriginalMoney);
this.benMoney += parseFloat(x.Money);
})
}else{
this.benMoney2 = 0
this.GetDetail.CashierDetail.forEach(x=>{
x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100)
x.Money = (x.Rate*100)*x.OriginalMoney
x.Money = (x.Money/100).toFixed(2)
x.OriginalMoney = Math.round(x.OriginalMoney * 100) / 100
this.currentMoney += parseFloat(x.OriginalMoney);
this.benMoney += parseFloat(x.Money);
})
this.benMoney2 += parseFloat(x.Money);
})
}
},
Financial_post_GetDetail(id){ //获取单据详情
if(!id) return;
......@@ -130,6 +177,14 @@ export default {
data.Money = this.$commonUtils.addCommas(Math.round(data.Money * 100) / 100);
data.AuditSteps.reverse();
this.GetDetail = data;
this.benMoney2 = 0
this.GetDetail.CashierDetail.forEach(x=>{
x.UnitPrice = this.$commonUtils.addCommas(Math.round(x.UnitPrice * 100) / 100)
x.Money = (x.Rate*100)*x.OriginalMoney
x.Money = (x.Money/100).toFixed(2)
x.OriginalMoney = Math.round(x.OriginalMoney * 100) / 100
this.benMoney2 += parseFloat(x.Money);
})
this.loading=false
this.$set(this.$data,"GetDetail",data);
}
......@@ -150,7 +205,15 @@ export default {
watch: { // 监听参数变化
GetDetail: {
handler: function(val, oldVal) {
this.$emit('getList',val)
let isAmount = true
if(this.benMoney2>0){
if(this.benMoney2===(this.benMoney-this.GetDetail.Fee)){
isAmount = false
}else{
isAmount = true
}
}
this.$emit('getList',val,isAmount)
},
deep: true
},
......
......@@ -4,10 +4,14 @@
<template>
<el-dialog title="修改汇率" :visible.sync="isShow" @closed="clickcancel" width="600px">
<my-Bill v-if="hlData.Type===2 && hlData.Type!==5" :isPrintPage="false" :ID="hlData.FrID"
<my-Bill v-if="hlData.Type===2 && hlData.Type!==5"
:isPrintPage="false"
:ID="hlData.FrID"
:width="widthSon" :color="colorSon" @getList='getList'></my-Bill>
<my-RVB-Bill v-else-if="hlData.Type===1" :ID="hlData.FrID" :isPrintPage="false" :width="widthSon"
:color="colorSon"></my-RVB-Bill>
<my-RVB-Bill v-else-if="hlData.Type===1" :ID="hlData.FrID"
:isPrintPage="false"
:width="widthSon"
:color="colorSon" @getList='getList'></my-RVB-Bill>
<span slot="footer" class="dialog-footer">
<el-button size="mini" @click="clickcancel">取 消</el-button>
<el-button class="normalBtn" size="mini" @click="submit" :loading="loadingSubmit">保 存</el-button>
......@@ -47,6 +51,7 @@
widthSon: "100%",
colorSon: "#ffffff",
AccountAmount: false
}
},
components: {
......@@ -56,9 +61,7 @@
watch: {
hlData:{
handler(val, oldVal){
console.log(val,'------')
this.parameters.FrID = val.FrID
// this.parameters.Fee = val.Fee
},
deep: true,
immediate: true
......@@ -68,8 +71,14 @@
},
methods: {
getList(GetDetail){
getList(GetDetail,isAmount){
if(isAmount){
this.AccountAmount = true
}else{
this.AccountAmount = false
}
if(GetDetail&&GetDetail.DetailList){
this.parameters.Fee = GetDetail.Fee
this.parameters.detailList = []
GetDetail.DetailList.forEach(itme=>{
let data = {ID:itme.ID,Rate:itme.Rate,Money:itme.Money}
......@@ -78,13 +87,16 @@
if(GetDetail.CashierDetail.length>0){
this.parameters.BankList = []
GetDetail.CashierDetail.forEach(itme=>{
let data = {ID:itme.ID,Rate:itme.Rate,Money:itme.Money}
let data = {ID:itme.ID,Rate:itme.Rate,Money:itme.Money,OriginalMoney:itme.Money}
this.parameters.BankList.push(data)
})
}
}
},
submit(){
if(this.AccountAmount){
return this.Error('请检查金额是否一致!');
}
if(this.parameters.detailList.length>0){
for(let i = 0;i<this.parameters.detailList.length;i++){
if(!this.parameters.detailList[i].Rate){
......@@ -101,9 +113,10 @@
this.isShow = false
this.$emit('success')
}else{
this.loadingSubmit = false
this.Error(res.data.message);
}
}, err => {})
}, err => {this.loadingSubmit = false})
},
clickcancel(){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment