Ejemplo n.º 1
0
 /// <summary>
 /// Add JobSeekerApplyStatus AppService
 /// </summary>
 /// <returns>bool<bool></returns>
 public async Task <bool> AddJobSeekerApplyStatus(JobSeekerApplyStatusAddDTO jobSeekerApplyStatusAddDTO)
 {
     #region Declare a return type with initial value.
     bool isCreated = false;
     #endregion
     try
     {
         if (jobSeekerApplyStatusAddDTO != null)
         {
             isCreated = await JobSeekerApplyStatusBusinessMapping.AddJobSeekerApplyStatus(jobSeekerApplyStatusAddDTO);
         }
     }
     catch (Exception exception) {}
     return(isCreated);
 }
        /// <summary>
        /// Create User Action Activity Log
        /// </summary>
        /// <param name=></param>
        /// <returns>bool</returns>
        public async Task <bool> AddJobSeekerApplyStatus(JobSeekerApplyStatusAddDTO JobSeekerApplyStatusAddDTO)
        {
            #region Declare a return type with initial value.
            bool isJobSeekerApplyStatusCreated = default(bool);
            #endregion
            try
            {
                #region Vars
                JobSeekerApplyStatus JobSeekerApplyStatus = null;
                #endregion
                JobSeekerApplyStatus = JobSeekerApplyStatusMapping.MappingJobSeekerApplyStatusAddDTOToJobSeekerApplyStatus(JobSeekerApplyStatusAddDTO);
                if (JobSeekerApplyStatus != null)
                {
                    await UnitOfWork.JobSeekerApplyStatusRepository.Insert(JobSeekerApplyStatus);

                    isJobSeekerApplyStatusCreated = await UnitOfWork.Commit() > default(int);
                }
            }
            catch (Exception exception)
            {
            }
            return(isJobSeekerApplyStatusCreated);
        }
 /// <summary>
 /// Mapping user Action Actitvity Log
 /// </summary>
 /// <param name=></ param >
 /// <returns>Task<JobSeekerApplyStatus></returns>
 public JobSeekerApplyStatus MappingJobSeekerApplyStatusAddDTOToJobSeekerApplyStatus(JobSeekerApplyStatusAddDTO JobSeekerApplyStatusAddDTO)
 {
     #region Declare a return type with initial value.
     JobSeekerApplyStatus JobSeekerApplyStatus = null;
     #endregion
     try
     {
         JobSeekerApplyStatus = new JobSeekerApplyStatus
         {
             JobSeekerApplyStatusName = JobSeekerApplyStatusAddDTO.JobSeekerApplyStatusName,
             CreationDate             = DateTime.Now,
             IsDeleted = (byte)DeleteStatusEnum.NotDeleted
         };
     }
     catch (Exception exception) { }
     return(JobSeekerApplyStatus);
 }
Ejemplo n.º 4
0
        public async Task <ActionResult <CommonAPIResponse <bool> > > AddJobSeekerApplyStatus(JobSeekerApplyStatusAddDTO JobSeekerApplyStatusAddDTO)
        {
            #region Declare return type with initial value.
            JsonResult jsonResult = GetDefaultJsonResult <bool>();
            #endregion

            try
            {
                #region Validate AddJobSeekerApplyStatus for nullability before prepaing the response.

                if (await JobSeekerApplyStatusAppService.AddJobSeekerApplyStatus(JobSeekerApplyStatusAddDTO))
                {
                    jsonResult = JsonResultResponse(CommonHelper.GetResponseMessage(APIResponseMessage.Success, CurrentLanguagId), true, HttpStatusCode.OK);
                }
                else
                {
                    jsonResult = JsonResultResponse(CommonHelper.GetResponseMessage(APIResponseMessage.InvalidCredentials, CurrentLanguagId), false, HttpStatusCode.BadRequest);
                }
                #endregion
            }
            catch (Exception exception)
            {
            }
            return(jsonResult);
        }