Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
Education
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
黄奎
Education
Commits
c1f814e4
Commit
c1f814e4
authored
Dec 11, 2020
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面修改
parent
841c9b8d
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
83 additions
and
19 deletions
+83
-19
RB_Post_ViewModel.cs
Edu.Model/ViewModel/User/RB_Post_ViewModel.cs
+5
-0
AssistModule.cs
Edu.Module.User/AssistModule.cs
+19
-12
DepartmentModule.cs
Edu.Module.User/DepartmentModule.cs
+5
-3
PostModule.cs
Edu.Module.User/PostModule.cs
+10
-0
TeacherModule.cs
Edu.Module.User/TeacherModule.cs
+2
-2
RB_PostRepository.cs
Edu.Repository/User/RB_PostRepository.cs
+24
-0
UserController.cs
Edu.WebApi/Controllers/User/UserController.cs
+18
-2
No files found.
Edu.Model/ViewModel/User/RB_Post_ViewModel.cs
View file @
c1f814e4
...
...
@@ -52,5 +52,10 @@ namespace Edu.Model.ViewModel.User
/// 岗位角色列表
/// </summary>
public
List
<
RB_Post_Role_ViewModel
>
PostRoleList
{
get
;
set
;
}
/// <summary>
/// 部门查询
/// </summary>
public
string
QDeptIds
{
get
;
set
;
}
}
}
Edu.Module.User/AssistModule.cs
View file @
c1f814e4
...
...
@@ -103,24 +103,31 @@ namespace Edu.Module.User
var
oldModel
=
GetAssistModule
(
model
.
AId
);
Dictionary
<
string
,
object
>
fileds
=
new
Dictionary
<
string
,
object
>()
{
{
nameof
(
RB_Assist
.
School_Id
),
model
.
School_Id
},
{
nameof
(
RB_Assist
.
Teacher_Id
),
model
.
Teacher_Id
},
{
nameof
(
RB_Assist
.
AssistName
),
model
.
AssistName
.
Trim
()
},
{
nameof
(
RB_Assist
.
AssistTel
),
model
.
AssistTel
},
{
nameof
(
RB_Assist
.
AssistIcon
),
model
.
AssistIcon
},
{
nameof
(
RB_Assist
.
AssistIntro
),
model
.
AssistIntro
},
{
nameof
(
RB_Assist
.
UpdateBy
),
model
.
UpdateBy
},
{
nameof
(
RB_Assist
.
UpdateTime
),
model
.
UpdateTime
},
{
nameof
(
RB_Assist
.
IDCard
),
model
.
IDCard
},
{
nameof
(
RB_Assist
.
Sex
),
model
.
Sex
},
{
nameof
(
RB_Assist
.
EntryTime
),
model
.
EntryTime
},
{
nameof
(
RB_Assist
.
Address
),
model
.
Address
},
{
nameof
(
RB_Assist
.
BirthDate
),
model
.
BirthDate
},
{
nameof
(
RB_Assist
.
LeaveStatus
),
model
.
LeaveStatus
},
{
nameof
(
RB_Assist
.
LeaveTime
),
model
.
LeaveTime
},
{
nameof
(
RB_Assist
.
Education
),
model
.
Education
},
};
if
(
isUpdateBasic
)
{
fileds
.
Add
(
nameof
(
RB_Assist
.
Dept_Id
),
model
.
Dept_Id
);
fileds
.
Add
(
nameof
(
RB_Assist
.
Post_Id
),
model
.
Post_Id
);
fileds
.
Add
(
nameof
(
RB_Assist
.
AssistIntro
),
model
.
AssistIntro
);
fileds
.
Add
(
nameof
(
RB_Assist
.
Teacher_Id
),
model
.
Teacher_Id
);
fileds
.
Add
(
nameof
(
RB_Assist
.
School_Id
),
model
.
School_Id
);
}
else
{
fileds
.
Add
(
nameof
(
RB_Assist
.
IDCard
),
model
.
IDCard
);
fileds
.
Add
(
nameof
(
RB_Assist
.
Sex
),
model
.
Sex
);
fileds
.
Add
(
nameof
(
RB_Assist
.
EntryTime
),
model
.
EntryTime
);
fileds
.
Add
(
nameof
(
RB_Assist
.
Address
),
model
.
Address
);
fileds
.
Add
(
nameof
(
RB_Assist
.
BirthDate
),
model
.
BirthDate
);
fileds
.
Add
(
nameof
(
RB_Assist
.
LeaveStatus
),
model
.
LeaveStatus
);
fileds
.
Add
(
nameof
(
RB_Assist
.
LeaveTime
),
model
.
LeaveTime
);
fileds
.
Add
(
nameof
(
RB_Assist
.
Education
),
model
.
Education
);
}
string
logContent
=
""
;
if
(
model
.
AssistName
!=
oldModel
.
AssistName
)
{
...
...
Edu.Module.User/DepartmentModule.cs
View file @
c1f814e4
...
...
@@ -470,9 +470,11 @@ namespace Edu.Module.User
});
extModel
.
ChoosePostList
=
new
List
<
int
>();
if
(
deptPostList
!=
null
&&
deptPostList
.
Count
>
0
)
{
{
foreach
(
var
item
in
deptPostList
)
{
extModel
.
ChoosePostList
.
Add
(
item
.
PostId
);
}
}
extModel
.
DeptPostList
=
deptPostList
;
}
...
...
Edu.Module.User/PostModule.cs
View file @
c1f814e4
...
...
@@ -47,6 +47,16 @@ namespace Edu.Module.User
return
postRepository
.
GetPostListRepository
(
query
);
}
/// <summary>
/// 根据部门编号获取岗位列表
/// </summary>
/// <param name="query"></param>
/// <returns></returns>
public
List
<
RB_Post_ViewModel
>
GetDeptPostListModule
(
RB_Post_ViewModel
query
)
{
return
postRepository
.
GetDeptPostListRepository
(
query
);
}
/// <summary>
/// 新增修改岗位
/// </summary>
...
...
Edu.Module.User/TeacherModule.cs
View file @
c1f814e4
...
...
@@ -110,8 +110,6 @@ namespace Edu.Module.User
{
nameof
(
RB_Teacher_ViewModel
.
UpdateBy
),
model
.
UpdateBy
},
{
nameof
(
RB_Teacher_ViewModel
.
UpdateTime
),
model
.
UpdateTime
},
{
nameof
(
RB_Teacher_ViewModel
.
School_Id
),
model
.
School_Id
},
//{nameof(RB_Teacher_ViewModel.Dept_Id),model.Dept_Id },
// {nameof(RB_Teacher_ViewModel.Post_Id),model.Post_Id },
};
if
(
isUpdateBasic
)
{
...
...
@@ -121,6 +119,8 @@ namespace Edu.Module.User
fileds
.
Add
(
nameof
(
RB_Teacher_ViewModel
.
IsShow
),
model
.
IsShow
);
fileds
.
Add
(
nameof
(
RB_Teacher_ViewModel
.
TeacherIntro
),
model
.
TeacherIntro
);
fileds
.
Add
(
nameof
(
RB_Teacher_ViewModel
.
TeacherSay
),
model
.
TeacherSay
);
fileds
.
Add
(
nameof
(
RB_Teacher_ViewModel
.
Dept_Id
),
model
.
Dept_Id
);
fileds
.
Add
(
nameof
(
RB_Teacher_ViewModel
.
Post_Id
),
model
.
Post_Id
);
}
else
{
...
...
Edu.Repository/User/RB_PostRepository.cs
View file @
c1f814e4
...
...
@@ -99,5 +99,29 @@ WHERE 1=1
return
new
List
<
RB_Post_ViewModel
>();
}
}
/// <summary>
/// 根据部门编号获取岗位列表
/// </summary>
/// <param name="query"></param>
/// <returns></returns>
public
List
<
RB_Post_ViewModel
>
GetDeptPostListRepository
(
RB_Post_ViewModel
query
)
{
StringBuilder
builder
=
new
StringBuilder
();
builder
.
AppendFormat
(
@"
SELECT B.PostId,B.PostName
FROM rb_department_post AS A INNER JOIN rb_post AS B ON A.PostId=B.PostId
WHERE 1=1
"
);
if
(
query
!=
null
)
{
if
(!
string
.
IsNullOrEmpty
(
query
.
QDeptIds
))
{
builder
.
AppendFormat
(
@" AND A.Dept_Id IN({0}) "
,
query
.
QDeptIds
);
}
}
return
Get
<
RB_Post_ViewModel
>(
builder
.
ToString
()).
ToList
();
}
}
}
\ No newline at end of file
Edu.WebApi/Controllers/User/UserController.cs
View file @
c1f814e4
...
...
@@ -346,7 +346,7 @@ namespace Edu.WebApi.Controllers.User
extModel
.
UpdateTime
=
DateTime
.
Now
;
extModel
.
AuditStatus
=
Common
.
Enum
.
User
.
AccountStatusEnum
.
Normal
;
extModel
.
Group_Id
=
base
.
UserInfo
.
Group_Id
;
bool
flag
=
teacherModule
.
SetTeacherModule
(
extModel
);
bool
flag
=
teacherModule
.
SetTeacherModule
(
extModel
,
isUpdateBasic
:
true
);
return
flag
?
ApiResult
.
Success
()
:
ApiResult
.
Failed
();
}
...
...
@@ -458,7 +458,7 @@ namespace Edu.WebApi.Controllers.User
extModel
.
UpdateTime
=
DateTime
.
Now
;
extModel
.
Group_Id
=
base
.
UserInfo
.
Group_Id
;
extModel
.
AuditStatus
=
Common
.
Enum
.
User
.
AccountStatusEnum
.
Normal
;
bool
flag
=
assistModule
.
SetAssistModule
(
extModel
);
bool
flag
=
assistModule
.
SetAssistModule
(
extModel
,
isUpdateBasic
:
true
);
return
flag
?
ApiResult
.
Success
()
:
ApiResult
.
Failed
();
}
...
...
@@ -1223,6 +1223,22 @@ namespace Edu.WebApi.Controllers.User
}
/// <summary>
/// 根据部门编号获取岗位列表
/// </summary>
/// <param name="query"></param>
/// <returns></returns>
public
ApiResult
GetDeptPostList
()
{
var
query
=
new
RB_Post_ViewModel
()
{
Group_Id
=
base
.
UserInfo
.
Group_Id
,
QDeptIds
=
base
.
ParmJObj
.
GetStringValue
(
"QDeptIds"
)
};
var
list
=
postModule
.
GetDeptPostListModule
(
query
);
return
ApiResult
.
Success
(
data
:
list
);
}
/// <summary>
/// 添加修改岗位
/// </summary>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment