This commit is contained in:
2017-12-25 20:23:32 +01:00
parent 1175a4f8ff
commit 0cc882060c
36 changed files with 781 additions and 86 deletions
@@ -0,0 +1,18 @@
/**
* Created by Pensare Software.
* User: Theo Weijmer
* Date: 22/12/2017
* Time: 13:32
*/
dbo.pageDataservice = {
getAppPages : function(callback){
$.getJSON('index.php/menu/getAppPages')
.done(function(data){
callback(data);
});
}
};
@@ -0,0 +1,23 @@
/**
* Created by Pensare Software.
* User: Theo Weijmer
* Date: 25/12/2017
* Time: 17:11
*/
dbo.rolesDataservice = {
roles: false,
getAllRoles: function ( archive, callback ) {
var ds = dbo.rolesDataservice
if ( ds.roles ) callback( ds.roles );
$.getJSON( 'index.php/beheer/rolesController/getAllRoles/' + archive )
.done( function ( data ) {
ds.roles = data;
callback( data );
} );
}
}
@@ -0,0 +1,33 @@
/**
* Created by Pensare Software.
* User: Theo Weijmer
* Date: 25/12/2017
* Time: 09:50
*/
dbo.userDataService = {
getAllUsers: function ( archive = 'F', callback ) {
$.getJSON( 'index.php/beheer/usersController/getAllUsers/' + archive )
.done( function ( data ) {
callback( data );
} );
},
getUser: function ( userID, callback ) {
$.getJSON( 'index.php/beheer/usersController/getUser/' + userID )
.done( function ( data ) {
callback( data );
} );
},
checkUsername: function ( username, callback ) {
$.post( 'index.php/beheer/userController/checkUsername', 'json' )
.done( function ( data ) {
console.log( data );
callback( data );
} )
}
}