瀏覽代碼

简化审核状态处理逻辑

在 `Fin_DailyFeePaymentView.cs` 文件中,优化了 `FAudit` 和 `MAudit` 的审核状态处理逻辑。将多行的 `if-else` 结构改为单行 `if` 语句,提升了代码的可读性和简洁性。同时,增加了对 `MAudit == 3` 的处理,确保所有审核状态均被正确处理。
LEIYI 2 天之前
父節點
當前提交
dbc6bbee58
共有 1 個文件被更改,包括 4 次插入15 次删除
  1. 4 15
      OASystem/OASystem.Domain/ViewModels/Financial/Fin_DailyFeePaymentView.cs

+ 4 - 15
OASystem/OASystem.Domain/ViewModels/Financial/Fin_DailyFeePaymentView.cs

@@ -96,21 +96,9 @@ namespace OASystem.Domain.ViewModels.Financial
             {
                 string str = "未审核";
                 if (FAudit == 0) str = "未审核";
-                else if (FAudit == 1)
-                {
-                    str = "已通过";
-                    FAuditName = "朱成梅";
-                }
-                else if (FAudit == 2)
-                {
-                    str = "未通过";
-                    FAuditName = "朱成梅";
-                }
-                else if (FAudit == 3)
-                {
-                    str = "自动审核";
-                    FAuditName = "管理员";
-                }
+                else if (FAudit == 1) { str = "已通过"; FAuditName = "朱成梅"; }
+                else if (FAudit == 2) { str = "未通过"; FAuditName = "朱成梅"; }
+                else if (FAudit == 3) { str = "自动审核"; FAuditName = "管理员"; }
                 return str;
             }
         }
@@ -136,6 +124,7 @@ namespace OASystem.Domain.ViewModels.Financial
                 if (MAudit == 0) str = "未审核";
                 else if (MAudit == 1) { str = "已通过"; MAuditName = "张海麟"; }
                 else if (MAudit == 2) { str = "未通过"; MAuditName = "张海麟"; }
+                else if (MAudit == 3) { str = "自动审核"; MAuditName = "管理员"; }
                 return str;
             }
         }