Commit 527ff0dd authored by 华国豪's avatar 华国豪 🙄

新增新增、修改财务付款单选择费用选择地接费时绑定历史汇率,获取币种汇率新增参数 tcid

parent a95b739b
......@@ -290,7 +290,7 @@
</tr>
<tr v-else @keyup.enter="addList(2,daIn+1)">
<td height="26px">
<el-select filterable v-model='da.CostTypeId' ref='CostTypeId' :placeholder="$t('rule.qxzfyshuoming')" @change="getCostTypeName(da.CostTypeId, daIn),addList(2,daIn+1)" class=" _border_b_1">
<el-select filterable v-model='da.CostTypeId' ref='CostTypeId' :placeholder="$t('rule.qxzfyshuoming')" @change="getCostTypeName(da.CostTypeId, daIn),getRate(da.CostTypeId,da.CurrencyId,2,daIn),addList(2,daIn+1)" class=" _border_b_1">
<el-option v-for='item in GetCostTypeList'
:label='item.Name'
:value='item.ID'
......@@ -308,7 +308,7 @@
<input v-model="da.UnitPrice" type="text" @blur="addList(2,daIn+1)" @change="Calculation(2,daIn+1)" class="w80 h34 _border_b_1"></input>
</td>
<td height="26px">
<el-select filterable v-model='da.CurrencyId' :placeholder="$t('rule.qxzbzhong')" @change="getRate(da.CurrencyId,2,daIn),addList(2,daIn+1)" class=" _border_b_1">
<el-select filterable v-model='da.CurrencyId' :placeholder="$t('rule.qxzbzhong')" @change="getRate(da.CostTypeId,da.CurrencyId,2,daIn),addList(2,daIn+1)" class=" _border_b_1">
<el-option v-for='item in coinGetList'
:label='item.Name'
:value='item.ID'
......@@ -326,7 +326,7 @@
<tr @keyup.enter="addList(1)">
<td >
<el-select filterable v-model='detailList.CostTypeId' ref='CostTypeId' :placeholder="$t('rule.qxzfyshuoming')" @change="getCostTypeName(detailList.CostTypeId),addList(1)" class=" _border_b_1">
<el-select filterable v-model='detailList.CostTypeId' ref='CostTypeId' :placeholder="$t('rule.qxzfyshuoming')" @change="getCostTypeName(detailList.CostTypeId), getRate(detailList.CostTypeId,detailList.CurrencyId,1),addList(1)" class=" _border_b_1">
<el-option v-for='item in GetCostTypeList'
:label='item.Name'
:value='item.ID'
......@@ -347,7 +347,7 @@
<input v-model="detailList.UnitPrice" type="text" @blur="addList(1)" @change="Calculation(1)" class="w80 h34 _border_b_1"></input>
</td>
<td>
<el-select filterable v-model='detailList.CurrencyId' :placeholder="$t('rule.qxzbzhong')" @change="getRate(detailList.CurrencyId,1),addList(1)" class=" _border_b_1">
<el-select filterable v-model='detailList.CurrencyId' :placeholder="$t('rule.qxzbzhong')" @change="getRate(detailList.CostTypeId,detailList.CurrencyId,1),addList(1)" class=" _border_b_1">
<el-option v-for='item in coinGetList'
:label='item.Name'
:value='item.ID'
......@@ -1037,15 +1037,14 @@ export default {
}
})
},
getRate(i,t,index){ // 根据选择币种获取汇率
getRate(cID,i,t,index){ // 根据选择币种获取汇率
this.coinGetList.forEach(x=>{
if(x.ID==i){
if(t==1){
this.detailList.Rate = x.PayRate;
this.detailList.Rate = cID === 57 ? x.PayRateHistory : x.PayRate;
this.detailList.currenName = x.Name;
}else{
console.log(x)
this.msg.detailList[index].Rate =x.PayRate;
this.msg.detailList[index].Rate = cID === 57 ? x.PayRateHistory : x.PayRate;
this.msg.detailList[index].currenName = x.Name;
}
this.$forceUpdate();
......@@ -1164,8 +1163,8 @@ export default {
}
}, err => {})
},
financeinfo_post_GetList(){ // 获取币种
this.apipost('financeinfo_post_GetList',{Name:''}, res => {
financeinfo_post_GetList(TCID){ // 获取币种
this.apipost('financeinfo_post_GetList',{Name:'', TCID: TCID}, res => {
if(res.data.resultCode == 1) {
this.coinGetList = res.data.data;
}
......@@ -1263,6 +1262,10 @@ export default {
}
this.msg.URL = this.$route.query.path;
this.msg.Cmd = this.$route.query.Cmd?this.$route.query.Cmd:'';
if (id > 0) {
let TCID = data.TCIDList.length>0 ? data.TCIDList[0] : 0
this.financeinfo_post_GetList(TCID);
}
this.$forceUpdate();
this.loading=false;
if(this.$route.query.InPay)
......@@ -1270,7 +1273,7 @@ export default {
this.msg.Type=this.$route.query.InPay;
}
if(this.isFrompassenger){
this.setDocument();
this.setDocument();
}
}else{
this.loading=false;
......@@ -1424,7 +1427,6 @@ export default {
this.IsUploadPic = this.$route.query.IsUploadPic;
this.msg.Cmd = this.$route.query.Cmd?this.$route.query.Cmd:'';
this.financeinfo_post_GetClientTypeList();
this.financeinfo_post_GetList();
const myDate = new Date();
this.yaer = myDate.getFullYear(); //获取完整的年份(4位,1970-????)
this.month = myDate.getMonth()+1; //获取当前月份(0-11,0代表1月)
......@@ -1444,6 +1446,8 @@ export default {
this.BillSonName = this.$route.query.Name;
this.FinancialFlowTemplate_post_GetProcessList(this.$route.query.id);
this.Financial_post_Get(0,parseInt(this.$route.query.id));
let TCID = this.orderObj.TCID ? this.orderObj.TCID : 0
this.financeinfo_post_GetList(TCID);
}
if(this.$route.query.Conditon){
this.returnCode = this.$route.query.Conditon;
......
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