示例#1
0
 public void Post([FromBody] RestaurantPOS_OrderedProductBillKOT RestaurantPOS_OrderedProductBillKOT)
 {
     if (ModelState.IsValid)
     {
         RestaurantPOS_OrderedProductBillKOTRepository.Add(RestaurantPOS_OrderedProductBillKOT);
     }
 }
示例#2
0
        public void Put(int OP_ID, [FromBody] RestaurantPOS_OrderedProductBillKOT RestaurantPOS_OrderedProductBillKOT)
        {
            RestaurantPOS_OrderedProductBillKOT.OP_ID = OP_ID;

            if (ModelState.IsValid)
            {
                RestaurantPOS_OrderedProductBillKOTRepository.Update(RestaurantPOS_OrderedProductBillKOT);
            }
        }
 public void Update(RestaurantPOS_OrderedProductBillKOT RestaurantPOS_OrderedProductBillKOT)
 {
     using (IDbConnection dbConnection = Connection)
     {
         string sQuery = "UPDATE RestaurantPOS_OrderedProductBillKOT SET  BillID=@BillID, Dish=@Dish, Rate=@Rate, Quantity=@Quantity, Amount=@Amount, VATPer=@VATPer, VATAmount=@VATAmount,STPer=@STPer,STAmount=@STAmount,SCPer=@SCPer,SCAmount=@SCAmount,DiscountPer=@DiscountPer,DiscountAmount=@DiscountAmount,TotalAmount=@TotalAmount,TableNo=@TableNo"
                         + " WHERE OP_ID = @OP_ID";
         dbConnection.Open();
         dbConnection.Query(sQuery, RestaurantPOS_OrderedProductBillKOT);
     }
 }
 public void Add(RestaurantPOS_OrderedProductBillKOT RestaurantPOS_OrderedProductBillKOT)
 {
     using (IDbConnection dbConnection = Connection)
     {
         string sQuery = " INSERT INTO RestaurantPOS_OrderedProductBillKOT(BillID, Dish, Rate, Quantity, Amount, VATPer, VATAmount ,STPer,STAmount,SCPer, SCAmount, DiscountPer, DiscountAmount, TotalAmount, TableNo )"
                         + " VALUES(@BillID, @Dish, @Rate, @Quantity, @Amount, @VATPer, @VATAmount,@STPer,@STAmount,@SCPer,@SCAmount,@DiscountPer,@DiscountAmount,@TotalAmount,@TableNo   )";
         dbConnection.Open();
         dbConnection.Query(sQuery, RestaurantPOS_OrderedProductBillKOT);
     }
 }