Commit 444ad8c3 by lizefeng

rabbit mq 地址变更

parent 12298c6b
......@@ -59,10 +59,10 @@
"ProjectData": "https://web.bailuntec.com/gateway/system/api/visualdev/ComponentTable/ListData"
},
"RabbitMQ": {
"Host": "rabbitmq.bailuntec.com",
"Port": "6783",
"Host": "10.0.241.16",
"UserName": "bailun",
"Password": "bailun2022"
"Password": "bailun2022",
"Port": "5672"
}
}
\ No newline at end of file
......@@ -134,6 +134,9 @@ namespace AutoTurnOver.Services
transferFee.settlement_date_str = $"{transferFee.start_date.Value.ToString("yyyy-MM-ddTHH:mm:ss")}";
transferFee.other = transferFee.total;
transferFee.data_id = $"{transferFee.type}_{transferFee.account}-{transferFee.settlement_date_str}";
var events = GetFinancialEventsByGroupId(item, feeItem.FinancialEventGroupId);
feeDbs.Add(transferFee);
......@@ -141,7 +144,7 @@ namespace AutoTurnOver.Services
// 提取预留金额
// 预留金额
//decimal reserveAmount = 0M;
//var events = GetFinancialEventsByGroupId(item, feeItem.FinancialEventGroupId);
//var reserveCreditDatas = events.Where(s => s.AdjustmentEventList != null && s.AdjustmentEventList.Any(s => s.AdjustmentType == "ReserveCredit")).ToList();
//if (reserveCreditDatas.Count >= 1)
//{
......@@ -342,7 +345,7 @@ namespace AutoTurnOver.Services
}
}
public void SynchroReportIdByCreate(ReportTypes reportTypeEnum, int version = 8, string account = "", string site = "", DateTime? btime = null, DateTime? etime = null,int interval = 72)
public void SynchroReportIdByCreate(ReportTypes reportTypeEnum, int version = 8, string account = "", string site = "", DateTime? btime = null, DateTime? etime = null, int interval = 72)
{
if (btime != null && etime != null)
{
......@@ -2287,10 +2290,14 @@ namespace AutoTurnOver.Services
}
public void SetMarketplaceNameByDate()
public void SetMarketplaceNameByDate(int? id = null)
{
var datas = MyMySqlConnection._connection.Query<dc_base_amazon_fee>(" select * from dc_base_amazon_fee where ifnull(settlement_id,'-')='-' and ifnull(MarketplaceNameSys,'')='' order by id desc limit 1000 ").ToList();
//datas = datas.Where(s=>s.id== 263627).ToList();
if (id > 0)
{
datas = datas.Where(s => s.id == id).ToList();
}
foreach (var item in datas)
{
......@@ -2323,7 +2330,7 @@ namespace AutoTurnOver.Services
/// <summary>
/// 计算站点 (目前只有欧洲站点有这个情况)
/// </summary>
public void SetMarketplaceName(DateTime nowDate)
public void SetMarketplaceName(DateTime nowDate, int? id = 0)
{
var allSites = new List<string> { "Amazon.it", "Amazon.fr", "Amazon.nl", "Amazon.es", "Amazon.de", "Amazon.com.be" };
// 查询没有找到站点的结算表
......@@ -2331,6 +2338,10 @@ namespace AutoTurnOver.Services
{
nowDate = nowDate
}).ToList();
if (id > 0)
{
datas = datas.Where(s => s.id == id).ToList();
}
foreach (var item in datas)
{
// 查询这个计算表差不多时间
......
......@@ -49,13 +49,14 @@ namespace ResetOutofstock
//report_invest_return_dao.SynchBtmOrderRefund();
//report_invest_return_dao.CalculationStockScore("962073701");
//dc_ana_deviation_dao.PushAnaTask();
new AmazonDataSynchroService().SynchroFinancialEventGroups("Zayigus", "US");
//new AmazonDataSynchroService().SynchroFinancialEventGroups("ouzyi", "FR");
//new AmazonDataSynchroService().SetMarketplaceName(DateTime.Now);
//new AmazonDataSynchroService().SetSettlementByDate();
//new AmazonDataSynchroService().SetMarketplaceNameByDate();
new AmazonDataSynchroService().SetMarketplaceName(DateTime.Now.AddHours(-24), 372205);
//new AmazonDataSynchroService().SetMarketplaceNameByDate(id: 341198);
//new AmazonDataSynchroService().SynchroReportIds();
//new AmazonDataSynchroService().SynchroReportIdByCreate(FikaAmazonAPI.Utils.Constants.ReportTypes.GET_AFN_INVENTORY_DATA_BY_COUNTRY, 17, "Siqidzi", "ES");
//new AmazonDataSynchroService().SynchroReportIdByCreate(FikaAmazonAPI.Utils.Constants.ReportTypes.GET_V2_SETTLEMENT_REPORT_DATA_XML, 23, "Ruieach", "US");
//new AmazonDataSynchroService().SynchroReportIdByCreate(FikaAmazonAPI.Utils.Constants.ReportTypes.GET_FBA_INVENTORY_PLANNING_DATA, version: 22, account: "Elite99 Nail Art", site: "US",
// btime: DateTime.Parse("2023-04-01"), DateTime.Parse("2023-04-24 23:59:59"));
//new AmazonDataSynchroService().SynchroReportIds(FikaAmazonAPI.Utils.Constants.ReportTypes.GET_AFN_INVENTORY_DATA, 13, "Natural Daisy Encens", "ES");
......
......@@ -59,10 +59,10 @@
"ProjectData": "https://web.bailuntec.com/gateway/system/api/visualdev/ComponentTable/ListData"
},
"RabbitMQ": {
"Host": "10.0.6.36",
"Host": "10.0.241.16",
"UserName": "bailun",
"Password": "bailun2022",
"Port": "6783"
"Port": "5672"
}
}
\ No newline at end of file
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