Ejemplo n.º 1
0
        public bool UpdateResetPassword(string userName, string NewPassword, string otp)
        {
            var user = tbl_UserRegistration.GetWithInclude(x => x.UserName.ToLower() == userName.ToLower() && x.OTPPassword == otp).FirstOrDefault();

            if (user == null)
            {
                return(false);
            }
            user.Password = NewPassword;
            tbl_UserRegistration.Update(user);
            return(true);
        }
Ejemplo n.º 2
0
        public long Save(CourseSessionModel model)
        {
            CourseSession _tbl_courseSession = new CourseSession(model);

            if (model.Id != null && model.Id != 0)
            {
                _CourseSession.Update(_tbl_courseSession);
            }
            else
            {
                _tbl_courseSession.CreatedOn = System.DateTime.Now;
                _CourseSession.Insert(_tbl_courseSession);
            }

            return(_tbl_courseSession.Id);
        }
        public int Save(ExistingMadarsaOperationsRequestModel model)
        {
            ExistingMadarsaOperationsRequest _tblList = new ExistingMadarsaOperationsRequest(model);

            _RequestSubmitModel.ShortDesc     = model.ShortDescription;
            _RequestSubmitModel.UserId        = model.UserId;
            _RequestSubmitModel.CreatedDate   = Convert.ToDateTime(System.DateTime.Now);
            _RequestSubmitModel.RequestTypeId = model.RequestTypeId;
            RequestSubmit _requestSubmit = new RequestSubmit(_RequestSubmitModel);

            if (_tblList.Id != null && _tblList.Id != 0)
            {
                _tblList.CreatedDate = Convert.ToDateTime(System.DateTime.Now);
                tbl_ExistingMadarsaOperationsRequestModel.Update(_tblList);
            }
            else
            {
                _requestSubmit           = _RequestSubmit.Insert(_requestSubmit);
                _tblList.RequestSubmitId = _requestSubmit.Id;
                _tblList.CreatedDate     = Convert.ToDateTime(System.DateTime.Now);
                _tblList = tbl_ExistingMadarsaOperationsRequestModel.Insert(_tblList);
            }


            return(_tblList.Id);
        }
Ejemplo n.º 4
0
        public int Save(EventRequestModel model)
        {
            EventRequest _eventRequest = new EventRequest(model);

            if (model.Id != null && model.Id != 0)
            {
                _EventRequest.Update(_eventRequest);
            }
            else
            {
                RequestSubmitModel res = new RequestSubmitModel();
                res.RequestTypeId = 9;
                res.UserId        = model.UserId;
                res.ShortDesc     = model.Description;

                int id = new RequestSubmitBs().Save(res);
                _eventRequest.RequestSubmitId = id;
                _eventRequest.Poster          = model.Poster;
                _eventRequest.CreatedDate     = System.DateTime.Now;
                _eventRequest.RequestTypeId   = 9;
                _EventRequest.Insert(_eventRequest);
            }

            return(_eventRequest.Id);
        }
Ejemplo n.º 5
0
        public int Save(MasjidLandRequestModel model)
        {
            MasjidLandRequest _tbl_mlr = new MasjidLandRequest(model);

            _RequestSubmitModel.ShortDesc     = model.ShortDescription;
            _RequestSubmitModel.UserId        = model.UserId;
            _RequestSubmitModel.CreatedDate   = Convert.ToDateTime(System.DateTime.Now);
            _RequestSubmitModel.RequestTypeId = model.RequestTypeId;
            RequestSubmit _requestSubmit = new RequestSubmit(_RequestSubmitModel);

            if (_tbl_mlr.Id != null && _tbl_mlr.Id != 0)
            {
                _tbl_mlr.CreatedDate = Convert.ToDateTime(System.DateTime.Now);
                //_tblList.CreatedBy = 1;
                _tbl_MLR.Update(_tbl_mlr);
            }
            else
            {
                _requestSubmit           = _RequestSubmit.Insert(_requestSubmit);
                _tbl_mlr.RequestSubmitId = _requestSubmit.Id;
                _tbl_mlr.CreatedDate     = Convert.ToDateTime(System.DateTime.Now);
                //_tblList.CreatedBy = 1;
                _tbl_mlr = _tbl_MLR.Insert(_tbl_mlr);
            }


            return(_tbl_mlr.Id);
        }
Ejemplo n.º 6
0
        public long Save(CourseModel model)
        {
            Course _tbl_course = new Course(model);

            if (model.Id != null && model.Id != 0)
            {
                _Course.Update(_tbl_course);
            }
            else
            {
                _tbl_course.IsDelete  = false;
                _tbl_course.CreatedOn = System.DateTime.Now;
                _Course.Insert(_tbl_course);
            }

            return(_tbl_course.Id);
        }
        public int SaveMasjidCommittee(AddMasjidCommittee model)
        {
            tbl_AddMasjidCommittee _tbl_addMasjidCommittee = new tbl_AddMasjidCommittee(model);

            if (model.Id != null && model.Id != 0)
            {
                _tbl_addMasjidCommittee.Status = true;
                _tbl_AddMasjidCommittee.Update(_tbl_addMasjidCommittee);
            }
            else
            {
                _tbl_addMasjidCommittee.CreatedBy   = 1;
                _tbl_addMasjidCommittee.CreatedDate = System.DateTime.Now;
                _tbl_addMasjidCommittee.Status      = true;
                _tbl_addMasjidCommittee             = _tbl_AddMasjidCommittee.Insert(_tbl_addMasjidCommittee);
            }

            return(_tbl_addMasjidCommittee.Id);
        }
        public int Save(NewMadarsaOperation model)
        {
            tbl_NewMadarsaOperations _tbl_EMO_LocalVar = new tbl_NewMadarsaOperations(model);

            if (model.Id != null && model.Id != 0)
            {
                _tbl_EMO_LocalVar.Status = true;
                _tbl_NewMadarsaOperations.Update(_tbl_EMO_LocalVar);
            }
            else
            {
                _tbl_EMO_LocalVar.CreateDate = System.DateTime.Now;
                _tbl_EMO_LocalVar.CreatedBy  = 1;
                _tbl_EMO_LocalVar.Status     = true;
                _tbl_EMO_LocalVar            = _tbl_NewMadarsaOperations.Insert(_tbl_EMO_LocalVar);
            }

            return(_tbl_EMO_LocalVar.Id);
        }
        public int SaveMasjidConstruction(MasjidConstruction model)
        {
            {
                tbl_MasjidConstruction _tbl_MasjidConstruction_LocalVar = new tbl_MasjidConstruction(model);
                if (model.Id != null && model.Id != 0)
                {
                    _tbl_MasjidConstruction_LocalVar.Status = true;
                    _tbl_MasjidConstruction.Update(_tbl_MasjidConstruction_LocalVar);
                }
                else
                {
                    _tbl_MasjidConstruction_LocalVar.CreatedDate = System.DateTime.Now;
                    _tbl_MasjidConstruction_LocalVar.CreatedBy   = 1;
                    _tbl_MasjidConstruction_LocalVar.Status      = true;
                    _tbl_MasjidConstruction_LocalVar             = _tbl_MasjidConstruction.Insert(_tbl_MasjidConstruction_LocalVar);
                }

                return(_tbl_MasjidConstruction_LocalVar.Id);
            }
        }
        public int SaveMasjidLandRequest(MasjidLandRequest model)
        {
            tbl_MasjidLandRequest _tbl_masjidLandRequest = new tbl_MasjidLandRequest(model);

#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
            if (model.Id != null && model.Id != 0)
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
            {
                _tbl_masjidLandRequest.Status = true;
                _tbl_MasjidLandRequest.Update(_tbl_masjidLandRequest);
            }
            else
            {
                _tbl_masjidLandRequest.CreatedBy   = 1;
                _tbl_masjidLandRequest.CreatedDate = System.DateTime.Now;
                _tbl_masjidLandRequest.Status      = true;
                _tbl_masjidLandRequest             = _tbl_MasjidLandRequest.Insert(_tbl_masjidLandRequest);
            }

            return(_tbl_masjidLandRequest.Id);
        }
Ejemplo n.º 11
0
        public long Save(CourseTestAnswerModel model)
        {
            Course_Test_Answer _tbl_courseTest = new Course_Test_Answer(model);

            if (model.Id != null && model.Id != 0)
            {
                _CourseTestAnswer.Update(_tbl_courseTest);
            }
            else
            {
                _CourseTestAnswer.Insert(_tbl_courseTest);
            }

            return(_tbl_courseTest.Id);
        }
Ejemplo n.º 12
0
        public int Save(UserCategoryMappingModel model)
        {
            UserCategoryMapping _tbl_usercategory = new UserCategoryMapping(model);

            if (model.Id != null && model.Id != 0)
            {
                _userCategory.Update(_tbl_usercategory);
            }
            else
            {
                _userCategory.Insert(_tbl_usercategory);
            }

            return(_tbl_usercategory.ID);
        }
Ejemplo n.º 13
0
        public long Save(CourseTestModel model)
        {
            Course_Test _tbl_course = new Course_Test(model);

            if (model.Id != null && model.Id != 0)
            {
                _CourseTest.Update(_tbl_course);
            }
            else
            {
                _CourseTest.Insert(_tbl_course);
            }

            return(_tbl_course.Id);
        }
Ejemplo n.º 14
0
        public int Save(ZoneModel model)
        {
            Zone _tblZone = new Zone(model);

            if (model.Id != null && model.Id != 0)
            {
                _tbl_Zone.Update(_tblZone);
            }
            else
            {
                _tblZone = _tbl_Zone.Insert(_tblZone);
            }

            return(_tblZone.Id);
        }
Ejemplo n.º 15
0
        public int Save(MasjidModel model)
        {
            Masjid _tbl_masjid = new Masjid(model);

            if (model.Id != null && model.Id != 0)
            {
                _tbl_Masjid.Update(_tbl_masjid);
            }
            else
            {
                _tbl_masjid.CreatedDate = System.DateTime.Now;
                _tbl_Masjid.Insert(_tbl_masjid);
            }

            return(_tbl_masjid.Id);
        }
Ejemplo n.º 16
0
        public int Save(PanelInvolvementModel model)
        {
            PanelInvolvement _panelInvolvement = new PanelInvolvement(model);

            if (model.Id != null && model.Id != 0)
            {
                _PanelInvolvement.Update(_panelInvolvement);
            }
            else
            {
                _panelInvolvement.CreatedDate = Convert.ToDateTime(System.DateTime.Now);
                _PanelInvolvement.Insert(_panelInvolvement);
            }

            return(_panelInvolvement.Id);
        }
Ejemplo n.º 17
0
        public int Save(VolunteerModel model)
        {
            Volunteer _volunteer = new Volunteer(model);

            if (model.Id != null && model.Id != 0)
            {
                _Volunteer.Update(_volunteer);
            }
            else
            {
                _volunteer.CreatedDate = System.DateTime.Now;
                _Volunteer.Insert(_volunteer);
            }

            return(_volunteer.Id);
        }
Ejemplo n.º 18
0
        public int AmeerComment(RequestSubmitModel model)
        {
            RequestSubmit _requestComment = new RequestSubmit(model);

            if (model.Id != null && model.Id != 0)
            {
                _RequestSubmit.Update(_requestComment);
            }
            else
            {
                //  _requestApprove.CreatedDate = System.DateTime.Now;

                _requestComment = _RequestSubmit.Insert(_requestComment);
            }

            return(_requestComment.Id);
        }
Ejemplo n.º 19
0
        public int Save(CategoryModel model)
        {
            Category _tbl_category = new Category(model);

            if (model.Id != null && model.Id != 0)
            {
                _Category.Update(_tbl_category);
            }
            else
            {
                _tbl_category.IsDelete    = false;
                _tbl_category.CreatedDate = System.DateTime.Now;
                _Category.Insert(_tbl_category);
            }

            return(_tbl_category.Id);
        }
Ejemplo n.º 20
0
        public int SaveEventDetails(EventRequestDetailModel model)
        {
            EventRequestDetail _eventRequestDetails = new EventRequestDetail(model);

            if (model.Id != null && model.Id != 0)
            {
                _EventRequestDetail.Update(_eventRequestDetails);
            }
            else
            {
                //_eventRequest.IsDelete = false;
                _eventRequestDetails.CreatedDate = System.DateTime.Now;
                _EventRequestDetail.Insert(_eventRequestDetails);
            }

            return(_eventRequestDetails.Id);
        }
Ejemplo n.º 21
0
        public int Save(RequestApproveModel model)
        {
            RequestApprove _requestApprove = new RequestApprove(model);

            if (model.Id != null && model.Id != 0)
            {
                _RequestApprove.Update(_requestApprove);
            }
            else
            {
                //  _requestApprove.CreatedDate = System.DateTime.Now;

                _requestApprove = _RequestApprove.Insert(_requestApprove);
            }

            return(_requestApprove.Id);
        }
        public int SaveMasjid(AddMasjid model)
        {
            tbl_AddMasjid _tbl_addmasjid = new tbl_AddMasjid(model);

            if (model.Id != null && model.Id != 0)
            {
                _tbl_addmasjid.Status = true;
                _tbl_AddMasjid.Update(_tbl_addmasjid);
            }
            else
            {
                _tbl_addmasjid.CreatedBy   = 1;
                _tbl_addmasjid.CreatedDate = System.DateTime.Now;
                _tbl_addmasjid.Status      = true;
                _tbl_addmasjid             = _tbl_AddMasjid.Insert(_tbl_addmasjid);
            }

            return(_tbl_addmasjid.Id);
        }
Ejemplo n.º 23
0
        public int Save(RequestSubmitModel model)
        {
            RequestSubmit requestSubmit = new RequestSubmit(model);
            int           id            = model.Id;
            var           res           = _RequestSubmit.GetById(id);

            //  res.IsApproved = model.IsApproved;
            // res.CreatedDate = Convert.ToDateTime(System.DateTime.Now);
            if (model.Id != null && model.Id != 0)
            {
                _RequestSubmit.Update(res);
            }
            else
            {
                requestSubmit = _RequestSubmit.Insert(requestSubmit);
            }

            return(requestSubmit.Id);
        }
Ejemplo n.º 24
0
        public int SaveMasjidCommitteeMember(AddMasjidCommitteeMember model)
        {
            tbl_AddMasjidCommitteeMember _tbl_addMasjidCommitteeMember = new tbl_AddMasjidCommitteeMember(model);

            if (model.Id != null && model.Id != 0)
            {
                _tbl_addMasjidCommitteeMember.Status = true;
                _tbl_AddMasjidCommitteeMember.Update(_tbl_addMasjidCommitteeMember);
            }
            else
            {
                _tbl_addMasjidCommitteeMember.CreatedBy  = 1;
                _tbl_addMasjidCommitteeMember.CreateDate = System.DateTime.Now;
                _tbl_addMasjidCommitteeMember.Status     = true;
                _tbl_addMasjidCommitteeMember            = _tbl_AddMasjidCommitteeMember.Insert(_tbl_addMasjidCommitteeMember);
            }

            return(_tbl_addMasjidCommitteeMember.Id);
        }
        public int SaveMadarsa(AddMadarsa model)
        {
            tbl_AddMadarsa _tbl_addMadarsa = new tbl_AddMadarsa(model);

            if (model.Id != null && model.Id != 0)
            {
                _tbl_addMadarsa.Status = true;
                _tbl_AddMadarsa.Update(_tbl_addMadarsa);
            }
            else
            {
                _tbl_addMadarsa.CreatedDate = System.DateTime.Now;
                _tbl_addMadarsa.CreatedBy   = 1;
                _tbl_addMadarsa.Status      = true;
                _tbl_addMadarsa             = _tbl_AddMadarsa.Insert(_tbl_addMadarsa);
            }

            return(_tbl_addMadarsa.Id);
        }
Ejemplo n.º 26
0
        public long Save(UserGroupModel model)
        {
            UserGroup _tbl_userGroup = new UserGroup(model);

            if (model.Id != null && model.Id != 0)
            {
                _tbl_userGroup.UpdatedOn = System.DateTime.Now;
                _tbl_userGroup.IsActive  = true;
                _userGroup.Update(_tbl_userGroup);
            }
            else
            {
                _tbl_userGroup.IsActive  = true;
                _tbl_userGroup.CreatedOn = System.DateTime.Now;
                _userGroup.Insert(_tbl_userGroup);
            }

            return(_tbl_userGroup.Id);
        }
Ejemplo n.º 27
0
        public int Save(CourseModel model)
        {
            Course _tblCourse = new Course(model);

            if (model.Id != null && model.Id != 0)
            {
                _tblCourse.CreatedOn = System.DateTime.Now;
                _tblCourse.CreatedBy = 1;
                _tbl_Course.Update(_tblCourse);
            }
            else
            {
                _tblCourse.CreatedOn = System.DateTime.Now;
                _tblCourse.CreatedBy = 1;

                _tblCourse = _tbl_Course.Insert(_tblCourse);
            }
            return((int)_tblCourse.Id);
        }
        public int SaveMasjidExtension(MasjidExtension model)
        {
            tbl_MasjidExtension _tbl_masjidExtension = new tbl_MasjidExtension(model);

            if (model.Id != null && model.Id != 0)

            {
                _tbl_masjidExtension.Status = true;
                _tbl_MasjidExtension.Update(_tbl_masjidExtension);
            }
            else
            {
                _tbl_masjidExtension.CreatedBy   = 1;
                _tbl_masjidExtension.CreatedDate = System.DateTime.Now;
                _tbl_masjidExtension.Status      = true;
                _tbl_masjidExtension             = _tbl_MasjidExtension.Insert(_tbl_masjidExtension);
            }

            return(_tbl_masjidExtension.Id);
        }
        public int SaveHalqa(AddHalqa model)
        {
            tbl_AddHalqa _tbl_addHalqa = new tbl_AddHalqa(model);

#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
            if (model.Id != null && model.Id != 0)
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
            {
                _tbl_addHalqa.Status = true;
                _tbl_AddHalqa.Update(_tbl_addHalqa);
            }
            else
            {
                _tbl_addHalqa.CreatedBy   = 1;
                _tbl_addHalqa.CreatedDate = System.DateTime.Now;
                _tbl_addHalqa.Status      = true;
                _tbl_addHalqa             = _tbl_AddHalqa.Insert(_tbl_addHalqa);
            }

            return(_tbl_addHalqa.Id);
        }
Ejemplo n.º 30
0
        public int Save(MadarsaModel model)
        {
            Madarsa _tblMadarsa = new Madarsa(model);

            if (model.Id != null && model.Id != 0)
            {
                _tblMadarsa.CreatedDate = System.DateTime.Now;
                _tblMadarsa.CreatedBy   = 1;
                _tbl_Madarsa.Update(_tblMadarsa);
            }
            else
            {
                _tblMadarsa.CreatedDate = System.DateTime.Now;
                _tblMadarsa.CreatedBy   = 1;

                _tblMadarsa = _tbl_Madarsa.Insert(_tblMadarsa);
            }


            return(_tblMadarsa.Id);
        }