/// <summary> /// 绑定Grid /// </summary> public override void BindGrid() { JYOrderRule rule = new JYOrderRule(); gridView1.GridControl.DataSource = rule.RShowDts(HTDataConditionStr, ProcessGrid.GetQueryField(gridView1).Replace("SelectFlag", "0 SelectFlag")); gridView1.GridControl.Show(); }
/// <summary> /// 删除 /// </summary> public override void EntityDelete() { JYOrderRule rule = new JYOrderRule(); JYOrder entity = EntityGet(); rule.RDelete(entity); }
/// <summary> /// 修改 /// </summary> public override void EntityUpdate() { JYOrderRule rule = new JYOrderRule(); JYOrder entity = EntityGet(); JYOrderDts[] entitydts = EntityDtsGet(); decimal totalqty = 0m; for (int i = 0; i < entitydts.Length; i++) { totalqty += SysConvert.ToDecimal(entitydts[i].Qty); } entity.TotalQty = totalqty; entity.SubmitFlag = this.HTSubmitFlagUpdateGet(); rule.RUpdate(entity, entitydts); }
/// <summary> /// 新增 /// </summary> public override int EntityAdd() { JYOrderRule rule = new JYOrderRule(); JYOrder entity = EntityGet(); JYOrderDts[] entitydts = EntityDtsGet(); decimal totalqty = 0m; for (int i = 0; i < entitydts.Length; i++) { totalqty += SysConvert.ToDecimal(entitydts[i].Qty); } entity.TotalQty = totalqty; entity.SubmitFlag = this.HTSubmitFlagInsertGet(); rule.RAdd(entity, entitydts); return(entity.ID); }