File tree 6 files changed +64
-7
lines changed
Webgentle.BookStore/Webgentle.BookStore
6 files changed +64
-7
lines changed Original file line number Diff line number Diff line change @@ -17,9 +17,11 @@ public BookController()
17
17
_bookRepository = new BookRepository ( ) ;
18
18
}
19
19
20
- public List < BookModel > GetAllBooks ( )
20
+ public ViewResult GetAllBooks ( )
21
21
{
22
- return _bookRepository . GetAllBooks ( ) ;
22
+ var data = _bookRepository . GetAllBooks ( ) ;
23
+
24
+ return View ( ) ;
23
25
}
24
26
25
27
public BookModel GetBook ( int id )
Original file line number Diff line number Diff line change @@ -8,9 +8,14 @@ namespace Webgentle.BookStore.Controllers
8
8
{
9
9
public class HomeController : Controller
10
10
{
11
- public string Index ( )
11
+ public ViewResult Index ( )
12
12
{
13
- return "WebGentle" ;
13
+ return View ( ) ;
14
+ }
15
+
16
+ public ViewResult AboutUs ( )
17
+ {
18
+ return View ( ) ;
14
19
}
15
20
}
16
21
}
Original file line number Diff line number Diff line change
1
+
2
+ @{
3
+ Layout = null ;
4
+ }
5
+
6
+ <!DOCTYPE html>
7
+
8
+ <html >
9
+ <head >
10
+ <meta name =" viewport" content =" width=device-width" />
11
+ <title >GetAllBooks</title >
12
+ </head >
13
+ <body >
14
+ <h1 >All book list</h1 >
15
+ <button >Click me</button >
16
+ </body >
17
+ </html >
Original file line number Diff line number Diff line change
1
+
2
+ @{
3
+ Layout = null ;
4
+ }
5
+
6
+ <!DOCTYPE html>
7
+
8
+ <html >
9
+ <head >
10
+ <meta name =" viewport" content =" width=device-width" />
11
+ <title >AboutUs</title >
12
+ </head >
13
+ <body >
14
+ <h1 >This is the about page of application</h1 >
15
+ </body >
16
+ </html >
Original file line number Diff line number Diff line change
1
+
2
+ @{
3
+ Layout = null ;
4
+ }
5
+
6
+ <!DOCTYPE html>
7
+
8
+ <html >
9
+ <head >
10
+ <meta name =" viewport" content =" width=device-width" />
11
+ <title >Index</title >
12
+ </head >
13
+ <body >
14
+ <h1 >Welcome to book store application</h1 >
15
+ <p >This is the home page of our book store application</p >
16
+ </body >
17
+ </html >
Original file line number Diff line number Diff line change 8
8
<Controller_SelectedScaffolderID >MvcControllerEmptyScaffolder</Controller_SelectedScaffolderID >
9
9
<Controller_SelectedScaffolderCategoryPath >root/Controller</Controller_SelectedScaffolderCategoryPath >
10
10
<WebStackScaffolding_ControllerDialogWidth >600</WebStackScaffolding_ControllerDialogWidth >
11
- <WebStackScaffolding_IsLayoutPageSelected >True </WebStackScaffolding_IsLayoutPageSelected >
11
+ <WebStackScaffolding_IsLayoutPageSelected >False </WebStackScaffolding_IsLayoutPageSelected >
12
12
<WebStackScaffolding_IsPartialViewSelected >False</WebStackScaffolding_IsPartialViewSelected >
13
- <WebStackScaffolding_IsReferencingScriptLibrariesSelected >True</WebStackScaffolding_IsReferencingScriptLibrariesSelected >
14
- <WebStackScaffolding_LayoutPageFile />
13
+ <WebStackScaffolding_IsReferencingScriptLibrariesSelected >False</WebStackScaffolding_IsReferencingScriptLibrariesSelected >
15
14
<WebStackScaffolding_IsAsyncSelected >False</WebStackScaffolding_IsAsyncSelected >
15
+ <WebStackScaffolding_ViewDialogWidth >600</WebStackScaffolding_ViewDialogWidth >
16
16
</PropertyGroup >
17
17
</Project >
You can’t perform that action at this time.
0 commit comments