Commit 7cf651cd by guanzhenshan

增加预收款订单数

parent a1161a89
......@@ -413,5 +413,10 @@ namespace Bailun.DC.Models.Orders
/// </summary>
public decimal loss_withdrawal { get; set; }
/// <summary>
/// 未发货订单数
/// </summary>
public int noshippingcount { get; set; }
}
}
......@@ -513,5 +513,10 @@ namespace Bailun.DC.Models.Orders
/// </summary>
public decimal profitrate { get; set; }
/// <summary>
/// 未发货订单数
/// </summary>
public int noshippingcount { get; set; }
}
}
......@@ -149,6 +149,11 @@ namespace Bailun.DC.Models.Orders
/// </summary>
public decimal cost_package { get; set; }
/// <summary>
/// 未发货订单数
/// </summary>
public int noshippingcount { get; set; }
}
......
......@@ -111,7 +111,7 @@ namespace Bailun.DC.Services
{
var sqlparam = new DynamicParameters();
var sql = @"select platform_type,seller_account,website,order_currency,sum(amount_sales*seller_order_exchange_rate*bailun_sku_quantity_shipped) 'amount_product',sum(cost_product*bailun_sku_quantity_shipped) 'cost_product',sum(cost_platform_fee*seller_order_exchange_rate*bailun_sku_quantity_shipped) 'platform_fee',sum(cost_first*bailun_sku_quantity_shipped) 'head_fee',count(t1.bailun_order_id) 'order_count',sum(cost_total*bailun_sku_quantity_shipped) 'cost_count',sum(cost_tail*bailun_sku_quantity_shipped) 'nofba_logisticsfee',sum(profit_total*bailun_sku_quantity_shipped) 'profit_count',(sum(profit_total*bailun_sku_quantity_shipped)/sum(amount_sales*seller_order_exchange_rate*bailun_sku_quantity_shipped)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate*bailun_sku_quantity_shipped) amount_refund from dc_base_oms_sku t1";
var sql = @"select platform_type,seller_account,website,order_currency,sum(amount_sales*seller_order_exchange_rate) 'amount_product',sum(cost_product) 'cost_product',sum(cost_platform_fee*seller_order_exchange_rate) 'platform_fee',sum(cost_first) 'head_fee',count(t1.id) 'order_count',sum(cost_total) 'cost_count',sum(cost_tail) 'nofba_logisticsfee',sum(profit_total) 'profit_count',(sum(profit_total)/sum(amount_sales*seller_order_exchange_rate)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate) amount_refund,count(amount_prepaid>0 or null) as noshippingcount from dc_base_oms_order t1";
var presql = "select platform_type,seller_account,website,order_currency,sum(amount_prepaid) as amount_prepaid from dc_base_oms_sku t1 ";
if (!string.IsNullOrEmpty(warehoursetype))
......@@ -151,7 +151,7 @@ namespace Bailun.DC.Services
}
var prefromsql = fromsql;
fromsql += " and bailun_sku_quantity_shipped>0";
fromsql += " and t1.bailun_payment_status!='Canceled'";
fromsql += " group by seller_account,website,order_currency,platform_type";
if (!string.IsNullOrWhiteSpace(parameter.sort))
......@@ -205,7 +205,7 @@ namespace Bailun.DC.Services
var sqlparam = new DynamicParameters();
var presql = "select sum(amount_prepaid) as amount_prepaid from dc_base_oms_sku t1 ";
var sql = "select sum(amount_sales*seller_order_exchange_rate*bailun_sku_quantity_shipped) 'amount_product',sum(cost_product*bailun_sku_quantity_shipped) 'cost_product',sum(cost_platform_fee*seller_order_exchange_rate*bailun_sku_quantity_shipped) 'platform_fee',sum(cost_first*bailun_sku_quantity_shipped) 'head_fee',count(t1.id) 'order_count',sum(cost_total*bailun_sku_quantity_shipped) 'cost_count',sum(cost_tail*bailun_sku_quantity_shipped) 'nofba_logisticsfee',sum(profit_total*bailun_sku_quantity_shipped) 'profit_count',(sum(profit_total*bailun_sku_quantity_shipped)/sum(amount_sales*seller_order_exchange_rate*bailun_sku_quantity_shipped)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate*bailun_sku_quantity_shipped) amount_refund from dc_base_oms_sku t1 ";
var sql = "select sum(amount_sales*seller_order_exchange_rate) 'amount_product',sum(cost_product) 'cost_product',sum(cost_platform_fee*seller_order_exchange_rate) 'platform_fee',sum(cost_first) 'head_fee',count(t1.id) 'order_count',sum(cost_total) 'cost_count',sum(cost_tail) 'nofba_logisticsfee',sum(profit_total) 'profit_count',(sum(profit_total)/sum(amount_sales*seller_order_exchange_rate)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate) amount_refund,count(amount_prepaid>0 or null) as noshippingcount from dc_base_oms_order t1 ";
if (!string.IsNullOrEmpty(warehoursetype))
{
......@@ -244,7 +244,7 @@ namespace Bailun.DC.Services
}
var prefromsql = fromsql;
fromsql += " and bailun_sku_quantity_shipped>0";
fromsql += " and t1.bailun_payment_status!='Canceled'";
using (var cn = new MySqlConnection(Common.GlobalConfig.ConnectionString))
{
......@@ -290,7 +290,7 @@ namespace Bailun.DC.Services
var sqlparam = new DynamicParameters();
var sql = @"select platform_type,seller_account,website,sum(amount_product*seller_order_exchange_rate) 'amount_product',sum(cost_product) 'cost_product',sum(cost_platform_fee*seller_order_exchange_rate) 'platform_fee',sum(cost_first) 'head_fee',count(id) 'order_count',sum(cost_total) 'cost_count',sum(cost_shipping) 'nofba_logisticsfee',sum(profit_total) 'profit_count',(sum(profit_total)/sum(amount_total*seller_order_exchange_rate)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_fba_fee*seller_order_exchange_rate) cost_fba_fee,sum(cost_paypal_fee*seller_order_exchange_rate) cost_paypal_fee,sum(cost_package) cost_package from dc_base_oms_order where paid_time>='" + start.ToString("yyyy-MM-dd") + "' and paid_time<'" + end.AddDays(1).ToString("yyyy-MM-dd") + "' and platform_type='FBA' and bailun_order_status!='Canceled' ";
var sql = @"select platform_type,seller_account,website,sum(amount_sales*seller_order_exchange_rate) 'amount_product',sum(cost_product) 'cost_product',sum(cost_platform_fee*seller_order_exchange_rate) 'platform_fee',sum(cost_first) 'head_fee',count(id) 'order_count',sum(cost_total) 'cost_count',sum(cost_shipping) 'nofba_logisticsfee',sum(profit_total) 'profit_count',(sum(profit_total)/sum(amount_total*seller_order_exchange_rate)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_fba_fee*seller_order_exchange_rate) cost_fba_fee,sum(cost_paypal_fee*seller_order_exchange_rate) cost_paypal_fee,sum(cost_package) cost_package,count(amount_prepaid>0 or null) as noshippingcount from dc_base_oms_order where paid_time>='" + start.ToString("yyyy-MM-dd") + "' and paid_time<'" + end.AddDays(1).ToString("yyyy-MM-dd") + "' and platform_type='FBA' and bailun_order_status!='Canceled' ";
if (!string.IsNullOrWhiteSpace(account))
{
......@@ -337,7 +337,7 @@ namespace Bailun.DC.Services
{
var sqlparam = new DynamicParameters();
var sql = @"select sum(amount_product*seller_order_exchange_rate) 'amount_product',sum(cost_product) 'cost_product',sum(cost_platform_fee*seller_order_exchange_rate) 'platform_fee',sum(cost_first) 'head_fee',count(id) 'order_count',sum(cost_total) 'cost_count',sum(cost_shipping) 'nofba_logisticsfee',sum(profit_total) 'profit_count',(sum(profit_total)/sum(amount_product*seller_order_exchange_rate)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_fba_fee*seller_order_exchange_rate) cost_fba_fee,sum(cost_paypal_fee*seller_order_exchange_rate) cost_paypal_fee,sum(cost_package) cost_package from dc_base_oms_order where paid_time>='" + start.ToString("yyyy-MM-dd") + "' and paid_time<'" + end.AddDays(1).ToString("yyyy-MM-dd") + "' and platform_type='FBA' and bailun_order_status!='Canceled' ";
var sql = @"select sum(amount_sales*seller_order_exchange_rate) 'amount_product',sum(cost_product) 'cost_product',sum(cost_platform_fee*seller_order_exchange_rate) 'platform_fee',sum(cost_first) 'head_fee',count(id) 'order_count',sum(cost_total) 'cost_count',sum(cost_shipping) 'nofba_logisticsfee',sum(profit_total) 'profit_count',(sum(profit_total)/sum(amount_product*seller_order_exchange_rate)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_fba_fee*seller_order_exchange_rate) cost_fba_fee,sum(cost_paypal_fee*seller_order_exchange_rate) cost_paypal_fee,sum(cost_package) cost_package,count(amount_prepaid>0 or null) as noshippingcount from dc_base_oms_order where paid_time>='" + start.ToString("yyyy-MM-dd") + "' and paid_time<'" + end.AddDays(1).ToString("yyyy-MM-dd") + "' and platform_type='FBA' and bailun_order_status!='Canceled' ";
if (!string.IsNullOrWhiteSpace(account))
{
......@@ -936,12 +936,19 @@ namespace Bailun.DC.Services
/// <param name="start">付款开始时间</param>
/// <param name="end">付款结束时间</param>
/// <returns></returns>
public List<Models.Orders.dc_base_oms_sku> ListPlatformProfit(string platform, DateTime? start, DateTime? end)
public List<Models.Orders.dc_base_oms_sku> ListPlatformProfit(string platform, DateTime? start, DateTime? end,DateTime? shipstart,DateTime? shipend)
{
var sqlparam = new DynamicParameters();
var sql = "select tb.platform_type,count(tb.bailun_order_id) order_count,sum(tb.amount_sales*seller_order_exchange_rate) as amount_sales,sum(tb.cost_platform_fee*seller_order_exchange_rate) as cost_platform_fee,sum(cost_first) as cost_first,sum(cost_tail) cost_tail,sum(cost_handle_bailun) cost_handle_bailun,sum(cost_handle_platform) cost_handle_platform,sum(tb.profit_total) as profit_total,(sum(tb.profit_total)/sum(tb.amount_sales)) profitrate ,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_product) cost_product,sum(profit_total) profit_total,(sum(profit_total)/sum(tb.amount_sales*seller_order_exchange_rate)) profit_rate from dc_base_oms_order tb where bailun_order_status!='Canceled'";
var sql = "select tb.platform_type,count(tb.bailun_order_id) order_count,sum(tb.amount_sales*seller_order_exchange_rate) as amount_sales,sum(tb.cost_platform_fee*seller_order_exchange_rate) as cost_platform_fee,sum(cost_first) as cost_first,sum(cost_tail) cost_tail,sum(cost_handle_bailun) cost_handle_bailun,sum(cost_handle_platform) cost_handle_platform,sum(tb.profit_total) as profit_total,(sum(tb.profit_total)/sum(tb.amount_sales)) profitrate ,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_product) cost_product,sum(profit_total) profit_total,(sum(profit_total)/sum(tb.amount_sales*seller_order_exchange_rate)) profit_rate,count(amount_prepaid>0 or null) as noshippingcount from dc_base_oms_order tb ";
var presql = "select platform_type,sum(amount_prepaid) amount_prepaid from dc_base_oms_sku where bailun_order_status!='Canceled' and amount_prepaid>0 ";
if (shipstart.HasValue)
{
sql+= " left join dc_base_oms_pick t1 on tb.bailun_order_id "
}
sql += " where bailun_order_status!='Canceled'";
if (!string.IsNullOrWhiteSpace(platform))
{
sql += " and platform_type=@platform_type";
......@@ -1673,7 +1680,7 @@ namespace Bailun.DC.Services
{
var sqlparam = new DynamicParameters();
var sql = @"select platform_type,seller_account,website,order_currency,sum(amount_sales*seller_order_exchange_rate) 'amount_sales',sum(cost_product) 'cost_product',sum(cost_platform_fee*seller_other_exchange_rate) 'cost_platform_fee',sum(cost_paypal_fee*seller_order_exchange_rate) as cost_paypal_fee,sum(cost_first) 'cost_first',count(t1.bailun_order_id) 'order_count',sum(cost_total) 'cost_total',sum(cost_tail) 'cost_tail',sum(profit_total) 'profit_total',(sum(profit_total)/sum(amount_sales*seller_order_exchange_rate)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_handle_bailun) cost_handle_bailun,sum(cost_handle_platform) cost_handle_platform from dc_base_oms_order t1";
var sql = @"select platform_type,seller_account,website,order_currency,sum(amount_sales*seller_order_exchange_rate) 'amount_sales',sum(cost_product) 'cost_product',sum(cost_platform_fee*seller_other_exchange_rate) 'cost_platform_fee',sum(cost_paypal_fee*seller_order_exchange_rate) as cost_paypal_fee,sum(cost_first) 'cost_first',count(t1.bailun_order_id) 'order_count',sum(cost_total) 'cost_total',sum(cost_tail) 'cost_tail',sum(profit_total) 'profit_total',(sum(profit_total)/sum(amount_sales*seller_order_exchange_rate)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_handle_bailun) cost_handle_bailun,sum(cost_handle_platform) cost_handle_platform,count(amount_prepaid>0 or null) as noshippingcount from dc_base_oms_order t1";
var presql = "select platform_type,seller_account,website,order_currency,sum(amount_prepaid) as amount_prepaid from dc_base_oms_sku t1 ";
if (!string.IsNullOrEmpty(warehousetype))
......@@ -1775,7 +1782,7 @@ namespace Bailun.DC.Services
{
var sqlparam = new DynamicParameters();
var sql = @"select sum(amount_sales*seller_order_exchange_rate) 'amount_sales',sum(cost_paypal_fee*seller_other_exchange_rate) 'cost_paypal_fee',sum(cost_product) 'cost_product',sum(cost_platform_fee*seller_order_exchange_rate) 'cost_platform_fee',sum(cost_first) 'cost_first',count(t1.bailun_order_id) 'order_count',sum(cost_total) 'cost_total',sum(cost_tail) 'cost_tail',sum(profit_total) 'profit_total',(sum(profit_total)/sum(amount_sales*seller_order_exchange_rate)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_handle_bailun) cost_handle_bailun,sum(cost_handle_platform) cost_handle_platform from dc_base_oms_order t1";
var sql = @"select sum(amount_sales*seller_order_exchange_rate) 'amount_sales',sum(cost_paypal_fee*seller_other_exchange_rate) 'cost_paypal_fee',sum(cost_product) 'cost_product',sum(cost_platform_fee*seller_order_exchange_rate) 'cost_platform_fee',sum(cost_first) 'cost_first',count(t1.bailun_order_id) 'order_count',sum(cost_total) 'cost_total',sum(cost_tail) 'cost_tail',sum(profit_total) 'profit_total',(sum(profit_total)/sum(amount_sales*seller_order_exchange_rate)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_handle_bailun) cost_handle_bailun,sum(cost_handle_platform) cost_handle_platform,count(amount_prepaid>0 or null) as noshippingcount from dc_base_oms_order t1";
var presql = "select platform_type,seller_account,website,order_currency,sum(amount_prepaid) as amount_prepaid from dc_base_oms_sku t1 ";
//var sql = @"select t1.platform_type,t1.seller_account,t1.website,sum(t1.amount_product*t1.seller_order_exchange_rate) 'amount_product',sum(t1.cost_product) 'cost_product',sum(t1.cost_platform_fee*t1.seller_other_exchange_rate) 'cost_platform_fee',sum(t1.cost_first) 'cost_first',count(t1.id) 'order_count',sum(t1.cost_total) 'cost_total',sum(t1.cost_shipping) 'cost_shipping',sum(t1.profit_total) 'profit_total',(sum(t1.profit_total)/sum(t1.amount_total*t1.seller_order_exchange_rate)) 'profit_rate',sum(t1.amount_prepaid) amount_prepaid,sum(t1.amount_refund*t1.seller_order_exchange_rate) amount_refund from dc_base_oms_order t1";
......@@ -1867,7 +1874,7 @@ namespace Bailun.DC.Services
{
var sqlparam = new DynamicParameters();
var sql = @"select platform_type,website,sum(amount_sales*seller_order_exchange_rate) 'amount_sales',sum(cost_product) 'cost_product',sum(cost_platform_fee*seller_other_exchange_rate) 'cost_platform_fee',sum(cost_paypal_fee*seller_order_exchange_rate) as cost_paypal_fee,sum(cost_first) 'cost_first',count(t1.bailun_order_id) 'order_count',sum(cost_total) 'cost_total',sum(cost_tail) 'cost_tail',sum(profit_total) 'profit_total',(sum(profit_total)/sum(amount_sales*seller_order_exchange_rate)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_handle_bailun) cost_handle_bailun,sum(cost_handle_platform) cost_handle_platform from dc_base_oms_order t1";
var sql = @"select platform_type,website,sum(amount_sales*seller_order_exchange_rate) 'amount_sales',sum(cost_product) 'cost_product',sum(cost_platform_fee*seller_other_exchange_rate) 'cost_platform_fee',sum(cost_paypal_fee*seller_order_exchange_rate) as cost_paypal_fee,sum(cost_first) 'cost_first',count(t1.bailun_order_id) 'order_count',sum(cost_total) 'cost_total',sum(cost_tail) 'cost_tail',sum(profit_total) 'profit_total',(sum(profit_total)/sum(amount_sales*seller_order_exchange_rate)) 'profit_rate',sum(amount_prepaid) amount_prepaid,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_handle_bailun) cost_handle_bailun,sum(cost_handle_platform) cost_handle_platform,count(amount_prepaid>0 or null) as noshippingcount from dc_base_oms_order t1";
var presql = "select platform_type,website,sum(amount_prepaid) as amount_prepaid from dc_base_oms_sku t1 ";
if (!string.IsNullOrEmpty(warehousetype))
......
......@@ -154,7 +154,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
cost_product = p.cost_product.ToString("N2"),
platform_fee = p.platform_fee.ToString("N2"),
head_fee = p.head_fee>0?p.head_fee.ToString("N2"):"0",
p.order_count,
order_count = p.order_count.ToString("N0"),
loss_withdrawal = (p.amount_product * (objwithdraw == null ? 0 : objwithdraw.Loss_withdrawal_percent ?? 0))>0? (p.amount_product * (objwithdraw == null ? 0 : objwithdraw.Loss_withdrawal_percent ?? 0)).ToString("N2"):"0",
cost_count = p.cost_count.ToString("N2"),
forecast_profit_count = p.forecast_profit_count.ToString("N2"),
......@@ -166,6 +166,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
p.order_currency,
amount_prepaid = p.amount_prepaid.ToString("N2"),
amount_refund = p.amount_refund>0?p.amount_refund.ToString("N2"):"0",
noshippingcount = p.noshippingcount.ToString("N0")
});
return JsonConvert.SerializeObject(new { total = total, rows = obj,count_row=new {
......@@ -186,6 +187,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
countM.order_currency,
amount_prepaid = countM.amount_prepaid.ToString("N2"),
amount_refund = countM.amount_refund > 0 ? countM.amount_refund.ToString("N2") : "0",
noshippingcount = countM.noshippingcount.ToString("N0")
}
});
}
......@@ -264,6 +266,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
cost_fba_fee = p.cost_fba_fee>0?p.cost_fba_fee.ToString("N2"):"0",
cost_paypal_fee = p.cost_paypal_fee>0?p.cost_paypal_fee.ToString("N2"):"0",
cost_package = p.cost_package>0?p.cost_package.ToString("N2"):"0",
noshippingcount = p.noshippingcount.ToString("N0"),
});
return JsonConvert.SerializeObject(new { total = total, rows = obj,
......@@ -289,6 +292,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
cost_fba_fee = countM.cost_fba_fee > 0 ? countM.cost_fba_fee.ToString("N2") : "0",
cost_paypal_fee = countM.cost_paypal_fee > 0 ? countM.cost_paypal_fee.ToString("N2") : "0",
cost_package = countM.cost_package > 0 ? countM.cost_package.ToString("N2") : "0",
noshippingcount = countM.noshippingcount.ToString("N0"),
}
});
}
......@@ -565,9 +569,9 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
/// <param name="end">付款结束时间</param>
/// <returns></returns>
[HttpPost]
public JsonResult PlatformProfitCountJson(string platform,DateTime? start,DateTime? end)
public JsonResult PlatformProfitCountJson(string platform,DateTime? start,DateTime? end,DateTime? shipstart,DateTime? shipend)
{
var result = new Services.OrdersServices().ListPlatformProfit(platform, start, end);
var result = new Services.OrdersServices().ListPlatformProfit(platform, start, end,shipstart,shipend);
if (result.Count > 0)
{
......@@ -588,6 +592,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
cost_tail = result.Sum(a => a.cost_tail),
amount_prepaid = result.Sum(a=>a.amount_prepaid),
cost_product = result.Sum(a=>a.cost_product),
noshippingcount = result.Sum(a=>a.noshippingcount)
};
result.Add(m);
}
......@@ -609,7 +614,8 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
cost_handle_platform = p.cost_handle_platform.ToString("N2"),
cost_tail = p.cost_tail.ToString("N2"),
amount_prepaid = p.amount_prepaid.ToString("N2"),
cost_product = p.cost_product.ToString("N2")
cost_product = p.cost_product.ToString("N2"),
noshippingcount = p.noshippingcount.ToString("N0")
});
return Json(list);
......@@ -956,6 +962,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
profit_rate = (100 * p.profit_rate).ToString("N2"),
cost_tail = p.cost_tail.ToString("N2"),
cost_handle_bailun = p.cost_handle_bailun.ToString("N2"),
noshippingcount = p.noshippingcount.ToString("N0"),
});
return JsonConvert.SerializeObject(new
......@@ -984,6 +991,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
profit_rate = (100 * countM.profit_rate).ToString("N2"),
cost_tail = countM.cost_tail.ToString("N2"),
cost_handle_bailun = countM.cost_handle_bailun.ToString("N2"),
noshippingcount = countM.noshippingcount.ToString("N0"),
}
});
}
......@@ -1064,6 +1072,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
profit_rate = (100 * p.profit_rate).ToString("N2"),
cost_tail = p.cost_tail.ToString("N2"),
cost_handle_bailun = p.cost_handle_bailun.ToString("N2"),
noshippingcount = p.noshippingcount.ToString("N0")
});
return JsonConvert.SerializeObject(new
......@@ -1092,6 +1101,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
profit_rate = (100 * countM.profit_rate).ToString("N2"),
cost_tail = countM.cost_tail.ToString("N2"),
cost_handle_bailun = countM.cost_handle_bailun.ToString("N2"),
noshippingcount = countM.noshippingcount.ToString("N0"),
}
});
}
......
......@@ -109,6 +109,11 @@
}
},
{
field: 'order_count', title: '销售数量', width: '100', sortable: true, iscount: true, formatter: function (idx, data) {
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account + '\',\'订单数\',\'\',0)">' + data.order_count + '</span>';
}
},
{
field: 'cost_product', title: '产品成本', width: '100', sortable: true, iscount: true, formatter: function (idx, data) {
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account + '\',\'产品成本\',\'cost_product\',1)">' + data.cost_product + '</span>';
}
......@@ -123,11 +128,6 @@
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account + '\',\'头程费\',\'cost_first\',1)">' + data.head_fee + '</span>';
}
},
{
field: 'order_count', title: '销售数量', width: '100', sortable: true, iscount: true, formatter: function (idx, data) {
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account + '\',\'订单数\',\'\',0)">' + data.order_count + '</span>';
}
},
{ field: 'loss_withdrawal', title: '提现损耗', width: '100', sortable: false, iscount: true },
{
field: 'cost_count', title: '总支出', width: '110', sortable: true, iscount: true, formatter: function (idx, data) {
......@@ -149,6 +149,9 @@
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account + '\',\'预收金额\',\'amount_prepaid\',1)">' + data.amount_prepaid + '</span>';
}
},
{
field: 'noshippingcount', title: '预收订单数', width: '120', sortable: true, iscount: true
},
//{ field: 'forecast_profit_rate', title: '预测利润率%', width: '120', sortable: true },
{
field: 'profit_count', title: '实际利润', width: '120', sortable: true, iscount: true, formatter: function (idx, data) {
......
......@@ -161,6 +161,9 @@
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account + '\',\'预收金额\',\'amount_prepaid\',1)">' + data.amount_prepaid + '</span>';
}
},
{
field: 'noshippingcount', title: '预收订单数', width: '120', sortable: true, iscount: true
},
//{ field: 'forecast_profit_rate', title: '预测利润率%', width: '120', sortable: true },
{
field: 'profit_total', title: '实际利润', width: '120', sortable: true, iscount: true, formatter: function (idx, data) {
......
......@@ -161,6 +161,9 @@
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account + '\',\'预收金额\',\'amount_prepaid\',1)">' + data.amount_prepaid + '</span>';
}
},
{
field: 'noshippingcount', title: '预收订单数', width: '120', sortable: true, iscount: true
},
//{ field: 'forecast_profit_rate', title: '预测利润率%', width: '120', sortable: true },
{
field: 'profit_total', title: '实际利润', width: '120', sortable: true, iscount: true, formatter: function (idx, data) {
......
......@@ -89,8 +89,13 @@
},
{ field: 'website', title: '站点', width: '80', sortable: false, iscount: true },
{
field: 'amount_product', title: '商品收入', width: '100', sortable: true, iscount: true, formatter: function (idx, data) {
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account + '\',\'商品收入\',\'amount_product\',1)">' + data.amount_product + '</span>';
field: 'amount_product', title: '销售额', width: '100', sortable: true, iscount: true, formatter: function (idx, data) {
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account + '\',\'商品收入\',\'amount_sales\',1)">' + data.amount_product + '</span>';
}
},
{
field: 'order_count', title: '销售数量', width: '100', sortable: true, iscount: true, formatter: function (idx, data) {
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account + '\',\'订单数\',\'\',0)">' + data.order_count + '</span>';
}
},
{
......@@ -118,11 +123,6 @@
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account + '\',\'头程费\',\'cost_first\',1)">' + data.head_fee + '</span>';
}
},
{
field: 'order_count', title: '销售数量', width: '100', sortable: true, iscount: true, formatter: function (idx, data) {
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account+ '\',\'订单数\',\'\',0)">' + data.order_count + '</span>';
}
},
{ field: 'loss_withdrawal', title: '提现损耗', width: '100', sortable: false, iscount: true },
{
field: 'cost_count', title: '总支出', width: '110', sortable: true, iscount: true, formatter: function (idx, data) {
......@@ -144,6 +144,9 @@
return '<span class="alink" onclick="ShowDetail(\'' + data.platform_type + '\',\'' + data.website + '\',\'' + data.seller_account + '\',\'预收金额\',\'amount_prepaid\',1)">' + data.amount_prepaid + '</span>';
}
},
//{
// field: 'noshippingcount', title: '预收订单数', width: '120', sortable: true, iscount: true
//},
//{ field: 'forecast_profit_rate', title: '预测利润率%', width: '120', sortable: true },
{
field: 'profit_count', title: '实际利润', width: '120', sortable: true, iscount: true, formatter: function (idx, data) {
......
......@@ -44,6 +44,7 @@
<th>处理费(百伦)</th>
<th>平台操作费</th>
<th>预收金额</th>
<th>预收订单数</th>
<th>利润</th>
<th>利润率%</th>
<th>退款</th>
......@@ -104,6 +105,7 @@
s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'处理费(百伦)\',\'cost_handle_bailun\',1)">' + result[i].cost_handle_bailun + '</td>';
s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'平台操作费\',\'cost_handle_platform\',1)">' + result[i].cost_handle_platform + '</td>';
s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'预收款\',\'amount_prepaid\',1)">' + result[i].amount_prepaid + '</td>';
s += '<td class="alink">' + result[i].noshippingcount + '</td>';
s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'利润\',\'profit_total\',1)">' + result[i].profit_total + '</td>';
s += '<td>' + result[i].profit_rate + '</td>';
s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'退款金额\',\'amount_refund\',1)">' + result[i].amount_refund + '</td>';
......
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