Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

modified in app.js

  • Loading branch information...
commit 77afd3a7836b96549beabc226fc83593b7ac38dc 1 parent 85b9f63
@roshandarekar roshandarekar authored
Showing with 10 additions and 5 deletions.
  1. +10 −5 public/javascript/controllers/app.js
View
15 public/javascript/controllers/app.js
@@ -14,12 +14,17 @@ MainController = function(app) { with (app) {
app.get('#/home', function(context) {
- context.render('views/index.html').replace("#main-content");
- var profile_id=$.cookie("profile_id");
- //alert(profile_id);
- console.log(profile_id)
- //context.render('views/profiler.html',{"name":profile_id}).replace("#profile");
+ var profile_id=$.cookie("profile_id");
+ if (typeof(profile_id) == 'undefined') {
+
+ $("#logout").click();
+ }
+ console.log(profile_id);
+ context.load('/api/Contact/' + profile_id)
+ .then(function(json){
+ $("#profile").text(data['name']);
+ })
});
app.get('#/task', function(context) {
Please sign in to comment.
Something went wrong with that request. Please try again.