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
caa322d9
Commit
caa322d9
authored
Apr 07, 2022
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增实体类
parent
00299133
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
374 additions
and
0 deletions
+374
-0
RB_Assessment_Subtype.cs
Edu.Model/Entity/DataStatistics/RB_Assessment_Subtype.cs
+76
-0
RB_Assessment_Type.cs
Edu.Model/Entity/DataStatistics/RB_Assessment_Type.cs
+64
-0
RB_Assessment_Subtype_Extend.cs
.../ViewModel/DataStatistics/RB_Assessment_Subtype_Extend.cs
+39
-0
RB_Assessment_Type_Extend.cs
...del/ViewModel/DataStatistics/RB_Assessment_Type_Extend.cs
+18
-0
TeacherAssessmentModule.cs
Edu.Module.User/TeacherAssessmentModule.cs
+77
-0
RB_Assessment_SubtypeRepository.cs
...ository/DataStatistics/RB_Assessment_SubtypeRepository.cs
+52
-0
RB_Assessment_TypeRepository.cs
...Repository/DataStatistics/RB_Assessment_TypeRepository.cs
+48
-0
No files found.
Edu.Model/Entity/DataStatistics/RB_Assessment_Subtype.cs
0 → 100644
View file @
caa322d9
using
Edu.Common.Enum
;
using
System
;
using
System.Collections.Generic
;
using
System.Text
;
using
VT.FW.DB
;
namespace
Edu.Model.Entity.DataStatistics
{
/// <summary>
/// 老师考评子类型配置表实体类
/// </summary>
[
Serializable
]
[
DB
(
ConnectionName
=
"DefaultConnection"
)]
public
class
RB_Assessment_Subtype
{
/// <summary>
/// 教师考评子类型主键编号
/// </summary>
public
int
Id
{
get
;
set
;
}
/// <summary>
/// 教师考评类型编号
/// </summary>
public
int
AssessmentTypeId
{
get
;
set
;
}
/// <summary>
/// 子类型名称
/// </summary>
public
string
SubTypeName
{
get
;
set
;
}
/// <summary>
/// 集团编号
/// </summary>
public
int
Group_Id
{
get
;
set
;
}
/// <summary>
/// 学校编号
/// </summary>
public
int
School_Id
{
get
;
set
;
}
/// <summary>
/// 创建人
/// </summary>
public
int
CreateBy
{
get
;
set
;
}
/// <summary>
/// 创建时间
/// </summary>
public
DateTime
CreateTime
{
get
;
set
;
}
/// <summary>
/// 修改人
/// </summary>
public
int
UpdateBy
{
get
;
set
;
}
/// <summary>
/// 更新时间
/// </summary>
public
DateTime
UpdateTime
{
get
;
set
;
}
/// <summary>
/// 删除状态(0-正常,1-禁用)
/// </summary>
public
DateStateEnum
Status
{
get
;
set
;
}
/// <summary>
/// 考评类型JSON字符串
/// </summary>
public
string
Options
{
get
;
set
;
}
/// <summary>
/// 排序
/// </summary>
public
int
SortNum
{
get
;
set
;
}
}
}
Edu.Model/Entity/DataStatistics/RB_Assessment_Type.cs
0 → 100644
View file @
caa322d9
using
Edu.Common.Enum
;
using
System
;
using
VT.FW.DB
;
namespace
Edu.Model.Entity.DataStatistics
{
/// <summary>
/// 老师考评类型配置表实体类
/// </summary>
[
Serializable
]
[
DB
(
ConnectionName
=
"DefaultConnection"
)]
public
class
RB_Assessment_Type
{
/// <summary>
/// 教师考评类型主键编号
/// </summary>
public
int
Id
{
get
;
set
;
}
/// <summary>
/// 考评类型名称
/// </summary>
public
string
TypeName
{
get
;
set
;
}
/// <summary>
/// 集团编号
/// </summary>
public
int
Group_Id
{
get
;
set
;
}
/// <summary>
/// 学校编号
/// </summary>
public
int
School_Id
{
get
;
set
;
}
/// <summary>
/// 创建人
/// </summary>
public
int
CreateBy
{
get
;
set
;
}
/// <summary>
/// 创建时间
/// </summary>
public
DateTime
CreateTime
{
get
;
set
;
}
/// <summary>
/// 修改人
/// </summary>
public
int
UpdateBy
{
get
;
set
;
}
/// <summary>
/// 更新时间
/// </summary>
public
DateTime
UpdateTime
{
get
;
set
;
}
/// <summary>
/// 删除状态(0-正常,1-禁用)
/// </summary>
public
DateStateEnum
Status
{
get
;
set
;
}
/// <summary>
/// 排序
/// </summary>
public
int
SortNum
{
get
;
set
;
}
}
}
Edu.Model/ViewModel/DataStatistics/RB_Assessment_Subtype_Extend.cs
0 → 100644
View file @
caa322d9
using
Edu.Model.Entity.DataStatistics
;
using
System
;
using
System.Collections.Generic
;
using
System.Text
;
namespace
Edu.Model.ViewModel.DataStatistics
{
/// <summary>
/// 老师考评子类型配置表扩展实体类
/// </summary>
public
class
RB_Assessment_Subtype_Extend
:
RB_Assessment_Subtype
{
/// <summary>
/// 考评项目列表
/// </summary>
public
List
<
SubtypeItem
>
OptionList
{
get
;
set
;
}
}
/// <summary>
/// 考评具体项
/// </summary>
public
class
SubtypeItem
{
/// <summary>
/// 等级名称
/// </summary>
public
string
LevelTitle
{
get
;
set
;
}
/// <summary>
/// 等级描述
/// </summary>
public
string
LevelDesc
{
get
;
set
;
}
/// <summary>
/// 等级得分
/// </summary>
public
decimal
LevelScore
{
get
;
set
;
}
}
}
Edu.Model/ViewModel/DataStatistics/RB_Assessment_Type_Extend.cs
0 → 100644
View file @
caa322d9
using
Edu.Model.Entity.DataStatistics
;
using
System
;
using
System.Collections.Generic
;
using
System.Text
;
namespace
Edu.Model.ViewModel.DataStatistics
{
/// <summary>
/// 老师考评类型配置表扩展实体类
/// </summary>
public
class
RB_Assessment_Type_Extend
:
RB_Assessment_Type
{
/// <summary>
/// 子类型列表
/// </summary>
public
List
<
RB_Assessment_Subtype_Extend
>
SubtypeList
{
get
;
set
;
}
}
}
Edu.Module.User/TeacherAssessmentModule.cs
0 → 100644
View file @
caa322d9
using
Edu.Common.Enum
;
using
Edu.Model.ViewModel.DataStatistics
;
using
Edu.Repository.DataStatistics
;
using
System
;
using
System.Collections.Generic
;
using
System.Text
;
using
VT.FW.DB
;
namespace
Edu.Module.User
{
/// <summary>
/// 老师考评类型配置处理类
/// </summary>
public
class
TeacherAssessmentModule
{
/// <summary>
/// 老师考评类型配置表仓储层对象
/// </summary>
private
RB_Assessment_TypeRepository
assessment_TypeRepository
=
new
RB_Assessment_TypeRepository
();
/// <summary>
/// 老师考评子类型配置表仓储层对象
/// </summary>
private
RB_Assessment_SubtypeRepository
assessment_SubtypeRepository
=
new
RB_Assessment_SubtypeRepository
();
/// <summary>
/// 新增修改老师考评类型
/// </summary>
/// <param name="model"></param>
/// <returns></returns>
public
bool
SetAssessmentTypeModule
(
RB_Assessment_Type_Extend
model
)
{
bool
flag
=
false
;
if
(
model
.
Id
>
0
)
{
Dictionary
<
string
,
object
>
fileds
=
new
Dictionary
<
string
,
object
>()
{
{
nameof
(
RB_Assessment_Type_Extend
.
TypeName
),
model
.
TypeName
}
};
flag
=
assessment_TypeRepository
.
Update
(
fileds
,
new
WhereHelper
(
nameof
(
RB_Assessment_Type_Extend
.
Id
),
model
.
Id
));
}
else
{
var
newId
=
assessment_TypeRepository
.
Insert
(
model
);
model
.
Id
=
newId
;
flag
=
newId
>
0
;
}
return
flag
;
}
/// <summary>
/// 根据编号获取老师考评类型
/// </summary>
/// <param name="Id"></param>
/// <returns></returns>
public
RB_Assessment_Type_Extend
GetAssessmentTypeModule
(
object
Id
)
{
var
extModel
=
assessment_TypeRepository
.
GetEntity
<
RB_Assessment_Type_Extend
>(
Id
);
return
extModel
;
}
/// <summary>
/// 根据编号删除老师考评类型
/// </summary>
/// <param name="Id"></param>
/// <returns></returns>
public
bool
RemoveAssessmentTypeModule
(
object
Id
)
{
Dictionary
<
string
,
object
>
fileds
=
new
Dictionary
<
string
,
object
>()
{
{
nameof
(
RB_Assessment_Type_Extend
.
Status
),(
int
)
DateStateEnum
.
Delete
}
};
bool
flag
=
assessment_TypeRepository
.
Update
(
fileds
,
new
WhereHelper
(
nameof
(
RB_Assessment_Type_Extend
.
Id
),
Id
));
return
flag
;
}
}
}
Edu.Repository/DataStatistics/RB_Assessment_SubtypeRepository.cs
0 → 100644
View file @
caa322d9
using
Edu.Common.Enum
;
using
Edu.Model.Entity.DataStatistics
;
using
Edu.Model.ViewModel.DataStatistics
;
using
System
;
using
System.Collections.Generic
;
using
System.Linq
;
using
System.Text
;
using
VT.FW.DB.Dapper
;
namespace
Edu.Repository.DataStatistics
{
/// <summary>
/// 老师考评子类型配置表仓储层
/// </summary>
public
class
RB_Assessment_SubtypeRepository
:
BaseRepository
<
RB_Assessment_Subtype
>
{
/// <summary>
/// 获取老师考评子类型配置列表
/// </summary>
/// <param name="query"></param>
/// <returns></returns>
public
List
<
RB_Assessment_Subtype_Extend
>
GetAssessmentSubtypeListRepository
(
RB_Assessment_Subtype_Extend
query
)
{
var
parameters
=
new
DynamicParameters
();
StringBuilder
builder
=
new
StringBuilder
();
builder
.
AppendFormat
(
@"
SELECT A.*
FROM RB_Assessment_Subtype AS A
WHERE 1=1
"
);
builder
.
AppendFormat
(
" AND A.{0}={1} "
,
nameof
(
RB_Assessment_Subtype_Extend
.
Status
),
(
int
)
DateStateEnum
.
Normal
);
if
(
query
!=
null
)
{
if
(
query
.
Group_Id
>
0
)
{
builder
.
AppendFormat
(
" AND A.{0}={1} "
,
nameof
(
RB_Assessment_Subtype_Extend
.
Group_Id
),
query
.
Group_Id
);
}
if
(
query
.
AssessmentTypeId
>
0
)
{
builder
.
AppendFormat
(
" AND A.{0}={1} "
,
nameof
(
RB_Assessment_Subtype_Extend
.
AssessmentTypeId
),
query
.
AssessmentTypeId
);
}
if
(!
string
.
IsNullOrEmpty
(
query
.
SubTypeName
))
{
builder
.
AppendFormat
(
" AND A.{0} LIKE @SubTypeName "
,
nameof
(
RB_Assessment_Subtype_Extend
.
SubTypeName
));
parameters
.
Add
(
"SubTypeName"
,
"%"
+
query
.
SubTypeName
.
Trim
()
+
"%"
);
}
}
builder
.
AppendFormat
(
" ORDER BY A.{0} ASC "
,
nameof
(
RB_Assessment_Subtype_Extend
.
SortNum
));
return
Get
<
RB_Assessment_Subtype_Extend
>(
builder
.
ToString
(),
parameters
).
ToList
();
}
}
}
Edu.Repository/DataStatistics/RB_Assessment_TypeRepository.cs
0 → 100644
View file @
caa322d9
using
Edu.Common.Enum
;
using
Edu.Model.Entity.DataStatistics
;
using
Edu.Model.ViewModel.DataStatistics
;
using
System
;
using
System.Collections.Generic
;
using
System.Linq
;
using
System.Text
;
using
VT.FW.DB.Dapper
;
namespace
Edu.Repository.DataStatistics
{
/// <summary>
/// 老师考评类型配置表仓储层
/// </summary>
public
class
RB_Assessment_TypeRepository
:
BaseRepository
<
RB_Assessment_Type
>
{
/// <summary>
/// 获取老师考评类型配置列表
/// </summary>
/// <param name="query"></param>
/// <returns></returns>
public
List
<
RB_Assessment_Type_Extend
>
GetAssessmentTypeListRepository
(
RB_Assessment_Type_Extend
query
)
{
var
parameters
=
new
DynamicParameters
();
StringBuilder
builder
=
new
StringBuilder
();
builder
.
AppendFormat
(
@"
SELECT A.*
FROM RB_Assessment_Type AS A
WHERE 1=1
"
);
builder
.
AppendFormat
(
" AND A.{0}={1} "
,
nameof
(
RB_Assessment_Type_Extend
.
Status
),
(
int
)
DateStateEnum
.
Normal
);
if
(
query
!=
null
)
{
if
(
query
.
Group_Id
>
0
)
{
builder
.
AppendFormat
(
" AND A.{0}={1} "
,
nameof
(
RB_Assessment_Type_Extend
.
Group_Id
),
query
.
Group_Id
);
}
if
(!
string
.
IsNullOrEmpty
(
query
.
TypeName
))
{
builder
.
AppendFormat
(
" AND A.{0} LIKE @TypeName "
,
nameof
(
RB_Assessment_Type_Extend
.
TypeName
));
parameters
.
Add
(
"TypeName"
,
"%"
+
query
.
TypeName
.
Trim
()
+
"%"
);
}
}
builder
.
AppendFormat
(
" ORDER BY A.{0} ASC "
,
nameof
(
RB_Assessment_Type_Extend
.
SortNum
));
return
Get
<
RB_Assessment_Type_Extend
>(
builder
.
ToString
(),
parameters
).
ToList
();
}
}
}
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