Commit 04a8f675 authored by 黄奎's avatar 黄奎

Merge branch 'master' of http://gitlab.oytour.com/Kui2/education

parents d10b274f 1fce6a38
...@@ -149,15 +149,16 @@ namespace Edu.Module.User ...@@ -149,15 +149,16 @@ namespace Edu.Module.User
/// 添加修改学生 /// 添加修改学生
/// </summary> /// </summary>
/// <param name="model"></param> /// <param name="model"></param>
/// <param name="fromApp">来至于同业 1是</param>
/// <returns></returns> /// <returns></returns>
public bool SetStudentModule(RB_Student_ViewModel model) public bool SetStudentModule(RB_Student_ViewModel model, int fromApp =0)
{ {
bool IsInsert = false; bool IsInsert = false;
if (model.StuId == 0) { IsInsert = true; } if (model.StuId == 0) { IsInsert = true; }
bool flag = studentRepository.SetStudentRepository(model); bool flag = studentRepository.SetStudentRepository(model);
if (flag) if (flag)
{ {
if (IsInsert && model.CustomerId > 0) if (IsInsert && model.CustomerId > 0 && fromApp == 1)
{ {
var queryTargetWorkId = accountModule.GetWorkUserIdModule(model.CreateBy); var queryTargetWorkId = accountModule.GetWorkUserIdModule(model.CreateBy);
if (!string.IsNullOrEmpty(queryTargetWorkId)) if (!string.IsNullOrEmpty(queryTargetWorkId))
......
...@@ -813,7 +813,7 @@ namespace Edu.WebApi.Controllers.User ...@@ -813,7 +813,7 @@ namespace Edu.WebApi.Controllers.User
{ {
return ApiResult.Failed("此学员手机号已绑定同行!请重新录入!"); return ApiResult.Failed("此学员手机号已绑定同行!请重新录入!");
} }
bool flag = studentModule.SetStudentModule(extModel); bool flag = studentModule.SetStudentModule(extModel, 1);
return flag ? ApiResult.Success() : ApiResult.Failed(); return flag ? ApiResult.Success() : ApiResult.Failed();
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment