amigotrip месяцев назад: 7
Родитель
Сommit
81a779e41a

+ 11 - 3
OASystem/OASystem.Api/Controllers/StatisticsController.cs

@@ -3025,7 +3025,6 @@ Order By Count Desc");
             }
         }
 
-
         /// <summary>
         /// 日付类型数据 Save
         /// </summary>
@@ -3153,10 +3152,19 @@ Where dfp.IsDel = 0 And dfp.IsPay = 1
                         x.Contents = _sqlSugar.Queryable<DailyFeePaymentContentView>()
                                               .SetContext(x1 => x1.DFPId, () => x.Id, x)
                                               .ToList();
-                    });
-
 
+                        //string str = "";
+                        //int index = 1;
+                        //foreach (var item in x.Contents)
+                        //{
+                        //    string str1 = $"{index}、费用名称:[{item.PriceName}]   单价:[{item.Price.ToString("#0.00")}]   数量:[{item.Quantity.ToString("#0.00")}]   小计:[{item.ItemTotal.ToString("#0.00")}]   备注:[{item.Remark}]";
 
+                        //    if (index == x.Contents.Count) str += str1;
+                        //    else str += str1 + "\r\n";
+                        //    index++;
+                        //}
+                        //x.ContentStr = str;
+                    });
 
                     return Ok(JsonView(true, "操作成功!", _view, total));
                 }

+ 24 - 8
OASystem/OASystem.Domain/ViewModels/Financial/Fin_DailyFeePaymentView.cs

@@ -516,7 +516,13 @@ namespace OASystem.Domain.ViewModels.Financial
     [SqlSugar.SugarTable("Fin_DailyFeePayment")]
     public class DailyFeePaymentRangeView
     {
-        public string ViewStr { get; set; }
+        public string ViewStr
+        {
+            get
+            {
+                return $"{RowIndex}、【{CompanyName}】【{TransferType}】【{FeeType}】【{Instructions}】【{SumPrice.ToString("#0.00")}】【申请人:{Applicant}  申请时间:{ApplicantDt.ToString("yyyy-MM-dd HH:mm:ss")}】";
+            }
+        }
 
         [SugarColumn(IsIgnore = true)]//需要加上
         public int RowIndex { get; set; } //行号 序号
@@ -538,19 +544,16 @@ namespace OASystem.Domain.ViewModels.Financial
 
         [Navigate(NavigateType.OneToMany, nameof(DailyFeePaymentContentView.DFPId))]//BookA表中的studenId
         public List<DailyFeePaymentContentView> Contents { get; set; }
+
+
+        //public string ContentStr { get; set; }
     }
 
 
     [SqlSugar.SugarTable("Fin_DailyFeePaymentContent")]
     public class DailyFeePaymentContentView
     {
-        /// <summary>
-        /// 示例:费用名称:[2024.07.11招商信用卡还款]   单价:[20000.00]   数量:[1.00]   小计:[20000.00]   备注:[]
-        /// </summary>
-        public string ViewStr { get {
-
-                return $"费用名称:[{PriceName}]   单价:[{Price.ToString("#0.00")}]   数量:[{Quantity.ToString("#0.00")}]   小计:[{ItemTotal.ToString("#0.00")}]   备注:[{Remark}]";
-            } }
+        
         //[SugarColumn(IsIgnore = true)]//需要加上
         //public int RowIndex { get; set; } //行号 序号
         [SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
@@ -569,6 +572,19 @@ namespace OASystem.Domain.ViewModels.Financial
         public string Remark { get; set; }
 
         //public int IsDel { get; set; }
+
+        /// <summary>
+        /// 示例:费用名称:[2024.07.11招商信用卡还款]   单价:[20000.00]   数量:[1.00]   小计:[20000.00]   备注:[]
+        /// </summary>
+        //public string ViewStr
+        //{
+        //    get
+        //    {
+        //        return $"费用名称:[{PriceName}]   单价:[{Price.ToString("#0.00")}]   数量:[{Quantity.ToString("#0.00")}]   小计:[{ItemTotal.ToString("#0.00")}]   备注:[{Remark}]";
+        //    }
+        //}
+
+        //public string ViewSubStr { get; set; }
     }