From 134faa5a361e852c00aac007eb8566bb194e4ecb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Halil=20=C4=B0brahim=20Kalkan?= Date: Wed, 22 Nov 2017 17:37:05 +0300 Subject: [PATCH] Added a simple TODO page via vue.js. --- .../AbpDesk.Web.Mvc/AbpDesk.Web.Mvc.csproj | 3 +++ .../Navigation/MainMenuContributor.cs | 2 ++ .../AbpDesk.Web.Mvc/Pages/App/Todo/Index.cshtml | 17 +++++++++++++++++ .../Pages/App/Todo/Index.cshtml.cs | 12 ++++++++++++ .../wwwroot/pages/app/todo/index.js | 14 ++++++++++++++ 5 files changed, 48 insertions(+) create mode 100644 src/AbpDesk/AbpDesk.Web.Mvc/Pages/App/Todo/Index.cshtml create mode 100644 src/AbpDesk/AbpDesk.Web.Mvc/Pages/App/Todo/Index.cshtml.cs create mode 100644 src/AbpDesk/AbpDesk.Web.Mvc/wwwroot/pages/app/todo/index.js diff --git a/src/AbpDesk/AbpDesk.Web.Mvc/AbpDesk.Web.Mvc.csproj b/src/AbpDesk/AbpDesk.Web.Mvc/AbpDesk.Web.Mvc.csproj index 0b36692389..14d14cd088 100644 --- a/src/AbpDesk/AbpDesk.Web.Mvc/AbpDesk.Web.Mvc.csproj +++ b/src/AbpDesk/AbpDesk.Web.Mvc/AbpDesk.Web.Mvc.csproj @@ -35,6 +35,7 @@ + @@ -46,6 +47,8 @@ All + + diff --git a/src/AbpDesk/AbpDesk.Web.Mvc/Navigation/MainMenuContributor.cs b/src/AbpDesk/AbpDesk.Web.Mvc/Navigation/MainMenuContributor.cs index 19b4fd25ca..f3b0ec6098 100644 --- a/src/AbpDesk/AbpDesk.Web.Mvc/Navigation/MainMenuContributor.cs +++ b/src/AbpDesk/AbpDesk.Web.Mvc/Navigation/MainMenuContributor.cs @@ -22,6 +22,8 @@ namespace AbpDesk.Web.Mvc.Navigation .AddItem( new ApplicationMenuItem("TicketManagement.Tickets", "Tickets", url: "/App/Tickets") ) + ).AddItem( + new ApplicationMenuItem("TodoList", "Todo List", url: "/App/Todo") ); //Disabled blog module. This should be inside the module! diff --git a/src/AbpDesk/AbpDesk.Web.Mvc/Pages/App/Todo/Index.cshtml b/src/AbpDesk/AbpDesk.Web.Mvc/Pages/App/Todo/Index.cshtml new file mode 100644 index 0000000000..b4881c523a --- /dev/null +++ b/src/AbpDesk/AbpDesk.Web.Mvc/Pages/App/Todo/Index.cshtml @@ -0,0 +1,17 @@ +@page +@using AbpDesk.Web.Mvc.Pages.App.Todo +@model IndexModel +

TODO application!

+ +
+
    +
  1. + {{ todo.text }} +
  2. +
+
+ +@section scripts { + + +} \ No newline at end of file diff --git a/src/AbpDesk/AbpDesk.Web.Mvc/Pages/App/Todo/Index.cshtml.cs b/src/AbpDesk/AbpDesk.Web.Mvc/Pages/App/Todo/Index.cshtml.cs new file mode 100644 index 0000000000..47651ccd70 --- /dev/null +++ b/src/AbpDesk/AbpDesk.Web.Mvc/Pages/App/Todo/Index.cshtml.cs @@ -0,0 +1,12 @@ +using Volo.Abp.AspNetCore.Mvc.RazorPages; + +namespace AbpDesk.Web.Mvc.Pages.App.Todo +{ + public class IndexModel : AbpPageModel + { + public void OnGet() + { + + } + } +} diff --git a/src/AbpDesk/AbpDesk.Web.Mvc/wwwroot/pages/app/todo/index.js b/src/AbpDesk/AbpDesk.Web.Mvc/wwwroot/pages/app/todo/index.js new file mode 100644 index 0000000000..14570e3853 --- /dev/null +++ b/src/AbpDesk/AbpDesk.Web.Mvc/wwwroot/pages/app/todo/index.js @@ -0,0 +1,14 @@ +(function() { + + var app = new Vue({ + el: '#TodoApp', + data: { + todos: [ + { text: 'Learn JavaScript' }, + { text: 'Learn Vue' }, + { text: 'Build something awesome' } + ] + } + }); + +})(); \ No newline at end of file