public ActionResult SaveDeliveryMethod(AnFDeliveryMethod anFDeliveryMethod)
        {
            Operation objOperation = new Operation { Success = false };

            if (ModelState.IsValid)
            {
                if (anFDeliveryMethod.Id == 0)
                {
                    if ((bool)Session["Add"])
                    {
                        objOperation = _dmService.SaveAnFDeliveryMethod(anFDeliveryMethod);
                    }
                    else { objOperation.OperationId = -1; }
                }
                else
                {
                    if ((bool)Session["Edit"])
                    {
                        objOperation = _dmService.UpdateAnFDeliveryMethod(anFDeliveryMethod);
                    }
                    else { objOperation.OperationId = -2; }
                }
            }

            return Json(objOperation, JsonRequestBehavior.DenyGet);
        }
        public Operation DeleteAnFDeliveryMethod(AnFDeliveryMethod objAnFDeliveryMethod)
        {
            Operation objOperation = new Operation { Success = true, OperationId = objAnFDeliveryMethod.Id };
            _AnFDeliveryMethodRepository.Delete(objAnFDeliveryMethod);

            try
            {
                _UnitOfWork.Commit();
            }
            catch (Exception)
            {

                objOperation.Success = false;
            }
            return objOperation;
        }
        public Operation SaveAnFDeliveryMethod(AnFDeliveryMethod objAnFDeliveryMethod)
        {
            Operation objOperation = new Operation { Success = true };

            long Id = _AnFDeliveryMethodRepository.AddEntity(objAnFDeliveryMethod);
            objOperation.OperationId = Id;

            try
            {
                _UnitOfWork.Commit();
            }
            catch (Exception ex)
            {
                objOperation.Success = false;
            }
            return objOperation;
        }