From: James HK <jam...@gm...> - 2013-12-17 18:32:22
|
Hi, > When a user approves a certain revision with Approved Revs, the extension > essentially re-saves that page behind the scenes, so that the data > (categories, properties, etc.) for that one revision become the data for > the page. That's how it's supposed to work in theory, anyway. When run through appropriate hooks [1], [2], [3] SMW will recognize a changed data set but the core itself doesn't recognizes revision related properties meaning that the Store only contains information about the most current revision (and in case a historical revision is set as the current revision the Store only keeps reference to exactly that data set). [1] https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/includes/hooks/LinksUpdateConstructed.php [2] https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/includes/hooks/ParserAfterTidy.php [3] https://github.com/SemanticMediaWiki/SemanticMediaWiki/blob/master/includes/hooks/NewRevisionFromEditComplete.php Cheers On 12/18/13, Yaron Koren <ya...@wi...> wrote: > Hi James, > > When a user approves a certain revision with Approved Revs, the extension > essentially re-saves that page behind the scenes, so that the data > (categories, properties, etc.) for that one revision become the data for > the page. That's how it's supposed to work in theory, anyway. > > -Yaron > > > On Tue, Dec 17, 2013 at 1:02 PM, James HK > <jam...@gm...>wrote: > >> Hi, >> >> Ask queries (#ask or Api) do not make any assumption about additional >> filtering options (such as approved revisions) and only output the >> "raw" results from the Store. If you wish to have other options to be >> considered by an Ask query than those should be applied on top of the >> "raw" result (using appropriate hook, which would be likely part of a >> non-core extension). >> >> Cheers >> >> On 12/17/13, Joost De Cock <jo...@de...> wrote: >> > Hi all, >> > >> > I have a Semantic MediaWiki instance setup where I run ask queries >> through >> > the API. >> > >> > For example, this query: >> > >> api.php?format=jsonfm&action=ask&query=[[Category%3AItecDocuments]]%0A++|%3F%23%0A++|%3FHasSubtitle%0A++ >> > >> > (Asking for the 'Social Media Strategy' document with the 'HasSubtitle' >> > property gives me the following result (showing relevant part of output >> > only): >> > >> > "results": { >> > "Social Media Strategy": { >> > "printouts": { >> > "HasSubtitle": ["DG ITEC on social media platforms"] >> > }, >> > "fulltext": "Social Media Strategy", >> > "fullurl": >> > "http:\/\/staging.iteccom.ep.parl.union.eu >> \/docs\/Social_Media_Strategy", >> > "namespace": 0, >> > "exists": true >> > } >> > }, >> > >> > So far so good. But when I go to the 'Social Media Strategy' page and >> > set >> > any revision that is not the latest as the approved revision (with the >> > ApprovedRevs extension) and I run the same query, I get an empty result >> > set: >> > >> > "results": [ >> > >> > ], >> > >> > >> > *Questions* >> > Is this behaviour expected? (I'm fairly new to both MediaWiki and >> Semantic >> > MediaWiki so please forgive my ignorance). >> > If so, can I work around it somehow? I noticed that >> > semantic-mediawiki.orgalso uses ApprovedRevs, so I'm hopeful that both >> > should be able to play >> > nice together :) >> > >> > >> > Thanks in advance for your thoughts. >> > >> > Joost >> > >> ------------------------------------------------------------------------------ >> > Rapidly troubleshoot problems before they affect your business. Most IT >> > organizations don't have a clear picture of how application performance >> > affects their revenue. With AppDynamics, you get 100% visibility into >> your >> > Java,.NET, & PHP application. Start your 15-day FREE TRIAL of >> > AppDynamics >> > Pro! >> > >> http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk >> > _______________________________________________ >> > Semediawiki-user mailing list >> > Sem...@li... >> > https://lists.sourceforge.net/lists/listinfo/semediawiki-user >> > >> >> >> ------------------------------------------------------------------------------ >> Rapidly troubleshoot problems before they affect your business. Most IT >> organizations don't have a clear picture of how application performance >> affects their revenue. With AppDynamics, you get 100% visibility into >> your >> Java,.NET, & PHP application. Start your 15-day FREE TRIAL of AppDynamics >> Pro! >> http://pubads.g.doubleclick.net/gampad/clk?id=84349831&iu=/4140/ostg.clktrk >> _______________________________________________ >> Semediawiki-user mailing list >> Sem...@li... >> https://lists.sourceforge.net/lists/listinfo/semediawiki-user >> > > > > -- > WikiWorks · MediaWiki Consulting · http://wikiworks.com > |