Пример #1
0
        public DocumentResponse RemoveDocument(DocumentRequestRemove docID)
        {
            DocumentResponse retval = default;

            if (docID != null)
            {
                retval = _DAL.Removedocument(docID);
            }
            return(retval);
        }
        public DocumentResponse Removedocument(DocumentRequestRemove docID)
        {
            DocumentResponse retval = default;

            try
            {
                var param   = _paramConverter.ConvertToParameter(docID, "DocID");
                var dataset = _SQLDAL.ExecSPQuery("RemoveDocument", con, param);
                if (dataset.Tables[0].Rows.Count != 0)
                {
                    retval = new DocumentResponseRemoveOK();
                }
            }
            catch (Exception e)
            {
                retval = new DocumentResponseDontRemove();
                //log
            }
            return(retval);
        }