Re: [xwiki-users] LIvetable macro display objects on same page
you won't be able to use HQL because it will return a list of pages, all pointing to the same page. A good starting point is the example given in the Livetable Macro documentation. I used that as a starting point. You need to read all the objects into an array using $doc.getObjects( 'myClass' ), where myClass is the name of your xwiki object class. Dan -Original Message- From: Gerritjan Koekkoek Sent: Friday, August 12, 2016 8:47 AM To: XWiki Users Subject: Re: [xwiki-users] LIvetable macro display objects on same page Yes, that's correct, thank you... Is there a convenient way to generate the json for a set of objects of one class on one page? Gerritjan Koekkoek Vader van Rai Koekkoek (cdls) en voorzitter vereniging CdLS Visit our websiteFrom: users on behalf of Daniel Ullfig Sent: 12 August 2016 17:34:34 To: XWiki Users Subject: Re: [xwiki-users] LIvetable macro display objects on same page Are you attaching several objects of the same type to the page? In that case, the standard livetable will not work. you will have to implement a JSON page to return the data for the livetable. Dan -Original Message- From: Gerritjan Koekkoek Sent: Friday, August 12, 2016 5:32 AM To: XWiki Users Subject: [xwiki-users] LIvetable macro display objects on same page Can the livable macro display objects that are on the same page ? my use case looks to show the right number of records, but all the rows show the data of the first object on the page. {{velocity wiki=false}} #set($myColumns = ["personKey","observationType", "doc.name" , "odatetimestart","measureNominal", "withmilestone", "byRole", "withtopic", "_actions"]) #set($myTableOptions = { "className":"WaihonaCode.observationClass", "translationPrefix" : "waihonapedia.scorecards.growth.", "rowCount": 10, "extraParams" : "=RaiKoekkoek=weight=RaiKoekkoek_growthfeeding" } ) #set($columnsProperties = { "personKey" : { "type" : "hidden", "filterable":"false"}, "observationType" : { "type" : "hidden", "filterable":"false"}, "doc.name" :{"type":"hidden", "filterable":"false"}, "odatetimestart" : { "type" : "date", "sortable":"false" , "filterable":"false", "size" : 5}, "measureNominal" : { "type" : "number" , "filterable":"false", "size" : 5}, "withmilestone" : {"type" : "text", "filterable":"false" , "size" : 5}, "byRole" : { "type" : "text", "filterable":"false" , "size" : 5}, "withtopic" : { "type" : "text", "filterable":"false" , "size" : 10} }) #livetable('growthTable' $myColumns $columnsProperties $myTableOptions) {{/velocity}} Gerritjan Koekkoek Vader van Rai Koekkoek (cdls) en voorzitter vereniging CdLS Visit our website ___ users mailing list users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users ___ users mailing list users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users ___ users mailing list users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users ___ users mailing list users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users
Re: [xwiki-users] LIvetable macro display objects on same page
Yes, that's correct, thank you... Is there a convenient way to generate the json for a set of objects of one class on one page? Gerritjan Koekkoek Vader van Rai Koekkoek (cdls) en voorzitter vereniging CdLS Visit our websiteFrom: users on behalf of Daniel Ullfig Sent: 12 August 2016 17:34:34 To: XWiki Users Subject: Re: [xwiki-users] LIvetable macro display objects on same page Are you attaching several objects of the same type to the page? In that case, the standard livetable will not work. you will have to implement a JSON page to return the data for the livetable. Dan -Original Message- From: Gerritjan Koekkoek Sent: Friday, August 12, 2016 5:32 AM To: XWiki Users Subject: [xwiki-users] LIvetable macro display objects on same page Can the livable macro display objects that are on the same page ? my use case looks to show the right number of records, but all the rows show the data of the first object on the page. {{velocity wiki=false}} #set($myColumns = ["personKey","observationType", "doc.name" , "odatetimestart","measureNominal", "withmilestone", "byRole", "withtopic", "_actions"]) #set($myTableOptions = { "className":"WaihonaCode.observationClass", "translationPrefix" : "waihonapedia.scorecards.growth.", "rowCount": 10, "extraParams" : "=RaiKoekkoek=weight=RaiKoekkoek_growthfeeding" } ) #set($columnsProperties = { "personKey" : { "type" : "hidden", "filterable":"false"}, "observationType" : { "type" : "hidden", "filterable":"false"}, "doc.name" :{"type":"hidden", "filterable":"false"}, "odatetimestart" : { "type" : "date", "sortable":"false" , "filterable":"false", "size" : 5}, "measureNominal" : { "type" : "number" , "filterable":"false", "size" : 5}, "withmilestone" : {"type" : "text", "filterable":"false" , "size" : 5}, "byRole" : { "type" : "text", "filterable":"false" , "size" : 5}, "withtopic" : { "type" : "text", "filterable":"false" , "size" : 10} }) #livetable('growthTable' $myColumns $columnsProperties $myTableOptions) {{/velocity}} Gerritjan Koekkoek Vader van Rai Koekkoek (cdls) en voorzitter vereniging CdLS Visit our website ___ users mailing list users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users ___ users mailing list users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users ___ users mailing list users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users
Re: [xwiki-users] LIvetable macro display objects on same page
Are you attaching several objects of the same type to the page? In that case, the standard livetable will not work. you will have to implement a JSON page to return the data for the livetable. Dan -Original Message- From: Gerritjan Koekkoek Sent: Friday, August 12, 2016 5:32 AM To: XWiki Users Subject: [xwiki-users] LIvetable macro display objects on same page Can the livable macro display objects that are on the same page ? my use case looks to show the right number of records, but all the rows show the data of the first object on the page. {{velocity wiki=false}} #set($myColumns = ["personKey","observationType", "doc.name" , "odatetimestart","measureNominal", "withmilestone", "byRole", "withtopic", "_actions"]) #set($myTableOptions = { "className":"WaihonaCode.observationClass", "translationPrefix" : "waihonapedia.scorecards.growth.", "rowCount": 10, "extraParams" : "=RaiKoekkoek=weight=RaiKoekkoek_growthfeeding" } ) #set($columnsProperties = { "personKey" : { "type" : "hidden", "filterable":"false"}, "observationType" : { "type" : "hidden", "filterable":"false"}, "doc.name" :{"type":"hidden", "filterable":"false"}, "odatetimestart" : { "type" : "date", "sortable":"false" , "filterable":"false", "size" : 5}, "measureNominal" : { "type" : "number" , "filterable":"false", "size" : 5}, "withmilestone" : {"type" : "text", "filterable":"false" , "size" : 5}, "byRole" : { "type" : "text", "filterable":"false" , "size" : 5}, "withtopic" : { "type" : "text", "filterable":"false" , "size" : 10} }) #livetable('growthTable' $myColumns $columnsProperties $myTableOptions) {{/velocity}} Gerritjan Koekkoek Vader van Rai Koekkoek (cdls) en voorzitter vereniging CdLS Visit our website___ users mailing list users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users ___ users mailing list users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users
[xwiki-users] LIvetable macro display objects on same page
Can the livable macro display objects that are on the same page ? my use case looks to show the right number of records, but all the rows show the data of the first object on the page. {{velocity wiki=false}} #set($myColumns = ["personKey","observationType", "doc.name" , "odatetimestart","measureNominal", "withmilestone", "byRole", "withtopic", "_actions"]) #set($myTableOptions = { "className":"WaihonaCode.observationClass", "translationPrefix" : "waihonapedia.scorecards.growth.", "rowCount": 10, "extraParams" : "=RaiKoekkoek=weight=RaiKoekkoek_growthfeeding" } ) #set($columnsProperties = { "personKey" : { "type" : "hidden", "filterable":"false"}, "observationType" : { "type" : "hidden", "filterable":"false"}, "doc.name" :{"type":"hidden", "filterable":"false"}, "odatetimestart" : { "type" : "date", "sortable":"false" , "filterable":"false", "size" : 5}, "measureNominal" : { "type" : "number" , "filterable":"false", "size" : 5}, "withmilestone" : {"type" : "text", "filterable":"false" , "size" : 5}, "byRole" : { "type" : "text", "filterable":"false" , "size" : 5}, "withtopic" : { "type" : "text", "filterable":"false" , "size" : 10} }) #livetable('growthTable' $myColumns $columnsProperties $myTableOptions) {{/velocity}} Gerritjan Koekkoek Vader van Rai Koekkoek (cdls) en voorzitter vereniging CdLS Visit our website___ users mailing list users@xwiki.org http://lists.xwiki.org/mailman/listinfo/users