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
5b430c69
Commit
5b430c69
authored
Dec 15, 2021
by
黄奎
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
页面修改
parent
9e085edc
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
76 additions
and
27 deletions
+76
-27
CustomerModule.cs
Edu.Module.Customer/CustomerModule.cs
+2
-2
StudentModule.cs
Edu.Module.User/StudentModule.cs
+24
-2
RB_StudentRepository.cs
Edu.Repository/User/RB_StudentRepository.cs
+4
-1
B2BCustomerController.cs
Edu.WebApi/Controllers/Customer/B2BCustomerController.cs
+46
-22
No files found.
Edu.Module.Customer/CustomerModule.cs
View file @
5b430c69
...
...
@@ -345,11 +345,11 @@ namespace Edu.Module.Customer
}
/// <summary>
/// 获取
我的
同行列表
/// 获取同行列表
/// </summary>
/// <param name="query"></param>
/// <returns></returns>
public
List
<
RB_Customer_Extend
>
Get
MyCustomerList
(
RB_Customer_Extend
query
)
public
List
<
RB_Customer_Extend
>
Get
CustomerListModule
(
RB_Customer_Extend
query
)
{
return
customerRepository
.
GetCustomerListRepository
(
query
);
}
...
...
Edu.Module.User/StudentModule.cs
View file @
5b430c69
...
...
@@ -119,7 +119,8 @@ namespace Edu.Module.User
{
QStuIds
=
stuIds
});
List
<
int
>
empIdList
=
Common
.
ConvertHelper
.
StringToList
(
string
.
Join
(
","
,
list
.
Select
(
qitem
=>
qitem
.
StuSourceId
)));
//内部介绍人
List
<
int
>
empIdList
=
Common
.
ConvertHelper
.
StringToList
(
string
.
Join
(
","
,
list
.
Where
(
qitem
=>
qitem
.
CreateType
==
StuCreateTypeEnum
.
InternalIntroduction
).
Select
(
qitem
=>
qitem
.
StuSourceId
)));
List
<
int
>
aIds
=
Common
.
ConvertHelper
.
StringToList
(
string
.
Join
(
","
,
assistList
.
Select
(
qitem
=>
qitem
.
AssistId
)));
List
<
RB_Account_ViewModel
>
accountList
=
new
List
<
RB_Account_ViewModel
>();
if
(
aIds
!=
null
&&
aIds
.
Count
>
0
)
...
...
@@ -166,6 +167,20 @@ namespace Edu.Module.User
qIds
=
"0"
;
}
var
destinationList
=
destinationRepository
.
GetDestinationListRepository
(
new
Model
.
ViewModel
.
System
.
RB_Destination_ViewModel
()
{
Ids
=
qIds
});
//转介人列表
List
<
RB_Customer_Extend
>
customerList
=
new
List
<
RB_Customer_Extend
>();
List
<
int
>
transIdList
=
Common
.
ConvertHelper
.
StringToList
(
string
.
Join
(
","
,
list
.
Where
(
qitem
=>
qitem
.
CreateType
==
StuCreateTypeEnum
.
TransIntroduction
).
Select
(
qitem
=>
qitem
.
StuSourceId
)));
if
(
transIdList
!=
null
&&
transIdList
.
Count
>
0
)
{
customerList
=
customerRepository
.
GetCustomerListRepository
(
new
RB_Customer_Extend
()
{
CustomerIds
=
string
.
Join
(
","
,
transIdList
)
});
}
foreach
(
var
item
in
list
)
{
var
tempOrderList
=
stuOrderList
?.
Where
(
qitem
=>
qitem
.
Student_Id
==
item
.
StuId
)?.
ToList
();
...
...
@@ -188,7 +203,14 @@ namespace Edu.Module.User
item
.
AssistList
=
tempAssistList
;
item
.
VisitCount
=
visitList
?.
FirstOrDefault
(
qitem
=>
qitem
.
StuId
==
item
.
StuId
)?.
VisitCount
??
0
;
item
.
TrialLessonCount
=
stuReserveList
?.
FirstOrDefault
(
qitem
=>
qitem
.
Visitor_Id
==
item
.
StuId
)?.
TrialLessonCount
??
0
;
item
.
StuSourceIdName
=
accountList
?.
FirstOrDefault
(
qitem
=>
qitem
.
Id
==
item
.
StuSourceId
)?.
AccountName
??
""
;
if
(
item
.
CreateType
==
StuCreateTypeEnum
.
InternalIntroduction
)
{
item
.
StuSourceIdName
=
accountList
?.
FirstOrDefault
(
qitem
=>
qitem
.
Id
==
item
.
StuSourceId
)?.
AccountName
??
""
;
}
else
if
(
item
.
CreateType
==
StuCreateTypeEnum
.
TransIntroduction
)
{
item
.
StuSourceIdName
=
customerList
?.
FirstOrDefault
(
qitem
=>
qitem
.
CustomerId
==
item
.
StuSourceId
)?.
CustomerName
??
""
;
}
}
}
return
list
;
...
...
Edu.Repository/User/RB_StudentRepository.cs
View file @
5b430c69
...
...
@@ -250,7 +250,10 @@ WHERE o.OrderState=1 and og.`Status`=0 and sog.`Status`=0 and og.GuestState=1 an
string
logContent
=
""
;
string
logTitle
=
""
;
int
createBy
=
0
;
if
(
model
.
CreateType
==
Common
.
Enum
.
User
.
StuCreateTypeEnum
.
CustomerInput
||
model
.
CreateType
==
Common
.
Enum
.
User
.
StuCreateTypeEnum
.
EmployeeInput
)
{
model
.
StuSourceId
=
0
;
}
if
(
model
.
StuId
>
0
)
{
logTitle
=
"修改客户"
;
...
...
Edu.WebApi/Controllers/Customer/B2BCustomerController.cs
View file @
5b430c69
...
...
@@ -138,7 +138,7 @@ namespace Edu.WebApi.Controllers.Customer
{
var
CustomerId
=
base
.
ParmJObj
.
GetInt
(
"CustomerId"
);
var
data
=
customerModule
.
GetCustomerModule
(
CustomerId
);
if
(
data
!=
null
&&
data
.
CreateBy
>
0
)
if
(
data
!=
null
&&
data
.
CreateBy
>
0
)
{
data
.
CreateByName
=
UserReidsCache
.
GetUserLoginInfo
(
data
.
CreateBy
)?.
AccountName
??
""
;
}
...
...
@@ -282,13 +282,13 @@ namespace Edu.WebApi.Controllers.Customer
{
DetailId
=
jobj
.
GetInt
(
"DetailId"
),
TaskId
=
jobj
.
GetInt
(
"TaskId"
),
DetailsName
=
jobj
.
GetStringValue
(
"DetailsName"
),
DetailsName
=
jobj
.
GetStringValue
(
"DetailsName"
),
TaskType
=
(
TaskTypeEnum
)
jobj
.
GetInt
(
"TaskType"
),
TargetId
=
string
.
Join
(
","
,
targetIds
),
TaskFinishValue
=
jobj
.
GetDecimal
(
"TaskFinishValue"
),
TaskKudo
=
jobj
.
GetStringValue
(
"TaskKudo"
),
TaskKudoImg
=
JsonHelper
.
Serialize
(
imgKudoList
),
KudoDescription
=
jobj
.
GetStringValue
(
"KudoDescription"
)
TaskKudo
=
jobj
.
GetStringValue
(
"TaskKudo"
),
TaskKudoImg
=
JsonHelper
.
Serialize
(
imgKudoList
),
KudoDescription
=
jobj
.
GetStringValue
(
"KudoDescription"
)
});
}
}
...
...
@@ -367,9 +367,9 @@ namespace Edu.WebApi.Controllers.Customer
Group_Id
=
base
.
UserInfo
.
Group_Id
,
RebateType
=
base
.
ParmJObj
.
GetInt
(
"RebateType"
),
BalanceType
=
base
.
ParmJObj
.
GetInt
(
"BalanceType"
),
CustomerId
=
base
.
ParmJObj
.
GetInt
(
"CustomerId"
),
OrderId
=
base
.
ParmJObj
.
GetInt
(
"OrderId"
),
Description
=
base
.
ParmJObj
.
GetStringValue
(
"Description"
),
CustomerId
=
base
.
ParmJObj
.
GetInt
(
"CustomerId"
),
OrderId
=
base
.
ParmJObj
.
GetInt
(
"OrderId"
),
Description
=
base
.
ParmJObj
.
GetStringValue
(
"Description"
),
};
var
list
=
balanceDetailModule
.
GetCustomerBalanceDetailPageModule
(
pageModel
.
PageIndex
,
pageModel
.
PageSize
,
out
long
rowsCount
,
query
);
pageModel
.
PageData
=
list
;
...
...
@@ -394,9 +394,9 @@ namespace Edu.WebApi.Controllers.Customer
{
Group_Id
=
base
.
UserInfo
.
Group_Id
,
CustomerName
=
base
.
ParmJObj
.
GetStringValue
(
"CustomerName"
),
TaskName
=
base
.
ParmJObj
.
GetStringValue
(
"TaskName"
),
ExchangeStatus
=
base
.
ParmJObj
.
GetInt
(
"ExchangeStatus"
),
ExchangeCode
=
base
.
ParmJObj
.
GetStringValue
(
"ExchangeCode"
),
TaskName
=
base
.
ParmJObj
.
GetStringValue
(
"TaskName"
),
ExchangeStatus
=
base
.
ParmJObj
.
GetInt
(
"ExchangeStatus"
),
ExchangeCode
=
base
.
ParmJObj
.
GetStringValue
(
"ExchangeCode"
),
};
var
list
=
taskModule
.
GetCustomerFinishtaskPageModule
(
pageModel
.
PageIndex
,
pageModel
.
PageSize
,
out
long
rowsCount
,
query
);
pageModel
.
PageData
=
list
;
...
...
@@ -416,10 +416,10 @@ namespace Edu.WebApi.Controllers.Customer
{
TaskId
=
base
.
ParmJObj
.
GetInt
(
"TaskId"
),
DetailId
=
base
.
ParmJObj
.
GetInt
(
"DetailId"
),
CustomerId
=
base
.
ParmJObj
.
GetInt
(
"CustomerId"
),
FinishId
=
base
.
ParmJObj
.
GetInt
(
"GetCustomerFinishtaskDetailsPage"
),
CustomerId
=
base
.
ParmJObj
.
GetInt
(
"CustomerId"
),
FinishId
=
base
.
ParmJObj
.
GetInt
(
"GetCustomerFinishtaskDetailsPage"
),
};
var
list
=
taskModule
.
GetCustomerFinishdetailsPageModule
(
pageModel
.
PageIndex
,
pageModel
.
PageSize
,
out
long
rowsCount
,
query
);
var
list
=
taskModule
.
GetCustomerFinishdetailsPageModule
(
pageModel
.
PageIndex
,
pageModel
.
PageSize
,
out
long
rowsCount
,
query
);
pageModel
.
Count
=
rowsCount
;
pageModel
.
PageData
=
list
;
return
ApiResult
.
Success
(
data
:
pageModel
);
...
...
@@ -492,12 +492,14 @@ namespace Edu.WebApi.Controllers.Customer
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetCustomerCommissionPassbook
()
{
public
ApiResult
GetCustomerCommissionPassbook
()
{
var
userInfo
=
base
.
UserInfo
;
JObject
parms
=
JObject
.
Parse
(
base
.
RequestParm
.
Msg
.
ToString
());
int
CustomerId
=
parms
.
GetInt
(
"CustomerId"
,
0
);
//同业ID
int
Type
=
parms
.
GetInt
(
"Type"
,
1
);
//类型 1佣金 2幸福存折
if
(
CustomerId
<=
0
)
{
if
(
CustomerId
<=
0
)
{
return
ApiResult
.
ParamIsNull
();
}
...
...
@@ -510,15 +512,18 @@ namespace Edu.WebApi.Controllers.Customer
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
SetCustomerCareOf
()
{
public
ApiResult
SetCustomerCareOf
()
{
var
userInfo
=
base
.
UserInfo
;
JObject
parms
=
JObject
.
Parse
(
base
.
RequestParm
.
Msg
.
ToString
());
string
CustomerIds
=
parms
.
GetStringValue
(
"CustomerIds"
);
//同业IDs
int
EmpId
=
parms
.
GetInt
(
"EmpId"
,
0
);
//接收人Id
if
(
string
.
IsNullOrEmpty
(
CustomerIds
))
{
if
(
string
.
IsNullOrEmpty
(
CustomerIds
))
{
return
ApiResult
.
ParamIsNull
(
"请传递同业ID"
);
}
if
(
EmpId
<=
0
)
{
if
(
EmpId
<=
0
)
{
return
ApiResult
.
ParamIsNull
(
"请传递接收人ID"
);
}
...
...
@@ -527,7 +532,8 @@ namespace Edu.WebApi.Controllers.Customer
{
return
ApiResult
.
Success
();
}
else
{
else
{
return
ApiResult
.
Failed
(
msg
);
}
}
...
...
@@ -555,7 +561,8 @@ namespace Edu.WebApi.Controllers.Customer
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetMyCustomerList
()
{
public
ApiResult
GetMyCustomerList
()
{
var
query
=
new
RB_Customer_Extend
()
{
Group_Id
=
base
.
UserInfo
.
Group_Id
,
...
...
@@ -566,7 +573,7 @@ namespace Edu.WebApi.Controllers.Customer
ApproveState
=
1
,
QCustomerState
=
1
,
};
var
list
=
customerModule
.
Get
MyCustomerList
(
query
);
var
list
=
customerModule
.
Get
CustomerListModule
(
query
);
return
ApiResult
.
Success
(
data
:
list
.
Select
(
x
=>
new
{
x
.
CustomerId
,
...
...
@@ -578,5 +585,22 @@ namespace Edu.WebApi.Controllers.Customer
}
#
endregion
/// <summary>
/// 获取客户列表
/// </summary>
/// <returns></returns>
[
HttpPost
]
public
ApiResult
GetCustomerList
()
{
var
query
=
new
RB_Customer_Extend
()
{
Group_Id
=
base
.
UserInfo
.
Group_Id
,
ApproveState
=
1
,
QCustomerState
=
1
,
};
var
list
=
customerModule
.
GetCustomerListModule
(
query
);
return
ApiResult
.
Success
(
data
:
list
);
}
}
}
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