Commit 86e5dac1 authored by 黄奎's avatar 黄奎

属性接口调整

parent cba31319
using VT.FW.DB; using System;
using Mall.Common.Enum.User; using VT.FW.DB;
using System;
using System.Collections.Generic;
using System.Text;
namespace Mall.Model.Entity.Product namespace Mall.Model.Entity.Product
{ {
...@@ -59,6 +56,8 @@ namespace Mall.Model.Entity.Product ...@@ -59,6 +56,8 @@ namespace Mall.Model.Entity.Product
/// 默认0,1-是,是日期格式,方便后面转换成日期 /// 默认0,1-是,是日期格式,方便后面转换成日期
/// </summary> /// </summary>
public int IsDateFormat { get; set; } public int IsDateFormat { get; set; }
/// <summary> /// <summary>
/// Status /// Status
/// </summary> /// </summary>
......
...@@ -1956,7 +1956,6 @@ namespace Mall.Module.Product ...@@ -1956,7 +1956,6 @@ namespace Mall.Module.Product
#region 获取商品的自定义表单 #region 获取商品的自定义表单
if (gList != null && gList.Any()) if (gList != null && gList.Any())
{ {
string formsIds = string.Join(",", gList.Where(x => x.FormsId > 1).Select(x => x.FormsId)); string formsIds = string.Join(",", gList.Where(x => x.FormsId > 1).Select(x => x.FormsId));
if (!string.IsNullOrWhiteSpace(formsIds)) if (!string.IsNullOrWhiteSpace(formsIds))
{ {
......
...@@ -2528,6 +2528,7 @@ namespace Mall.Module.Product ...@@ -2528,6 +2528,7 @@ namespace Mall.Module.Product
EduTeacherId = model?.EduTeacherId ?? 0, EduTeacherId = model?.EduTeacherId ?? 0,
attr_groups = model.SpecificationList.Select(x => new attr_groups = model.SpecificationList.Select(x => new
{ {
isdateformat = x.IsDateFormat,
attr_group_id = x.Sort, attr_group_id = x.Sort,
attr_group_name = x.Name, attr_group_name = x.Name,
//购买次数(进阶小课堂使用) //购买次数(进阶小课堂使用)
...@@ -2539,6 +2540,7 @@ namespace Mall.Module.Product ...@@ -2539,6 +2540,7 @@ namespace Mall.Module.Product
pic_url = z.ImagePath pic_url = z.ImagePath
}) })
}), }),
attr = priceList,
goodsRelevanceList = goodsRelevanceList?.Select(qitem => new goodsRelevanceList = goodsRelevanceList?.Select(qitem => new
{ {
qitem.RelevanceId, qitem.RelevanceId,
...@@ -2584,7 +2586,6 @@ namespace Mall.Module.Product ...@@ -2584,7 +2586,6 @@ namespace Mall.Module.Product
area_type=x.AreaType area_type=x.AreaType
}) } }, }) } },
form_id = model.FormsId, form_id = model.FormsId,
//form_data_json= new { formData = !string.IsNullOrWhiteSpace(customFormModel.FormData)?JsonConvert.DeserializeObject<List<Model.Extend.TradePavilion.FormDataItem>>(customFormModel.FormData):new List<Model.Extend.TradePavilion.FormDataItem>(), formType=customFormModel.FormType },
sales = (model.SalesNum ?? 0) + payment_num,//已售出数量 + 订单商品数量// sales = (model.SalesNum ?? 0) + payment_num,//已售出数量 + 订单商品数量//
name = model.Name, name = model.Name,
subname = model?.SubName ?? "", subname = model?.SubName ?? "",
...@@ -2596,7 +2597,7 @@ namespace Mall.Module.Product ...@@ -2596,7 +2597,7 @@ namespace Mall.Module.Product
video_url = model?.VideoAddress ?? "", video_url = model?.VideoAddress ?? "",
level_show = (userModel?.MemberGrade ?? 0) > 0 ? 1 : 2,//是否显示会员价 level_show = (userModel?.MemberGrade ?? 0) > 0 ? 1 : 2,//是否显示会员价
is_sales = model.GoodsStatus == 1 && model.InventoryNum > 0 ? 1 : 2,//是否可购买 is_sales = model.GoodsStatus == 1 && model.InventoryNum > 0 ? 1 : 2,//是否可购买
attr = priceList,
//goods_num = model.InventoryNum, //goods_num = model.InventoryNum,
goods_no = model.GoodsNumbers, goods_no = model.GoodsNumbers,
goods_weight = model.GoodsWeight, goods_weight = model.GoodsWeight,
......
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