From 52267147e624f3a0daef4870ba72f023ef9162a9 Mon Sep 17 00:00:00 2001
From: username@email.com <yzy2002yzy@163.com>
Date: 星期六, 07 十月 2023 12:46:29 +0800
Subject: [PATCH] 修改中国政府采购网爬虫规则
---
zhengcaioa/zhengcaioa/Timer/TimedBackgroundService.cs | 32 +++++++++++++++++++++++++++-----
1 files changed, 27 insertions(+), 5 deletions(-)
diff --git a/zhengcaioa/zhengcaioa/Timer/TimedBackgroundService.cs b/zhengcaioa/zhengcaioa/Timer/TimedBackgroundService.cs
index 5a71989..76d3848 100644
--- a/zhengcaioa/zhengcaioa/Timer/TimedBackgroundService.cs
+++ b/zhengcaioa/zhengcaioa/Timer/TimedBackgroundService.cs
@@ -139,14 +139,13 @@
jisuangonglinggongzi();
}
-
- _logger.LogInformation("鎶婅秴杩�90澶╄繕娌℃湁杞寲鐨勬。妗堝鎴风殑涓氬姟缁忕悊褰掍负鏃�");
- this.ywjlguiling();
- _logger.LogInformation("鎶婅秴杩�90澶╄繕娌℃湁杞寲鐨勬。妗堝鎴风殑涓氬姟缁忕悊褰掍负鏃犳墽琛岀粨鏉�");
-
_logger.LogInformation("鎶婁細鍛樼郴缁熷拰oa绯荤粺鎵嬫満鍙风浉鍚岀殑瀹㈡埛鍏宠仈璧锋潵");
this.huiyuanguanlian();
_logger.LogInformation("鎶婁細鍛樼郴缁熷拰oa绯荤粺鎵嬫満鍙风浉鍚岀殑瀹㈡埛鍏宠仈璧锋潵鎵ц缁撴潫");
+
+ _logger.LogInformation("鎶婅秴杩�90澶╄繕娌℃湁杞寲鐨勬。妗堝鎴风殑涓氬姟缁忕悊褰掍负鏃�");
+ this.ywjlguiling();
+ _logger.LogInformation("鎶婅秴杩�90澶╄繕娌℃湁杞寲鐨勬。妗堝鎴风殑涓氬姟缁忕悊褰掍负鏃犳墽琛岀粨鏉�");
}
catch (Exception ex)
{
@@ -329,6 +328,18 @@
if (frameworkUser != null)
{
cooperatecustomCustomer.HuiyuanId = frameworkUser.Id.ToString();
+ //2023-03-23 娣诲姞鍦ㄨ亴浼佷笟
+ var customerGuanlianhuiyuan1 = _context.CustomerGuanlianhuiyuans.Where(x => x.Huiyuanid == cooperatecustomCustomer.HuiyuanId && x.Customerid == cooperatecustomCustomer.Id).FirstOrDefault();
+ if (customerGuanlianhuiyuan1 == null)
+ {
+ CustomerGuanlianhuiyuan customerGuanlianhuiyuan = new CustomerGuanlianhuiyuan();
+ customerGuanlianhuiyuan.Id = Guid.NewGuid().ToString();
+ customerGuanlianhuiyuan.Huiyuanid = cooperatecustomCustomer.HuiyuanId;
+ customerGuanlianhuiyuan.Customerid = cooperatecustomCustomer.Id;
+ customerGuanlianhuiyuan.Customertype = "鍚堜綔瀹㈡埛";
+ _context.CustomerGuanlianhuiyuans.Add(customerGuanlianhuiyuan);
+ }
+
}
}
@@ -349,6 +360,17 @@
if (frameworkUser != null)
{
intentionCustomer.HuiyuanId = frameworkUser.Id.ToString();
+ //2023-03-23 娣诲姞鍦ㄨ亴浼佷笟
+ var customerGuanlianhuiyuan1 = _context.CustomerGuanlianhuiyuans.Where(x => x.Huiyuanid == intentionCustomer.HuiyuanId && x.Customerid == intentionCustomer.Id).FirstOrDefault();
+ if (customerGuanlianhuiyuan1 == null)
+ {
+ CustomerGuanlianhuiyuan customerGuanlianhuiyuan = new CustomerGuanlianhuiyuan();
+ customerGuanlianhuiyuan.Id = Guid.NewGuid().ToString();
+ customerGuanlianhuiyuan.Huiyuanid = intentionCustomer.HuiyuanId;
+ customerGuanlianhuiyuan.Customerid = intentionCustomer.Id;
+ customerGuanlianhuiyuan.Customertype = "妗f瀹㈡埛";
+ _context.CustomerGuanlianhuiyuans.Add(customerGuanlianhuiyuan);
+ }
}
}
--
Gitblit v1.9.1