Commit 33fe2b77 by guanzhenshan

增加待收款明细报表,退款明细报表

parent b1e0da58
...@@ -939,7 +939,7 @@ namespace Bailun.DC.Services ...@@ -939,7 +939,7 @@ namespace Bailun.DC.Services
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)
{ {
var sqlparam = new DynamicParameters(); var sqlparam = new DynamicParameters();
var sql = "select platform_type, sum(amount_sales*seller_order_exchange_rate*bailun_sku_quantity_shipped) amount_sales,count(bailun_order_id) order_count,sum(cost_platform_fee*seller_order_exchange_rate*bailun_sku_quantity_shipped) cost_platform_fee,(sum(amount_sales*seller_order_exchange_rate*bailun_sku_quantity_shipped)/count(bailun_order_id)) customerprice,sum(profit_total*bailun_sku_quantity_shipped) profit_total,(sum(profit_total*bailun_sku_quantity_shipped)/sum(amount_sales*seller_order_exchange_rate*bailun_sku_quantity_shipped)) profitrate,sum(amount_refund*seller_order_exchange_rate*bailun_sku_quantity_shipped) amount_refund,sum(cost_first*bailun_sku_quantity_shipped) cost_first,sum(cost_tail*bailun_sku_quantity_shipped) cost_tail,sum(cost_handle_bailun*bailun_sku_quantity_shipped) cost_handle_bailun,sum(cost_handle_platform*bailun_sku_quantity_shipped) cost_handle_platform from dc_base_oms_sku where bailun_order_status!='Canceled' and bailun_sku_quantity_shipped>0"; var sql = "select tb.platform_type,count(tb.bailun_order_id) order_count,sum(tb.amount_sales) as amount_sales,sum(tb.cost_platform_fee) 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) amount_refund from (select bailun_order_id,platform_type,sum(amount_sales*seller_order_exchange_rate*bailun_sku_quantity_shipped) amount_sales,sum(cost_platform_fee*seller_order_exchange_rate*bailun_sku_quantity_shipped) cost_platform_fee,sum(profit_total*bailun_sku_quantity_shipped) profit_total,sum(amount_refund*seller_order_exchange_rate*bailun_sku_quantity_shipped) amount_refund,sum(cost_first*bailun_sku_quantity_shipped) cost_first,sum(cost_tail*bailun_sku_quantity_shipped) cost_tail,sum(cost_handle_bailun*bailun_sku_quantity_shipped) cost_handle_bailun,sum(cost_handle_platform*bailun_sku_quantity_shipped) cost_handle_platform from dc_base_oms_sku where bailun_order_status!='Canceled' and bailun_sku_quantity_shipped>0";
var presql = "select platform_type,sum(amount_prepaid) amount_prepaid from dc_base_oms_sku where bailun_order_status!='Canceled' and amount_prepaid>0 "; 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 (!string.IsNullOrWhiteSpace(platform)) if (!string.IsNullOrWhiteSpace(platform))
...@@ -961,7 +961,7 @@ namespace Bailun.DC.Services ...@@ -961,7 +961,7 @@ namespace Bailun.DC.Services
sqlparam.Add("paid_time_end", end.Value.AddDays(1)); sqlparam.Add("paid_time_end", end.Value.AddDays(1));
} }
sql += " group by platform_type"; sql += " group by bailun_order_id) tb group by tb.platform_type";
presql += " group by platform_type"; presql += " group by platform_type";
using (var cn = new MySqlConnection(Common.GlobalConfig.ConnectionString)) using (var cn = new MySqlConnection(Common.GlobalConfig.ConnectionString))
...@@ -1130,40 +1130,48 @@ namespace Bailun.DC.Services ...@@ -1130,40 +1130,48 @@ namespace Bailun.DC.Services
public List<Models.Orders.dc_base_oms_order> ListPlatformProfitOrders(BtTableParameter parameter, string platform, string website,string account, DateTime? start, DateTime? end, string orderno, ref int total) public List<Models.Orders.dc_base_oms_order> ListPlatformProfitOrders(BtTableParameter parameter, string platform, string website,string account, DateTime? start, DateTime? end, string orderno, ref int total)
{ {
var sqlparam = new DynamicParameters(); var sqlparam = new DynamicParameters();
var sql = "select platform_type,website,origin_order_id,bailun_order_id,seller_account,order_currency,sum(amount_sales*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_total,sum(amount_product*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_product,sum(amount_shipping*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_shipping,sum(amount_tax*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_tax,sum(amount_adjustment*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_adjustment,sum(amount_gift_wrap*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_gift_wrap,sum(amount_refund*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_refund,sum(cost_total*bailun_sku_quantity_shipped) cost_total,sum(cost_promotion*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_promotion,sum(cost_platform_fee*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_platform_fee,sum(cost_product*bailun_sku_quantity_shipped) cost_product,sum(cost_shipping*bailun_sku_quantity_shipped) cost_shipping,sum(cost_package*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_package,sum(cost_fba_fee*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_fba_fee,sum(cost_paypal_fee*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_paypal_fee,sum(cost_refund_commisson*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_refund_commisson,sum(cost_handle_bailun*bailun_sku_quantity_shipped) cost_handle_bailun,sum(cost_handle_platform*bailun_sku_quantity_shipped) cost_handle_platform,sum(cost_tail*bailun_sku_quantity_shipped) cost_tail,sum(cost_first*bailun_sku_quantity_shipped) cost_first,sum(profit_total*bailun_sku_quantity_shipped) profit_total,(sum(profit_total)/sum(amount_sales)) profit_rate,create_time,paid_time,seller_order_exchange_rate,seller_other_exchange_rate,sum(amount_prepaid*seller_order_exchange_rate) amount_prepaid from dc_base_oms_sku where bailun_order_status!='Canceled' and bailun_sku_quantity_shipped>0"; var sql = "select platform_type,website,origin_order_id,bailun_order_id,seller_account,order_currency,sum(amount_sales*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_sales,sum(amount_product*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_product,sum(amount_shipping*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_shipping,sum(amount_tax*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_tax,sum(amount_adjustment*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_adjustment,sum(amount_gift_wrap*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_gift_wrap,sum(amount_refund*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_refund,sum(cost_total*bailun_sku_quantity_shipped) cost_total,sum(cost_promotion*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_promotion,sum(cost_platform_fee*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_platform_fee,sum(cost_product*bailun_sku_quantity_shipped) cost_product,sum(cost_shipping*bailun_sku_quantity_shipped) cost_shipping,sum(cost_package*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_package,sum(cost_fba_fee*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_fba_fee,sum(cost_paypal_fee*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_paypal_fee,sum(cost_refund_commisson*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_refund_commisson,sum(cost_handle_bailun*bailun_sku_quantity_shipped) cost_handle_bailun,sum(cost_handle_platform*bailun_sku_quantity_shipped) cost_handle_platform,sum(cost_tail*bailun_sku_quantity_shipped) cost_tail,sum(cost_first*bailun_sku_quantity_shipped) cost_first,sum(profit_total*bailun_sku_quantity_shipped) profit_total,(sum(profit_total)/sum(amount_sales*seller_order_exchange_rate)) profit_rate,create_time,paid_time,seller_order_exchange_rate,seller_other_exchange_rate,sum(amount_prepaid) amount_prepaid from dc_base_oms_sku where bailun_order_status!='Canceled' and bailun_sku_quantity_shipped>0";
var precolumn = "select bailun_order_id,sum(amount_prepaid*seller_order_exchange_rate) amount_prepaid from dc_base_oms_sku where bailun_order_status!='Canceled' ";
if (!string.IsNullOrWhiteSpace(platform)) if (!string.IsNullOrWhiteSpace(platform))
{ {
sql += " and platform_type=@platform_type"; sql += " and platform_type=@platform_type";
precolumn += " and platform_type=@platform_type";
sqlparam.Add("platform_type", platform); sqlparam.Add("platform_type", platform);
} }
if (start.HasValue) if (start.HasValue)
{ {
sql += " and paid_time>=@paid_time_start"; sql += " and paid_time>=@paid_time_start";
precolumn += " and paid_time>=@paid_time_start";
sqlparam.Add("paid_time_start", start.Value); sqlparam.Add("paid_time_start", start.Value);
} }
if (end.HasValue) if (end.HasValue)
{ {
sql += " and paid_time<@paid_time_end"; sql += " and paid_time<@paid_time_end";
precolumn += " and paid_time<@paid_time_end";
sqlparam.Add("paid_time_end", end.Value.AddDays(1)); sqlparam.Add("paid_time_end", end.Value.AddDays(1));
} }
if (!string.IsNullOrEmpty(website)) if (!string.IsNullOrEmpty(website))
{ {
sql += " and website=@website"; sql += " and website=@website";
precolumn += " and website=@website";
sqlparam.Add("website", website); sqlparam.Add("website", website);
} }
if (!string.IsNullOrEmpty(orderno)) if (!string.IsNullOrEmpty(orderno))
{ {
sql += " and bailun_order_id=@bailun_order_id"; sql += " and bailun_order_id=@bailun_order_id";
precolumn += " and bailun_order_id=@bailun_order_id";
sqlparam.Add("bailun_order_id", orderno); sqlparam.Add("bailun_order_id", orderno);
} }
if (!string.IsNullOrEmpty(account)) if (!string.IsNullOrEmpty(account))
{ {
sql += " and seller_account=@seller_account"; sql += " and seller_account=@seller_account";
precolumn += " and seller_account=@seller_account";
sqlparam.Add("seller_account", account); sqlparam.Add("seller_account", account);
} }
sql += " group by bailun_order_id "; sql += " group by bailun_order_id ";
if (!string.IsNullOrEmpty(parameter.sort)) if (!string.IsNullOrEmpty(parameter.sort))
{ {
...@@ -1177,8 +1185,22 @@ namespace Bailun.DC.Services ...@@ -1177,8 +1185,22 @@ namespace Bailun.DC.Services
cn.Open(); cn.Open();
} }
var obj = cn.Query<Models.Orders.dc_base_oms_order>(sql, sqlparam); //cn.Page<Models.Orders.dc_base_oms_order>(parameter.pageIndex, parameter.limit, sql, ref total, sqlparam); var obj = cn.Page<Models.Orders.dc_base_oms_order>(parameter.pageIndex, parameter.limit, "select * from ("+sql+") a ", ref total, sqlparam,"",2*60);
precolumn += (" and bailun_order_id in ('" + string.Join("','", obj.Select(a => a.bailun_order_id)) + "') " + " group by bailun_order_id ");
var obj1 = cn.Query<Models.Orders.dc_base_oms_order>(precolumn, sqlparam);
foreach (var item in obj)
{
var temp = obj1.Where(a => a.bailun_order_id == item.bailun_order_id).FirstOrDefault();
if (temp != null)
{
item.amount_prepaid = temp.amount_prepaid;
}
}
return obj.AsList(); return obj.AsList();
} }
...@@ -1196,36 +1218,44 @@ namespace Bailun.DC.Services ...@@ -1196,36 +1218,44 @@ namespace Bailun.DC.Services
public Models.Orders.dc_base_oms_order ListPlatformProfitOrdersCount(string platform, string website,string account, DateTime? start, DateTime? end, string orderno) public Models.Orders.dc_base_oms_order ListPlatformProfitOrdersCount(string platform, string website,string account, DateTime? start, DateTime? end, string orderno)
{ {
var sqlparam = new DynamicParameters(); var sqlparam = new DynamicParameters();
var sql = "select sum(amount_total*seller_order_exchange_rate) amount_total,sum(amount_product*seller_order_exchange_rate) amount_product,sum(amount_shipping*seller_order_exchange_rate) amount_shipping,sum(amount_tax*seller_order_exchange_rate) amount_tax,sum(amount_adjustment*seller_order_exchange_rate) amount_adjustment,sum(amount_gift_wrap*seller_order_exchange_rate) amount_gift_wrap,sum(amount_refund*seller_order_exchange_rate) amount_refund,sum(cost_total) cost_total,sum(cost_promotion*seller_order_exchange_rate) cost_promotion,sum(cost_platform_fee*seller_order_exchange_rate) cost_platform_fee,sum(cost_product) cost_product,sum(cost_shipping) cost_shipping,sum(cost_package) cost_package,sum(cost_fba_fee*seller_order_exchange_rate) cost_fba_fee,sum(cost_paypal_fee*seller_order_exchange_rate) cost_paypal_fee,sum(cost_refund_commisson*seller_order_exchange_rate) cost_refund_commisson,sum(cost_handle_bailun) cost_handle_bailun,sum(cost_handle_platform) cost_handle_platform,sum(cost_tail) cost_tail,sum(cost_first) cost_first,sum(profit_total) profit_total,sum(amount_prepaid) amount_prepaid from dc_base_oms_order where bailun_order_status!='Canceled' "; var sql = "select sum(amount_sales*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_sales,sum(amount_product*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_product,sum(amount_shipping*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_shipping,sum(amount_tax*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_tax,sum(amount_adjustment*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_adjustment,sum(amount_gift_wrap*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_gift_wrap,sum(amount_refund*bailun_sku_quantity_shipped*seller_order_exchange_rate) amount_refund,sum(cost_total*bailun_sku_quantity_shipped) cost_total,sum(cost_promotion*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_promotion,sum(cost_platform_fee*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_platform_fee,sum(cost_product*bailun_sku_quantity_shipped) cost_product,sum(cost_shipping*bailun_sku_quantity_shipped) cost_shipping,sum(cost_package*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_package,sum(cost_fba_fee*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_fba_fee,sum(cost_paypal_fee*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_paypal_fee,sum(cost_refund_commisson*bailun_sku_quantity_shipped*seller_order_exchange_rate) cost_refund_commisson,sum(cost_handle_bailun*bailun_sku_quantity_shipped) cost_handle_bailun,sum(cost_handle_platform*bailun_sku_quantity_shipped) cost_handle_platform,sum(cost_tail*bailun_sku_quantity_shipped) cost_tail,sum(cost_first*bailun_sku_quantity_shipped) cost_first,sum(profit_total*bailun_sku_quantity_shipped) profit_total,(sum(profit_total)/sum(amount_sales*seller_order_exchange_rate)) profit_rate,sum(amount_prepaid) amount_prepaid from dc_base_oms_sku where bailun_order_status!='Canceled' and bailun_sku_quantity_shipped>0";
var precolumn = "select sum(amount_prepaid) amount_prepaid from dc_base_oms_sku where bailun_order_status!='Canceled' ";
if (!string.IsNullOrWhiteSpace(platform)) if (!string.IsNullOrWhiteSpace(platform))
{ {
sql += " and platform_type=@platform_type"; sql += " and platform_type=@platform_type";
precolumn+= " and platform_type=@platform_type";
sqlparam.Add("platform_type", platform); sqlparam.Add("platform_type", platform);
} }
if (start.HasValue) if (start.HasValue)
{ {
sql += " and paid_time>=@paid_time_start"; sql += " and paid_time>=@paid_time_start";
precolumn += " and paid_time>=@paid_time_start";
sqlparam.Add("paid_time_start", start.Value); sqlparam.Add("paid_time_start", start.Value);
} }
if (end.HasValue) if (end.HasValue)
{ {
sql += " and paid_time<@paid_time_end"; sql += " and paid_time<@paid_time_end";
precolumn += " and paid_time<@paid_time_end";
sqlparam.Add("paid_time_end", end.Value.AddDays(1)); sqlparam.Add("paid_time_end", end.Value.AddDays(1));
} }
if (!string.IsNullOrEmpty(website)) if (!string.IsNullOrEmpty(website))
{ {
sql += " and website=@website"; sql += " and website=@website";
precolumn += " and website=@website";
sqlparam.Add("website", website); sqlparam.Add("website", website);
} }
if (!string.IsNullOrEmpty(orderno)) if (!string.IsNullOrEmpty(orderno))
{ {
sql += " and bailun_order_id=@bailun_order_id"; sql += " and bailun_order_id=@bailun_order_id";
precolumn += " and bailun_order_id=@bailun_order_id";
sqlparam.Add("bailun_order_id", orderno); sqlparam.Add("bailun_order_id", orderno);
} }
if (!string.IsNullOrEmpty(account)) if (!string.IsNullOrEmpty(account))
{ {
sql += " and seller_account=@seller_account"; sql += " and seller_account=@seller_account";
precolumn += " and seller_account=@seller_account";
sqlparam.Add("seller_account", account); sqlparam.Add("seller_account", account);
} }
...@@ -1236,8 +1266,19 @@ namespace Bailun.DC.Services ...@@ -1236,8 +1266,19 @@ namespace Bailun.DC.Services
cn.Open(); cn.Open();
} }
var obj = cn.QueryFirst<Models.Orders.dc_base_oms_order>(sql,sqlparam); var obj = cn.QueryFirstOrDefault<Models.Orders.dc_base_oms_order>(sql,sqlparam);
if (obj != null)
{
var obj1 = cn.QueryFirstOrDefault<Models.Orders.dc_base_oms_order>(precolumn, sqlparam);
if (obj1 != null)
{
obj.amount_prepaid = obj1.amount_prepaid;
}
}
return obj; return obj;
} }
} }
...@@ -1632,63 +1673,62 @@ namespace Bailun.DC.Services ...@@ -1632,63 +1673,62 @@ namespace Bailun.DC.Services
{ {
var sqlparam = new DynamicParameters(); var sqlparam = new DynamicParameters();
var sql = @"select platform_type,seller_account,sum(amount_sales*seller_order_exchange_rate*bailun_sku_quantity_shipped) 'amount_product',sum(cost_paypal_fee*seller_order_exchange_rate*bailun_sku_quantity_shipped) 'cost_paypal_fee',sum(cost_product*bailun_sku_quantity_shipped) 'cost_product',sum(cost_platform_fee*seller_order_exchange_rate*bailun_sku_quantity_shipped) 'cost_platform_fee',sum(cost_first*bailun_sku_quantity_shipped) 'cost_first',count(t1.bailun_order_id) 'order_count',sum(cost_total*bailun_sku_quantity_shipped) 'cost_total',sum(cost_tail*bailun_sku_quantity_shipped) 'cost_tail',sum(profit_total*bailun_sku_quantity_shipped) 'profit_total',(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,sum(cost_handle_bailun*bailun_sku_quantity_shipped) cost_handle_bailun from dc_base_oms_sku t1"; 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 presql = "select platform_type,seller_account,website,order_currency,sum(amount_prepaid) as amount_prepaid from dc_base_oms_sku 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"; if (!string.IsNullOrEmpty(warehousetype))
var sqlwhere = " where platform_type='Ebay' and bailun_order_status!='Canceled' ";
if (!string.IsNullOrEmpty(warehousetype) || (!string.IsNullOrEmpty(warehousetype) && !string.IsNullOrEmpty(warehousecode)))
{ {
sql += " join dc_base_oms_pick t2 on t1.origin_order_id=t2.origin_order_id " + (!string.IsNullOrEmpty(warehousecode) ? " and t2.warehouse_code=@warehousecode" : ""); sql += " join dc_base_warehouse t2 on t1.warehouse_code=t2.warehouse_code and t2.warehouse_type_ex=@warehoursetype";
sql += " join dc_base_warehouse t3 on t2.warehouse_code =t3.warehouse_code and hq_type=@warehousetype"; presql += " join dc_base_warehouse t2 on t1.warehouse_code=t2.warehouse_code and t2.warehouse_type_ex=@warehoursetype";
sqlparam.Add("warehoursetype", warehousetype);
presql += " join dc_base_oms_pick t2 on t1.origin_order_id=t2.origin_order_id " + (!string.IsNullOrEmpty(warehousecode) ? " and t2.warehouse_code=@warehousecode" : "");
presql += " join dc_base_warehouse t3 on t2.warehouse_code =t3.warehouse_code and hq_type=@warehousetype";
sqlparam.Add("warehousetype", warehousetype);
if (!string.IsNullOrEmpty(warehousecode))
{
sqlparam.Add("warehousecode", warehousecode);
}
} }
else if (!string.IsNullOrEmpty(warehousecode)) if (!string.IsNullOrEmpty(warehousecode))
{ {
sql += " join dc_base_oms_pick t2 on t1.origin_order_id=t2.origin_order_id and t2.warehouse_code=@warehousecode"; if (!string.IsNullOrEmpty(warehousetype))
presql += " join dc_base_oms_pick t2 on t1.origin_order_id=t2.origin_order_id and t2.warehouse_code=@warehousecode"; {
sqlparam.Add("warehousecode", warehousecode); sql += " and t2.warehouse_code=@warehouse_code";
presql += " and t2.warehouse_code=@warehouse_code";
sqlparam.Add("warehouse_code", warehousecode);
}
else
{
sql += " join dc_base_warehouse t2 on t1.warehouse_code=t2.warehouse_code and t2.warehouse_code=@warehouse_code";
presql += " join dc_base_warehouse t2 on t1.warehouse_code=t2.warehouse_code and t2.warehouse_code=@warehouse_code";
sqlparam.Add("warehouse_code", warehousecode);
}
} }
var fromsql = " where platform_type='Ebay' and bailun_order_status!='Canceled' ";
if (!string.IsNullOrWhiteSpace(account)) if (!string.IsNullOrWhiteSpace(account))
{ {
sqlwhere += " and t1.seller_account=@seller_account"; fromsql += " and t1.seller_account=@seller_account";
sqlparam.Add("seller_account", account); sqlparam.Add("seller_account", account);
} }
if (!string.IsNullOrWhiteSpace(website)) if (!string.IsNullOrWhiteSpace(website))
{ {
sqlwhere += " and t1.website=@website"; fromsql += " and t1.website=@website";
sqlparam.Add("website", website); sqlparam.Add("website", website);
} }
if (start.HasValue) if (start.HasValue)
{ {
sqlwhere += " and t1.paid_time>='" + start.Value.ToString("yyyy-MM-dd") + "'"; fromsql += " and t1.paid_time>='" + start.Value.ToString("yyyy-MM-dd") + "'";
} }
if (end.HasValue) if (end.HasValue)
{ {
sqlwhere += " and t1.paid_time<'" + end.Value.AddDays(1).ToString("yyyy-MM-dd") + "'"; fromsql += " and t1.paid_time<'" + end.Value.AddDays(1).ToString("yyyy-MM-dd") + "'";
} }
var prefromsql = sqlwhere; var prefromsql = fromsql;
sqlwhere += " and bailun_sku_quantity_shipped>0"; fromsql += " and bailun_sku_quantity_shipped>0";
sqlwhere += " group by t1.seller_account,t1.platform_type"; fromsql += " group by seller_account,website,order_currency,platform_type";
if (!string.IsNullOrWhiteSpace(parameter.sort)) if (!string.IsNullOrWhiteSpace(parameter.sort))
{ {
sqlwhere += " order by " + parameter.sort + " " + parameter.order; fromsql += " order by " + parameter.sort + " " + parameter.order;
} }
using (var cn = new MySqlConnection(Common.GlobalConfig.ConnectionString)) using (var cn = new MySqlConnection(Common.GlobalConfig.ConnectionString))
...@@ -1698,13 +1738,13 @@ namespace Bailun.DC.Services ...@@ -1698,13 +1738,13 @@ namespace Bailun.DC.Services
cn.Open(); cn.Open();
} }
var obj = cn.Page<Models.Orders.dc_base_oms_order>(parameter.pageIndex, parameter.limit, sql+sqlwhere, ref total, sqlparam); var obj = cn.Page<Models.Orders.dc_base_oms_order>(parameter.pageIndex, parameter.limit, sql + fromsql, ref total, sqlparam);
//另外计算预收款金额 //另外计算预收款金额
var list = obj.AsList(); var list = obj.AsList();
prefromsql += " and bailun_sku_quantity_shipped<=0"; prefromsql += " and bailun_sku_quantity_shipped<=0";
prefromsql += " and seller_account in ('" + string.Join("','", list.Select(a => a.seller_account)) + "')"; prefromsql += " and seller_account in ('" + string.Join("','", list.Select(a => a.seller_account)) + "') and website in ('" + string.Join("','", list.Select(a => a.website)) + "') and order_currency in ('" + string.Join("','", list.Select(a => a.order_currency)) + "')";
prefromsql += " group by seller_account,platform_type"; prefromsql += " group by seller_account,website,order_currency,platform_type";
var obj1 = cn.Query<Models.Orders.dc_base_oms_order>(presql + prefromsql, sqlparam); var obj1 = cn.Query<Models.Orders.dc_base_oms_order>(presql + prefromsql, sqlparam);
...@@ -1716,10 +1756,9 @@ namespace Bailun.DC.Services ...@@ -1716,10 +1756,9 @@ namespace Bailun.DC.Services
item.amount_prepaid = temp.amount_prepaid; item.amount_prepaid = temp.amount_prepaid;
} }
} }
return obj.AsList(); return list;
} }
} }
......
...@@ -594,7 +594,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers ...@@ -594,7 +594,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
var list = result.Select(p => new { var list = result.Select(p => new {
p.platform_type, p.platform_type,
customerprice = p.customerprice > 0 ? p.customerprice.ToString("N2") : "0", customerprice = (p.amount_sales/p.order_count).ToString("N2"),
p.order_count, p.order_count,
cost_platform_fee = p.cost_platform_fee > 0 ? p.cost_platform_fee.ToString("N2") : "0", cost_platform_fee = p.cost_platform_fee > 0 ? p.cost_platform_fee.ToString("N2") : "0",
profit_total = p.profit_total.ToString("N2"), profit_total = p.profit_total.ToString("N2"),
...@@ -736,6 +736,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers ...@@ -736,6 +736,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
var countM = service.ListPlatformProfitOrdersCount(platform, website, account, start, end, orderno); var countM = service.ListPlatformProfitOrdersCount(platform, website, account, start, end, orderno);
countM.bailun_order_id = "总计"; countM.bailun_order_id = "总计";
countM.amount_sales = Math.Round(countM.amount_sales, 2, MidpointRounding.AwayFromZero);
countM.amount_total = Math.Round((countM.amount_total), 2, MidpointRounding.AwayFromZero); countM.amount_total = Math.Round((countM.amount_total), 2, MidpointRounding.AwayFromZero);
countM.amount_product = Math.Round((countM.amount_product), 2, MidpointRounding.AwayFromZero); countM.amount_product = Math.Round((countM.amount_product), 2, MidpointRounding.AwayFromZero);
countM.amount_shipping = Math.Round((countM.amount_shipping), 2, MidpointRounding.AwayFromZero); countM.amount_shipping = Math.Round((countM.amount_shipping), 2, MidpointRounding.AwayFromZero);
...@@ -759,6 +760,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers ...@@ -759,6 +760,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
countM.cost_tail = Math.Round(countM.cost_tail, 2, MidpointRounding.AwayFromZero); countM.cost_tail = Math.Round(countM.cost_tail, 2, MidpointRounding.AwayFromZero);
countM.profit_total = Math.Round(countM.profit_total, 2, MidpointRounding.AwayFromZero); countM.profit_total = Math.Round(countM.profit_total, 2, MidpointRounding.AwayFromZero);
countM.amount_prepaid = Math.Round(countM.amount_prepaid, 2, MidpointRounding.AwayFromZero); countM.amount_prepaid = Math.Round(countM.amount_prepaid, 2, MidpointRounding.AwayFromZero);
countM.profit_rate = countM.amount_sales > 0 ? Math.Round((countM.profit_total / countM.amount_sales)*100,2,MidpointRounding.AwayFromZero) : 0;
var list = obj.Select(p => new var list = obj.Select(p => new
{ {
...@@ -769,30 +771,31 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers ...@@ -769,30 +771,31 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
p.seller_account, p.seller_account,
p.order_currency, p.order_currency,
amount_total = Math.Round((p.amount_total * p.seller_order_exchange_rate),2,MidpointRounding.AwayFromZero), amount_total = p.amount_total.ToString("N2"),
amount_product = Math.Round((p.amount_product * p.seller_order_exchange_rate),2,MidpointRounding.AwayFromZero), amount_sales = p.amount_sales.ToString("N2"),
amount_shipping = Math.Round((p.amount_shipping * p.seller_order_exchange_rate),2,MidpointRounding.AwayFromZero), amount_product = p.amount_product.ToString("N2"),
amount_tax = Math.Round((p.amount_tax * p.seller_order_exchange_rate),2,MidpointRounding.AwayFromZero), amount_shipping = p.amount_shipping.ToString("N2"),
amount_adjustment = Math.Round((p.amount_adjustment * p.seller_order_exchange_rate),2,MidpointRounding.AwayFromZero), amount_tax = p.amount_tax.ToString("N2"),
amount_gift_wrap = Math.Round((p.amount_gift_wrap * p.seller_order_exchange_rate),2,MidpointRounding.AwayFromZero), amount_adjustment = p.amount_adjustment.ToString("N2"),
amount_refund = Math.Round((p.amount_refund * p.seller_order_exchange_rate),2,MidpointRounding.AwayFromZero), amount_gift_wrap = p.amount_gift_wrap.ToString("N2"),
amount_refund = p.amount_refund.ToString("N2"),
cost_total = Math.Round(p.cost_total,2,MidpointRounding.AwayFromZero),
cost_promotion = Math.Round(p.cost_promotion * p.seller_order_exchange_rate,2,MidpointRounding.AwayFromZero), cost_total = p.cost_total.ToString("N2"),
cost_platform_fee = Math.Round(p.cost_platform_fee * p.seller_order_exchange_rate,2,MidpointRounding.AwayFromZero), cost_promotion = p.cost_promotion.ToString("N2"),
cost_product = Math.Round(p.cost_product,2,MidpointRounding.AwayFromZero), cost_platform_fee = p.cost_platform_fee.ToString("N2"),
cost_shipping = Math.Round(p.cost_shipping,2,MidpointRounding.AwayFromZero), cost_product = p.cost_product.ToString("N2"),
cost_package = Math.Round(p.cost_package,2,MidpointRounding.AwayFromZero), cost_shipping = p.cost_shipping.ToString("N2"),
cost_fba_fee = Math.Round(p.cost_fba_fee * p.seller_order_exchange_rate,2,MidpointRounding.AwayFromZero), cost_package = p.cost_package.ToString("N2"),
cost_paypal_fee = Math.Round(p.cost_paypal_fee*p.seller_order_exchange_rate,2,MidpointRounding.AwayFromZero), cost_fba_fee = p.cost_fba_fee.ToString("N2"),
cost_refund_commisson = Math.Round(p.cost_refund_commisson*p.seller_order_exchange_rate,2,MidpointRounding.AwayFromZero), cost_paypal_fee = p.cost_paypal_fee.ToString("N2"),
cost_handle_bailun = Math.Round(p.cost_handle_bailun,2,MidpointRounding.AwayFromZero), cost_refund_commisson = p.cost_refund_commisson.ToString("N2"),
cost_handle_platform = Math.Round(p.cost_handle_platform,2,MidpointRounding.AwayFromZero), cost_handle_bailun = p.cost_handle_bailun.ToString("N2"),
cost_first = Math.Round(p.cost_first,2,MidpointRounding.AwayFromZero), cost_handle_platform = p.cost_handle_platform.ToString("N2"),
cost_tail = Math.Round(p.cost_tail,2,MidpointRounding.AwayFromZero), cost_first = p.cost_first.ToString("N2"),
profit_total = Math.Round(p.profit_total,2,MidpointRounding.AwayFromZero), cost_tail = p.cost_tail.ToString("N2"),
profit_rate = Math.Round(p.profit_rate*100,2,MidpointRounding.AwayFromZero), profit_total = p.profit_total.ToString("N2"),
amount_prepaid = Math.Round(p.amount_prepaid,2,MidpointRounding.AwayFromZero), profit_rate = (p.profit_rate*100).ToString("N2"),
amount_prepaid = p.amount_prepaid.ToString("N2"),
create_time = p.create_time.ToString("yyyy-MM-dd HH:mm:ss"), create_time = p.create_time.ToString("yyyy-MM-dd HH:mm:ss"),
paid_time = p.paid_time.ToString("yyyy-MM-dd HH:mm:ss"), paid_time = p.paid_time.ToString("yyyy-MM-dd HH:mm:ss"),
...@@ -1152,7 +1155,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers ...@@ -1152,7 +1155,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
[HttpPost] [HttpPost]
public JsonResult ListAccount(string platform) public JsonResult ListAccount(string platform)
{ {
var result = Services.CommonServices.ListAccount(platform); var result = Services.CommonServices.ListAccount(platform).Where(a=>!string.IsNullOrEmpty(a));
return Json(result); return Json(result);
} }
...@@ -1164,7 +1167,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers ...@@ -1164,7 +1167,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
[HttpPost] [HttpPost]
public JsonResult ListWebSite(string platform) public JsonResult ListWebSite(string platform)
{ {
var result = Services.CommonServices.ListWebSite(platform); var result = Services.CommonServices.ListWebSite(platform).Where(a => !string.IsNullOrEmpty(a));
return Json(result); return Json(result);
} }
......
...@@ -8,7 +8,6 @@ ...@@ -8,7 +8,6 @@
<div class="col-sm-12"> <div class="col-sm-12">
<div class="ibox-content m-b-sm border-bottom"> <div class="ibox-content m-b-sm border-bottom">
<form id="toolbar"> <form id="toolbar">
<input id="platform" name="platform" type="hidden" />
<div class="form-inline" style="line-height:40px;"> <div class="form-inline" style="line-height:40px;">
<div class="form-group"> <div class="form-group">
<label>平台类型:</label> <label>平台类型:</label>
...@@ -167,9 +166,9 @@ ...@@ -167,9 +166,9 @@
paramData: 'platform=FBA', paramData: 'platform=FBA',
func: function (result) { func: function (result) {
if (result != null && result != undefined) { if (result != null && result != undefined) {
$('#saleaccount').html('<option value="">选择帐号</option>'); $('#account').html('<option value="">选择帐号</option>');
for (var i = 0; i < result.length; i++) { for (var i = 0; i < result.length; i++) {
$('#saleaccount').append('<option value="' + result[i] + '">' + result[i]+'</option>'); $('#account').append('<option value="' + result[i] + '">' + result[i]+'</option>');
} }
} }
} }
......
...@@ -26,6 +26,8 @@ ...@@ -26,6 +26,8 @@
<label>仓库类型:</label> <label>仓库类型:</label>
<select id="warehousetype" name="warehousetype" class="form-control"> <select id="warehousetype" name="warehousetype" class="form-control">
<option value="">选择仓库类型</option> <option value="">选择仓库类型</option>
<option value="自发货仓">自发货仓</option>
<option value="第三方仓">第三方仓</option>
</select> </select>
</div> </div>
<div class="form-group"> <div class="form-group">
...@@ -84,7 +86,7 @@ ...@@ -84,7 +86,7 @@
//listWebsite(); //listWebsite();
listwarehousetype(); //listwarehousetype();
listwarehouse(); listwarehouse();
...@@ -231,19 +233,22 @@ ...@@ -231,19 +233,22 @@
} }
function listwarehouse() { function listwarehouse() {
var wtype = $('#warehousetype').val(); var type = $('#warehousetype').val();
if (type == '') {
$('#warehousecode').html('<option value="">请选择仓库</option>');
return false;
}
$.submit({ $.submit({
url: '@Url.Content("~/Home/ListWareHouse")', url: '@Url.Content("~/Home/ListWarehouseByExtType")',
paramData: 'warehousetype=' + wtype, type: 'POST',
type:'POST', paramData: 'type=' + type,
func: function (result) { func: function (result) {
if (result != null && result != undefined) { if (result != null && result != undefined) {
$('#warehousecode').html('<option value="">仓库不限</option>'); $('#warehousecode').html('<option value="">请选择仓库</option>');
for (var i = 0; i < result.length; i++) { for (var i = 0; i < result.length; i++) {
if (result[i].warehouse_name.indexOf('FBA') < 0) { $('#warehousecode').append('<option value="' + result[i].code + '">' + result[i].name + '</option>');
$('#warehousecode').append('<option value="' + result[i].warehouse_code + '">' + result[i].warehouse_name + '</option>');
}
} }
} }
} }
......
...@@ -89,7 +89,7 @@ ...@@ -89,7 +89,7 @@
{ field: 'website', title: '站点', width: '90' }, { field: 'website', title: '站点', width: '90' },
{ field: 'seller_account', title: '销售帐号', width: '110', sortable: false }, { field: 'seller_account', title: '销售帐号', width: '110', sortable: false },
{ {
field: 'amount_total', title: '总收入', width: '90', sortable: true, iscount: true field: 'amount_sales', title: '销售额', width: '90', sortable: true, iscount: true
}, },
{ field: 'amount_product', title: '产品收入', width: '110', sortable: true, iscount: true }, { field: 'amount_product', title: '产品收入', width: '110', sortable: true, iscount: true },
{ {
...@@ -103,7 +103,6 @@ ...@@ -103,7 +103,6 @@
{ field: 'cost_promotion', title: '促销费用', width: '110', sortable: true, iscount: true }, { field: 'cost_promotion', title: '促销费用', width: '110', sortable: true, iscount: true },
{ field: 'cost_platform_fee', title: '平台费用', width: '100', sortable: true, iscount: true }, { field: 'cost_platform_fee', title: '平台费用', width: '100', sortable: true, iscount: true },
{ field: 'cost_product', title: '产品成本', width: '100', sortable: true, iscount: true }, { field: 'cost_product', title: '产品成本', width: '100', sortable: true, iscount: true },
{ field: 'cost_shipping', title: '发货费用', width: '100', sortable: true, iscount: true },
{ field: 'cost_package', title: '包装费用', width: '100', sortable: true, iscount: true }, { field: 'cost_package', title: '包装费用', width: '100', sortable: true, iscount: true },
{ field: 'cost_fba_fee', title: 'FBA费用', width: '100', sortable: true, iscount: true }, { field: 'cost_fba_fee', title: 'FBA费用', width: '100', sortable: true, iscount: true },
{ field: 'cost_paypal_fee', title: 'Paypal费用', width: '120', sortable: true, iscount: true }, { field: 'cost_paypal_fee', title: 'Paypal费用', width: '120', sortable: true, iscount: true },
...@@ -113,7 +112,8 @@ ...@@ -113,7 +112,8 @@
{ field: 'cost_first', title: '头程费', width: '100', sortable: true, iscount: true }, { field: 'cost_first', title: '头程费', width: '100', sortable: true, iscount: true },
{ field: 'cost_tail', title: '尾程费', width: '100', sortable: true, iscount: true }, { field: 'cost_tail', title: '尾程费', width: '100', sortable: true, iscount: true },
{ field: 'profit_total', title: '利润', width: '100', sortable: true, iscount: true }, { field: 'profit_total', title: '利润', width: '100', sortable: true, iscount: true },
{ field: 'profit_rate', title: '利润率', width: '100', sortable: true }, { field: 'profit_rate', title: '利润率', width: '100', sortable: true, iscount: true },
{ field: 'amount_prepaid', title: '预收款', width: '100', sortable: true,iscount: true },
{ field: 'create_time', title: '下单时间', width: '150', sortable: true }, { field: 'create_time', title: '下单时间', width: '150', sortable: true },
{ field: 'paid_time', title: '付款时间', width: '150', sortable: true } { field: 'paid_time', title: '付款时间', width: '150', sortable: true }
]; ];
......
...@@ -9,7 +9,6 @@ ...@@ -9,7 +9,6 @@
<div class="col-sm-12"> <div class="col-sm-12">
<div class="ibox-content m-b-sm border-bottom"> <div class="ibox-content m-b-sm border-bottom">
<form id="toolbar"> <form id="toolbar">
<input id="platform" name="platform" type="hidden" />
<div class="form-inline" style="line-height:40px;"> <div class="form-inline" style="line-height:40px;">
<div class="form-group"> <div class="form-group">
<label>平台类型:</label> <label>平台类型:</label>
...@@ -147,22 +146,24 @@ ...@@ -147,22 +146,24 @@
$('#platform').append('<option value="' + result[i] + '">' + result[i]+'</option>'); $('#platform').append('<option value="' + result[i] + '">' + result[i]+'</option>');
} }
listWebsite(); //listWebsite();
} }
} }
}) })
} }
function listAccount() { function listAccount() {
var platform = $('#platform').val();
$.submit({ $.submit({
url: '@Url.Content("~/Reports/Orders/ListAccount")', url: '@Url.Content("~/Reports/Orders/ListAccount")',
type:'POST', type:'POST',
paramData: 'platform=FBA', paramData: 'platform=' + platform,
func: function (result) { func: function (result) {
if (result != null && result != undefined) { if (result != null && result != undefined) {
$('#saleaccount').html('<option value="">选择帐号</option>'); $('#account').html('<option value="">选择帐号</option>');
for (var i = 0; i < result.length; i++) { for (var i = 0; i < result.length; i++) {
$('#saleaccount').append('<option value="' + result[i] + '">' + result[i]+'</option>'); $('#account').append('<option value="' + result[i] + '">' + result[i]+'</option>');
} }
} }
} }
...@@ -170,10 +171,11 @@ ...@@ -170,10 +171,11 @@
} }
function listWebsite() { function listWebsite() {
var platform = $('#platform').val();
$.submit({ $.submit({
url: '@Url.Content("~/Reports/Orders/ListWebSite")', url: '@Url.Content("~/Reports/Orders/ListWebSite")',
type:'POST', type:'POST',
paramData: 'platform=FBA', paramData: 'platform=' + platform,
func: function (result) { func: function (result) {
if (result != null && result != undefined) { if (result != null && result != undefined) {
$('#website').html('<option value="">选择站点</option>'); $('#website').html('<option value="">选择站点</option>');
......
...@@ -94,7 +94,7 @@ ...@@ -94,7 +94,7 @@
for (var i = 0; i < result.length; i++) { for (var i = 0; i < result.length; i++) {
var s = '<tr><td class="platform"><a href="javascript:;" onclick="ShowWebsite(\'' + result[i].platform_type + '\');">' + result[i].platform_type + '</a></td>'; var s = '<tr><td class="platform"><a href="javascript:;" onclick="ShowWebsite(\'' + result[i].platform_type + '\');">' + result[i].platform_type + '</a></td>';
s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'订单数\',\'\',0)">' + result[i].order_count + '</td>'; s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'订单数\',\'\',0)">' + result[i].order_count + '</td>';
s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'销售额\',\'amount_sales\',1)">' + result[i].amount_sales + '</td>'; s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'销售额\',\'0\',0)">' + result[i].amount_sales + '</td>';
s += '<td>' + result[i].customerprice + '</td>'; s += '<td>' + result[i].customerprice + '</td>';
s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'平台费用\',\'cost_platform_fee\',1)">' + result[i].cost_platform_fee + '</td>'; s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'平台费用\',\'cost_platform_fee\',1)">' + result[i].cost_platform_fee + '</td>';
s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'头程费\',\'cost_first\',1)">' + result[i].cost_first + '</td>'; s += '<td class="alink" onclick="ShowDetail(\'' + result[i].platform_type + '\',\'头程费\',\'cost_first\',1)">' + result[i].cost_first + '</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