diff --git a/section6/lesson1/index.html b/section6/lesson1/index.html index 6706a6f..8974fbf 100644 --- a/section6/lesson1/index.html +++ b/section6/lesson1/index.html @@ -5,6 +5,7 @@ Contacts + @@ -105,23 +106,66 @@
Details
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+ +
+ +
+
+ +
+ +
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
+
+
+ +
+ +
-
-
Name
-
{{contacts.selectedPerson.name}}
-
Email
-
{{contacts.selectedPerson.email}}
-
Birthday
-
{{contacts.selectedPerson.birthdate | date:"longDate"}}
-
Phonenumber
-
{{contacts.selectedPerson.phonenumber}}
-
Address
-
{{contacts.selectedPerson.address}}
-
City
-
{{contacts.selectedPerson.city}}
-
Country
-
{{contacts.selectedPerson.country}}
-
@@ -135,6 +179,9 @@ + + + diff --git a/section6/lesson1/main.js b/section6/lesson1/main.js index 55c0f2d..52124bc 100644 --- a/section6/lesson1/main.js +++ b/section6/lesson1/main.js @@ -1,14 +1,19 @@ var app = angular.module('codecraft', [ 'ngResource', 'infinite-scroll', - 'angularSpinner' + 'angularSpinner', + 'jcs-autoValidate', + 'angular-ladda' ]); //we will add the factory $httpProvider -app.config(function ($httpProvider, $resourceProvider) { +app.config(function ($httpProvider, $resourceProvider, laddaProvider) { $httpProvider.defaults.headers.common['Authorization'] = 'Token 7f482b5192e232141b0a10f0d36ee4443f14dc20'; //In the API we have, we normally have trailing slashes and to avoid we use below setting. $resourceProvider.defaults.stripTrailingSlashes = false; + laddaProvider.setOption({ + style: 'expand-right' + }); }); app.factory('Contact', function ($resource) { return $resource("http://codecraftpro.com/api/samples/v1/contact/:id/");