Commit c7b933e7 authored by 黄媛媛's avatar 黄媛媛

票务管理新增机票服务费

parent a8326654
...@@ -323,8 +323,8 @@ ...@@ -323,8 +323,8 @@
<el-radio v-model="radio" v-else @change="getCostTypeList(2),CostIdS=[],accListMsg=[],accListShow=false" :label="7">{{$t('fnc.guazhang')}}</el-radio> <el-radio v-model="radio" v-else @change="getCostTypeList(2),CostIdS=[],accListMsg=[],accListShow=false" :label="7">{{$t('fnc.guazhang')}}</el-radio>
<el-radio v-model="radio" v-if="addMsg.TemplateType!=8" disabled="disabled" :label="8"></el-radio> <el-radio v-model="radio" v-if="addMsg.TemplateType!=8" disabled="disabled" :label="8"></el-radio>
<el-radio v-model="radio" v-else @change="getCostTypeList(2),CostIdS=[],accListMsg=[],accListShow=false" :label="8"></el-radio> <el-radio v-model="radio" v-else @change="getCostTypeList(2),CostIdS=[],accListMsg=[],accListShow=false" :label="8"></el-radio>
</el-form-item> </el-form-item>
<el-form-item :label="$t('fnc.scfujian')"> <el-form-item :label="$t('fnc.scfujian')">
<el-radio v-model="addMsg.IsUploadPic" :label="0">{{$t('fnc.buqiyong')}}</el-radio> <el-radio v-model="addMsg.IsUploadPic" :label="0">{{$t('fnc.buqiyong')}}</el-radio>
......
...@@ -1221,7 +1221,57 @@ ...@@ -1221,7 +1221,57 @@
.MyTicketManager .el-checkbox{ .MyTicketManager .el-checkbox{
margin-left: 30px; margin-left: 30px;
} }
.MyTicketManager .picload{
width: 138px;
height: 92px;
border-radius: 2px;
cursor: pointer;
margin-bottom: 10px;
padding: 5px;
margin-right: 10px;
position: relative;
}
.MyTicketManager .picload .el-upload{
width: 138px;
height: 92px;
}
.MyTicketManager .picload .el-upload-dragger{
width: 100%;
height: 100%;
}
.MyTicketManager ._addUpload_box>div{
float: left;
width: 138px;
height: 92px;
border: 1px dashed rgba(210,210,210,1);
border-radius: 2px;
cursor: pointer;
margin-bottom: 10px;
padding: 5px;
margin-right: 10px;
position: relative;
}
.MyTicketManager ._addUpload_box .icon-excel, .MyTicketManager ._addUpload_box .icon-pdf{
text-align: center;
font-size: 38px;
color: green;
line-height: 75px;
}
.MyTicketManager ._addUpload_box .icon-guanbi1{
font-size: 12px;
color: white;
display: inline-block;
margin-left: 15px;
position: absolute;
right: -6px;
top: -9px;
background-color: #f56c6c;
border-radius: 50%;
height: 20px;
width: 20px;
text-align: center;
line-height: 20px;
}
</style> </style>
<template> <template>
<div class="flexOne TicketManager MyTicketManager"> <div class="flexOne TicketManager MyTicketManager">
...@@ -1640,6 +1690,9 @@ ...@@ -1640,6 +1690,9 @@
@click="InfoChangeLogShow(item.ID)"></el-button> @click="InfoChangeLogShow(item.ID)"></el-button>
</el-popover> </el-popover>
</el-tooltip> </el-tooltip>
<el-tooltip class="item" effect="dark" content="机票服务费" placement="top-start">
<el-button type="primary" icon="iconfont icon-caidan-fill" @click="TikcetServiceCharge(item)"></el-button>
</el-tooltip>
</el-button-group> </el-button-group>
</div> </div>
<div style="margin-top:5px;"> <div style="margin-top:5px;">
...@@ -1677,6 +1730,7 @@ ...@@ -1677,6 +1730,7 @@
<a style="color:blue;cursor:pointer" @click='goUrlT("RegistrationList",subItem.TCID,"报名清单")'> <a style="color:blue;cursor:pointer" @click='goUrlT("RegistrationList",subItem.TCID,"报名清单")'>
({{subItem.TCID}}){{subItem.TCNUM}} </a> ({{subItem.TCID}}){{subItem.TCNUM}} </a>
<a style="color:red;cursor:pointer;" @click="goUrlTicketUnion(subItem.TCID,item.ID)">设置联运</a> <a style="color:red;cursor:pointer;" @click="goUrlTicketUnion(subItem.TCID,item.ID)">设置联运</a>
<a style="cursor:pointer;" @click="goFinaceDetails(subItem.FinanceId)" v-if="subItem.FinanceId">(折让单:{{subItem.FinanceId}})</a>
</span> </span>
</div> </div>
</el-col> </el-col>
...@@ -2216,6 +2270,146 @@ ...@@ -2216,6 +2270,146 @@
<button class="normalBtn" type="primary" @click="TicketFinalTranfer">{{$t('pub.sureBtn')}}</button> <button class="normalBtn" type="primary" @click="TicketFinalTranfer">{{$t('pub.sureBtn')}}</button>
</div> </div>
</el-dialog> </el-dialog>
<!-- 机票服务费 -->
<el-dialog width="1000px" title="保存" :visible.sync="moneyR" center>
<el-form :rules="TicketServerules" class="Rform" ref="form" :model="Ticketform" label-width="110px">
<el-row v-if="MsgRAirServiceList.length>0">
<el-col :span="1" style="padding-top:12px">团号</el-col>
<el-col :span="23">
<el-row v-if="!item.disabled" v-for="(item,index) in MsgRAirServiceList" :key="index">
<el-col :span="2" style="padding-top:12px">
<input type="checkbox" :value="item.TCID" v-model="customerList"/>{{item.TCID}}
</el-col>
<el-col :span="7">
<el-form-item label="机位">
<el-input v-model="item.TicketNum" @keyup.native="checkInteger(item,'TicketNum')"></el-input>
</el-form-item>
</el-col>
<el-col :span="7">
<el-form-item label="服务费" >
<el-input v-model="item.Money" @keyup.native="checkPrice(item,'Money')"></el-input>
</el-form-item>
</el-col>
<el-col :span="7">
<el-form-item label="备注">
<el-input v-model="item.Remark"></el-input>
</el-form-item>
</el-col>
</el-row>
<div>
</div>
</el-col>
</el-row>
<el-row style="margin-bottom: 15px;text-align:center" v-if="MsgRAirServiceList.length==0">暂无</el-row>
<div style="border-bottom:1px solid #eeeeee;margin-bottom: 15px;"></div>
<el-row>
<el-col :span="8">
<el-form-item label="预计付款日期">
<el-date-picker
v-model="Ticketform.PayDate"
value-format="yyyy-MM-dd"
type="date"
placeholder="选择日期">
</el-date-picker>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="币种">
<el-select filterable v-model='Ticketform.CurrencyId'>
<el-option v-for="item in currencyTypeList" :key="item.ID" :value="item.ID" :label="item.Name">
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="付款类型">
<el-select filterable prop="IsPublic" v-model='Ticketform.IsPublic' >
<el-option :label="$t('fnc.gongzhang')" :value='1' :key='1'></el-option>
<el-option :label="$t('fnc.sizhang')" :value='0' :key='0'></el-option>
<el-option :label="$t('fnc.rmbxianjin')" :value='2' :key='2'></el-option>
<el-option :label="$t('fnc.wbxianjin')" :value='3' :key='3'></el-option>
<el-option :label="$t('fnc.zjinchi')" :value='4' :key='4'></el-option>
<el-option :label="$t('fnc.ptxnzhanghu')" :value='5' :key='5'></el-option>
<el-option :label="$t('fnc.djxnzhanghu')" :value='6' :key='6'></el-option>
<el-option :label="$t('fnc.szxiangdi')" :value='7' :key='7'></el-option>
<el-option label="原路退款" :value='8' :key='8'></el-option>
<el-option label="地接预支款" :value='9' :key='9'></el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="客户类型">
<el-select v-if="!showDisable" filterable v-model='Ticketform.ClientType' @change="financeinfo_post_GetClientAccountList(Ticketform.ClientType)">
<el-option v-for='item in ClientTypeList'
:label='item.Name'
:value='item.ID'
:key='item.ID'>
</el-option>
</el-select>
</el-form-item>
</el-col>
<el-col :span="8">
<el-form-item label="客户名称">
<el-select filterable v-model='Ticketform.ClientID'>
<el-option v-for='item in ClientAccountList'
:label='item.Name'
:value='item.ID'
:key='item.ID'>
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="8">
<el-form-item label="上传附件">
<div class="picload">
<el-upload style="width: 138px;height: 92px;"
drag
:http-request="uploadFileBtn"
:multiple="true" :show-file-list="false" action="">
<i class="el-icon-plus avatar-uploader-icon"></i>
<div class="el-upload__text">{{$t('active.ld_djscwj')}}</div>
</el-upload>
</div>
</el-form-item>
</el-col>
<el-col :span="16" style="padding-top:5px">
<div class="_addUpload_box" v-for="(file,fIndex) in saveMsg" :key="fIndex">
<div v-if="file.Type==3">
<div style="width:100%;height:100%;overflow: hidden;">
<img style="width:100%" :src="file.Url?file.Url:file.Content" @click="showUpLoadFile(file)">
</div>
<span class="iconfont icon-guanbi1" @click="deleteUploadFile(fIndex)"></span>
</div>
<div v-if="file.Type==1">
<div class="iconfont " :class="file.Content.substring(file.Content.lastIndexOf('.')+1,file.Content.length).toUpperCase()=='PDF'? 'icon-pdf' : 'icon-excel'" @click="showUpLoadFile(file)">
</div>
<span class="iconfont icon-guanbi1" @click="deleteUploadFile(fIndex)"></span>
</div>
<div v-if="file.Type==2">
<div class="iconfont icon-excel" @click="showUpLoadFile(file)">
</div>
<span class="iconfont icon-guanbi1" @click="deleteUploadFile(fIndex)"></span>
</div>
</div>
</el-col>
</el-row>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button size="small" @click="moneyR = false">取 消</el-button>
<el-button :loading="Btnloading" size="small" type="danger" @click="RSumbit">确 定</el-button>
</span>
</el-dialog>
</div> </div>
</template> </template>
<script> <script>
...@@ -2229,6 +2423,34 @@ ...@@ -2229,6 +2423,34 @@
} }
} }
return { return {
currencyTypeList:[],
MsgRAirServiceList:[],
isCkedAll:false,
customerList:[],
Btnloading:false,
showDisable:false,
ClientAccountList:[],
ClientTypeList:[],
moneyR:false,
saveMsg:[],
Ticketform:{
ImportType:'',
IsPublic:"",
ClientType:"",
ClientID:"",
vorcherInos:[],
PayDate:'',
CurrencyId:1,
},
TicketServerules:{
ImportType: [
{ required: true, message: '请选择导入类型', trigger: 'change' }
],
IsPublic: [
{ required: true, message: '请选择付款类型', trigger: 'change' }
],
},
ticketMsg:{ ticketMsg:{
OldAirId:"", OldAirId:"",
NewAirId:'', NewAirId:'',
...@@ -2501,6 +2723,218 @@ ...@@ -2501,6 +2723,218 @@
}; };
}, },
methods: { methods: {
TikcetServiceCharge(item){
this.moneyR=true;
this.MsgRAirServiceList=[];
item.PriceList.forEach(price=>{
if(!price.disabled){
let obj={
AirTicketId:price.AirTicketId,
Money:price.Money,
TCID:price.TCID,
TCNUM:price.TCNUM,
TicketNum:price.TicketNum,
disabled:price.disabled,
Remark:"",
};
this.MsgRAirServiceList.push(obj);
}
})
},
IsPublicChange(val){
this.showDisable=false;
this.Ticketform.ClientType = '';
this.Ticketform.ClientID = '';
this.Ticketform.AccountNumber = '';
this.ClientAccountListS=[];
if(val==8||val==9){
this.showDisable=true;
}
},
RSumbit(){
if(this.customerList.length==0){
this.Error("至少选择一项!")
return;
}
this.Ticketform.AirServiceList=[];
this.customerList.forEach(item=>{
this.MsgRAirServiceList.forEach(obj=>{
if(item==obj.TCID){
this.Ticketform.AirServiceList.push(obj)
}
})
})
let list=this.Ticketform.AirServiceList;
for(let i=0;i<list.length;i++){
if(!list[i].Money || list[i].Money==""){
this.Error("请输入服务费")
return;
}
if(!list[i].TicketNum || list[i].TicketNum==""){
this.Error("请输入机位数")
return;
}
}
this.Ticketform.vorcherInos = this.saveMsg;
if(this.Ticketform.PayDate==""){
this.Error("请选择时间!");
return;
}
this.Btnloading=true;
this.apipost('Financial_post_SetAirTicketServiceBetchImport',this.Ticketform,res=>{
this.Btnloading=false;
if(res.data.resultCode==1){
this.Success(res.data.message)
this.initMsg();
this.moneyR=false;
this.getList();
}else{
this.Error(res.data.message)
}
},err=>{})
},
getCurrencyType() { // 币种类型
this.apipost('financeinfo_post_GetList', {
Name: ''
}, res => {
if (res.data.resultCode == 1) {
this.currencyTypeList = res.data.data;
}
}, err => {})
},
initMsg(){
this.saveMsg=[];
this.Ticketform={
ImportType:'',
IsPublic:"",
ClientType:"",
ClientID:"",
vorcherInos:[],
PayDate:'',
}
},
showUpLoadFile(i){ // 预览上传文件
if(i.Type==3){
this.picObj.push(i.Url);
this.picIsShow= true;
}else{
if(i.Content.substring(i.Content.lastIndexOf('.')+1,i.Content.length).toUpperCase()=='PDF'){
this.previewPDF(i.Url)
}else{
window.open("https://view.officeapps.live.com/op/view.aspx?src="+i.Url)
}
}
},
deleteUploadFile(i){ // 删除上传文件
this.saveMsg.splice(i,1);
},
uploadFileBtn(file) { //上传
if(file.file.size > 1024 * 1024 * 10) {
this.$message.warning(this.$t('tips.wjdxbncgsz'))
return
}
// 1 文档 2 数据 3 图片
let typeArr=[
{stringArr:'GIF|JPG|JPEG|PNG|BMP',type:3},
{stringArr:'DOCX|DOC|XLSX|XLS|PPT|PPTX|PDF',type:1},
]
let ft=file.file.name.substring(file.file.name.lastIndexOf('.')+1,file.file.name.length).toUpperCase();
let fileTypeNumber = 2;
let typeOk = false;
typeArr.forEach(x=>{
if(x.stringArr.indexOf(ft)!='-1')
{
fileTypeNumber=x.type;
typeOk = true;
}
})
if (!typeOk) return this.$message.error(this.$t('tips.qscWEfile'));
let newArr = [];
newArr.push(file.file)
let path = "/Upload/Temporary/"
this.$message.info(this.$t('tips.shangchuanzhong'))
this.UploadSelfFileT(path, newArr, x => {
let fileSize = file.file.size<1024? file.file.size:(file.file.size / 1024).toFixed(0);
this.saveMsg.push({
Content: x.data.FilePath,
ID:0,
Type:fileTypeNumber,
Url: this.domainManager().ViittoFileUrl + x.data.FilePath,
})
this.$message.success(this.$t('tips.scchenggong'))
}, 1);
},
financeinfo_post_GetClientTypeList(){ // 获取对象类型
this.apipost('financeinfo_post_GetClientTypeList',{}, res => {
if(res.data.resultCode == 1) {
this.ClientTypeList = res.data.data;
}
}, err => {})
},
financeinfo_post_GetClientAccountList(t,i){ //获取付款 对象类型 新增用
let msg = {
ID:0,
Type:t,
ObjID:0,
CardNum:''
}
if(i>=0){
msg.ID=i;
}else{
this.msg.ClientID='';
this.msg.AccountNumber='';
this.msg.RemitterName='';
this.msg.IsLeader=1;
}
this.apipost('financeinfo_post_GetClientAccountList',msg, res => {
if(res.data.resultCode == 1) {
let data = res.data.data;
let ClientAccountList = [];
if(i){
data.forEach(x=>{
let obj = {
ID:x.ID,
Name:x.AccountHolder + + `(${x.AccountAlias})`,
Nom:x.CardNum,
OpenBankName:x.OpenBankName,
allName:x.CardNum+" "+x.OpenBankName,
ObjID:x.ObjID,
}
ClientAccountList.push(obj)
})
this.ClientAccountListS = ClientAccountList;
}else{
data.forEach(x=>{
let obj = {
ID:x.ID,
Name:x.AccountHolder + `(${x.AccountAlias})`,
Nom:x.CardNum,
OpenBankName:x.OpenBankName,
ObjID:x.ObjID,
}
ClientAccountList.push(obj)
})
this.ClientAccountList = ClientAccountList;
}
}
}, err => {})
},
GetClientAccountList(i){ //获取客户名称并且根据费用类型和付款对象获取客户账号
this.msg.AccountNumber='';
this.ClientAccountList.forEach(x=>{
if(x.ID==i){
this.msg.RemitterName=x.Name;
this.financeinfo_post_GetClientAccountList(this.msg.ClientType,x.ID);
}
})
},
TicketFinalTranfer(){ TicketFinalTranfer(){
if(this.ticketMsg.NewAirId==""){ if(this.ticketMsg.NewAirId==""){
this.Error("请输入新机票编码"); this.Error("请输入新机票编码");
...@@ -2770,6 +3204,21 @@ ...@@ -2770,6 +3204,21 @@
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
this.total = res.data.data.count; this.total = res.data.data.count;
this.dataList = res.data.data.pageData; this.dataList = res.data.data.pageData;
// PriceList
// RAirServiceList
this.dataList.forEach(data=>{
data.RAirServiceList.forEach(item=>{
data.PriceList.forEach(price=>{
if(price.TCID==item.TCID){
price.FinanceId=item.FinanceId;
price.Money=item.Money;
price.TicketNum=item.TicketNum;
price.disabled=true;
}
})
})
})
this.noData = !this.total > 0; this.noData = !this.total > 0;
} }
if (this.msg.ID == 0) { if (this.msg.ID == 0) {
...@@ -3423,6 +3872,8 @@ ...@@ -3423,6 +3872,8 @@
this.GetPlatform(); this.GetPlatform();
this.getDownList(); this.getDownList();
this.getEmployeeList(); this.getEmployeeList();
this.financeinfo_post_GetClientTypeList();
this.getCurrencyType();
} }
}; };
......
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