diff --git a/WeChatApplet/Services/Impl/ClientSideService.cs b/WeChatApplet/Services/Impl/ClientSideService.cs index 73bf627..5885b62 100644 --- a/WeChatApplet/Services/Impl/ClientSideService.cs +++ b/WeChatApplet/Services/Impl/ClientSideService.cs @@ -170,10 +170,9 @@ namespace YD_WeChatApplet.Api.Services.Impl .Select(x => x.TaxonomyId) .ToListAsync(); - // 获取所有类型为2的课程 var paidCourses = await _sportsContext.CurricularTaxonomy - .Where(x => x.Remarks == redeemCode) + .Where(x => x.RedeemCode == redeemCode) .ToListAsync(); // 找出用户未购买的课程 diff --git a/WeChatApplet/SmartSportsEntitys/Y_CurricularTaxonomy.cs b/WeChatApplet/SmartSportsEntitys/Y_CurricularTaxonomy.cs index ca1684b..92b431e 100644 --- a/WeChatApplet/SmartSportsEntitys/Y_CurricularTaxonomy.cs +++ b/WeChatApplet/SmartSportsEntitys/Y_CurricularTaxonomy.cs @@ -31,5 +31,13 @@ namespace YD_WeChatApplet.Api.SmartSportsEntitys [Comment("课程类型")] [Column(TypeName = "int)")] public int CurricularType { get; set; } + + /// + ///兑换码 + /// + [Display(Name = "兑换码")] + [Comment("兑换码")] + [Column(TypeName = "nvarchar(1000)")] + public string RedeemCode { get; set; } } }