配合前端对接开班接口

master
xiaochanghai 4 months ago
parent 4798c0a230
commit 0669df261f
  1. 15
      Model/Tiobon.Web.pdm
  2. 18
      Tiobon.Core.Api/Controllers/Ghre/Ghre_OpenClassController.cs
  3. 4
      Tiobon.Core.IServices/Ghre/IGhre_OpenClassServices.cs
  4. 1
      Tiobon.Core.Services/Ghre/Ghre_OpenClassFeeServices.cs
  5. 11
      Tiobon.Core.Services/Ghre/Ghre_OpenClassServices.cs

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<?PowerDesigner AppLocale="UTF16" ID="{C294868A-C3F3-41AD-98CC-78B6D4E0CC40}" Label="" LastModificationDate="1739175366" Name="Tiobon" Objects="3156" Symbols="124" Target="Microsoft SQL Server 2008" Type="{CDE44E21-9669-11D1-9914-006097355D9B}" signature="PDM_DATA_MODEL_XML" version="15.0.0.2613"?>
<?PowerDesigner AppLocale="UTF16" ID="{C294868A-C3F3-41AD-98CC-78B6D4E0CC40}" Label="" LastModificationDate="1739251983" Name="Tiobon" Objects="3158" Symbols="124" Target="Microsoft SQL Server 2008" Type="{CDE44E21-9669-11D1-9914-006097355D9B}" signature="PDM_DATA_MODEL_XML" version="15.0.0.2613"?>
<!-- do not edit this file -->
<Model xmlns:a="attribute" xmlns:c="collection" xmlns:o="object">
@ -49411,7 +49411,7 @@ Ghra_staff_InsureBase
<a:Code>Ghre_OpenClassFee</a:Code>
<a:CreationDate>1738915608</a:CreationDate>
<a:Creator>Administrator</a:Creator>
<a:ModificationDate>1738976945</a:ModificationDate>
<a:ModificationDate>1739251430</a:ModificationDate>
<a:Modifier>Administrator</a:Modifier>
<a:Comment>开班费用</a:Comment>
<c:Columns>
@ -49573,14 +49573,15 @@ Ghra_staff_InsureBase
</o:Column>
<o:Column Id="o3071">
<a:ObjectID>C55369A6-3ABE-435C-B237-0CC46CDE71DD</a:ObjectID>
<a:Name>费用项目ID</a:Name>
<a:Code>ItemId</a:Code>
<a:Name>费用项目</a:Name>
<a:Code>ItemCode</a:Code>
<a:CreationDate>1738915608</a:CreationDate>
<a:Creator>Administrator</a:Creator>
<a:ModificationDate>1738976907</a:ModificationDate>
<a:ModificationDate>1739251983</a:ModificationDate>
<a:Modifier>Administrator</a:Modifier>
<a:Comment>费用项目ID</a:Comment>
<a:DataType>bigint</a:DataType>
<a:Comment>费用项目</a:Comment>
<a:DataType>nvarchar(32)</a:DataType>
<a:Length>32</a:Length>
</o:Column>
<o:Column Id="o3072">
<a:ObjectID>B0A3FDFA-12BF-431A-8138-6842C69328BA</a:ObjectID>

@ -35,4 +35,22 @@ public class Ghre_OpenClassController : BaseController<IGhre_OpenClassServices,
[HttpPost, Route("QueryStaff/{Id}")]
public async Task<List<Ghre_OpenClassStaffDto>> QueryStaff(long Id) => await _service.QueryStaff(Id);
#endregion
#region 费用
/// <summary>
/// 查询团体费用
/// </summary>
/// <param name="Id">开班ID</param>
/// <returns></returns>
[HttpPost, Route("QueryGroupFee/{Id}")]
public async Task<List<Ghre_OpenClassFeeDto>> QueryGroupFee(long Id) => await _service.QueryGroupFee(Id);
/// <summary>
/// 查询个人费用
/// </summary>
/// <param name="Id">开班ID</param>
/// <returns></returns>
[HttpPost, Route("QueryPersonalFee/{Id}")]
public async Task<List<Ghre_OpenClassFeeDto>> QueryPersonalFee(long Id) => await _service.QueryPersonalFee(Id);
#endregion
}

@ -6,4 +6,8 @@
public interface IGhre_OpenClassServices : IBaseServices<Ghre_OpenClass, Ghre_OpenClassDto, InsertGhre_OpenClassInput, EditGhre_OpenClassInput>
{
Task<List<Ghre_OpenClassStaffDto>> QueryStaff(long Id);
Task<List<Ghre_OpenClassFeeDto>> QueryGroupFee(long Id);
Task<List<Ghre_OpenClassFeeDto>> QueryPersonalFee(long Id);
}

@ -24,6 +24,7 @@ public class Ghre_OpenClassFeeServices : BaseServices<Ghre_OpenClassFee, Ghre_Op
var DT_TableDataT1 = result.result.DT_TableDataT1[i];
//DT_TableDataT1.Source = DT_TableDataT1.Source == "Backend" ? "后台新增" : "报名";
//DT_TableDataT1.OpenClassType = await GetParaLabel("TrainingOpenClassType", result.result.DT_TableDataT1[i].OpenClassType);
result.result.DT_TableDataT1[i] = DT_TableDataT1;
}

@ -119,10 +119,15 @@ public class Ghre_OpenClassServices : BaseServices<Ghre_OpenClass, Ghre_OpenClas
}
#endregion
#region 学员
public async Task<List<Ghre_OpenClassFeeDto>> QueryFee(long Id)
#region 费用
public async Task<List<Ghre_OpenClassFeeDto>> QueryGroupFee(long Id)
{
var result = await _ghre_OpenClassFeeServices.QueryFilterPage(new QueryBody(), $"OpenClassId='{Id}' AND StaffId IS NULL");
return result.result.DT_TableDataT1;
}
public async Task<List<Ghre_OpenClassFeeDto>> QueryPersonalFee(long Id)
{
var result = await _ghre_OpenClassFeeServices.QueryFilterPage(new QueryBody(), $"OpenClassId='{Id}'");
var result = await _ghre_OpenClassFeeServices.QueryFilterPage(new QueryBody(), $"OpenClassId='{Id}' AND StaffId IS NOT NULL");
return result.result.DT_TableDataT1;
}
#endregion

Loading…
Cancel
Save