Browse Source

添加默认选中

yuanrf 11 months ago
parent
commit
63746515e2

+ 6 - 1
OASystem/OASystem.Infrastructure/Repositories/Groups/CarTouristGuideGroundRepository.cs

@@ -315,7 +315,7 @@ namespace OASystem.Infrastructure.Repositories.Groups
                 {
                     //获取成本选中
                     var checkTopArr = _checkRep.GetCheckBoxsByDiid(grpCarOp.DiId);
-                    if (checkTopArr.Count > 0)
+                    if (true)
                     {
                         var FindTop = checkTopArr.Find(x => x.CbType == "Top");
                         if (FindTop != null)
@@ -336,6 +336,11 @@ namespace OASystem.Infrastructure.Repositories.Groups
                                 }
                             }
                         }
+                        else
+                        {
+                            checkedItem = new List<string>() { "车费", "导游费", "客户午餐费用", "导游景点费", "导游小费", "接送机费", "其他费用", "司机工资", "司机小费", "司机餐补", "车超时费", "导游餐补", "导游房补", "导游交通", "客户早餐费用", "客户晚餐费用", "景点门票费", "饮料/零食/水果", "住补费用", "翻译费" };
+                            checkedItemId.AddRange(_TableInitialization.Select(x => x.Id).ToList());
+                        }
                     }
                 }
                 else