From 274fb67703d0ffcc7e3398d41855c5c8bfb3383b Mon Sep 17 00:00:00 2001
From: username@email.com <yzy2002yzy@163.com>
Date: 星期五, 25 六月 2021 13:07:44 +0800
Subject: [PATCH] Merge branch 'master' of http://47.108.235.38:8080/r/zhengcaioa

---
 zhengcaioa/Services/SimService.cs |   24 +++++++++++++++---------
 1 files changed, 15 insertions(+), 9 deletions(-)

diff --git a/zhengcaioa/Services/SimService.cs b/zhengcaioa/Services/SimService.cs
index d8cd69a..07fdc0e 100644
--- a/zhengcaioa/Services/SimService.cs
+++ b/zhengcaioa/Services/SimService.cs
@@ -289,19 +289,25 @@
             ResultDataEntity<SimCostView> data = new ResultDataEntity<SimCostView>();
             try
             {
-                var codedata = (from e in _context.SysCodes
-                                join c in _context.SysCodeDtls
-                                on e.Id equals c.CodeId
-                                where e.RecStatus == "A"
-                                && c.RecStatus == "A"
-                                && e.CodeTable == "t_sim_bind"
-                                && e.CodeField == "cardpro"
-                                select c).OrderBy(x => x.Sort).ToList();
+                //var codedata = (from e in _context.SysCodes
+                //                join c in _context.SysCodeDtls
+                //                on e.Id equals c.CodeId
+                //                where e.RecStatus == "A"
+                //                && c.RecStatus == "A"
+                //                && e.CodeTable == "t_sim_bind"
+                //                && e.CodeField == "cardpro"
+                //                select c).OrderBy(x => x.Sort).ToList();
 
                 var dt = _context.SimCostView.OrderByDescending(c => c.accounted_time).ToList();
                 if (!string.IsNullOrEmpty(searchEntity.searchtime))
                 {
-                    //dt = dt.Where(c => c.simcard.Contains(searchEntity.simcard)).ToList();
+                    var times = searchEntity.searchtime.Split('|');
+                    if(times.Length==2)
+                    {
+                        DateTime d1 = DateTime.Parse(times[0]);
+                        DateTime d2 = DateTime.Parse(times[1]);
+                        dt = dt.Where(c => c.accounted_time > d1 && c.accounted_time < d2).ToList();
+                    }                    
                 }
                 if (!string.IsNullOrEmpty(searchEntity.searchsim))
                 {

--
Gitblit v1.9.1