Created
October 4, 2011 19:32
-
-
Save rotty3000/1262555 to your computer and use it in GitHub Desktop.
get all RatingsEntry by user and asset type
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
long classNameId = PortalUtil.getClassNameId(className); | |
DynamicQuery dynamicQuery = DynamicQueryFactoryUtil.forClass(RatingsEntry.class, PortalClassLoaderUtil.getClassLoader()); | |
dynamicQuery.add(RestrictionsFactoryUtil.eq("userId", userId)); | |
dynamicQuery.add(RestrictionsFactoryUtil.eq("classNameId", classNameId)); | |
List<RatingsEntry> ratings = (List<RatingsEntry>)RatingsEntryLocalServiceUtil.dynamicQuery(dynamicQuery); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment