Ejemplo n.º 1
0
        public bool Insert()
        {
            bool flag = false;

            using (PersistentManager persistentManager = new PersistentManager())
            {
                DeliveryBillDetailDao dao = new DeliveryBillDetailDao();

                string sql = string.Format("Insert into WMS_OUT_BILLDETAIL (ID,BILLNO,PRODUCTCODE,PRICE,QUANTITY,OUTPUTQUANTITY,UNITCODE,MEMO) values('{0}','{1}','{2}','{3}','{4}','{5}','{6}','{7}')"
                                           , this.ID, this.BILLNO,
                                           this.PRODUCTCODE,
                                           this.PRICE,
                                           this.QUANTITY,
                                           this.OUTPUTQUANTITY,
                                           this.UNITCODE,
                                           this.MEMO);
                dao.SetData(sql);
                flag = true;
            }
            return(flag);
        }
Ejemplo n.º 2
0
        public bool Update()
        {
            bool flag = false;

            using (PersistentManager persistentManager = new PersistentManager())
            {
                DeliveryBillDetailDao dao = new DeliveryBillDetailDao();
                string sql = string.Format("update WMS_OUT_BILLDETAIL set BILLNO='{1}',PRODUCTCODE='{2}',PRICE='{3}',QUANTITY='{4}',OUTPUTQUANTITY='{5}',UNITCODE='{6}',MEMO='{7}'  where ID='{0}'"
                                           , this.ID,
                                           this.BILLNO,
                                           this.PRODUCTCODE,
                                           this.PRICE,
                                           this.QUANTITY,
                                           this.OUTPUTQUANTITY,
                                           this.UNITCODE,
                                           this.MEMO);

                dao.SetData(sql);
                flag = true;
            }
            return(flag);
        }