Commit 01e9384f authored by 柳 佳乐's avatar 柳 佳乐
Browse files

202211201

parent 979e03ac
......@@ -149,7 +149,7 @@ export default {
//重置数据
resetForm(){
this.$refs.form.resetFields()
this.getProject()
},
//提交数据
submitForm(){
......
......@@ -699,11 +699,7 @@ export default {
this.reimbursementDetails.list = res.data;
this.$message.success(res.msg);
}else{
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
this.$message.error(res.msg)
}
})
.catch((error) => {
......@@ -722,13 +718,8 @@ export default {
if (res.success) {
//获取数据
this.financeList.list = res.data;
// this.$message.success(res.msg);
}else{
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
this.$message.success(res.msg);
}
})
.catch((error) => {
......@@ -754,11 +745,6 @@ export default {
this.total = res.data.total;
} else {
this.$message.error(res.msg);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -817,11 +803,6 @@ export default {
this.getReimbursement();
} else {
this.$message.error(res.msg);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -868,11 +849,6 @@ export default {
this.getReimbursement();
} else {
this.$message.error(res.msg);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -944,11 +920,7 @@ export default {
} else {
this.$message.error(res.msg);
this.back();
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -1075,11 +1047,7 @@ export default {
}
} else {
this.$message.error(res.msg);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -1115,13 +1083,9 @@ export default {
type: "success",
});
this.visible = false;
console.log(res.msg);
}else{
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
this.$message.error(res.msg)
}
})
.catch((errror) => {
......@@ -1151,11 +1115,7 @@ export default {
this.Refresh();
} else {
this.$message.error("请添加附件,在进行提交");
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
},
//刷新附件
......@@ -1170,11 +1130,7 @@ export default {
this.proutlist1.enclosureDescribe = ""; //初始化数据
} else {
this.$message.error(res.msg);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -1212,11 +1168,7 @@ export default {
if (res.success) {
this.getinvoive(data);
}else{
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
this.$message.error(res.msg)
}
});
},
......
......@@ -588,11 +588,7 @@ export default {
this.reimbursementDetails.list = res.data;
this.$message.success(res.msg);
}else{
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
this.$message.error(res.msg)
}
})
.catch((error) => {
......@@ -608,11 +604,6 @@ export default {
this.total = res.data.total;
} else {
this.$message.error(res.msg);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -645,11 +636,6 @@ export default {
this.getReimbursement();
} else {
this.$message.error(res.msg);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -693,11 +679,6 @@ export default {
this.getReimbursement();
} else {
this.$message.error(res.msg);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -768,11 +749,6 @@ export default {
} else {
this.$message.error(res.msg);
this.back();
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -800,11 +776,6 @@ export default {
}
} else {
this.$message.error(res.msg);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -841,17 +812,13 @@ export default {
type: "success",
});
this.visible = false;
console.log(res.msg);
}else{
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
this.$message.error(res.msg);
}
})
.catch((errror) => {
this.$message.error(res.msg);
this.$message.error("删除失败");
});
},
//清除附件文件
......@@ -877,11 +844,7 @@ export default {
this.Refresh();
} else {
this.$message.error("请添加附件,在进行提交");
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
},
//刷新附件
......@@ -896,11 +859,6 @@ export default {
this.proutlist1.enclosureDescribe = ""; //初始化数据
} else {
this.$message.error(res.msg);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -938,11 +896,7 @@ export default {
if (res.success) {
this.getinvoive(data);
}else{
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
this.$message.error(res.msg)
}
});
},
......
......@@ -2,7 +2,7 @@
<div class="container" :gutter="20">
<div class="box">
<el-row :gutter="24">
<el-col :xl="12" :lg="12" :md="12" :sm="24" :xs="24">
<el-col :xl="12" :lg="10" :md="10" :sm="24" :xs="24">
<el-form
ref="form"
:model="from"
......@@ -92,6 +92,8 @@
:action="action1"
:auto-upload="false"
:data="enclosurelist"
:on-remove="fileError"
:on-success="fileSuccess"
multiple
>
<i class="el-icon-upload"></i>
......@@ -123,7 +125,7 @@
</el-form>
</el-col>
<!-- 右边 -->
<el-col :xl="12" :lg="12" :md="12" :sm="24" :xs="24">
<el-col :xl="12" :lg="14" :md="14" :sm="24" :xs="24">
<div v-show="subbut">
<el-empty description="暂无报销项,因此无法报销"></el-empty>
</div>
......@@ -148,7 +150,7 @@
required: true,
}"
>
<el-input v-model="item.money"
<el-input v-model="item.money" style="width:130px"
><i
slot="suffix"
style="font-style: normal; margin-right: 10px"
......@@ -156,8 +158,8 @@
></el-input
>
</el-form-item>
<el-form-item label="备注">
<el-input v-model="item.remarks"></el-input>
<el-form-item label="说明">
<el-input v-model="item.remarks" type="textarea" :rows="2" style="width:120%"></el-input>
</el-form-item>
</el-col>
</el-row>
......@@ -192,7 +194,6 @@ export default {
paymentMethod: null, //支付方式
reimbursementState: 0, //状态
projectId: null, //项目id
fromList: [],
remarks: "", //备注
enclosureDescribe: "", //附件描述
invoiceIdList: [], //发票号码
......@@ -353,11 +354,6 @@ export default {
this.projectList = res.data;
} else {
this.$message.error(res.msg);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -399,6 +395,17 @@ export default {
this.$message.error("获取报销项失败");
});
},
//上传失败的回调
fileError(){
this.$message.error("附件上传失败");
},
fileSuccess(res){
if(res.success){
this.$message.success(res.msg)
}else{
this.$message.error(res.msg);
}
},
//定义金额校验
moneyrow(rule, value, callback) {
let RegExp =
......@@ -471,7 +478,7 @@ export default {
}
});
});
if (this.from.fromList.length == 0) {
if (this.from.invoiceIdList.length == 0) {
this.from.applyTotalAmountLarge = null;
}
this.convertCurrency(this.from.applyTotalAmountSmall);
......@@ -519,10 +526,6 @@ export default {
//超出最大处理数字
return "";
}
if (money == 0) {
chineseStr = cnNums[0] + cnIntLast + cnInteger;
return chineseStr;
}
//转换为字符串
money = money.toString();
if (money.indexOf(".") == -1) {
......
This diff is collapsed.
......@@ -119,7 +119,7 @@
></el-input
>
</el-form-item>
<el-form-item label="备注">
<el-form-item label="说明">
<el-input v-model="item.remarks"></el-input>
</el-form-item>
</el-col>
......@@ -263,11 +263,6 @@ export default {
this.projectList = res.data;
} else {
this.$message.error(res.msg);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
}
})
.catch((error) => {
......@@ -281,12 +276,7 @@ export default {
if (res.status == "success") {
this.company = res.data;
} else {
this.$message.error(res.data);
if (res.code == 4) {
//执行退出功能
this.$store.dispatch("user/logout");
this.$router.push(`/login?redirect=${this.$route.fullPath}`);
}
this.$message.error(res.msg);
}
})
.catch((error) => {
......
......@@ -118,7 +118,7 @@ export default {
if (res.success) {
this.rolesList = res.data
} else {
this.$message.error(res.data)
this.$message.error(res.msg)
}
}).catch((error) => {
this.$message.error("查询角色失败")
......@@ -140,7 +140,7 @@ export default {
this.$store.dispatch('tagsView/delView', this.$route)
this.$router.push("/staffList")
} else {
this.$message.error(res.data)
this.$message.error(res.msg)
}
}).catch((error) => {
this.$message.error("添加失败")
......
......@@ -159,7 +159,7 @@ export default {
if (res.success) {
this.rolesList = res.data;
} else {
this.$message.error(res.data);
this.$message.error(res.msg);
}
})
.catch(error => {
......@@ -175,7 +175,7 @@ export default {
this.staffList = res.data.list;
this.total = res.data.total;
} else {
this.$message.error(res.data);
this.$message.error(res.msg);
}
})
.catch(error => {
......@@ -241,7 +241,7 @@ export default {
if (res.success) {
this.getSatff();
} else {
this.$message.error(res.data);
this.$message.error(res.msg);
}
});
this.dialogVisible = false;
......
This diff is collapsed.
......@@ -68,7 +68,7 @@
typeList:[
{
key:Date.now(),
typeCategory:'1',
typeCategory:'0',
typeName:'',
companyId:this.$store.getters.companyId,
}
......@@ -114,7 +114,6 @@
}
})
.catch(error => {
console.log(error);
this.$message.error("添加失败");
});
} else {
......@@ -144,7 +143,7 @@
{
key:Date.now(),
typeName:'',
typeCategory:'1',
typeCategory:'0',
companyId:this.$store.getters.companyId,
}
);
......
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