Liferay 7 ignores AssetEntryQuery parameters -


assetentryquery ignoring parameters set, executing wildcard query , retrieving asset entries.

snippet of i'm doing right now:

long[] classtypeids = new long[] { 30837 };  assetentryquery assetquery = new assetentryquery(); assetquery.setclasstypeids(classtypeids);  list<assetentry> entries = assetentrylocalserviceutil.getentries(assetquery);  foreach (assetentry entry : entries) {     system.out.printf("entry classtypeid %d expected %d", entry.getclasstypeid(), 30837); } 

when execute code, returns list of entries liferay without classtypeid being filtered.

output:

[...] entry classtypeid 0 expected 30837 entry classtypeid 0 expected 30837 entry classtypeid 28920 expected 30837 entry classtypeid 30331 expected 30837 entry classtypeid 30837 expected 30837 entry classtypeid 30837 expected 30837 entry classtypeid 30837 expected 30837 entry classtypeid 30921 expected 30837 [...] 

am missing liferay ignoring assetentryquery params or bug within liferay itself?

i don't know if it's intentional or not (probably not), in assetentry table of db (i'm looking @ dev purposes, it's never recommended directly db), classtypeid field 0 entries in build of latest liferay-portal master branch. shot in dark, try calling

assetentryquery.setclassnameids

instead of setclasstypeids, , see if trick.


Comments

Popular posts from this blog

javascript - Clear button on addentry page doesn't work -

c# - Selenium Authentication Popup preventing driver close or quit -

tensorflow when input_data MNIST_data , zlib.error: Error -3 while decompressing: invalid block type -