Commit 03d46a8d authored by liudong1993's avatar liudong1993

小程序商品详情

parent a160159e
...@@ -494,7 +494,7 @@ namespace Mall.Model.Entity.Product ...@@ -494,7 +494,7 @@ namespace Mall.Model.Entity.Product
/// <summary> /// <summary>
/// 使用日期 天 /// 使用日期 天
/// </summary> /// </summary>
public decimal? UserDay { get; set; } public decimal? UseDay { get; set; }
/// <summary> /// <summary>
/// 线路名称 /// 线路名称
/// </summary> /// </summary>
......
This diff is collapsed.
...@@ -3,6 +3,7 @@ using System.Collections.Generic; ...@@ -3,6 +3,7 @@ using System.Collections.Generic;
using System.Linq; using System.Linq;
using System.Threading.Tasks; using System.Threading.Tasks;
using Mall.Common.API; using Mall.Common.API;
using Mall.Common.Plugin;
using Mall.Model.Extend.GuideCar; using Mall.Model.Extend.GuideCar;
using Mall.Module.Product; using Mall.Module.Product;
using Mall.WebApi.Filter; using Mall.WebApi.Filter;
...@@ -10,6 +11,7 @@ using Microsoft.AspNetCore.Cors; ...@@ -10,6 +11,7 @@ using Microsoft.AspNetCore.Cors;
using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc; using Microsoft.AspNetCore.Mvc;
using Newtonsoft.Json; using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
namespace Mall.WebApi.Controllers.Product namespace Mall.WebApi.Controllers.Product
{ {
...@@ -22,6 +24,38 @@ namespace Mall.WebApi.Controllers.Product ...@@ -22,6 +24,38 @@ namespace Mall.WebApi.Controllers.Product
{ {
private readonly GuideCarModule guideCarModule = new GuideCarModule(); private readonly GuideCarModule guideCarModule = new GuideCarModule();
#region 商品详情
/// <summary>
/// 获取小程序商品详情
/// </summary>
/// <returns></returns>
[HttpPost]
public ApiResult GetAppletSDGoodsInfo(object requestMsg)
{
var req = JsonConvert.DeserializeObject<RequestParm>(requestMsg.ToString());
if (req.MallBaseId <= 0)
{
return ApiResult.ParamIsNull();
}
JObject prams = JObject.Parse(req.msg.ToString());
int GoodsId = prams.GetInt("GoodsId", 0);
if (GoodsId <= 0)
{
return ApiResult.ParamIsNull();
}
int UserId = req.UserId;
var Robj = guideCarModule.GetAppletGoodsInfo_V2(GoodsId, UserId, req.SmallShopsId, req.TenantId, req.MallBaseId);
return ApiResult.Success("", Robj);
}
#endregion
#region 订单信息
#endregion
/// <summary> /// <summary>
/// 获取详情 /// 获取详情
/// </summary> /// </summary>
......
...@@ -352,7 +352,7 @@ namespace Mall.WebApi.Controllers.MallBase ...@@ -352,7 +352,7 @@ namespace Mall.WebApi.Controllers.MallBase
model?.CarBuyYear, model?.CarBuyYear,
model?.CarType, model?.CarType,
CarTypeName = model?.CarType.GetEnumName(), CarTypeName = model?.CarType.GetEnumName(),
model?.UserDay, model?.UseDay,
model?.LineName, model?.LineName,
model?.LineDescriptionList, model?.LineDescriptionList,
model?.IsSpell, model?.IsSpell,
...@@ -437,7 +437,7 @@ namespace Mall.WebApi.Controllers.MallBase ...@@ -437,7 +437,7 @@ namespace Mall.WebApi.Controllers.MallBase
} }
if (demodel.CarType == Common.Enum.Goods.GuideCarGoodsTypeEnum.SQ || demodel.CarType == Common.Enum.Goods.GuideCarGoodsTypeEnum.ZB || demodel.CarType == Common.Enum.Goods.GuideCarGoodsTypeEnum.Line) if (demodel.CarType == Common.Enum.Goods.GuideCarGoodsTypeEnum.SQ || demodel.CarType == Common.Enum.Goods.GuideCarGoodsTypeEnum.ZB || demodel.CarType == Common.Enum.Goods.GuideCarGoodsTypeEnum.Line)
{ {
if ((demodel.UserDay ?? 0) <= 0) if ((demodel.UseDay ?? 0) <= 0)
{ {
return ApiResult.ParamIsNull("请输入使用时间"); return ApiResult.ParamIsNull("请输入使用时间");
} }
......
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