From 69a8bb4807c77d05b5b43328acbf4ad26fb5fc68 Mon Sep 17 00:00:00 2001
From: username@email.com <yzy2002yzy@163.com>
Date: 星期五, 05 五月 2023 15:00:52 +0800
Subject: [PATCH] 提交

---
 zhengcaioa/Services/ProjectService.cs |   53 +++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 53 insertions(+), 0 deletions(-)

diff --git a/zhengcaioa/Services/ProjectService.cs b/zhengcaioa/Services/ProjectService.cs
index 6fcde97..89a6f22 100644
--- a/zhengcaioa/Services/ProjectService.cs
+++ b/zhengcaioa/Services/ProjectService.cs
@@ -884,6 +884,16 @@
             return list;
         }
 
+        public List<ZhengfuProjectDTO> GetListsalaryzhengfu(string userid, DateTime datemin, DateTime datemax)
+        {
+
+
+            var listPosition = _webcontext.ZhengfuProjects.Where(r => r.RecStatus == "A" && r.Creater == userid && r.Createtime >= datemin && r.Createtime < datemax).ToList();
+
+            var list = _mapper.Map<List<ZhengfuProjectDTO>>(listPosition);
+            return list;
+        }
+
         public List<ZhengfuProjectDTO> GetcaigougonggaoListsalary(string userid, DateTime datemin, DateTime datemax)
         {
 
@@ -1400,5 +1410,48 @@
 
             return resultEntity;
         }
+
+
+        public ResultEntity GetZhengfuProjectDTOByTitle(string Title, string Id, DateTime? NoticeTime)
+        {
+            ResultEntity resultEntity = new ResultEntity();
+            resultEntity.Result = true;
+            if(!string.IsNullOrWhiteSpace(Title) && NoticeTime.HasValue)
+            {
+                var checkUserSn = _webcontext.ZhengfuProjects.Where(x => x.Title == Title && x.RecStatus == "A" && x.Id != Id && x.NoticeTime >= NoticeTime.Value.AddDays(-1) && x.NoticeTime <= NoticeTime.Value.AddDays(1)).FirstOrDefault();
+                if (checkUserSn != null && (string.IsNullOrWhiteSpace(Id) || (!string.IsNullOrWhiteSpace(Id) && checkUserSn.Id != Id)))
+                {
+                    resultEntity.Result = false;
+                    resultEntity.Message = "璇ラ〉闈㈠凡缁忓瓨鍦�";
+
+                }
+            }
+           
+
+
+            return resultEntity;
+        }
+
+       
+        public ResultEntity saveProjectfasongxiaoxi(Projectfasongxiaoxi project)
+        {
+            ResultEntity resultEntity = new ResultEntity();
+            try
+            {
+
+                project.Id = Guid.NewGuid().ToString();
+                _context.Projectfasongxiaoxis.Add(project);
+                _context.SaveChanges();
+                resultEntity.ReturnID = project.Id;
+                resultEntity.Result = true;
+            }
+            catch (Exception ex)
+            {
+                resultEntity.Result = false;
+                resultEntity.Message = "淇濆瓨澶辫触锛岃鑱旂郴绠$悊鍛�";
+
+            }
+            return resultEntity;
+        }
     }
 }

--
Gitblit v1.9.1