Ejemplo n.º 1
0
        public void DeleteData(ModelNotifiedForOrderDetails modelNotifiedForOrderDetails, out string error)
        {
            OrderDetailsBsn  bsn    = new OrderDetailsBsn(wpfConfig);
            OrderDetailsInfo dbItem = new OrderDetailsInfo();

            Cloner.CopyAllTo(typeof(ModelNotifiedForOrderDetails), modelNotifiedForOrderDetails, typeof(OrderDetailsInfo), dbItem);
            bsn.DeleteByID(dbItem, out error);
        }
Ejemplo n.º 2
0
        public void DeleteData(ModelNotifiedForOrderDetails modelNotifiedForOrderDetails, out string error)
        {
            OrderDetailsGenericREST OrderDetailsGenericREST = new OrderDetailsGenericREST(wpfConfig);
            DeleteOrderDetailsView  deleteOrderDetailsView  = new DeleteOrderDetailsView();

            Cloner.CopyAllTo(typeof(ModelNotifiedForOrderDetails), modelNotifiedForOrderDetails, typeof(DeleteOrderDetailsView), deleteOrderDetailsView);
            OrderDetailsGenericREST.Delete(deleteOrderDetailsView, out error);
        }
Ejemplo n.º 3
0
        public void AddData(ModelNotifiedForOrderDetails modelNotifiedForOrderDetails, out string error)
        {
            OrderDetailsGenericREST OrderDetailsGenericREST = new OrderDetailsGenericREST(wpfConfig);
            CreateOrderDetailsView  createOrderDetailsView  = new CreateOrderDetailsView();

            Cloner.CopyAllTo(typeof(ModelNotifiedForOrderDetails), modelNotifiedForOrderDetails, typeof(CreateOrderDetailsView), createOrderDetailsView);
            OrderDetailsGenericREST.Insert(createOrderDetailsView, out error);
        }
Ejemplo n.º 4
0
        public void SaveData(ModelNotifiedForOrderDetails modelNotifiedForOrderDetails, out string error)
        {
            OrderDetailsGenericREST OrderDetailsGenericREST = new OrderDetailsGenericREST(wpfConfig);
            UpdateOrderDetailsView  updateOrderDetailsView  = new UpdateOrderDetailsView();

            Cloner.CopyAllTo(typeof(ModelNotifiedForOrderDetails), modelNotifiedForOrderDetails, typeof(UpdateOrderDetailsView), updateOrderDetailsView);
            OrderDetailsGenericREST.Update(updateOrderDetailsView, out error);
        }
Ejemplo n.º 5
0
        public ModelNotifiedForOrderDetails GetOrderDetailsByID(int OrderID, int ProductID, out string error)
        {
            error = null;
            OrderDetailsBsn              bsn    = new OrderDetailsBsn(wpfConfig);
            OrderDetailsInfo             dbItem = bsn.GetValueByID(OrderID, ProductID);
            ModelNotifiedForOrderDetails item   = new ModelNotifiedForOrderDetails();

            Cloner.CopyAllTo(typeof(OrderDetailsInfo), dbItem, typeof(ModelNotifiedForOrderDetails), item);
            return(item);
        }
Ejemplo n.º 6
0
        public void AddData(ModelNotifiedForOrderDetails modelNotifiedForOrderDetails, out string error)
        {
            OrderDetailsBsn  bsn    = new OrderDetailsBsn(wpfConfig);
            OrderDetailsInfo dbItem = new OrderDetailsInfo();

            Cloner.CopyAllTo(typeof(ModelNotifiedForOrderDetails), modelNotifiedForOrderDetails, typeof(OrderDetailsInfo), dbItem);
            bsn.InsertOne(dbItem, out error);
            modelNotifiedForOrderDetails.NewItem = false;
            Cloner.CopyAllTo(typeof(OrderDetailsInfo), dbItem, typeof(ModelNotifiedForOrderDetails), modelNotifiedForOrderDetails);
        }
Ejemplo n.º 7
0
        public ModelNotifiedForOrderDetails GetOrderDetailsByID(int OrderID, int ProductID, out string error)
        {
            error = null;
            OrderDetailsGenericREST      OrderDetailsGenericREST      = new OrderDetailsGenericREST(wpfConfig);
            GetOrderDetailsView          getOrderDetailsView          = OrderDetailsGenericREST.GetByPK <GetOrderDetailsView>(OrderID, ProductID, out error)[0];
            ModelNotifiedForOrderDetails modelNotifiedForOrderDetails = new ModelNotifiedForOrderDetails();

            Cloner.CopyAllTo(typeof(GetOrderDetailsView), getOrderDetailsView, typeof(ModelNotifiedForOrderDetails), modelNotifiedForOrderDetails);
            return(modelNotifiedForOrderDetails);
        }