예제 #1
0
        // 책 추가
        public void AddBook()
        {
            List <Data.Book> books;

            books = outputProcessor.APISearchScreen(DB);
            if (books == null)
            {
                return;
            }

            Data.Book book = outputProcessor.PrintBookList(books);
            if (book == null)
            {
                return;
            }
            book.Count = outputProcessor.InputBookCount();

            if (book != null && DB.InsertBook(book))
            {
                outputProcessor.PressAnyKey(book.Name + "이 등록되었습니다.");
                // 로그 기록
                DB.InsertLog("관리자", book.Name, "도서 추가");
            }
            else
            {
                outputProcessor.PressAnyKey("책 등록 실패");
            }
        }