コード例 #1
0
        public int Add(string title, string description, string code, int procedureId)
        {
            var document = new Document
            {
                Title = title,
                Description = description,
                Code = code,
                ProcedureId = procedureId,
                LastUpdate = DateTime.Now
            };

            this.data.Documents.Add(document);
            this.data.SaveChanges();
            return document.Id;
        }
コード例 #2
0
 public void UpdateFilePath(Document document, string filePath)
 {
     document.FilePath = filePath;
     this.data.SaveChanges();
 }