Beispiel #1
0
        /// <summary>
        /// 绑定Grid
        /// </summary>
        public override void BindGrid()
        {
            ShipBoatRule rule = new ShipBoatRule();

            gridView1.GridControl.DataSource = rule.RShow(HTDataConditionStr, ProcessGrid.GetQueryField(gridView1));
            gridView1.GridControl.Show();
        }
Beispiel #2
0
        /// <summary>
        /// 删除
        /// </summary>
        public override void EntityDelete()
        {
            ShipBoatRule rule   = new ShipBoatRule();
            ShipBoat     entity = EntityGet();

            rule.RDelete(entity);
        }
Beispiel #3
0
        /// <summary>
        /// 修改
        /// </summary>
        public override void EntityUpdate()
        {
            ShipBoatRule rule   = new ShipBoatRule();
            ShipBoat     entity = EntityGet();

            ShipBoatDts[] entitydts = EntityDtsGet();
            entity.SubmitFlag = this.HTSubmitFlagUpdateGet();

            decimal PieceQty    = 0;
            decimal NetWeight   = 0;
            decimal CroosWeight = 0;
            //decimal BoxNum = 0;
            decimal BulkSize = 0;

            for (int i = 0; i < entitydts.Length; i++)
            {
                PieceQty    += entitydts[i].PieceQty;
                NetWeight   += entitydts[i].NetWeight;
                CroosWeight += entitydts[i].CrossWeight;
                // CroosWeight += entitydts[i].CrossWeight;
                // BoxNum += entitydts[i].BoxNum;
                BulkSize += entitydts[i].BulkSize;
            }
            entity.PackNum     = SysConvert.ToDecimal(PieceQty, 0);
            entity.NetWeight   = SysConvert.ToDecimal(NetWeight, 0);
            entity.CroosWeight = SysConvert.ToDecimal(CroosWeight, 0);
            // entity.PortDischarge = BoxNum.ToString();
            entity.TotalBulk = SysConvert.ToDecimal(BulkSize, 1);
            rule.RUpdate(entity, entitydts);
        }