forked from dineshvankayalapati/My3_angular
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.js
41 lines (36 loc) · 771 Bytes
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
//author P.Tummala
var app = angular.module('myApp', []);
app.controller('myCtrl', function($scope) {
$scope.application = "My3/IIS tech touch-Angular concepts";
var day;
switch (new Date().getDay()) {
case 0:
day = "Sunday";
break;
case 1:
day = "Monday";
break;
case 2:
day = "Tuesday";
break;
case 3:
day = "Wednesday";
break;
case 4:
day = "Thursday";
break;
case 5:
day = "Friday";
break;
case 6:
day = "Saturday";
break;
}
if(day == "Friday"){
day = "Happy friday";
} else if(day == "Saturday" || day == "Sunday") {
day = "Happy Weekend";
}
$scope.idx = day;
$scope.d = new Date();
});