2014-03-27 16:31:42 -03:00
|
|
|
'use strict';
|
|
|
|
|
|
|
|
|
|
angular.module('cosign.signin').controller('SigninController',
|
|
|
|
|
function($scope, $rootScope, $location, Network) {
|
|
|
|
|
|
|
|
|
|
// Init peer
|
2014-03-31 16:48:43 -03:00
|
|
|
Network.init();
|
2014-03-27 16:31:42 -03:00
|
|
|
|
|
|
|
|
$scope.join = function(cid) {
|
2014-03-31 16:48:43 -03:00
|
|
|
console.log('------- joining to ' + cid + ' --------');
|
2014-03-27 16:31:42 -03:00
|
|
|
|
|
|
|
|
var pid = cid || $rootScope.peerId;
|
|
|
|
|
$location.path('join/' + pid);
|
|
|
|
|
};
|
|
|
|
|
});
|