|
@@ -130,100 +130,15 @@ namespace MySystem.Controllers
|
|
|
|
|
|
public string test()
|
|
|
{
|
|
|
- // WebCMSEntities db = new WebCMSEntities();
|
|
|
- // MerchantAddInfo merchantadd = db.MerchantAddInfo.FirstOrDefault(m => m.Id == 5660) ?? new MerchantAddInfo();
|
|
|
- // SortedList<string, string> obj = new SortedList<string, string>();
|
|
|
- // obj.Add("bind_time", DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss"));
|
|
|
- // obj.Add("merch_no", merchantadd.MchtNo);
|
|
|
- // obj.Add("name", merchantadd.CertMerchantName);
|
|
|
- // string IdCardNumber = merchantadd.IdCardNumber;
|
|
|
- // if(!string.IsNullOrEmpty(IdCardNumber))
|
|
|
- // {
|
|
|
- // IdCardNumber = IdCardNumber.Substring(0, 6) + "**********" + IdCardNumber.Substring(IdCardNumber.Length - 4);
|
|
|
- // }
|
|
|
- // obj.Add("supplement_info", IdCardNumber);
|
|
|
- // obj.Add("mobile", merchantadd.MobilePhone);
|
|
|
- // obj.Add("maker_code", "C00000001");
|
|
|
- // PushHelper.Instance.Do(obj);
|
|
|
- // string content = function.ReadInstance("/好哒地区.txt");
|
|
|
- // string[] contents = content.Split('\n');
|
|
|
- // foreach(string sub in contents)
|
|
|
- // {
|
|
|
- // string[] data = sub.Split(',');
|
|
|
- // if(data.Length == 6)
|
|
|
- // {
|
|
|
- // string CityName = "中国," + data[1];
|
|
|
- // bool op = db.OpenBankCityTable.Any(m => m.CityName == CityName);
|
|
|
- // if(!op)
|
|
|
- // {
|
|
|
- // db.OpenBankCityTable.Add(new OpenBankCityTable()
|
|
|
- // {
|
|
|
- // CityName = CityName,
|
|
|
- // Code = data[0] + "0000",
|
|
|
- // });
|
|
|
- // db.SaveChanges();
|
|
|
- // }
|
|
|
- // CityName = "中国," + data[1] + "," + data[3];
|
|
|
- // op = db.OpenBankCityTable.Any(m => m.CityName == CityName);
|
|
|
- // if(!op)
|
|
|
- // {
|
|
|
- // db.OpenBankCityTable.Add(new OpenBankCityTable()
|
|
|
- // {
|
|
|
- // CityName = CityName,
|
|
|
- // Code = data[2] + "00",
|
|
|
- // });
|
|
|
- // db.SaveChanges();
|
|
|
- // }
|
|
|
- // CityName = "中国," + data[1] + "," + data[3] + "," + data[5];
|
|
|
- // op = db.OpenBankCityTable.Any(m => m.CityName == CityName);
|
|
|
- // if(!op)
|
|
|
- // {
|
|
|
- // db.OpenBankCityTable.Add(new OpenBankCityTable()
|
|
|
- // {
|
|
|
- // CityName = CityName,
|
|
|
- // Code = data[4],
|
|
|
- // });
|
|
|
- // db.SaveChanges();
|
|
|
- // }
|
|
|
- // }
|
|
|
- // else
|
|
|
- // {
|
|
|
- // string CityName = "中国,," + data[1];
|
|
|
- // bool op = db.OpenBankCityTable.Any(m => m.CityName == CityName);
|
|
|
- // if(!op)
|
|
|
- // {
|
|
|
- // db.OpenBankCityTable.Add(new OpenBankCityTable()
|
|
|
- // {
|
|
|
- // CityName = CityName,
|
|
|
- // Code = data[0] + "0000",
|
|
|
- // });
|
|
|
- // db.SaveChanges();
|
|
|
- // }
|
|
|
- // CityName = "中国,," + data[1] + "," + data[3];
|
|
|
- // op = db.OpenBankCityTable.Any(m => m.CityName == CityName);
|
|
|
- // if(!op)
|
|
|
- // {
|
|
|
- // db.OpenBankCityTable.Add(new OpenBankCityTable()
|
|
|
- // {
|
|
|
- // CityName = CityName,
|
|
|
- // Code = data[2],
|
|
|
- // });
|
|
|
- // db.SaveChanges();
|
|
|
- // }
|
|
|
- // }
|
|
|
- // }
|
|
|
- // db.Dispose();
|
|
|
- // DateTime start = DateTime.Parse("2025-01-01 00:00:00");
|
|
|
- // Models.KxsMain.WebCMSEntities db = new Models.KxsMain.WebCMSEntities();
|
|
|
- // List<Models.KxsMain.ChangeTypes> brands = db.ChangeTypes.ToList();
|
|
|
- // List<Models.KxsMain.UserAccountRecord> records = db.UserAccountRecord.Where(m => m.CreateDate >= start && m.ChangeType > 300).ToList();
|
|
|
- // foreach(Models.KxsMain.UserAccountRecord record in records)
|
|
|
- // {
|
|
|
- // string name = brands.FirstOrDefault(m => m.Id == record.ChangeType).Name;
|
|
|
- // PrizePushHelper.Instance.Do(DateTime.Now.ToString("yyyyMMddHHmmssfff") + function.get_Random(8), name, record.ChangeType.ToString(), record.ChangeAmount, record.UserId, "{\"brand_id\":101,\"user_id\":" + record.UserId + "}");
|
|
|
- // }
|
|
|
- // db.SaveChanges();
|
|
|
-
|
|
|
+ WebCMSEntities db = new WebCMSEntities();
|
|
|
+ MerchantAddInfo AddInfo = db.MerchantAddInfo.FirstOrDefault(m => m.Id == 1) ?? new MerchantAddInfo();
|
|
|
+ db.Dispose();
|
|
|
+ // string result = HaoDaHelper.Instance.AddNewMerchant(AddNewMerchantSetUtil.SetValue(AddInfo), AddInfo.BrandId, AddInfo.AgentName);
|
|
|
+ CheckWeChatSignService.Instance.StartDo(new QueryMerchantStatus()
|
|
|
+ {
|
|
|
+ MerchantId = AddInfo.Id.ToString(),
|
|
|
+ MerchantNo = AddInfo.MchtNo,
|
|
|
+ });
|
|
|
return "ok";
|
|
|
}
|
|
|
|