Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Property
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
liudong1993
Property
Commits
2bc0e534
Commit
2bc0e534
authored
Jan 19, 2020
by
liudong1993
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
资产管理 耗材申请时间管理
parent
ccd0ff30
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
587 additions
and
10 deletions
+587
-10
RB_Supplies_Applyfor.cs
Property.Model/Entity/Supplies/RB_Supplies_Applyfor.cs
+4
-0
RB_Property_UseReceive_Extend.cs
...ty.Model/Extend/Property/RB_Property_UseReceive_Extend.cs
+4
-0
RB_Supplies_ApplyforSpecial_Extend.cs
...del/Extend/Supplies/RB_Supplies_ApplyforSpecial_Extend.cs
+4
-1
RB_Supplies_ApplyforWeekday_Extend.cs
...del/Extend/Supplies/RB_Supplies_ApplyforWeekday_Extend.cs
+4
-1
RB_Supplies_Applyfor_Extend.cs
...erty.Model/Extend/Supplies/RB_Supplies_Applyfor_Extend.cs
+9
-1
PropertyModule.cs
Property.Modele.FixedAssets/PropertyModule.cs
+42
-0
SuppliesModule.cs
Property.Modele.FixedAssets/SuppliesModule.cs
+254
-0
RB_Supplies_ApplyforRepository.cs
...rty.Repository/Supplies/RB_Supplies_ApplyforRepository.cs
+9
-2
RB_Supplies_ApplyforSpecialRepository.cs
...ository/Supplies/RB_Supplies_ApplyforSpecialRepository.cs
+6
-0
RB_Supplies_ApplyforWeekdayRepository.cs
...ository/Supplies/RB_Supplies_ApplyforWeekdayRepository.cs
+8
-5
PropertyController.cs
Property.WebApi/Controllers/Property/PropertyController.cs
+2
-0
SuppliesController.cs
Property.WebApi/Controllers/Property/SuppliesController.cs
+241
-0
No files found.
Property.Model/Entity/Supplies/RB_Supplies_Applyfor.cs
View file @
2bc0e534
...
...
@@ -30,6 +30,10 @@ namespace Property.Model.Entity
set
;
}
/// <summary>
/// 启用 1是 2否
/// </summary>
public
int
?
Enabled
{
get
;
set
;
}
/// <summary>
/// 状态 0正常 1删除
/// </summary>
public
int
?
Status
...
...
Property.Model/Extend/Property/RB_Property_UseReceive_Extend.cs
View file @
2bc0e534
...
...
@@ -12,6 +12,10 @@ namespace Property.Model.Extend
[
DB
(
ConnectionName
=
"PropertyConnection"
)]
public
class
RB_Property_UseReceive_Extend
:
RB_Property_UseReceive
{
/// <summary>
/// 是否是申请人签名 1是 其他否
/// </summary>
public
int
?
IsApplyForSign
{
get
;
set
;
}
/// <summary>
/// 数量
/// </summary>
...
...
Property.Model/Extend/Supplies/RB_Supplies_ApplyforSpecial_Extend.cs
View file @
2bc0e534
...
...
@@ -11,6 +11,9 @@ namespace Property.Model.Extend
[
DB
(
ConnectionName
=
"PropertyConnection"
)]
public
class
RB_Supplies_ApplyforSpecial_Extend
:
RB_Supplies_ApplyforSpecial
{
/// <summary>
/// 设置申请ids
/// </summary>
public
string
ApplyforIds
{
get
;
set
;
}
}
}
\ No newline at end of file
Property.Model/Extend/Supplies/RB_Supplies_ApplyforWeekday_Extend.cs
View file @
2bc0e534
...
...
@@ -11,6 +11,9 @@ namespace Property.Model.Extend
[
DB
(
ConnectionName
=
"PropertyConnection"
)]
public
class
RB_Supplies_ApplyforWeekday_Extend
:
RB_Supplies_ApplyforWeekday
{
/// <summary>
/// 设置ids
/// </summary>
public
string
ApplyforIds
{
get
;
set
;
}
}
}
\ No newline at end of file
Property.Model/Extend/Supplies/RB_Supplies_Applyfor_Extend.cs
View file @
2bc0e534
using
System
;
using
System.Collections.Generic
;
using
Property.Model.Entity
;
using
REBORN.Common.AOP
;
...
...
@@ -11,6 +12,13 @@ namespace Property.Model.Extend
[
DB
(
ConnectionName
=
"PropertyConnection"
)]
public
class
RB_Supplies_Applyfor_Extend
:
RB_Supplies_Applyfor
{
/// <summary>
/// 耗材申请工作日
/// </summary>
public
List
<
RB_Supplies_ApplyforWeekday_Extend
>
WeekdayList
{
get
;
set
;
}
/// <summary>
/// 特殊日期
/// </summary>
public
List
<
RB_Supplies_ApplyforSpecial_Extend
>
SpecialList
{
get
;
set
;
}
}
}
\ No newline at end of file
Property.Modele.FixedAssets/PropertyModule.cs
View file @
2bc0e534
...
...
@@ -985,6 +985,14 @@ namespace Property.Module.FixedAssets
bOldlist
=
branchRepository
.
GetBranchNameByIds
(
boldstr
);
bInlist
=
branchRepository
.
GetBranchNameByIds
(
bnewstr
);
List
<
Rb_Workflow_AuditRelevance_Extend
>
arlist
=
new
List
<
Rb_Workflow_AuditRelevance_Extend
>();
if
(
demodel
.
IsSelfApplication
==
1
)
{
//自助申请的查询
//查询所有的签名流程
arlist
=
workflow_AuditRelevanceRepository
.
GetAuditRelevanceList
(
0
,
rstr
,
WFRrocessStatus
.
NotAudit
);
}
foreach
(
var
item
in
list
)
{
item
.
DetailList
=
urlist
.
Where
(
x
=>
x
.
ReceiveId
==
item
.
Id
).
ToList
();
...
...
@@ -1010,6 +1018,16 @@ namespace Property.Module.FixedAssets
item
.
ImageList
.
Add
(
Config
.
GetFileUrl
(
img
));
}
}
item
.
IsApplyForSign
=
0
;
if
(
demodel
.
IsSelfApplication
==
1
)
{
var
arModel
=
arlist
.
Where
(
x
=>
x
.
WorkFlowId
==
item
.
Id
).
OrderBy
(
x
=>
x
.
Sort
).
FirstOrDefault
();
if
(
arModel
!=
null
&&
arModel
.
SpecialNode
==
WFSpecialNodeEnum
.
Pay
)
{
item
.
IsApplyForSign
=
1
;
}
}
}
}
return
list
;
...
...
@@ -2342,6 +2360,12 @@ namespace Property.Module.FixedAssets
{
string
rstr
=
string
.
Join
(
","
,
list
.
Select
(
x
=>
x
.
Id
));
urlist
=
useRelevanceRepository
.
GetList
(
new
RB_Property_UseRelevance_Extend
()
{
RB_Group_Id
=
demodel
.
RB_Group_Id
,
ReceiveIdStr
=
rstr
});
List
<
Rb_Workflow_AuditRelevance_Extend
>
arlist
=
new
List
<
Rb_Workflow_AuditRelevance_Extend
>();
if
(
demodel
.
IsSelfApplication
==
1
)
{
//自助申请的查询
//查询所有的签名流程
arlist
=
workflow_AuditRelevanceRepository
.
GetAuditRelevanceList
(
0
,
rstr
,
WFRrocessStatus
.
NotAudit
);
}
foreach
(
var
item
in
list
)
{
...
...
@@ -2350,6 +2374,15 @@ namespace Property.Module.FixedAssets
foreach
(
var
item2
in
item
.
DetailList
)
{
item2
.
CancelStockEmployeeName
=
CacheManager
.
User
.
UserReidsCache
.
GetEmployee
(
item2
.
CancelStockEmployeeId
)?.
EmName
??
""
;
}
item
.
IsApplyForSign
=
0
;
if
(
demodel
.
IsSelfApplication
==
1
)
{
var
arModel
=
arlist
.
Where
(
x
=>
x
.
WorkFlowId
==
item
.
Id
).
OrderBy
(
x
=>
x
.
Sort
).
FirstOrDefault
();
if
(
arModel
!=
null
&&
arModel
.
SpecialNode
==
WFSpecialNodeEnum
.
Pay
)
{
item
.
IsApplyForSign
=
1
;
}
}
}
}
return
list
;
...
...
@@ -2525,6 +2558,15 @@ namespace Property.Module.FixedAssets
}
}
/// <summary>
/// 更新审核人
/// </summary>
/// <param name="AuditId"></param>
/// <param name="OldEmId"></param>
/// <param name="NewEmId"></param>
/// <param name="coModelList"></param>
/// <param name="trans"></param>
/// <returns></returns>
public
bool
UpdateAuditEmId
(
int
AuditId
,
int
OldEmId
,
int
NewEmId
,
List
<
SetCareOfModel
>
coModelList
,
System
.
Data
.
IDbTransaction
trans
=
null
)
{
bool
flag
=
true
,
recordflag
=
true
;
...
...
Property.Modele.FixedAssets/SuppliesModule.cs
View file @
2bc0e534
This diff is collapsed.
Click to expand it.
Property.Repository/Supplies/RB_Supplies_ApplyforRepository.cs
View file @
2bc0e534
...
...
@@ -24,10 +24,13 @@ namespace Property.Repository
string
where
=
" where 1=1 "
;
where
+=
string
.
Format
(
" AND {0}={1}"
,
nameof
(
RB_Supplies_Applyfor_Extend
.
Status
),
0
);
where
+=
$@" and RB_Group_Id=
{
dmodel
.
RB_Group_Id
}
"
;
if
(
dmodel
.
BranchId
>=
0
)
if
(
dmodel
.
BranchId
>=
-
1
)
{
where
+=
" and "
+
nameof
(
RB_Supplies_Applyfor_Extend
.
BranchId
)
+
" ="
+
dmodel
.
BranchId
;
}
if
(
dmodel
.
Enabled
>
0
)
{
where
+=
" and "
+
nameof
(
RB_Supplies_Applyfor_Extend
.
Enabled
)
+
" ="
+
dmodel
.
Enabled
;
}
string
sql
=
$@" select * from RB_Supplies_Applyfor
{
where
}
order by Id desc"
;
return
GetPage
<
RB_Supplies_Applyfor_Extend
>(
pageIndex
,
pageSize
,
out
count
,
sql
).
ToList
();
...
...
@@ -44,10 +47,14 @@ namespace Property.Repository
string
where
=
" where 1=1 "
;
where
+=
string
.
Format
(
" AND {0}={1}"
,
nameof
(
RB_Supplies_Applyfor_Extend
.
Status
),
0
);
where
+=
$@" and RB_Group_Id=
{
dmodel
.
RB_Group_Id
}
"
;
if
(
dmodel
.
BranchId
>=
0
)
if
(
dmodel
.
BranchId
>=
-
1
)
{
where
+=
" and "
+
nameof
(
RB_Supplies_Applyfor_Extend
.
BranchId
)
+
" ="
+
dmodel
.
BranchId
;
}
if
(
dmodel
.
Enabled
>
0
)
{
where
+=
" and "
+
nameof
(
RB_Supplies_Applyfor_Extend
.
Enabled
)
+
" ="
+
dmodel
.
Enabled
;
}
string
sql
=
$@" select * from RB_Supplies_Applyfor
{
where
}
order by Id desc"
;
return
Get
<
RB_Supplies_Applyfor_Extend
>(
sql
).
ToList
();
...
...
Property.Repository/Supplies/RB_Supplies_ApplyforSpecialRepository.cs
View file @
2bc0e534
using
Property.Model.Entity
;
using
Property.Model.Extend
;
using
System
;
using
System.Collections.Generic
;
using
System.Linq
;
using
System.Text
;
...
...
@@ -42,10 +43,15 @@ namespace Property.Repository
{
string
where
=
" where 1=1 "
;
where
+=
string
.
Format
(
" AND {0}={1}"
,
nameof
(
RB_Supplies_ApplyforSpecial_Extend
.
Status
),
0
);
where
+=
$@" and
{
nameof
(
RB_Supplies_ApplyforSpecial_Extend
.
Date
)}
>='
{
DateTime
.
Now
.
ToString
(
"yyyy-MM-dd"
)}
'"
;
//必须要大于等于当前时间
if
(
dmodel
.
ApplyforId
>=
0
)
{
where
+=
" and "
+
nameof
(
RB_Supplies_ApplyforSpecial_Extend
.
ApplyforId
)
+
" ="
+
dmodel
.
ApplyforId
;
}
if
(!
string
.
IsNullOrEmpty
(
dmodel
.
ApplyforIds
))
{
where
+=
" and "
+
nameof
(
RB_Supplies_ApplyforSpecial_Extend
.
ApplyforId
)
+
" in("
+
dmodel
.
ApplyforIds
+
")"
;
}
string
sql
=
$@" select * from RB_Supplies_ApplyforSpecial
{
where
}
order by Id desc"
;
return
Get
<
RB_Supplies_ApplyforSpecial_Extend
>(
sql
).
ToList
();
...
...
Property.Repository/Supplies/RB_Supplies_ApplyforWeekdayRepository.cs
View file @
2bc0e534
...
...
@@ -23,13 +23,13 @@ namespace Property.Repository
{
string
where
=
" where 1=1 "
;
where
+=
string
.
Format
(
" AND {0}={1}"
,
nameof
(
RB_Supplies_ApplyforWeekday_Extend
.
Status
),
0
);
where
+=
$@" and RB_Group_Id=
{
dmodel
.
RB_Group_Id
}
"
;
if
(
dmodel
.
ApplyforId
>=
0
)
where
+=
$@" and RB_Group_Id=
{
dmodel
.
RB_Group_Id
}
"
;
if
(
dmodel
.
ApplyforId
>
0
)
{
where
+=
" and "
+
nameof
(
RB_Supplies_ApplyforWeekday_Extend
.
ApplyforId
)
+
" ="
+
dmodel
.
ApplyforId
;
}
string
sql
=
$@" select * from RB_Supplies_Applyfor
{
where
}
order by Id desc"
;
string
sql
=
$@" select * from RB_Supplies_Applyfor
Weekday
{
where
}
order by Id desc"
;
return
GetPage
<
RB_Supplies_ApplyforWeekday_Extend
>(
pageIndex
,
pageSize
,
out
count
,
sql
).
ToList
();
}
...
...
@@ -44,12 +44,15 @@ namespace Property.Repository
string
where
=
" where 1=1 "
;
where
+=
string
.
Format
(
" AND {0}={1}"
,
nameof
(
RB_Supplies_ApplyforWeekday_Extend
.
Status
),
0
);
where
+=
$@" and RB_Group_Id=
{
dmodel
.
RB_Group_Id
}
"
;
if
(
dmodel
.
ApplyforId
>
=
0
)
if
(
dmodel
.
ApplyforId
>
0
)
{
where
+=
" and "
+
nameof
(
RB_Supplies_ApplyforWeekday_Extend
.
ApplyforId
)
+
" ="
+
dmodel
.
ApplyforId
;
}
if
(!
string
.
IsNullOrEmpty
(
dmodel
.
ApplyforIds
))
{
where
+=
" and "
+
nameof
(
RB_Supplies_ApplyforWeekday_Extend
.
ApplyforId
)
+
" in("
+
dmodel
.
ApplyforIds
+
")"
;
}
string
sql
=
$@" select * from RB_Supplies_Applyfor
{
where
}
order by Id desc"
;
string
sql
=
$@" select * from RB_Supplies_Applyfor
Weekday
{
where
}
order by Id desc"
;
return
Get
<
RB_Supplies_ApplyforWeekday_Extend
>(
sql
).
ToList
();
}
}
...
...
Property.WebApi/Controllers/Property/PropertyController.cs
View file @
2bc0e534
...
...
@@ -1061,6 +1061,7 @@ namespace Property.WebApi.Controllers.User
x
.
BranchName
,
x
.
DepartmentName
,
TempleteId
=
x
.
TempleteId
??
0
,
x
.
IsApplyForSign
,
DetailList
=
x
.
DetailList
.
Select
(
z
=>
new
{
z
.
Id
,
...
...
@@ -1397,6 +1398,7 @@ namespace Property.WebApi.Controllers.User
x
.
OrderCode
,
AuditStatusName
=
x
.
AuditStatus
.
GetEnumName
(),
TempleteId
=
x
.
TempleteId
??
0
,
x
.
IsApplyForSign
,
DetailList
=
x
.
DetailList
.
Select
(
z
=>
new
{
z
.
Id
,
...
...
Property.WebApi/Controllers/Property/SuppliesController.cs
View file @
2bc0e534
This diff is collapsed.
Click to expand it.
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