Beispiel #1
0
        /// <summary>
        /// Adds the update.
        /// </summary>
        /// <param name="suiteDto">The suite dto.</param>
        /// <returns>
        /// Newly added object
        /// </returns>
        private IHttpActionResult AddUpdate(TblSuiteDto suiteDto)
        {
            var result = new ResultMessage <TblSuiteDto>();

            try
            {
                result = this.suiteService.SaveOrUpdate(suiteDto, this.UserId);
            }
            catch (Exception ex)
            {
                this.LoggerService.LogException(ex);
                result.Messages.Add(new Message(null, ex.Message));
            }

            return(this.CreateCustomResponse(result));
        }
Beispiel #2
0
 public IHttpActionResult Update([FromBody] TblSuiteDto suiteDto, long id)
 {
     suiteDto.SuiteTestMapList = null;
     suiteDto.Id = id;
     return(this.AddUpdate(suiteDto));
 }
Beispiel #3
0
 public IHttpActionResult Add([FromBody] TblSuiteDto suiteDto)
 {
     suiteDto.SuiteTestMapList = null;
     return(this.AddUpdate(suiteDto));
 }