Commit f23c851b by guanzhenshan

亚马逊广告导出增加asin字段

parent 567cf87a
......@@ -4433,7 +4433,7 @@ namespace Bailun.DC.Services
public List<dc_base_finance_amazon_ad_product> ListAmazonADSku(string account, DateTime? start, DateTime? end, int? companyid)
{
var sqlparam = new DynamicParameters();
var sql = "select t2.account_name,t1.sku,t1.currency,cost,(cost*exchange_rate) cost_rmb,report_date from dc_base_finance_amazon_ad_product t1 join dc_base_company_account t2 on t1.account_id=t2.account_id ";
var sql = "select t2.account_name,t1.sku,t1.currency,cost,(cost*exchange_rate) cost_rmb,report_date,asin from dc_base_finance_amazon_ad_product t1 join dc_base_company_account t2 on t1.account_id=t2.account_id ";
if (!string.IsNullOrEmpty(account))
{
......
......@@ -2208,6 +2208,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
var obj = _service.ListAmazonADSku(account, start, end, companyid);
var list = obj.Select(a => new {
a.asin,
a.account_name,
a.sku,
cost = a.cost.ToString("N2"),
......@@ -2217,7 +2218,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
});
var colNames = new List<string> {"帐号","SKU","费用", "币种", "费用RMB",
"报告日期"
"ASIN","报告日期"
};
var listVal = new List<string>();
......@@ -2225,7 +2226,7 @@ namespace Bailun.DC.Web.Areas.Reports.Controllers
{
listVal.Add(
item.account_name + "|" + item.sku + "|" + item.cost + "|" + item.currency + "|" + item.cost_rmb + "|" +
item.report_date
item.asin+"|"+item.report_date
);
}
......
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