Commit 5dabb33c by crushh

update: 附件样式

parent 95bbebf7
...@@ -66,12 +66,12 @@ Vue.axios.interceptors.response.use( ...@@ -66,12 +66,12 @@ Vue.axios.interceptors.response.use(
removePending(data.config); //在一个ajax响应后再执行一下取消操作,把已经完成的请求从pending中移除 removePending(data.config); //在一个ajax响应后再执行一下取消操作,把已经完成的请求从pending中移除
// console.log(data); // console.log(data);
if (data.status && data.status == 200 && data.data.errorCode != 1) { if (data.status && data.status == 200 && data.data.errorCode != 1) {
if (data.data.errorCode == 4) { // if (data.data.errorCode == 4) {
if (window.location.href.indexOf('gic-error') != -1) { // if (window.location.href.indexOf('gic-error') != -1) {
return false; // return false;
} // }
window.location.href = local + '/haoban-3/#/login'; // window.location.href = local + '/haoban-3/#/login';
} // }
if (data.data.errorCode == 10 || data.data.errorCode == 7) { if (data.data.errorCode == 10 || data.data.errorCode == 7) {
window.location.href = local + '/haoban-3/#/index'; window.location.href = local + '/haoban-3/#/index';
...@@ -81,25 +81,14 @@ Vue.axios.interceptors.response.use( ...@@ -81,25 +81,14 @@ Vue.axios.interceptors.response.use(
return data; return data;
}, },
err => { err => {
// console.log(err, typeof err, err.response); // if (err.response.status == 502) {
if (Vue.axios.isCancel(err)) { // window.location.href = local + '/haoban-3/#/login';
// console.log('请求取消'); // Message.error({ message: '服务异常⊙﹏⊙∥' });
} // }
if (err.response.status == 502) { // if (err.response.status != 403) {
window.location.href = local + '/haoban-3/#/login'; // window.location.href = local + '/haoban-3/#/login';
Message.error({ message: '服务异常⊙﹏⊙∥' }); // Message.error({ message: '登录失效!' });
} // }
// Message.error({message: err.response.message});
if (err.response.status == 504 || err.response.status == 404) {
// window.location.href= local + "/haoban-3/#/login"
// Message.error({message: '服务异常⊙﹏⊙∥'});
} else if (err.response.status == 403) {
// window.location.href= local + "/haoban-3/#/login"
// Message.error({message: '权限不足,请联系管理员!'});
} else {
window.location.href = local + '/haoban-3/#/login';
Message.error({ message: '登录失效!' });
}
return Promise.resolve(err); return Promise.resolve(err);
} }
); );
......
...@@ -17,10 +17,10 @@ export default { ...@@ -17,10 +17,10 @@ export default {
local = 'http://www.gicdev.com'; local = 'http://www.gicdev.com';
} */ } */
if (response.errorCode != 1) { if (response.errorCode != 1) {
if (response.errorCode == 4) { // if (response.errorCode == 4) {
window.location.href = local + '/haoban-3/#/login'; // window.location.href = local + '/haoban-3/#/login';
return false; // return false;
} // }
if (response.errorCode == 10) { if (response.errorCode == 10) {
window.location.href = local + '/haoban-3/#/index'; window.location.href = local + '/haoban-3/#/index';
return false; return false;
......
...@@ -224,7 +224,7 @@ export default { ...@@ -224,7 +224,7 @@ export default {
type: 'success' type: 'success'
}); });
// 跳转登录页 // 跳转登录页
window.location.href = window.location.origin + '/haoban-3/#/login'; // window.location.href = window.location.origin + '/haoban-3/#/login';
return; return;
} }
that.$message.error({ that.$message.error({
......
...@@ -363,6 +363,7 @@ export default { ...@@ -363,6 +363,7 @@ export default {
} }
return father.parentDepartmentId == 0; //返回第一层 return father.parentDepartmentId == 0; //返回第一层
}); });
console.log(tree);
return tree; return tree;
}, },
/** /**
......
...@@ -52,7 +52,7 @@ ...@@ -52,7 +52,7 @@
<el-table-column prop="suitDepartmentName" label="适用范围" width="120" show-overflow-tooltip> </el-table-column> <el-table-column prop="suitDepartmentName" label="适用范围" width="120" show-overflow-tooltip> </el-table-column>
<el-table-column label="操作" width="180"> <el-table-column label="操作" width="180">
<template slot-scope="{ row }"> <template slot-scope="{ row }">
<el-button type="text">编辑</el-button> <el-button type="text" @click="changeRoute(row)">编辑</el-button>
<el-button type="text">删除</el-button> <el-button type="text">删除</el-button>
</template> </template>
</el-table-column> </el-table-column>
...@@ -193,8 +193,8 @@ export default { ...@@ -193,8 +193,8 @@ export default {
/** /**
* 跳转 * 跳转
*/ */
changeRoute() { changeRoute(row) {
this.$router.push('/salutatorySet'); this.$router.push({ path: '/salutatorySet', query: { id: row.welcomeId } });
}, },
/** /**
......
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