Commit 71ce0e2a authored by huangjie's avatar huangjie

*

parent 827943de
...@@ -424,7 +424,7 @@ export default { ...@@ -424,7 +424,7 @@ export default {
/*overflow-y: auto;*/ /*overflow-y: auto;*/
overflow-y: overlay; overflow-y: overlay;
padding: 8px 0 0; padding: 8px 0 0;
width: 325px; width: 146px;
text-align: left; text-align: left;
border-radius: 4px; border-radius: 4px;
box-shadow: 0 2px 9px 2px rgba(0,0,0,.09), 0 1px 2px -2px rgba(0,0,0,.16); box-shadow: 0 2px 9px 2px rgba(0,0,0,.09), 0 1px 2px -2px rgba(0,0,0,.16);
...@@ -434,6 +434,9 @@ export default { ...@@ -434,6 +434,9 @@ export default {
>div{ >div{
padding: 8px 8px 8px 32px; padding: 8px 8px 8px 32px;
line-height: 20px; line-height: 20px;
white-space: nowrap;
text-overflow: ellipsis;
overflow: hidden;
} }
&:hover{ &:hover{
background: rgba(0, 0, 0, 0.04); background: rgba(0, 0, 0, 0.04);
......
...@@ -17,7 +17,7 @@ const service = axios.create({ ...@@ -17,7 +17,7 @@ const service = axios.create({
// axios中请求配置有baseURL选项,表示请求URL公共部分 // axios中请求配置有baseURL选项,表示请求URL公共部分
baseURL: process.env.VUE_APP_BASE_API, baseURL: process.env.VUE_APP_BASE_API,
// 超时 // 超时
timeout: 10000 timeout: 20000
}) })
// request拦截器 // request拦截器
......
<template> <template>
<div class="app-container"> <div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch"> <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch">
<el-form-item label="企业名称" prop="roleName"> <el-form-item label="企业名称" prop="companyName">
<el-input <el-input
v-model="queryParams.companyName" v-model="queryParams.companyName"
placeholder="请输入企业名称" placeholder="请输入企业名称"
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<el-form-item label="用户名称" prop="roleKey"> <el-form-item label="用户名称" prop="contactUserName">
<el-input <el-input
v-model="queryParams.contactUserName" v-model="queryParams.contactUserName"
placeholder="请输入用户名称" placeholder="请输入用户名称"
...@@ -19,10 +19,10 @@ ...@@ -19,10 +19,10 @@
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<el-form-item label="电话号码" prop="roleKey"> <el-form-item label="手机号码" prop="contactPhone">
<el-input <el-input
v-model="queryParams.contactPhone" v-model="queryParams.contactPhone"
placeholder="请输入电话号码" placeholder="请输入手机号码"
clearable clearable
style="width: 240px" style="width: 240px"
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
...@@ -116,7 +116,7 @@ ...@@ -116,7 +116,7 @@
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
icon="el-icon-delete" icon="el-icon-zoom-in"
@click="handleLook(scope.row)" @click="handleLook(scope.row)"
v-hasPermi="['system:role:remove']" v-hasPermi="['system:role:remove']"
>查看</el-button> >查看</el-button>
...@@ -187,7 +187,7 @@ ...@@ -187,7 +187,7 @@
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="企业规模" prop="accountCount"> <el-form-item label="企业规模" prop="accountCount">
<el-input :disabled="disabled" v-model="form.accountCount" placeholder="请输入企业规模"/> <el-input onkeyup="this.value=this.value.replace(/[^1-9]/g,'')" :disabled="disabled" v-model="form.accountCount" placeholder="请输入企业规模"/>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
...@@ -375,14 +375,13 @@ ...@@ -375,14 +375,13 @@
this.form = response.data; this.form = response.data;
this.form.dateRange = [response.data.startTime,response.data.expireTime] this.form.dateRange = [response.data.startTime,response.data.expireTime]
this.open = true; this.open = true;
this.title = "修改企业"; this.title = this.disabled == true?'查看企业':"修改企业";
}); });
}, },
//查看 //查看
handleLook(row){ handleLook(row){
this.handleUpdate(row) this.handleUpdate(row)
this.disabled = true this.disabled = true
this.getpack()
}, },
/** 提交按钮 */ /** 提交按钮 */
submitForm: function() { submitForm: function() {
...@@ -405,9 +404,11 @@ ...@@ -405,9 +404,11 @@
loading.close() loading.close()
} else { } else {
this.$modal.msgError(response.msg) this.$modal.msgError(response.msg)
loading.close();
} }
}).catch(response => { }).catch(response => {
this.$modal.msgError(response.msg) this.$modal.msgError(response.msg)
loading.close();
}); });
} else { } else {
saveTenant(this.form).then(response => { saveTenant(this.form).then(response => {
...@@ -418,6 +419,7 @@ ...@@ -418,6 +419,7 @@
loading.close(); loading.close();
}else{ }else{
this.$modal.msgError(response.msg) this.$modal.msgError(response.msg)
loading.close();
} }
}).catch(response => { }).catch(response => {
this.$modal.msgError(response.msg) this.$modal.msgError(response.msg)
......
<template> <template>
<div class="app-container"> <div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch"> <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch">
<el-form-item label="方案名称" prop="roleName"> <el-form-item label="方案名称" prop="packageName">
<el-input <el-input
v-model="queryParams.packageName" v-model="queryParams.packageName"
placeholder="请输入方案名称" placeholder="请输入方案名称"
...@@ -92,7 +92,7 @@ ...@@ -92,7 +92,7 @@
<el-button <el-button
size="mini" size="mini"
type="text" type="text"
icon="el-icon-edit" icon="el-icon-zoom-in"
@click="handleLook(scope.row)" @click="handleLook(scope.row)"
v-hasPermi="['system:role:edit']" v-hasPermi="['system:role:edit']"
>查看</el-button> >查看</el-button>
...@@ -336,7 +336,7 @@ ...@@ -336,7 +336,7 @@
} }
}) })
}) })
this.title = "修改方案"; this.title = this.disabled == true?'查看方案':"修改方案";
}); });
}, },
//查看 //查看
......
...@@ -8,8 +8,8 @@ ...@@ -8,8 +8,8 @@
<!--快捷登录--> <!--快捷登录-->
<el-form v-if="!islog && !islang && isDXlogin" ref="dxform" :model="dxform" :rules="dxRules" class="login-form"> <el-form v-if="!islog && !islang && isDXlogin" ref="dxform" :model="dxform" :rules="dxRules" class="login-form">
<div class="logintitle"> <div class="logintitle">
<div class="on" @click="isDXlogin = true">快捷登录</div>
<div @click="isDXlogin = false">密码登录</div> <div @click="isDXlogin = false">密码登录</div>
<div class="on" @click="isDXlogin = true">快捷登录</div>
</div> </div>
<el-form-item prop="phonenumber"> <el-form-item prop="phonenumber">
<el-input <el-input
...@@ -63,8 +63,8 @@ ...@@ -63,8 +63,8 @@
<!--密码登录--> <!--密码登录-->
<el-form v-if="!islog && !islang && !isDXlogin" ref="loginForm" :model="loginForm" :rules="loginRules" class="login-form"> <el-form v-if="!islog && !islang && !isDXlogin" ref="loginForm" :model="loginForm" :rules="loginRules" class="login-form">
<div class="logintitle"> <div class="logintitle">
<div @click="isDXlogin = true">快捷登录</div>
<div class="on" @click="isDXlogin = false">密码登录</div> <div class="on" @click="isDXlogin = false">密码登录</div>
<div @click="isDXlogin = true">快捷登录</div>
</div> </div>
<el-form-item prop="username"> <el-form-item prop="username">
<el-input <el-input
...@@ -190,7 +190,7 @@ ...@@ -190,7 +190,7 @@
return { return {
tenantId:-1, tenantId:-1,
islog:false, islog:false,
isDXlogin:true, isDXlogin:false,
codeUrl: "", codeUrl: "",
loginForm: { loginForm: {
username: "", username: "",
...@@ -303,10 +303,13 @@ ...@@ -303,10 +303,13 @@
//密码登录时根据手机号获取是否有多个租户 //密码登录时根据手机号获取是否有多个租户
userTenantList({phone:this.loginForm.username}).then(res=>{ userTenantList({phone:this.loginForm.username}).then(res=>{
if(res.data.length>1){ //需要安全验证(短信登录) if(res.data.length>1){ //需要安全验证(短信登录)
this.islang = true let _this = this
this.dxform.phonenumber = this.loginForm.username setTimeout(()=> {
this.dxform.captchaCode = this.loginForm.code _this.islang = true
this.showcode = false _this.dxform.phonenumber = _this.loginForm.username
_this.dxform.captchaCode = _this.loginForm.code
_this.showcode = false
},1000)
}else{//无租户列表和一个租户直接登录 }else{//无租户列表和一个租户直接登录
this.$store.dispatch("Login", froms).then(() => { this.$store.dispatch("Login", froms).then(() => {
this.loading = false; this.loading = false;
...@@ -343,6 +346,7 @@ ...@@ -343,6 +346,7 @@
} }
}) })
}else{ }else{
this.$message.error(res.msg)
this.getCode() this.getCode()
this.showcode = true this.showcode = true
} }
......
<template> <template>
<div class="app-container"> <div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch"> <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch">
<el-form-item label="部门名称" prop="deptName"> <el-form-item label="组织名称" prop="deptName">
<el-input <el-input
v-model="queryParams.deptName" v-model="queryParams.deptName"
placeholder="请输入部门名称" placeholder="请输入组织名称"
clearable clearable
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<el-form-item label="状态" prop="status"> <el-form-item label="状态" prop="status">
<el-select v-model="queryParams.status" placeholder="部门状态" clearable> <el-select v-model="queryParams.status" placeholder="组织状态" clearable>
<el-option <el-option
v-for="dict in dict.type.sys_normal_disable" v-for="dict in dict.type.sys_normal_disable"
:key="dict.value" :key="dict.value"
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
:default-expand-all="isExpandAll" :default-expand-all="isExpandAll"
:tree-props="{children: 'children', hasChildren: 'hasChildren'}" :tree-props="{children: 'children', hasChildren: 'hasChildren'}"
> >
<el-table-column prop="deptName" label="部门名称" width="260"></el-table-column> <el-table-column prop="deptName" label="组织名称" width="260"></el-table-column>
<el-table-column prop="orderNum" label="排序" width="200"></el-table-column> <el-table-column prop="orderNum" label="排序" width="200"></el-table-column>
<el-table-column prop="status" label="状态" width="100"> <el-table-column prop="status" label="状态" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
...@@ -96,20 +96,20 @@ ...@@ -96,20 +96,20 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<!-- 添加或修改部门对话框 --> <!-- 添加或修改组织对话框 -->
<el-dialog :title="title" :visible.sync="open" width="600px" append-to-body> <el-dialog :title="title" :visible.sync="open" width="600px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px"> <el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-row> <el-row>
<el-col :span="24" v-if="form.parentId !== 0"> <el-col :span="24" v-if="form.parentId !== 0">
<el-form-item label="上级部门" prop="parentId"> <el-form-item label="上级组织" prop="parentId">
<treeselect v-model="form.parentId" :options="deptOptions" :normalizer="normalizer" placeholder="选择上级部门" /> <treeselect v-model="form.parentId" :options="deptOptions" :normalizer="normalizer" placeholder="选择上级组织" />
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row> </el-row>
<el-row> <el-row>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="部门名称" prop="deptName"> <el-form-item label="组织名称" prop="deptName">
<el-input v-model="form.deptName" placeholder="请输入部门名称" /> <el-input v-model="form.deptName" placeholder="请输入组织名称" />
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
...@@ -137,7 +137,7 @@ ...@@ -137,7 +137,7 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="12"> <el-col :span="12">
<el-form-item label="部门状态"> <el-form-item label="组织状态">
<el-radio-group v-model="form.status"> <el-radio-group v-model="form.status">
<el-radio <el-radio
v-for="dict in dict.type.sys_normal_disable" v-for="dict in dict.type.sys_normal_disable"
...@@ -200,7 +200,7 @@ export default { ...@@ -200,7 +200,7 @@ export default {
showSearch: true, showSearch: true,
// 表格树数据 // 表格树数据
deptList: [], deptList: [],
// 部门树选项 // 组织树选项
deptOptions: [], deptOptions: [],
// 弹出层标题 // 弹出层标题
title: "", title: "",
...@@ -220,10 +220,10 @@ export default { ...@@ -220,10 +220,10 @@ export default {
// 表单校验 // 表单校验
rules: { rules: {
parentId: [ parentId: [
{ required: true, message: "上级部门不能为空", trigger: "blur" } { required: true, message: "上级组织不能为空", trigger: "blur" }
], ],
deptName: [ deptName: [
{ required: true, message: "部门名称不能为空", trigger: "blur" } { required: true, message: "组织名称不能为空", trigger: "blur" }
], ],
orderNum: [ orderNum: [
{ required: true, message: "显示排序不能为空", trigger: "blur" } { required: true, message: "显示排序不能为空", trigger: "blur" }
...@@ -250,7 +250,7 @@ export default { ...@@ -250,7 +250,7 @@ export default {
this.phone = this.$store.state.user.phonenumber this.phone = this.$store.state.user.phonenumber
}, },
methods: { methods: {
/** 查询部门列表 */ /** 查询组织列表 */
getList() { getList() {
this.loading = true; this.loading = true;
listDept(this.queryParams).then(response => { listDept(this.queryParams).then(response => {
...@@ -258,7 +258,7 @@ export default { ...@@ -258,7 +258,7 @@ export default {
this.loading = false; this.loading = false;
}); });
}, },
/** 转换部门数据结构 */ /** 转换组织数据结构 */
normalizer(node) { normalizer(node) {
if (node.children && !node.children.length) { if (node.children && !node.children.length) {
delete node.children; delete node.children;
...@@ -304,7 +304,7 @@ export default { ...@@ -304,7 +304,7 @@ export default {
this.form.parentId = row.deptId; this.form.parentId = row.deptId;
} }
this.open = true; this.open = true;
this.title = "添加部门"; this.title = "添加组织";
listDept().then(response => { listDept().then(response => {
this.deptOptions = this.handleTree(response.data, "deptId"); this.deptOptions = this.handleTree(response.data, "deptId");
}); });
...@@ -323,7 +323,7 @@ export default { ...@@ -323,7 +323,7 @@ export default {
getDept(row.deptId).then(response => { getDept(row.deptId).then(response => {
this.form = response.data; this.form = response.data;
this.open = true; this.open = true;
this.title = "修改部门"; this.title = "修改组织";
listDeptExcludeChild(row.deptId).then(response => { listDeptExcludeChild(row.deptId).then(response => {
this.deptOptions = this.handleTree(response.data, "deptId"); this.deptOptions = this.handleTree(response.data, "deptId");
if (this.deptOptions.length == 0) { if (this.deptOptions.length == 0) {
...@@ -339,15 +339,23 @@ export default { ...@@ -339,15 +339,23 @@ export default {
if (valid) { if (valid) {
if (this.form.deptId != undefined) { if (this.form.deptId != undefined) {
updateDept(this.form).then(response => { updateDept(this.form).then(response => {
if(response.code == 200){
this.$modal.msgSuccess("修改成功"); this.$modal.msgSuccess("修改成功");
this.open = false; this.open = false;
this.getList(); this.getList();
}else{
this.$modal.msgError(response.msg)
}
}); });
} else { } else {
addDept(this.form).then(response => { addDept(this.form).then(response => {
if(response.code == 200){
this.$modal.msgSuccess("新增成功"); this.$modal.msgSuccess("新增成功");
this.open = false; this.open = false;
this.getList(); this.getList();
}else{
this.$modal.msgError(response.msg)
}
}); });
} }
} }
...@@ -357,7 +365,7 @@ export default { ...@@ -357,7 +365,7 @@ export default {
handleDelete(row) { handleDelete(row) {
this.deptId = row.deptId this.deptId = row.deptId
let islast = true let islast = true
let txt = '是否确认删除名称为"' + row.deptName + '"的数据项?' let txt = '是否确认删除名称为"' + row.deptName + '"的组织?'
if((row.children && row.children.length>0) || row.existUsers == true){//该组织下还有数据 if((row.children && row.children.length>0) || row.existUsers == true){//该组织下还有数据
islast = false islast = false
txt='是否删除该组织及该组织包含的所有人员?' txt='是否删除该组织及该组织包含的所有人员?'
......
...@@ -692,16 +692,19 @@ export default { ...@@ -692,16 +692,19 @@ export default {
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
const userIds = row.userId || this.ids; const userIds = row.userId || this.ids;
let _this = this
this.$modal.confirm('是否确认删除用户编号为"' + userIds + '"的数据项?').then(function() { this.$modal.confirm('是否确认删除用户编号为"' + userIds + '"的数据项?').then(function() {
delUser(userIds).then(res=>{ delUser(userIds).then(res=>{
if(res.code == 200){ if(res.code == 200){
this.getList(); _this.getList();
this.$modal.msgSuccess("删除成功"); _this.$modal.msgSuccess("删除成功");
}else{ }else{
this.$modal.msgError(res.msg); _this.$modal.msgError(res.msg);
} }
}); });
}).catch(() => {}); }).catch(() => {
_this.$modal.msgError(res.msg);
});
}, },
/** 导出按钮操作 */ /** 导出按钮操作 */
handleExport() { handleExport() {
......
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