Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
H
huatu_API
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
huatu_API
Commits
11b3c89b
Commit
11b3c89b
authored
Aug 26, 2025
by
liudong1993
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
d12c7ed5
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
188 additions
and
64 deletions
+188
-64
FinancialModule.cs
REBORN.Module.FinanceModule/FinancialModule.cs
+20
-36
FinancialModule3.cs
REBORN.Module.FinanceModule/FinancialModule3.cs
+2
-11
FinancialService.cs
REBORN.Services.FinanceService/FinancialService.cs
+52
-0
FinancialService3.cs
REBORN.Services.FinanceService/FinancialService3.cs
+114
-17
No files found.
REBORN.Module.FinanceModule/FinancialModule.cs
View file @
11b3c89b
...
...
@@ -870,29 +870,15 @@ namespace REBORN.Module.FinanceModule
else
{
//F_Query_AllIncomPay-查看所有
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_AllIncomPay,"
))
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_AllIncomPay,"
)
||
(
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Cashier,"
)
)
{
}
//F_Query_SelfBranch-查看本公司
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfBranch,"
))
{
//日币 春花特殊权限
bool
IsJapanSelect
=
false
;
if
(
userInfo
.
EmployeeId
==
2739
&&
userInfo
.
RB_Group_id
==
2
)
{
IsJapanSelect
=
true
;
// 2024-07-25 邱老师同意 春花可以查询所有单据 主要为了核实 付款金额
//验证是否 日本账户&& (model.TradeWay == BranchAccountEnum.Bank || model.TradeWay == BranchAccountEnum.Cash) && model.BankID > 0
//var arModel = accountRelationRepository.GetList(new RB_AccountRelation() { AccountType = model.TradeWay, AccountID = model.BankID }).FirstOrDefault();
//if (arModel != null && arModel.RB_Branch_Id == userInfo.RB_Branch_id) {
// IsJapanSelect = true;
//}
}
if
(!
IsJapanSelect
)
{
model
.
RB_Branch_Id
=
userInfo
.
RB_Branch_id
;
}
}
//F_Query_SelfDepart查看本部门
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfDepart,"
))
{
...
...
@@ -2116,35 +2102,33 @@ namespace REBORN.Module.FinanceModule
public
List
<
RB_Finance_Extend
>
GetList
(
RB_Finance_Extend
model
,
UserInfo
userInfo
)
{
//判断条件
//总公司财务
if
(
Config
.
FinanceDepartmentId
==
userInfo
.
RB_Department_Id
||
IsHeadOrFinacne
(
userInfo
))
userInfo
.
ActionMenuCode
=
GetActionCode
(
userInfo
.
RB_Post_Id
);
if
(
string
.
IsNullOrEmpty
(
userInfo
.
ActionMenuCode
))
{
//TODO不做操作
model
.
UpdateBy
=
userInfo
.
EmployeeId
;
}
//分公司财务和分公司负责人能查看自己所负责的出纳会计窗口的数据
else
if
(
IsBranchHeadOrFinacne
(
userInfo
))
else
{
//日币 春花特殊权限
bool
IsJapanSelect
=
false
;
if
(
userInfo
.
EmployeeId
==
2739
&&
userInfo
.
RB_Group_id
==
2
)
//F_Query_AllIncomPay-查看所有
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_AllIncomPay,"
)
||
(
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Cashier,"
))
{
IsJapanSelect
=
true
;
//验证是否 日本账户&& (model.TradeWay == BranchAccountEnum.Bank || model.TradeWay == BranchAccountEnum.Cash) && model.BankID > 0
//var arModel = accountRelationRepository.GetList(new RB_AccountRelation() { AccountType = model.TradeWay, AccountID = model.BankID }).FirstOrDefault();
//if (arModel != null && arModel.RB_Branch_Id == userInfo.RB_Branch_id)
//{
// IsJapanSelect = true;
//}
}
if
(!
IsJapanSelect
)
//F_Query_SelfBranch-查看本公司
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfBranch,"
))
{
model
.
RB_Branch_Id
=
userInfo
.
RB_Branch_id
;
}
//F_Query_SelfDepart查看本部门
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfDepart,"
))
{
model
.
RB_Depart_Id
=
userInfo
.
RB_Department_Id
;
}
else
{
model
.
UpdateBy
=
userInfo
.
EmployeeId
;
}
}
//国内机票特殊处理
if
(
model
.
RB_Branch_Id
==
45
)
{
//国内票务
...
...
REBORN.Module.FinanceModule/FinancialModule3.cs
View file @
11b3c89b
...
...
@@ -3338,24 +3338,15 @@ namespace REBORN.Module.FinanceModule
else
{
//F_Query_AllIncomPay-查看所有
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_AllIncomPay,"
))
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_AllIncomPay,"
)
||
(
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Cashier,"
)
)
{
}
//F_Query_SelfBranch-查看本公司
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfBranch,"
))
{
//日币 春花特殊权限
bool
IsJapanSelect
=
false
;
if
(
userInfo
.
EmployeeId
==
2739
&&
userInfo
.
RB_Group_id
==
2
)
{
IsJapanSelect
=
true
;
// 2024-07-25 邱老师同意 春花可以查询所有单据 主要为了核实 付款金额
}
if
(!
IsJapanSelect
)
{
model
.
RB_Branch_Id
=
userInfo
.
RB_Branch_id
;
}
}
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfDepart,"
))
{
model
.
RB_Depart_Id
=
userInfo
.
RB_Department_Id
;
...
...
REBORN.Services.FinanceService/FinancialService.cs
View file @
11b3c89b
...
...
@@ -6160,6 +6160,32 @@ namespace REBORN.Services.FinanceService
//{
// return ApiResult.Failed("请选择汇款/付款日期");
//}
#
region
权限
userInfo
.
ActionMenuCode
=
module
.
GetActionCode
(
userInfo
.
RB_Post_Id
);
if
(
string
.
IsNullOrEmpty
(
userInfo
.
ActionMenuCode
))
{
return
ApiResult
.
Failed
(
"没有权限"
);
}
else
{
//F_Query_AllIncomPay-查看所有
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_AllIncomPay,"
)
||
(
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Cashier,"
))
{
}
//F_Query_SelfBranch-查看本公司
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfBranch,"
))
{
model
.
RB_Branch_Id
=
userInfo
.
RB_Branch_id
;
}
else
{
return
ApiResult
.
Failed
(
"没有权限"
);
}
}
#
endregion
var
data
=
module
.
GetAccountDetailList
(
model
,
out
_
,
out
_
);
var
list
=
data
.
Select
(
x
=>
new
{
...
...
@@ -6290,6 +6316,32 @@ namespace REBORN.Services.FinanceService
return
Common
.
Plugin
.
ExcelTempLateHelper
.
ToExcelExtend
(
slist
);
}
model
.
IsAirResponsibilitySelect
=
AccountToExcelType
==
2
?
11
:
0
;
#
region
权限
userInfo
.
ActionMenuCode
=
module
.
GetActionCode
(
userInfo
.
RB_Post_Id
);
if
(
string
.
IsNullOrEmpty
(
userInfo
.
ActionMenuCode
))
{
return
Common
.
Plugin
.
ExcelTempLateHelper
.
ToExcelExtend
(
slist
);
}
else
{
//F_Query_AllIncomPay-查看所有
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_AllIncomPay,"
)
||
(
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Cashier,"
))
{
}
//F_Query_SelfBranch-查看本公司
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfBranch,"
))
{
model
.
RB_Branch_Id
=
userInfo
.
RB_Branch_id
;
}
else
{
return
Common
.
Plugin
.
ExcelTempLateHelper
.
ToExcelExtend
(
slist
);
}
}
#
endregion
var
list
=
module
.
GetAccountDetailList
(
model
,
out
_
,
out
_
);
#
endregion
if
(!
list
.
Any
())
...
...
REBORN.Services.FinanceService/FinancialService3.cs
View file @
11b3c89b
...
...
@@ -1616,11 +1616,31 @@ namespace REBORN.Services.FinanceService
RB_Finance_Extend
model
=
JsonConvert
.
DeserializeObject
<
RB_Finance_Extend
>(
request
.
msg
.
ToString
());
UserInfo
userInfo
=
request
.
groupId
>
0
&&
request
.
requestFrom
==
Common
.
Enum
.
ApiRequestFromEnum
.
Edu
?
CacheManager
.
User
.
RbUserCache
.
GetUserInfoForEdu
(
request
)
:
CacheManager
.
User
.
RbUserCache
.
GetUserLoginInfo
(
request
.
uid
);
model
.
RB_Group_Id
=
userInfo
.
RB_Group_id
;
if
(
userInfo
.
RB_Branch_id
!=
0
&&
userInfo
.
RB_Branch_id
!=
49
)
#
region
权限
userInfo
.
ActionMenuCode
=
module
.
GetActionCode
(
userInfo
.
RB_Post_Id
);
if
(
string
.
IsNullOrEmpty
(
userInfo
.
ActionMenuCode
))
{
return
ApiResult
.
Failed
(
"没有权限"
);
}
else
{
//F_Query_AllIncomPay-查看所有
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_AllIncomPay,"
)
||
(
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Cashier,"
))
{
}
//F_Query_SelfBranch-查看本公司
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfBranch,"
))
{
//非成都 只能查询自己公司的单据
model
.
RB_Branch_Id
=
userInfo
.
RB_Branch_id
;
}
else
{
return
ApiResult
.
Failed
(
"没有权限"
);
}
}
#
endregion
var
data
=
module
.
GetPlatformPageList
(
pmodel
.
pageIndex
,
pmodel
.
pageSize
,
model
,
userInfo
,
out
long
count
);
var
list
=
data
?.
Select
(
x
=>
new
{
...
...
@@ -1688,11 +1708,30 @@ namespace REBORN.Services.FinanceService
RB_Finance_Extend
model
=
JsonConvert
.
DeserializeObject
<
RB_Finance_Extend
>(
request
.
msg
.
ToString
());
UserInfo
userInfo
=
request
.
groupId
>
0
&&
request
.
requestFrom
==
Common
.
Enum
.
ApiRequestFromEnum
.
Edu
?
CacheManager
.
User
.
RbUserCache
.
GetUserInfoForEdu
(
request
)
:
CacheManager
.
User
.
RbUserCache
.
GetUserLoginInfo
(
request
.
uid
);
model
.
RB_Group_Id
=
userInfo
.
RB_Group_id
;
if
(
userInfo
.
RB_Branch_id
!=
0
&&
userInfo
.
RB_Branch_id
!=
49
)
#
region
权限
userInfo
.
ActionMenuCode
=
module
.
GetActionCode
(
userInfo
.
RB_Post_Id
);
if
(
string
.
IsNullOrEmpty
(
userInfo
.
ActionMenuCode
))
{
return
ApiResult
.
Failed
(
"没有权限"
);
}
else
{
//F_Query_AllIncomPay-查看所有
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_AllIncomPay,"
)
||
(
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Cashier,"
))
{
}
//F_Query_SelfBranch-查看本公司
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfBranch,"
))
{
//非成都 只能查询自己公司的单据
model
.
RB_Branch_Id
=
userInfo
.
RB_Branch_id
;
}
else
{
return
ApiResult
.
Failed
(
"没有权限"
);
}
}
#
endregion
List
<
RB_TradeWay_Extend
>
TradeList
=
new
List
<
RB_TradeWay_Extend
>();
var
data
=
module
.
GetPlatformStatisticsList
(
model
,
userInfo
,
out
TradeList
);
...
...
@@ -1747,16 +1786,36 @@ namespace REBORN.Services.FinanceService
/// <returns></returns>
public
virtual
byte
[]
GetPlatformStatisticsExport_Cancel
(
RequestParm
request
)
{
List
<
ExcelDataSource
>
list
=
new
List
<
ExcelDataSource
>();
RB_Finance_Extend
model
=
JsonConvert
.
DeserializeObject
<
RB_Finance_Extend
>(
request
.
msg
.
ToString
());
JObject
parm
=
JObject
.
Parse
(
request
.
msg
.
ToString
());
int
EmployeeId
=
parm
.
GetInt
(
"EmployeeId"
);
UserInfo
userInfo
=
request
.
groupId
>
0
&&
request
.
requestFrom
==
Common
.
Enum
.
ApiRequestFromEnum
.
Edu
?
CacheManager
.
User
.
RbUserCache
.
GetUserInfoForEdu
(
request
)
:
CacheManager
.
User
.
RbUserCache
.
GetUserLoginInfo
(
EmployeeId
.
ToString
());
model
.
RB_Group_Id
=
userInfo
.
RB_Group_id
;
if
(
userInfo
.
RB_Branch_id
!=
0
&&
userInfo
.
RB_Branch_id
!=
49
)
#
region
权限
userInfo
.
ActionMenuCode
=
module
.
GetActionCode
(
userInfo
.
RB_Post_Id
);
if
(
string
.
IsNullOrEmpty
(
userInfo
.
ActionMenuCode
))
{
return
ExcelTempLateHelper
.
ToExcelExtend
(
list
);
}
else
{
//F_Query_AllIncomPay-查看所有
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_AllIncomPay,"
)
||
(
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Cashier,"
))
{
}
//F_Query_SelfBranch-查看本公司
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfBranch,"
))
{
//非成都 只能查询自己公司的单据
model
.
RB_Branch_Id
=
userInfo
.
RB_Branch_id
;
}
else
{
return
ExcelTempLateHelper
.
ToExcelExtend
(
list
);
}
}
#
endregion
if
(!
string
.
IsNullOrEmpty
(
model
.
CostTypeIDs
))
{
model
.
CostTypeIDs
=
model
.
CostTypeIDs
.
Substring
(
0
,
model
.
CostTypeIDs
.
Length
-
1
);
...
...
@@ -1787,7 +1846,6 @@ namespace REBORN.Services.FinanceService
List
<
object
>
tempResult
=
new
List
<
object
>();
List
<
object
>
result
=
new
List
<
object
>();
decimal
allMoney
=
0
;
List
<
ExcelDataSource
>
list
=
new
List
<
ExcelDataSource
>();
#
region
平台在途金额统计导出
if
(
data
!=
null
&&
data
.
Count
>
0
)
{
...
...
@@ -2099,11 +2157,30 @@ namespace REBORN.Services.FinanceService
RB_Finance_Extend
model
=
JsonConvert
.
DeserializeObject
<
RB_Finance_Extend
>(
request
.
msg
.
ToString
());
UserInfo
userInfo
=
request
.
groupId
>
0
&&
request
.
requestFrom
==
Common
.
Enum
.
ApiRequestFromEnum
.
Edu
?
CacheManager
.
User
.
RbUserCache
.
GetUserInfoForEdu
(
request
)
:
CacheManager
.
User
.
RbUserCache
.
GetUserLoginInfo
(
request
.
uid
);
model
.
RB_Group_Id
=
userInfo
.
RB_Group_id
;
if
(
userInfo
.
RB_Branch_id
!=
0
&&
userInfo
.
RB_Branch_id
!=
49
)
#
region
权限
userInfo
.
ActionMenuCode
=
module
.
GetActionCode
(
userInfo
.
RB_Post_Id
);
if
(
string
.
IsNullOrEmpty
(
userInfo
.
ActionMenuCode
))
{
return
ApiResult
.
Failed
(
"没有权限"
);
}
else
{
//F_Query_AllIncomPay-查看所有
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_AllIncomPay,"
)
||
(
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Cashier,"
))
{
}
//F_Query_SelfBranch-查看本公司
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfBranch,"
))
{
//非成都 只能查询自己公司的单据
model
.
RB_Branch_Id
=
userInfo
.
RB_Branch_id
;
}
else
{
return
ApiResult
.
Failed
(
"没有权限"
);
}
}
#
endregion
var
data
=
module
.
GetPlatformSumStatistics
(
model
);
return
ApiResult
.
Success
(
""
,
data
.
Select
(
x
=>
new
...
...
@@ -2137,16 +2214,36 @@ namespace REBORN.Services.FinanceService
/// <returns></returns>
public
virtual
byte
[]
GetPlatformStatisticsExport
(
RequestParm
request
)
{
List
<
ExcelDataSource
>
rlist
=
new
List
<
ExcelDataSource
>();
RB_Finance_Extend
model
=
JsonConvert
.
DeserializeObject
<
RB_Finance_Extend
>(
request
.
msg
.
ToString
());
JObject
parm
=
JObject
.
Parse
(
request
.
msg
.
ToString
());
int
EmployeeId
=
parm
.
GetInt
(
"EmployeeId"
);
UserInfo
userInfo
=
request
.
groupId
>
0
&&
request
.
requestFrom
==
Common
.
Enum
.
ApiRequestFromEnum
.
Edu
?
CacheManager
.
User
.
RbUserCache
.
GetUserInfoForEdu
(
request
)
:
CacheManager
.
User
.
RbUserCache
.
GetUserLoginInfo
(
EmployeeId
.
ToString
());
model
.
RB_Group_Id
=
userInfo
.
RB_Group_id
;
if
(
userInfo
.
RB_Branch_id
!=
0
&&
userInfo
.
RB_Branch_id
!=
49
)
#
region
权限
userInfo
.
ActionMenuCode
=
module
.
GetActionCode
(
userInfo
.
RB_Post_Id
);
if
(
string
.
IsNullOrEmpty
(
userInfo
.
ActionMenuCode
))
{
return
ExcelTempLateHelper
.
ToExcelExtend
(
rlist
);
}
else
{
//F_Query_AllIncomPay-查看所有
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_AllIncomPay,"
)
||
(
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Cashier,"
))
{
}
//F_Query_SelfBranch-查看本公司
else
if
((
","
+
userInfo
.
ActionMenuCode
+
","
).
Contains
(
",F_Query_SelfBranch,"
))
{
//非成都 只能查询自己公司的单据
model
.
RB_Branch_Id
=
userInfo
.
RB_Branch_id
;
}
else
{
return
ExcelTempLateHelper
.
ToExcelExtend
(
rlist
);
}
}
#
endregion
var
list
=
new
List
<
RB_Finance_Extend
>();
if
((
model
.
ImportType
??
0
)
!=
1
)
...
...
@@ -2156,7 +2253,7 @@ namespace REBORN.Services.FinanceService
}
var
data
=
module
.
GetPlatformSumStatistics
(
model
);
//统计
List
<
ExcelDataSource
>
rlist
=
new
List
<
ExcelDataSource
>();
if
(
list
!=
null
&&
list
.
Count
>
0
)
{
ExcelDataSource
header
=
new
ExcelDataSource
(
30
)
...
...
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