Commit bd954fc3 by guanzhenshan

逻辑仓库的sku明细增加调出在途数,调出30天数,导出增加调出数据

parent 854ff16d
......@@ -111,5 +111,15 @@ namespace Bailun.DC.Models.Stock
/// </summary>
public int? thirtyday_total_sales { get; set; }
/// <summary>
/// 调出在途数
/// </summary>
public int? quantity_tuneout_onway { get; set; }
/// <summary>
/// 30天内调出数量
/// </summary>
public int? quantity_tuneout_30days { get; set; }
}
}
......@@ -135,7 +135,7 @@ namespace Bailun.DC.Services
{
var sqlparam = new DynamicParameters();
var sqlwhere = " where 1=1 ";
var sql = @"select hq_type,warehouse_code,warehouse_name,sum(usable_stock) usable_stock,sum(amount_stock) amount_stock,sum(quantity_purchase) quantity_purchase,sum(purchase_amount) purchase_amount,sum(quantity_transfer) quantity_transfer,sum(amount_transit) amount_transit,sum(oneday_total_sales) oneday_total_sales,sum(amount_onedaysale) amount_onedaysale,sum(sevenday_total_sales) sevenday_total_sales,sum(fourteenday_total_sales) fourteenday_total_sales,sum(thirtyday_total_sales) thirtyday_total_sales from dc_skuwarehouse_stock_sales ";
var sql = @"select hq_type,warehouse_code,warehouse_name,sum(usable_stock) usable_stock,sum(amount_stock) amount_stock,sum(quantity_purchase) quantity_purchase,sum(purchase_amount) purchase_amount,sum(quantity_transfer) quantity_transfer,sum(amount_transit) amount_transit,sum(oneday_total_sales) oneday_total_sales,sum(amount_onedaysale) amount_onedaysale,sum(sevenday_total_sales) sevenday_total_sales,sum(fourteenday_total_sales) fourteenday_total_sales,sum(thirtyday_total_sales) thirtyday_total_sales,sum(quantity_tuneout_onway) quantity_tuneout_onway,sum(t1.quantity_tuneout_30days) quantity_tuneout_30days from dc_skuwarehouse_stock_sales ";
//var sqlcount = "select t1.warehouse_code from dc_skuwarehouse_stock_sales t1 ";
......
......@@ -127,11 +127,14 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
usable_stock = p.usable_stock.ToString("N0"),
p.warehouse_code,
p.warehouse_name,
quantity_tuneout_onway = p.quantity_tuneout_onway??0,
quantity_tuneout_30days = p.quantity_tuneout_30days??0
});
var colNames = new List<string> {"仓储仓库","库存数量","库存金额", "采购在途数量", "采购在途金额",
"调拨在途数量", "调拨在途金额","待发货数量","缺货数量","昨日总销量"
,"昨日总销售额","七天销量","十四天销量","三十天销量"
"调拨在途数量", "调拨在途金额","待发货数量","缺货数量","调出在途数",
"30天内调出数","昨日总销量","昨日总销售额","七天销量","十四天销量",
"三十天销量"
};
var listVal = new List<string>();
......@@ -139,8 +142,8 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
{
listVal.Add(
item.warehouse_name + "|" + item.usable_stock + "|" + item.amount_stock + "|" + item.quantity_purchase + "|" + item.purchase_amount + "|" +
item.quantity_transfer + "|" + item.amount_transit + "|" + item.noshippingcount + "|" + item.nostockcount + "|" + item.oneday_total_sales + "|" +
item.amount_onedaysale + "|" + item.sevenday_total_sales + "|" + item.fourteenday_total_sales + "|" + item.thirtyday_total_sales
item.quantity_transfer + "|" + item.amount_transit + "|" + item.noshippingcount + "|" + item.nostockcount + "|" + item.quantity_tuneout_onway+"|"+
item.quantity_tuneout_30days + "|" + item.oneday_total_sales + "|" + item.amount_onedaysale + "|" + item.sevenday_total_sales + "|" + item.fourteenday_total_sales + "|" + item.thirtyday_total_sales
);
}
......@@ -212,6 +215,8 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
usable_stock = p.usable_stock??0,
p.warehouse_code,
p.warehouse_name,
quantity_tuneout_onway = p.quantity_tuneout_onway??0,
quantity_tuneout_30days = p.quantity_tuneout_30days
});
return JsonConvert.SerializeObject(new { total = total, rows = list });
......
......@@ -155,6 +155,12 @@
{
field: 'nostockcount', title: '缺货数量', width: '130', sortable: true
},
{
field: 'quantity_tuneout_onway', title: '调出在途数', width: '130', sortable: true
},
{
field: 'quantity_tuneout_30days', title: '30天调出数', width: '130', sortable: true
},
{ field: 'oneday_total_sales', title: '昨日总销量', width: '130', sortable: true },
{ field: 'amount_onedaysale', title: '昨日总销售额', width: '130', sortable: true },
{ field: 'sevenday_total_sales', title: '七天销量', width: '100', sortable: true },
......
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