Commit c4b86246 authored by 黄奎's avatar 黄奎

页面修改

parent 0e6844fc
<!--修改-提成和额外金额-->
<template>
<q-dialog v-model="persistent" content-class="bg-grey-1" persistent transition-show="scale" transition-hide="scale">
<q-card style="width: 400px;max-width:500px;padding:0 20px;">
<q-card-section>
<div class="text-h6">一键制单</div>
</q-card-section>
<q-card-section class="q-pt-none scroll" style="max-height: 70vh">
<div class="col">
<q-radio v-model="FinanceMsg.IsPublic" :val="0" label="私账" />
<q-radio v-model="FinanceMsg.IsPublic" :val="1" label="公账" />
</div>
<div class="col" style="margin-top: 20px">
<q-select standout="bg-primary text-white" option-value="ID" option-label="Name"
v-model="FinanceMsg.CurrencyId" :options="CurrencyList" emit-value map-options label="币种"
class="col-6 q-pr-lg q-pb-lg" />
</div>
</q-card-section>
<q-card-section>
<div class="text-h6">账号信息</div>
<q-card-section class="q-pt-none scroll">
<div class="col">
<q-select standout="bg-primary text-white" option-value="Id" option-label="Name"
v-model="addMsg.AccountClassify" :options="AccountClassifyList" emit-value map-options label="账号分类"
class="col-6 q-pr-lg q-pb-lg" @input="changeTitle" />
</div>
<div class="col" v-if='addMsg.AccountClassify==2'>
<q-input filled stack-label maxlength="100" :dense="false" v-model="addMsg.BankName"
class="col-6 q-pr-lg q-pb-lg" label="所属机构" placeholder="例如:中国银行" />
</div>
<div class="col" v-if='addMsg.AccountClassify!=3 && addMsg.AccountClassify!=4'>
<q-input filled stack-label maxlength="100" :dense="false" v-model="addMsg.OpenBankName"
class="col-6 q-pr-lg q-pb-lg" :label="nameA" placeholder="例如:锦江支行" />
</div>
<div class="col" v-if='addMsg.AccountClassify!=3 && addMsg.AccountClassify!=4'>
<q-input filled stack-label maxlength="100" :dense="false" v-model="addMsg.AccountHolder"
class="col-6 q-pr-lg q-pb-lg" :label="nameB" />
</div>
<div class="col">
<q-input filled stack-label maxlength="100" :dense="false" v-model="addMsg.CardNum"
class="col-6 q-pr-lg q-pb-lg" :label="nameC" />
</div>
<div class="col">
<q-input filled stack-label maxlength="100" :dense="false" v-model="addMsg.AccountAlias"
class="col-6 q-pr-lg q-pb-lg" :label="nameD" />
</div>
</q-card-section>
</q-card-section>
<q-card-actions align="right" class="bg-white">
<q-btn label="取消" flat color="grey-10" style="font-weight:400 !important" @click="closeStuBillForm" />
<q-btn label="保存" color="accent" class="q-px-md" style="font-weight:400 !important" @click="addBack" />
</q-card-actions>
</q-card>
</q-dialog>
</template>
<script>
import {
saveStudentBackFinance, //生成财务单据
} from '../../api/sale/bill'
export default {
props: {
setingObj: {
type: Object,
default: null,
},
},
data() {
return {
persistent: true,
FinanceMsg: {
IsPublic: 0, //公账、私账
CurrencyId: 0, //币种
BackClassId: 0, //退课编号
ClientType: 10,
ClientId: 0
},
CurrencyList: [], //币种数组
//添加常用付款对象
addMsg: {
Id: '0',
ObjID: '-1',
BankId: '-1',
OpenBankName: '',
BankName: '',
AccountHolder: '',
CardNum: '',
AccountAlias: '',
AccountType: '1',
AccountClassify: 2,
Type: '10',
},
AccountClassifyList: [{
Id: 2,
Name: "银行"
},
{
Id: 3,
Name: "虚拟账户"
},
{
Id: 4,
Name: "微信支付宝"
}
],
nameA:"账号名称",
nameB:"开户人",
nameC:"卡号",
nameD:"账号别名",
}
},
created() {
this.FinanceMsg.BackClassId = this.setingObj.BackId;
this.addMsg.ObjID = this.setingObj.GuestId;
this.financeinfo_post_GetList();
},
mounted() {
},
methods: {
changeTitle() {
if (this.addMsg.AccountClassify == 1) {
this.nameA = this.$t("ground.pingtaimingcheng")
this.nameB = this.$t("ground.yonghumingcheng")
this.nameC = this.$t("fnc.ptAcc")
this.nameD = this.$t("fnc.accBming")
this.addMsg.AccountType = '1'
} else if (this.addMsg.AccountClassify == 2) {
this.nameA = this.$t("ground.zhanghumingcheng2")
this.nameB = this.$t("fnc.khuren")
this.nameC = this.$t("ground.kahao")
this.nameD = this.$t("fnc.accBming")
} else if (this.addMsg.AccountClassify == 3) {
this.nameA = this.$t("ground.pingtaimingcheng")
this.nameB = this.$t("ground.yonghumingcheng")
this.nameC = this.$t("fnc.ptAcc")
this.nameD = this.$t("fnc.accBming")
} else if (this.addMsg.AccountClassify == 4) {
this.nameA = this.$t("ground.pingtaimingcheng")
this.nameB = this.$t("ground.yonghumingcheng")
this.nameC = "账号"
this.nameD = "名称"
}
},
addBack() {
this.apipost("admin_post_SetEmpBankAccount", this.addMsg, res => {
if (res.data.resultCode == 1) {
this.FinanceMsg.ClientId = res.data.data;
this.createStuBill();
}
})
},
financeinfo_post_GetList() { // 获取币种
this.apipost('financeinfo_post_GetList', {
Name: '',
TCID: 0
}, res => {
if (res.data.resultCode == 1) {
this.CurrencyList = res.data.data;
this.FinanceMsg.CurrencyId = this.CurrencyList[0].ID
}
}, err => {})
},
//关闭弹窗
closeStuBillForm() {
this.persistent = false;
this.$emit('close');
},
//保存修改
createStuBill() {
saveStudentBackFinance(this.FinanceMsg).then(res => {
if (res.Code == 1) {
this.persistent = false;
this.$q.notify({
icon: 'iconfont icon-chenggong',
color: 'accent',
timeout: 2000,
message: '生成单据成功!',
position: 'top'
})
this.$emit('success');
}
});
}
}
}
</script>
<style> <style>
@import "./css/cssReset.css"; @import "./css/cssReset.css";
.empBankAccountTableLayer{overflow: auto; position:fixed;height:200px; .empBankAccountTableLayer {
z-index:50;bottom:0;left:50px;border-top:3px solid #38425d;background-color:#FFFFFF;padding: 10px 10px 0;width: 100%;} overflow: auto;
.empBankAccountTableLayer .el-form-item__label{font-size: 12px!important;} position: fixed;
.empBankAccountTableLayer>p{border-left: 3px solid #E95252; text-indent: 15px; height: 16px; padding-right: 50px; font-family: 'PingFangSc-Fine'; font-size: 16px; margin-bottom:20px; line-height: 14px; color: #000;} height: 200px;
.empBankAccountTable{width: 100%; min-width: 1500px; font-size:14px; color: #333; background: #ccc;} z-index: 50;
.empBankAccountTable tr{border-bottom: 2px solid #333;} bottom: 0;
.empBankAccountTable tr th{background: #BDBDBD;height:30px; font-size: 12px; text-align: left; text-indent: 20px;} left: 50px;
.empBankAccountTable tr{background: #fff;text-align: left;} border-top: 3px solid #38425d;
.empBankAccountTable tr:nth-child(2n+1){background: #E5E5E5;} background-color: #FFFFFF;
.empBankAccountTable tr td{height: 60px; padding-left:20px; border-right: 1px solid #DCDCDC; border-bottom: 1px solid #DCDCDC;} padding: 10px 10px 0;
.empBankAccountIcon button{width: 30px; height: 30px;border-radius:4px;} width: 100%;
.empBankAccountIcon .el-button--primary {padding: 5px;margin: 0;font-size: 14px!important;} }
.empBankAccountIcon .el-button+.el-button{margin-left: 0!important;}
.empBankAccountTableLayer .el-form-item__label {
font-size: 12px !important;
}
.empBankAccountTableLayer>p {
border-left: 3px solid #E95252;
text-indent: 15px;
height: 16px;
padding-right: 50px;
font-family: 'PingFangSc-Fine';
font-size: 16px;
margin-bottom: 20px;
line-height: 14px;
color: #000;
}
.empBankAccountTable {
width: 100%;
min-width: 1500px;
font-size: 14px;
color: #333;
background: #ccc;
}
.empBankAccountTable tr {
border-bottom: 2px solid #333;
}
.empBankAccountTable tr th {
background: #BDBDBD;
height: 30px;
font-size: 12px;
text-align: left;
text-indent: 20px;
}
.empBankAccountTable tr {
background: #fff;
text-align: left;
}
.empBankAccountTable tr:nth-child(2n+1) {
background: #E5E5E5;
}
.empBankAccountTable tr td {
height: 60px;
padding-left: 20px;
border-right: 1px solid #DCDCDC;
border-bottom: 1px solid #DCDCDC;
}
.empBankAccountIcon button {
width: 30px;
height: 30px;
border-radius: 4px;
}
.empBankAccountIcon .el-button--primary {
padding: 5px;
margin: 0;
font-size: 14px !important;
}
.empBankAccountIcon .el-button+.el-button {
margin-left: 0 !important;
}
</style> </style>
<template> <template>
<div class="flexOne"> <div class="flexOne">
...@@ -21,12 +89,13 @@ ...@@ -21,12 +89,13 @@
<p> <p>
{{dialogTitle}} {{dialogTitle}}
<span class="fr"> <span class="fr">
<button class="hollowFixedBtn" @click="outerVisible = false,resetForm('addMsg')">{{$t('pub.cancelBtn')}}</button> <button class="hollowFixedBtn"
@click="outerVisible = false,resetForm('addMsg')">{{$t('pub.cancelBtn')}}</button>
<button class="normalBtn" type="primary" @click="submitForm('addMsg')">{{$t('pub.saveBtn')}}</button> <button class="normalBtn" type="primary" @click="submitForm('addMsg')">{{$t('pub.saveBtn')}}</button>
</span> </span>
</p> </p>
<el-form :model="addMsg" :rules="rules" ref="addMsg" label-width="90px" style="padding-right: 80px"> <el-form :model="addMsg" :rules="rules" ref="addMsg" label-width="90px" style="padding-right: 80px">
<el-row > <el-row>
<el-col :span="4" :gutter="35"> <el-col :span="4" :gutter="35">
<el-form-item :label="$t('fnc.zhfenlei')" prop="AccountClassify"> <el-form-item :label="$t('fnc.zhfenlei')" prop="AccountClassify">
<el-select v-model='addMsg.AccountClassify' :placeholder="$t('pub.pleaseSel')" @change='changeTitle'> <el-select v-model='addMsg.AccountClassify' :placeholder="$t('pub.pleaseSel')" @change='changeTitle'>
...@@ -57,7 +126,7 @@ ...@@ -57,7 +126,7 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="4" :gutter="35"> <el-col :span="4" :gutter="35">
<el-form-item :label="nameD" prop="AccountAlias" > <el-form-item :label="nameD" prop="AccountAlias">
<el-input type="text" v-model="addMsg.AccountAlias"></el-input> <el-input type="text" v-model="addMsg.AccountAlias"></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
...@@ -66,9 +135,9 @@ ...@@ -66,9 +135,9 @@
</div> </div>
<div class="query-box"> <div class="query-box">
<ul> <ul>
<li> <li>
<input type="button" @click="outerVisible = true,dialogTitle=$t('ground.xinzengzhanghu'),resetForm('addMsg')" class="normalBtn" :value="$t('pub.addBtn')" /> <input type="button" @click="outerVisible = true,dialogTitle=$t('ground.xinzengzhanghu'),resetForm('addMsg')"
class="normalBtn" :value="$t('pub.addBtn')" />
</li> </li>
</ul> </ul>
</div> </div>
...@@ -94,7 +163,7 @@ ...@@ -94,7 +163,7 @@
</td> </td>
<td>{{item.BankName}}</td> <td>{{item.BankName}}</td>
<td>{{item.CardNum}} <td>{{item.CardNum}}
<br/>{{item.AccountHolder}}</td> <br />{{item.AccountHolder}}</td>
<td> <td>
<span v-if='item.Status!=0' style="color: #E95252;">{{$t('pub.fressSel')}}</span> <span v-if='item.Status!=0' style="color: #E95252;">{{$t('pub.fressSel')}}</span>
<span v-if='item.Status==0' style="color: #09D49D;">{{$t('pub.normalSel')}}</span> <span v-if='item.Status==0' style="color: #09D49D;">{{$t('pub.normalSel')}}</span>
...@@ -103,25 +172,25 @@ ...@@ -103,25 +172,25 @@
<td class="empBankAccountIcon"> <td class="empBankAccountIcon">
<el-button-group> <el-button-group>
<el-tooltip class="item" effect="dark" :content="$t('pub.updateMsg')" placement="top-start"> <el-tooltip class="item" effect="dark" :content="$t('pub.updateMsg')" placement="top-start">
<el-button @click="outerVisible = true,dialogTitle=$t('ground.xiugaizhanghu'),updateData(item.ID)" type="primary" style='background:#409EFF; border-color:#409EFF' icon="iconfont icon-bianji-smal" ></el-button> <el-button @click="outerVisible = true,dialogTitle=$t('ground.xiugaizhanghu'),updateData(item.ID)"
type="primary" style='background:#409EFF; border-color:#409EFF' icon="iconfont icon-bianji-smal">
</el-button>
</el-tooltip> </el-tooltip>
<el-tooltip class="item" effect="dark" :content="item.Status=='1'? $t('fnc.qiyong'):$t('pub.fressSel')" placement="top-start"> <el-tooltip class="item" effect="dark" :content="item.Status=='1'? $t('fnc.qiyong'):$t('pub.fressSel')"
<el-button v-if='item.Status==1' @click="deleteData(item.ID)" type="primary" style='background:#09D49D; border-color:#09D49D' icon="iconfont icon-qidong" ></el-button> placement="top-start">
<el-button v-if='item.Status==0' @click="deleteData(item.ID)" type="primary" style='background:#E95252; border-color:#E95252' icon="iconfont icon-dongjie" ></el-button> <el-button v-if='item.Status==1' @click="deleteData(item.ID)" type="primary"
style='background:#09D49D; border-color:#09D49D' icon="iconfont icon-qidong"></el-button>
<el-button v-if='item.Status==0' @click="deleteData(item.ID)" type="primary"
style='background:#E95252; border-color:#E95252' icon="iconfont icon-dongjie"></el-button>
</el-tooltip> </el-tooltip>
<!-- <el-tooltip class="item" effect="dark" :content="$t('ground.mingxi')" placement="top-start">-->
<!-- <el-button type="primary" style='background:#E6A014; border-color:#E6A014' icon="iconfont icon-rizhi1" ></el-button>-->
<!-- </el-tooltip>-->
</el-button-group> </el-button-group>
</td> </td>
</tr> </tr>
</table> </table>
<el-pagination background @current-change="handleCurrentChange" :current-page.sync="currentPage" layout="total,prev, pager, next, jumper" :page-size=msg.pageSize :total=total> <el-pagination background @current-change="handleCurrentChange" :current-page.sync="currentPage"
layout="total,prev, pager, next, jumper" :page-size=msg.pageSize :total=total>
</el-pagination> </el-pagination>
</div> </div>
</template> </template>
<script> <script>
...@@ -132,172 +201,169 @@ ...@@ -132,172 +201,169 @@
nameB: this.$t("fnc.khuren"), nameB: this.$t("fnc.khuren"),
nameC: this.$t("ground.kahao"), nameC: this.$t("ground.kahao"),
nameD: this.$t("fnc.accBming"), nameD: this.$t("fnc.accBming"),
switchValue:'1', switchValue: '1',
dialogTitle: '', dialogTitle: '',
insideDialogTxt: this.$t("tips.saveYes"), insideDialogTxt: this.$t("tips.saveYes"),
outerVisible: false, outerVisible: false,
innerVisible: false, innerVisible: false,
isRight:true, isRight: true,
versions: [], versions: [],
total: 0, total: 0,
currentPage: 1, currentPage: 1,
//请求数据 //请求数据
msg:{ msg: {
BranchId:'-1', BranchId: '-1',
EmpId:'-1', EmpId: '-1',
BankId:'', BankId: '',
AccountHolder:'', AccountHolder: '',
AccountAlias:'', AccountAlias: '',
pageIndex:1, pageIndex: 1,
pageSize:15, pageSize: 15,
Type:'', Type: '',
}, },
getCompanyMsg:{ getCompanyMsg: {
RB_Group_Id:'0', RB_Group_Id: '0',
Status:'0', Status: '0',
}, },
getUserMsg:{ getUserMsg: {
RB_Branch_id:'-1', RB_Branch_id: '-1',
}, },
//返回数据 //返回数据
list:[], list: [],
bankList:[], bankList: [],
layerItem:[], layerItem: [],
addMsg:{ addMsg: {
Id:'0', Id: '0',
ObjID:'-1', ObjID: '-1',
BankId:'-1', BankId: '-1',
OpenBankName:'', OpenBankName: '',
BankName: '', BankName: '',
AccountHolder:'', AccountHolder: '',
CardNum:'', CardNum: '',
AccountAlias:'', AccountAlias: '',
AccountType:'1', AccountType: '1',
AccountClassify:'2', AccountClassify: '2',
Type:'9', Type: '9',
}, },
rules:{ rules: {
BankName:[ BankName: [{
{ required: true, message: this.$t("ground.qingtianxieyh"), trigger: 'blur' } required: true,
], message: this.$t("ground.qingtianxieyh"),
trigger: 'blur'
}],
} }
} }
}, },
mounted() { mounted() {
let userInfo=this.getLocalStorage(); let userInfo = this.getLocalStorage();
this.getUserMsg.RB_Group_id=this.getCompanyMsg.RB_Group_Id=userInfo.Group_Id; //集团ID this.getUserMsg.RB_Group_id = this.getCompanyMsg.RB_Group_Id = userInfo.Group_Id; //集团ID
this.msg.EmpId=this.$route.query.id?this.$route.query.id:userInfo.Id; this.msg.EmpId = this.$route.query.id ? this.$route.query.id : userInfo.Id;
this.msg.Type=this.$route.query.type?this.$route.query.type:10; this.msg.Type = this.$route.query.type ? this.$route.query.type : 10;
this.addMsg.ObjID=this.$route.query.id?this.$route.query.id:userInfo.Id; this.addMsg.ObjID = this.$route.query.id ? this.$route.query.id : userInfo.Id;
this.addMsg.Type=this.$route.query.type?this.$route.query.type:10; this.addMsg.Type = this.$route.query.type ? this.$route.query.type : 10;
this.getBank(); this.getBank();
this.getList(); this.getList();
this.changeTitle() this.changeTitle()
}, },
methods: { methods: {
changeTitle(){ changeTitle() {
if(this.addMsg.AccountClassify==1){ if (this.addMsg.AccountClassify == 1) {
this.nameA= this.$t("ground.pingtaimingcheng") this.nameA = this.$t("ground.pingtaimingcheng")
this.nameB= this.$t("ground.yonghumingcheng") this.nameB = this.$t("ground.yonghumingcheng")
this.nameC= this.$t("fnc.ptAcc") this.nameC = this.$t("fnc.ptAcc")
this.nameD= this.$t("fnc.accBming") this.nameD = this.$t("fnc.accBming")
this.addMsg.AccountType='1' this.addMsg.AccountType = '1'
}else if(this.addMsg.AccountClassify==2){ } else if (this.addMsg.AccountClassify == 2) {
this.nameA= this.$t("ground.zhanghumingcheng2") this.nameA = this.$t("ground.zhanghumingcheng2")
this.nameB= this.$t("fnc.khuren") this.nameB = this.$t("fnc.khuren")
this.nameC= this.$t("ground.kahao") this.nameC = this.$t("ground.kahao")
this.nameD= this.$t("fnc.accBming") this.nameD = this.$t("fnc.accBming")
}else if(this.addMsg.AccountClassify==3){ } else if (this.addMsg.AccountClassify == 3) {
this.nameA= this.$t("ground.pingtaimingcheng") this.nameA = this.$t("ground.pingtaimingcheng")
this.nameB= this.$t("ground.yonghumingcheng") this.nameB = this.$t("ground.yonghumingcheng")
this.nameC= this.$t("fnc.ptAcc") this.nameC = this.$t("fnc.ptAcc")
this.nameD= this.$t("fnc.accBming") this.nameD = this.$t("fnc.accBming")
}else if(this.addMsg.AccountClassify==4){ } else if (this.addMsg.AccountClassify == 4) {
this.nameA= this.$t("ground.pingtaimingcheng") this.nameA = this.$t("ground.pingtaimingcheng")
this.nameB= this.$t("ground.yonghumingcheng") this.nameB = this.$t("ground.yonghumingcheng")
this.nameC= "账号" this.nameC = "账号"
this.nameD= "名称" this.nameD = "名称"
} }
}, },
getList() { //获取列表数据 getList() { //获取列表数据
this.apipost("admin_get_GetEmpBankAccountPageList", this.msg, res => { this.apipost("admin_get_GetEmpBankAccountPageList", this.msg, res => {
if(res.data.resultCode==1){ if (res.data.resultCode == 1) {
this.list = res.data.data.pageData; this.list = res.data.data.pageData;
this.total = res.data.data.count; this.total = res.data.data.count;
}else{} } else {}
}, err => {}) }, err => {})
}, },
// getCompany(){ getBank() {
// this.apipost('admin_get_BranchGetList',this.getCompanyMsg,res=>{ this.apipost('FinancialInstitutions_post_GetList', {
// if(res.data.resultCode==1){ Type: 0
// this.companyList=res.data.data; }, res => {
// }else{} if (res.data.resultCode == 1) {
// },err=>{}) this.bankList = res.data.data;
// }, } else {}
getBank(){ }, err => {})
this.apipost('FinancialInstitutions_post_GetList',{Type:0},res=>{
if(res.data.resultCode==1){
this.bankList=res.data.data;
}else{}
},err=>{})
}, },
addData(){ //添加角色 addData() { //添加角色
let userInfo=this.getLocalStorage(); let userInfo = this.getLocalStorage();
this.addMsg.ObjID=this.$route.query.id?this.$route.query.id:userInfo.Id; this.addMsg.ObjID = this.$route.query.id ? this.$route.query.id : userInfo.Id;
if(this.addMsg.AccountClassify!='3' && this.addMsg.AccountClassify!='4'){ if (this.addMsg.AccountClassify != '3' && this.addMsg.AccountClassify != '4') {
if(this.addMsg.OpenBankName==''){ if (this.addMsg.OpenBankName == '') {
this.$message.error(this.$t('visaT.Pleasefillin')+this.nameA) this.$message.error(this.$t('visaT.Pleasefillin') + this.nameA)
return return
} }
if(this.addMsg.AccountHolder==''){ if (this.addMsg.AccountHolder == '') {
this.$message.error(this.$t('visaT.Pleasefillin')+this.nameB) this.$message.error(this.$t('visaT.Pleasefillin') + this.nameB)
return return
} }
} }
if(this.addMsg.CardNum==''){ if (this.addMsg.CardNum == '') {
this.$message.error(this.$t('visaT.Pleasefillin')+this.nameC) this.$message.error(this.$t('visaT.Pleasefillin') + this.nameC)
return return
} }
if(this.addMsg.AccountAlias==''){ if (this.addMsg.AccountAlias == '') {
this.$message.error(this.$t('visaT.Pleasefillin')+this.nameD) this.$message.error(this.$t('visaT.Pleasefillin') + this.nameD)
return return
} }
this.apipost("admin_post_SetEmpBankAccount",this.addMsg,res=>{ this.apipost("admin_post_SetEmpBankAccount", this.addMsg, res => {
if(res.data.resultCode==1) if (res.data.resultCode == 1) {
{
this.$message.success(res.data.message) this.$message.success(res.data.message)
this.outerVisible=false; this.outerVisible = false;
this.getList() this.getList()
this.resetForm('addMsg'); this.resetForm('addMsg');
}else{ } else {
this.$message.error(res.data.message) this.$message.error(res.data.message)
} }
}, err => {})
},err=>{})
}, },
updateData(id){ //修改角色 updateData(id) { //修改角色
this.apipost('admin_get_GetEmpBackAccount',{BAId:id},res=>{ this.apipost('admin_get_GetEmpBackAccount', {
if(res.data.resultCode==1){ BAId: id
}, res => {
if (res.data.resultCode == 1) {
this.addMsg = res.data.data; this.addMsg = res.data.data;
this.addMsg.AccountType=res.data.data.AccountType.toString(); this.addMsg.AccountType = res.data.data.AccountType.toString();
this.addMsg.AccountClassify=res.data.data.AccountClassify.toString(); this.addMsg.AccountClassify = res.data.data.AccountClassify.toString();
this.addMsg.BankId=res.data.data.BankId this.addMsg.BankId = res.data.data.BankId
this.changeTitle() this.changeTitle()
}else{} } else {}
},err=>{}) }, err => {})
// this.addMsg = this.dataList[index] // this.addMsg = this.dataList[index]
// this.addMsg.Status = this.dataList[index].Status.toString(); // this.addMsg.Status = this.dataList[index].Status.toString();
}, },
deleteData(id){ deleteData(id) {
this.$confirm(this.$t('ground.querenqiyong'), '提示', { this.$confirm(this.$t('ground.querenqiyong'), '提示', {
confirmButtonText: this.$t('pub.sureBtn'), confirmButtonText: this.$t('pub.sureBtn'),
cancelButtonText: this.$t('pub.cancelBtn'), cancelButtonText: this.$t('pub.cancelBtn'),
type: 'warning' type: 'warning'
}).then(() => { }).then(() => {
this.apipost('admin_post_DelEmpBankAccount', { this.apipost('admin_post_DelEmpBankAccount', {
BAId:id BAId: id
}, res => { }, res => {
if(res.data.resultCode == 1) { if (res.data.resultCode == 1) {
this.$message.success(this.$t('tips.saveYes')) this.$message.success(this.$t('tips.saveYes'))
this.getList(); this.getList();
} }
...@@ -315,7 +381,7 @@ ...@@ -315,7 +381,7 @@
this.msg.pageIndex = 1; this.msg.pageIndex = 1;
this.currentPage = 1 this.currentPage = 1
}, },
submitForm(addMsg) {//提交创建、修改表单 submitForm(addMsg) { //提交创建、修改表单
this.$refs[addMsg].validate((valid) => { this.$refs[addMsg].validate((valid) => {
if (valid) { if (valid) {
this.addData(); this.addData();
...@@ -325,24 +391,25 @@ ...@@ -325,24 +391,25 @@
} }
}); });
}, },
closeChangeMachie(done){//弹出框关闭初始化弹框内表单 closeChangeMachie(done) { //弹出框关闭初始化弹框内表单
done(); done();
this.resetForm('addMsg'); this.resetForm('addMsg');
}, },
resetForm(formName) {//弹出框取消 初始化谈框内表单 resetForm(formName) { //弹出框取消 初始化谈框内表单
this.$refs[formName].resetFields(); this.$refs[formName].resetFields();
this.addMsg.AccountType='1'; this.addMsg.AccountType = '1';
this.addMsg.AccountClassify='2'; this.addMsg.AccountClassify = '2';
this.addMsg.Id='0'; this.addMsg.Id = '0';
this.addMsg.ObjID='-1'; this.addMsg.ObjID = '-1';
this.addMsg.BankId='-1'; this.addMsg.BankId = '-1';
this.addMsg.OpenBankName=''; this.addMsg.OpenBankName = '';
this.addMsg.BankName=''; this.addMsg.BankName = '';
this.addMsg.AccountHolder=''; this.addMsg.AccountHolder = '';
this.addMsg.CardNum=''; this.addMsg.CardNum = '';
this.addMsg.AccountAlias=''; this.addMsg.AccountAlias = '';
} }
} }
} }
</script> </script>
...@@ -81,21 +81,25 @@ ...@@ -81,21 +81,25 @@
<backbill-form v-if="isShowBillForm" :seting-obj="billObj" :showType="showType" @close="closeBillForm" <backbill-form v-if="isShowBillForm" :seting-obj="billObj" :showType="showType" @close="closeBillForm"
@success="refreshPage"> @success="refreshPage">
</backbill-form> </backbill-form>
<createbackbill-form v-if="isShowCreateBillForm" :seting-obj="billObj" @close="closeBillForm"
@success="refreshPage">
</createbackbill-form>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import { import {
queryStudentBackClassPage, queryStudentBackClassPage,
saveStudentBackFinance, //生成财务单据
} from '../../api/sale/bill' } from '../../api/sale/bill'
import backbillForm from '../../components/sale/backbill-form'; import backbillForm from '../../components/sale/backbill-form';
import createbackbillForm from '../../components/sale/createbackbill-form';
export default { export default {
meta: { meta: {
title: "退课单据" title: "退课单据"
}, },
components: { components: {
backbillForm backbillForm,
createbackbillForm
}, },
data() { data() {
return { return {
...@@ -203,6 +207,7 @@ ...@@ -203,6 +207,7 @@
tabCheck: "1", tabCheck: "1",
pageCount: 0, pageCount: 0,
isShowBillForm: false, //是否显示单据表单 isShowBillForm: false, //是否显示单据表单
isShowCreateBillForm: false, //是否显示制单表单
billObj: {}, //单据信息 billObj: {}, //单据信息
showType: 1, //1-查看,2-审核 showType: 1, //1-查看,2-审核
} }
...@@ -217,21 +222,13 @@ ...@@ -217,21 +222,13 @@
methods: { methods: {
//生成财务单据 //生成财务单据
createBillForm(item) { createBillForm(item) {
console.log("item", item); this.isShowCreateBillForm = true;
var billMsg = { this.billObj = item;
BackClassId: item.BackId,
IsPublic: 1,
CurrencyId: 1,
ClientType: 1,
ClientId: item.GuestId
};
saveStudentBackFinance(billMsg).then(res => {
console.log("createBillForm", res);
});
}, },
//关闭表单 //关闭表单
closeBillForm() { closeBillForm() {
this.isShowBillForm = false; this.isShowBillForm = false;
this.isShowCreateBillForm = false;
this.billObj = {}; this.billObj = {};
}, },
//显示表单 //显示表单
......
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