openworktime/desktopapp/index.html
desktopapp/index.htmlRaw
1
2 <!DOCTYPE html>
3 <html ng-app="workApp">
4 <head>
5 <!--Import Google Icon Font-->
6 <link href="fonts/icons.css" rel="stylesheet">
7 <!--Import materialize.css-->
8 <link type="text/css" rel="stylesheet" href="css/materialize.min.css" media="screen,projection"/>
9
10
11 <link type="text/css" rel="stylesheet" href="own.css"/>
12
13 <!--Let browser know website is optimized for mobile-->
14 <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
15 <title>Open Work Time - local version</title>
16
17
18
19 </head>
20
21 <body ng-controller="workController as work">
22
23
24 <nav>
25 <div class="nav-wrapper blue-grey darken-1">
26 <a href="#" class="brand-logo">Open Work Time - local version</a>
27 <ul id="nav-mobile" class="right">
28 <li>
29 <a ng-click="openCode()" target="_blank">
30 <i class="large material-icons" title="Visit code">code</i>
31 </a>
32 </li>
33 <li>
34 <a ng-click="deleteStorage()">
35 <i class="large material-icons" title="Delete storage">info_outline</i>
36 </a>
37 </li>
38 <li>
39 <a ng-click="saveStorage()" title="Save all to storage">
40 <i class="large material-icons">perm_identity</i>
41 </a>
42 </li>
43 </ul>
44 </div>
45 </nav>
46
47 <div class="">
48 <div class="row">
49 <div class="card blue-grey lighten-4 col s12 m5 l5">
50 <div class="card-content">
51 <span class="card-title">Projects</span>
52 <div class="collection">
53 <a href="#!" ng-click="projectSelect($index)" ng-repeat="project in projects" class="collection-item avatar blue-grey lighten-4">
54 <div class="right">
55 <div class="waves-effect waves-light btn-floating blue-grey lighten-2" ng-click="editProject($index)">
56 <i class="material-icons"><img src="img/edit.png" class="o_trash_icon" /></i>
57 </div>
58 <div class="waves-effect waves-light btn-floating blue-grey lighten-2" ng-click="removeProject($index)">
59 <i class="material-icons"><img src="img/trash.png" class="o_trash_icon" /></i>
60 </div>
61 </div>
62 <img ng-src="img/{{project.icon}}.png" class="circle"/>
63 <span class="title">{{project.title}}</span>
64 <p class="grey-text">{{project.totaltime | secondsToDateTime | date:'HH:mm:ss'}}</p>
65 </a>
66 </div>
67 </div>
68 <div class="card-action" ng-show="!editingProject">
69 <div class="input-field col s6">
70 <input ng-model="newproject.title" id="newprojectname" type="text" class="validate">
71 <label for="newprojectname">New project name</label>
72 </div>
73 <div class="input-field col s6">
74 <input ng-model="newproject.icon" id="icon" type="text" class="validate">
75 <label for="icon">icon</label>
76 </div>
77 <a ng-click="addNewProject()" class="waves-effect waves-light btn blue-grey lighten-1 right">Add new project</a>
78 </div>
79 <div class="card-action" ng-show="editingProject">
80 <div class="input-field col s6">
81 <input ng-model="editingProject.title" id="newprojectname" value=" " type="text" class="validate">
82 <label for="newprojectname">New project name</label>
83 </div>
84 <div class="input-field col s6">
85 <input ng-model="editingProject.icon" id="icon" value=" " type="text" class="validate">
86 <label for="icon">icon</label>
87 </div>
88 <a ng-click="cancelEditProject()" class="waves-effect waves-light btn red lighten-2">Cancel</a>
89 <a ng-click="updateProject()" class="waves-effect waves-light btn blue lighten-2 right">Update project</a>
90 </div>
91 </div>
92
93 <div ng-show="currentproject.title" class="card blue-grey lighten-4 col s12 m7 l7">
94 <div class="card-content">
95 <span class="card-title">
96 <img ng-src="img/{{currentproject.icon}}.png" class="o_project_title_img"/>
97 {{currentproject.title}}
98 </span>
99 <p>
100 Total time: {{currentproject.totaltime | secondsToDateTime | date:'HH:mm:ss'}}
101 </p>
102 <p>
103 Current strike time: <b>{{currentStrike | secondsToDateTime | date:'HH:mm:ss'}}</b>
104 </p>
105
106 </div>
107 <div class="card-action">
108 <a ng-click="btnWork()" ng-show="!working" class="waves-effect waves-light btn green lighten-2">Work!</a>
109 <a ng-click="btnStop()" ng-show="working" class="waves-effect waves-light btn red lighten-2">Stop!</a>
110
111 <!--<a class="waves-effect waves-light btn deep-orange lighten-2">Stop working!</a>-->
112 </div>
113 </div>
114 <div ng-show="!currentproject.title" class="card blue-grey lighten-4 col s12 m7 l7" style="height: 200px;">
115 <span class="card-title">
116 Select a project
117 </span>
118 </div>
119
120
121 </div>
122 </div>
123
124
125<!-- ELECTRON
126Insert this line above script imports
127Works for both browser and electron with the same code -->
128<script>if (typeof module === 'object') {window.module = module; module = undefined;}</script>
129
130 <!-- ANGULAR -->
131 <script src="libraries/angular.min.js"></script>
132
133 <!--Import jQuery before materialize.js-->
134 <script type="text/javascript" src="js/jquery-2.1.1.min.js"></script>
135 <script type="text/javascript" src="js/materialize.min.js"></script>
136
137 <script src="controllers.js"></script>
138
139 <script src="libraries/toastr.js"></script>
140 <link type="text/css" rel="stylesheet" href="libraries/toastr.css"/>
141
142<!-- ELECTRON
143Insert this line after script imports -->
144<script>if (window.module) module = window.module;</script>
145
146
147 </body>
148 </html>