Skip to content

Instantly share code, notes, and snippets.

@eduardolundgren
Created January 19, 2012 19:43
Show Gist options
  • Save eduardolundgren/1642112 to your computer and use it in GitHub Desktop.
Save eduardolundgren/1642112 to your computer and use it in GitHub Desktop.
Services
Liferay.Service('user/get-user-by-id');
Liferay.Service('user/get-user-by-id', fn);
Liferay.Service('user/get-user-by-id', {}, fn);
Liferay.Service({
'user/get-user-by-id': {}
});
Liferay.Service({
'user/get-user-by-id': {}
}, fn);
Liferay.Service({
'user/get-user-by-id': {},
'user/get-user-by-name': {}
}, fn);
Liferay.Service({
'user/get-user-by-id': {},
'user/get-user-by-name': {},
io: {
on: {
success: function(event){
console.log(this.get('responseData');
}
}
}
}
});
Liferay.Service({
'$user = user/get-user-by-id': {
'$contact = contact/get-contact': {
contactId: '$user.contactId',
'$email = email/get-email': {
emailId: '$contact.emailId',
...
}
}
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment