signin form ready for controller handling

parent c032ff50
...@@ -173,6 +173,7 @@ ...@@ -173,6 +173,7 @@
"login_footer": "<strong>Pictogram Web</strong> is a product by <a href='http://www.yottacode.com'>Yottacode S.L.</a> for Augmentative and Alternative Communication, loaded with more than 20,000 images from the <a href='https://www.n2y.com/products/symbolstix'>SymbolStix</a> collection, in several languages. From here, you will be able to manage devices with official <i>Pictogram Tablet</i> app installed.", "login_footer": "<strong>Pictogram Web</strong> is a product by <a href='http://www.yottacode.com'>Yottacode S.L.</a> for Augmentative and Alternative Communication, loaded with more than 20,000 images from the <a href='https://www.n2y.com/products/symbolstix'>SymbolStix</a> collection, in several languages. From here, you will be able to manage devices with official <i>Pictogram Tablet</i> app installed.",
"login_success": "Login succeed. Welcome {{name}}", "login_success": "Login succeed. Welcome {{name}}",
"logout": "Log Out", "logout": "Log Out",
"logo_url": "URL (http://...) to office's logo",
"man": "Man", "man": "Man",
"March": "March", "March": "March",
"mark": "Mark", "mark": "Mark",
...@@ -248,6 +249,7 @@ ...@@ -248,6 +249,7 @@
"pictogram_setup": "Pictogram setup", "pictogram_setup": "Pictogram setup",
"pictograms": "Pictograms", "pictograms": "Pictograms",
"place_pictos": "Place pictograms in the phrase tape when", "place_pictos": "Place pictograms in the phrase tape when",
"postal_code": "Postal code",
"press": "Long press", "press": "Long press",
"previous_actions": "Previous actions", "previous_actions": "Previous actions",
"previous_sessions": "Previous sessions", "previous_sessions": "Previous sessions",
...@@ -268,12 +270,14 @@ ...@@ -268,12 +270,14 @@
"select_instruction": "-- Select an instruction --", "select_instruction": "-- Select an instruction --",
"select_a_method": "-- Select a method --", "select_a_method": "-- Select a method --",
"select_method": "-- Select a method or create it --", "select_method": "-- Select a method or create it --",
"select_office": "Select an office from the list",
"send": "Send", "send": "Send",
"September": "September", "September": "September",
"serial": "Serial number", "serial": "Serial number",
"serial_created": "Serial number {{serial}} created", "serial_created": "Serial number {{serial}} created",
"serial_list": "Free serial numbers", "serial_list": "Free serial numbers",
"serial_not_created": "Serial number couldn't be created", "serial_not_created": "Serial number couldn't be created",
"server_error": "An error has been reported when connecting to the server.",
"session": "Session", "session": "Session",
"sessions": "Sessions", "sessions": "Sessions",
"session_mean_length": "Session mean length: {{hours}} hours", "session_mean_length": "Session mean length: {{hours}} hours",
...@@ -281,6 +285,7 @@ ...@@ -281,6 +285,7 @@
"sessions": "Sessions", "sessions": "Sessions",
"sessions_of": "Sessions of", "sessions_of": "Sessions of",
"setup": "Setup", "setup": "Setup",
"sexo": "Sex",
"show": "Show", "show": "Show",
"size": "Size", "size": "Size",
"small": "Small", "small": "Small",
......
...@@ -173,6 +173,7 @@ ...@@ -173,6 +173,7 @@
"login_footer": "<strong>Pictogram Web</strong> es un producto de <a href='http://www.yottacode.com'>Yottacode S.L.</a> para Comunicación Aumentativa y Alternativa, cargado con más de 20,000 pictogramas de <a href='https://www.n2y.com/products/symbolstix'>SymbolStix</a>, en varios idiomas. Desde aquí podrás gestionar los dispositivos que dispongan de la app oficial <i>Pictogram Tablet</i>.", "login_footer": "<strong>Pictogram Web</strong> es un producto de <a href='http://www.yottacode.com'>Yottacode S.L.</a> para Comunicación Aumentativa y Alternativa, cargado con más de 20,000 pictogramas de <a href='https://www.n2y.com/products/symbolstix'>SymbolStix</a>, en varios idiomas. Desde aquí podrás gestionar los dispositivos que dispongan de la app oficial <i>Pictogram Tablet</i>.",
"login_success": "Login correcto. Bienvenido {{name}}", "login_success": "Login correcto. Bienvenido {{name}}",
"logout": "Salir", "logout": "Salir",
"logo_url": "URL (http://...) al logo del centro/gabinete",
"man": "Hombre", "man": "Hombre",
"March": "Marzo", "March": "Marzo",
"mark": "Marcar", "mark": "Marcar",
...@@ -209,6 +210,7 @@ ...@@ -209,6 +210,7 @@
"objetive": "Objetivo", "objetive": "Objetivo",
"October": "Octubre", "October": "Octubre",
"office": "Gabinete", "office": "Gabinete",
"office_center": "Gabinete/centro",
"office_added": "Gabinete añadido", "office_added": "Gabinete añadido",
"office_deleted": "Gabinete eliminado", "office_deleted": "Gabinete eliminado",
"office_not_added": "No se ha podido añadir el gabinete", "office_not_added": "No se ha podido añadir el gabinete",
...@@ -248,6 +250,7 @@ ...@@ -248,6 +250,7 @@
"pictogram_setup": "Configuración del pictograma", "pictogram_setup": "Configuración del pictograma",
"pictograms": "Pictogramas", "pictograms": "Pictogramas",
"place_pictos": "Colocar pictogramas en la cinta de frase cuando", "place_pictos": "Colocar pictogramas en la cinta de frase cuando",
"postal_code": "Código postal",
"press": "Pulsación larga", "press": "Pulsación larga",
"previous_actions": "Acciones anteriores", "previous_actions": "Acciones anteriores",
"previous_sessions": "Sesiones anteriores", "previous_sessions": "Sesiones anteriores",
...@@ -269,12 +272,14 @@ ...@@ -269,12 +272,14 @@
"select_instruction": "-- Selecciona una instrucción --", "select_instruction": "-- Selecciona una instrucción --",
"select_a_method": "-- Selecciona un método --", "select_a_method": "-- Selecciona un método --",
"select_method": "-- Selecciona un método o créalo --", "select_method": "-- Selecciona un método o créalo --",
"select_office": "Seleccione una oficina/centro de la lista",
"send": "Enviar", "send": "Enviar",
"September": "Septiembre", "September": "Septiembre",
"serial": "Número de serie", "serial": "Número de serie",
"serial_created": "Número de serie {{serial}} creado", "serial_created": "Número de serie {{serial}} creado",
"serial_list": "Números de serie libres", "serial_list": "Números de serie libres",
"serial_not_created": "No se ha podido crear el número de serie", "serial_not_created": "No se ha podido crear el número de serie",
"server_error": "No se ha podido conectar con el servidor.",
"session": "Sesión", "session": "Sesión",
"sessions": "Sesiones", "sessions": "Sesiones",
"session_mean_length": "Duración media de sesión: {{hours}} horas", "session_mean_length": "Duración media de sesión: {{hours}} horas",
...@@ -282,6 +287,7 @@ ...@@ -282,6 +287,7 @@
"sessions": "Sesiones", "sessions": "Sesiones",
"sessions_of": "Sesiones de", "sessions_of": "Sesiones de",
"setup": "Configuración", "setup": "Configuración",
"sexo": "Sexo",
"show": "Mostrar", "show": "Mostrar",
"size": "Tamaño", "size": "Tamaño",
"small": "Pequeño", "small": "Pequeño",
......
...@@ -22,18 +22,32 @@ function SignInCtrl($scope, ...@@ -22,18 +22,32 @@ function SignInCtrl($scope,
surname: '', surname: '',
address: '', address: '',
phone: '', phone: '',
gender: 'F', gender: 'M',
email: '', email: '',
email_confirm: '', email_confirm: '',
password: '', password: '',
password_confirm: '', password_confirm: '',
lang: 'es', lang: 'es',
role: 'therapist_office', role: null,
office: {
country: 'NULL'
},
office_idx: -1
}; };
}; };
$scope.reset(); $scope.reset();
// Get the list of offices
$http
.get(config.backend + '/office/get_all')
.success(function (offices) {
$scope.offices = offices;
})
.error(function () {
ngToast.danger({ content: $translate.instant('server_error') });
});
// Form submit // Form submit
$scope.signin = function () { $scope.signin = function () {
// Validate email match // Validate email match
......
...@@ -60,7 +60,7 @@ module.exports.policies = { ...@@ -60,7 +60,7 @@ module.exports.policies = {
}, },
OfficeController: { OfficeController: {
getAll: ['tokenAuth', 'isAdmin'], getAll: true,
get: ['tokenAuth'], get: ['tokenAuth'],
getBasic: true, getBasic: true,
supervisors: ['tokenAuth', 'isAdmin'] supervisors: ['tokenAuth', 'isAdmin']
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment