コード例 #1
0
ファイル: AttachmentManipulation.cs プロジェクト: adkl/nsi
        /// <summary>
        /// Delete attachment with id
        /// </summary>
        /// <param name="attachmentId"></param>
        public void DeleteAttachmentById(int attachmentId)
        {
            AttachmentDomain attachmentDomain = _attachmentRepository.GetById(attachmentId);

            if (attachmentDomain == null)
            {
                throw new NsiArgumentException(NotificationMessages.AttachmentWithIdDoesNotExist);
            }

            _attachmentRepository.DeleteById(attachmentId);
        }
コード例 #2
0
ファイル: AttachmentService.cs プロジェクト: wpmyj/BlueHr
 public bool DeleteById(int id)
 {
     return(rep.DeleteById(id));
 }