Commit 33451a62 authored by liudong1993's avatar liudong1993

微店价格配置

parent 4fc29488
......@@ -18,5 +18,13 @@ namespace Mall.Model.Extend.User
/// 微店ids
/// </summary>
public string SmallShopsIds{ get; set; }
/// <summary>
/// 商品ids
/// </summary>
public string GoodsIds { get; set; }
/// <summary>
/// 商品名称
/// </summary>
public string GoodsName { get; set; }
}
}
......@@ -1089,7 +1089,6 @@ namespace Mall.Module.Product
List<string> CarouselIdList = JsonConvert.DeserializeObject<List<string>>(model.CarouselImage);
//封面图
model.CoverImage = CarouselIdList[0];
//轮播图
}
}
//小程序名称
......@@ -1765,7 +1764,7 @@ namespace Mall.Module.Product
var fxmodel = distributor_FXGradeRepository.GetEntity(model.PresentFXGrade);
if (fxmodel != null)
{
PresentFXGradeMsg = "购买后赠送" + fxmodel.GradeName + "会员";
PresentFXGradeMsg = "购买后赠送" + fxmodel.GradeName + " ";
if (model.PresentFXMonth > 0)
{
PresentFXGradeMsg += (model.PresentFXMonth ?? 0) + "个月";
......
This diff is collapsed.
......@@ -36,11 +36,51 @@ namespace Mall.Repository.User
if (!string.IsNullOrEmpty(dmodel.SmallShopsIds)) {
where += $@" and di.{nameof(RB_SmallShops_Price_Extend.SmallShopsId)} in({dmodel.SmallShopsIds})";
}
if (!string.IsNullOrEmpty(dmodel.GoodsIds)) {
where += $@" and di.{nameof(RB_SmallShops_Price_Extend.GoodsId)} in({dmodel.GoodsIds})";
}
string sql = $@"select di.* from RB_SmallShops_Price_Extend di
where {where} order by di.Id desc";
return Get<RB_SmallShops_Price_Extend>(sql).ToList();
}
/// <summary>
/// 获取微店商品价格列表
/// </summary>
/// <param name="pageIndex"></param>
/// <param name="pageSize"></param>
/// <param name="count"></param>
/// <param name="demodel"></param>
/// <returns></returns>
public List<RB_SmallShops_Price_Extend> GetSmallShopsGoodsPricePageList(int pageIndex, int pageSize, out long count, RB_SmallShops_Price_Extend demodel)
{
string where = $@" 1=1 and sp.Status=0";
if (demodel.TenantId > 0)
{
where += $@" and sp.{nameof(RB_SmallShops_Price_Extend.TenantId)}={demodel.TenantId}";
}
if (demodel.MallBaseId > 0)
{
where += $@" and sp.{nameof(RB_SmallShops_Price_Extend.MallBaseId)}={demodel.MallBaseId}";
}
if (demodel.GoodsId > 0)
{
where += $@" and sp.{nameof(RB_SmallShops_Price_Extend.GoodsId)}={demodel.GoodsId}";
}
if (!string.IsNullOrEmpty(demodel.GoodsName))
{
where += $@" and g.{nameof(Model.Entity.Product.RB_Goods.Name)} like '%{demodel.GoodsName}%'";
}
string sql = $@"
SELECT sp.GoodsId FROM rb_smallshops_price sp
INNER JOIN rb_goods g on sp.GoodsId=g.Id
{where}
GROUP BY sp.GoodsId ORDER BY sp.CreateDate DESC
";
return GetPage<RB_SmallShops_Price_Extend>(pageIndex, pageSize, out count, sql).ToList();
}
}
}
......@@ -1348,6 +1348,8 @@ namespace Mall.WebApi.Controllers.MallBase
new ExcelColumn(value:(item.IsSellWell??0).ToString()){ },
new ExcelColumn(value:(item.IsGoodsNegotiable??0).ToString()){ },
}
,
ColumnHight = 30
};
slist.Add(datarow);
}
......
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