Esempio n. 1
0
 /// <summary>
 /// 增加益损信息
 /// </summary>
 /// <param name="recordId">关联Id</param>
 /// <param name="targetType">目标类型</param>
 /// <param name="category">分类</param>
 /// <param name="quantity">数量</param>
 /// <param name="remark">备注</param>
 /// <param name="money">金额</param>
 /// <param name="creator">创建人</param>
 public void Create(string recordId, string targetType, string category, decimal quantity, string remark, string creator)
 {
     this.NewId();
     this.RecordId   = recordId;
     this.TargetType = targetType;
     this.Category   = category;
     this.Quantity   = quantity;
     this.Remark     = string.IsNullOrWhiteSpace(remark) ? string.Empty : remark.Trim();
     this.Creator    = creator;
     this.CreateTime = DataConvert.ConvertUTCToBeijing(DateTime.UtcNow);
 }
Esempio n. 2
0
 /// <summary>
 /// 创建
 /// </summary>
 /// <param name="deliveryId">交付ID</param>
 /// <param name="purchaseId">采购ID</param>
 /// <param name="purchaseCategory">采购分类</param>
 /// <param name="deliveryQuantity">交付数量</param>
 /// <param name="packQuantity">包装数量</param>
 /// <param name="packUnit">包装单位</param>
 /// <param name="creator">创建人</param>
 public void Create(string deliveryId, string purchaseId, string purchaseCategory, decimal deliveryQuantity, decimal packQuantity, string packUnit, string creator)
 {
     this.NewId();
     this.DeliveryId       = deliveryId;
     this.PurchaseId       = purchaseId;
     this.PurchaseCategory = purchaseCategory;
     this.DeliveryQuantity = deliveryQuantity;
     if (this.PurchaseCategory == PurchaseItemCategory.Product)
     {
         this.PackQuantity = packQuantity;
         this.PackUnit     = packUnit;
     }
     else
     {
         this.PackQuantity = Constant.DECIMAL_ZERO;
         this.PackUnit     = string.Empty;
     }
     this.Creator    = creator;
     this.CreateTime = DataConvert.ConvertUTCToBeijing(DateTime.UtcNow);
 }
Esempio n. 3
0
 /// <summary>
 /// 设置修改人和修改时间
 /// </summary>
 /// <param name="userId">用户Id</param>
 /// <param name="time">时间</param>
 public void SetMender(string userId, DateTime time)
 {
     this.Mender     = userId.Trim();
     this.ModifyTime = DataConvert.ConvertUTCToBeijing(time);
 }
Esempio n. 4
0
 /// <summary>
 /// 设置创建人和创建时间
 /// </summary>
 /// <param name="userId">用户Id</param>
 /// <param name="time">时间</param>
 public void SetCreator(string userId, DateTime time)
 {
     this.Creator    = userId.Trim();
     this.CreateTime = DataConvert.ConvertUTCToBeijing(time);
 }