Ejemplo n.º 1
0
        public async Task <IActionResult> CheckOutEquipmentStock(EquipmentInventoryCVM equipmentInventoryVM)
        {
            EquipmentsInventoryVM _checkOutEquipment = new EquipmentsInventoryVM
            {
                EventDetailsID     = equipmentInventoryVM.EventDetailsID,
                EquipmentDetailsID = equipmentInventoryVM.EquipmentDetailsID,
                Quantity           = equipmentInventoryVM.Quantity,
                Remarks            = equipmentInventoryVM.Remarks,
                UserID             = CurrentUser.ID
            };

            var response = await mediator.Send(new CheckOutEquipmentStockCommand
            {
                MyEquipmentInventoryVM = _checkOutEquipment
            });

            return(Json(response));
        }
Ejemplo n.º 2
0
        public async Task <IActionResult> AddEquipmentInventory(EquipmentInventoryCVM equipmentInventoryVM)
        {
            EquipmentsInventoryVM _equipmentInventory = new EquipmentsInventoryVM
            {
                EquipmentDetailsID = equipmentInventoryVM.EquipmentDetailsID,
                DeliveryDetailsID  = equipmentInventoryVM.DeliveryDetailsID,
                UserID             = CurrentUser.ID,
                EncodingDate       = DateTime.Now,
                ItemPrice          = equipmentInventoryVM.ItemPrice,
                Quantity           = equipmentInventoryVM.Quantity,
                Remarks            = equipmentInventoryVM.Remarks
            };

            var response = await mediator.Send(new AddEquipmentInventoryCommand
            {
                MyEquipmentsInventoryVM = _equipmentInventory
            });

            return(Json(response));
        }