@using System.Reflection @using System.ComponentModel.DataAnnotations @using Shared.DTOs @typeparam T
@item.CustomAttributes.Where(w => w.AttributeType.Name == "DisplayAttribute").Select(s => s.NamedArguments.Where(w => w.MemberName == "Name").Select(ss => ss.TypedValue.Value).First()).First().ToString() | } }عملیات | }|||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
@decimal.Parse(property.GetValue(item, null).ToString()).ToString("N0") ريال | } else if (property.Name.ToLower() == "id" && item.ToString() != "Shared.DTOs.SentTaxDto") { if (id > 0) {} else { | } } else if (property.Name.ToLower() == "msgsentstatus" && item.ToString() == "Shared.DTOs.SentTaxDto") { var convertmodel = (SentTaxDto)Convert.ChangeType(item, typeof(SentTaxDto)); switch (convertmodel.SentStatus) { case SentStatus.Send: | @property.GetValue(item, null) | break; case SentStatus.Successful:@property.GetValue(item, null) | break; case SentStatus.Unsuccessful:@property.GetValue(item, null) | break; case SentStatus.pending :@property.GetValue(item, null) | break; case SentStatus.IN_PROGRESS :@property.GetValue(item, null) | break; case SentStatus.NOT_FOUND:@property.GetValue(item, null) | break; case SentStatus.Unknown:@property.GetValue(item, null) | break; default:@property.GetValue(item, null) | break; } } else {@property.GetValue(item, null) | } } } if (item.ToString() == "Shared.DTOs.SentTaxDto") { var convertmodel = (SentTaxDto)Convert.ChangeType(item, typeof(SentTaxDto)); if (convertmodel.SentStatus == SentStatus.Send || convertmodel.SentStatus == SentStatus.pending || convertmodel.SentStatus == SentStatus.IN_PROGRESS) {} else if (convertmodel.SentStatus == SentStatus.Unsuccessful) { | } else { | } } else { if (id > 0) { | } else { | } } } |