コード例 #1
0
        public ResultViewModels <ResturantPackageEditViewModel> AddResturantPackage(ResturantPackageEditViewModel ResturantPackageEditView)
        {
            ResultViewModels <ResturantPackageEditViewModel> result
                = new ResultViewModels <ResturantPackageEditViewModel>();

            try
            {
                var resturantpackageTemp = resturantPackageService.Add(ResturantPackageEditView);
                if (resturantpackageTemp == null)
                {
                    result.Successed = false;
                    result.Message   = "Data is empty";
                }
                else
                {
                    result.Successed = true;

                    result.Message = "Data added";
                    result.Data    = resturantpackageTemp;
                }
            }
            catch (Exception ex)
            {
                result.Successed = false;
                result.Message   = "Something Went Wrong !!";
            }

            return(result);
        }
コード例 #2
0
        public ResturantPackageEditViewModel AddResturantPackage(ResturantPackageEditViewModel ResturantPackageEditView)
        {
            var ResturantPackage = resturantPackageService.Add(ResturantPackageEditView);

            return(ResturantPackage);
        }