You are here: Foswiki>Tasks Web>Item9464 (31 Jan 2018, GeorgeClark)Edit Attach

Item9464: Improve capabilities of SEARCH $changes parameter

pencil
Priority: Enhancement
Current State: Being Worked On
Released In: 2.2.0
Target Release: minor
Applies To: Engine
Component: FoswikiUsability, SEARCH
Branches: master Item14288 Item14380 Item14537
Reported By: VickiBrown
Waiting For:
Last Change By: GeorgeClark
In Formatted Search
$changes(n)      Summary of changes between latest rev and rev n 

That's not as helpful as it might be. I rarely know what n should be. I'm more likely to want to see changes between latest and 2 back, or 3 back...

I'd like to see support added for this, perhaps
$changes(n)      Summary of changes between latest rev and rev n; 
                 if n is a negative number, show summary of changes between latest
                 rev and "n" revisions ago.

So if I say $changes(-2) and latest is rev 19, show changes between 19 and 17; if latest is 5, changes between 5 and 3, and so on.

That would let me do this:

%SEARCH{".*"  type="regex" nosearch="on" noheader="on" 
   newline="%BR%" order="modified" limit="20" reverse="on" 
   format="| [[$web.$topic][$topic]] | r $rev | $date -- $wikiname | $changes | $changes(-2) | "}%

-- VickiBrown - 12 Aug 2010

Excellent point. It seems like a trivial enhancement, but it probably needs a feature proposal.

Set as enhancement

For what it's worth, this horrible monster could be a work-around:

%STARTSECTION{"search"}%
%SEARCH{"1"
   type="query"
   nonoise="on"
   newline="%BR%"
   order="modified"
   limit="20"
   reverse="on" 
   format="| [[$web.$topic][$topic]] | r $rev | $date -- $wikiname | $changes | Since rev($percntINCLUDE{      \"%TOPIC%\"      section=\"rev\"      web=\"$web\"      topic=\"$topic\"      n=\"-2\"   }$percnt): $changes($percntINCLUDE{      \"%TOPIC%\"      section=\"rev\"      web=\"$web\"      topic=\"$topic\"      n=\"-2\"   }$percnt) | Since rev(5): $changes(5) |"}%
%ENDSECTION{"search"}%

%STARTSECTION{"rev"}%%CALC{"$SUM(%REVINFO{
   "$rev"
   web="%web%"
   topic="%topic%"
}% , %n%)"}%%ENDSECTION{"rev"}%

Test

WebNotify r 177 28 Jun 2022 - 10:05 -- UnknownUser * BobKrzaczek: Item614
- * BramVanOosterhout: Item1087 Item1099 Item12553 Item12554 It...
+ * BramVanOosterhout: Item1087 Item1099 Item12553 Item12554 It...
* BrendanB: Item8533
* ChristianHölzer: Item14856
- * ChristianKern: Item14765 Item14920 Item14921 Item14925
Since rev(175): * BobKrzaczek: Item614
- * BramVanOosterhout: Item1087 Item1099 Item12553 Item12554 It...
+ * BramVanOosterhout: Item1087 Item1099 Item12553 Item12554 It...
* BrendanB: Item8533
* ChristianHölzer: Item14856
- * ChristianKern: Item14765 Item14920 Item14921 Item14925
Since rev(5): Tasks.WebNotify
-MAKETEXT{"This is a subscription service to be automatically notified...
+This topic is automatically generated by a script running on the serv...
+script analyses all the 'WaitingFor' and 'ReportedBy' fields in repor...
+generates this WebNotify.
- * Main.TWikiGuest example #64;your.company
WebStatistics r 1513 28 Jun 2022 - 00:58 -- AdminUser }%
- Jun 2022 248419 174 1 19111 WebCreateNewTopic 2722 ...
+ Jun 2022 252933 174 1 19140 WebCreateNewTopic 2810 ...
May 2022 407838 164 0 33870 WebCreateNewTopic 3439 ...
Since rev(1511): Tasks.WebStatistics %IF{ "istopic '.Default'" then="$percentINCLUDE{$quot.Default$quot}$percent" else="$percentINCLUDE{$quot.Default$quot}$percent" }% ... Since rev(5): }%
- Jan 2018 94759 150 1 3149 WebHome 653 ItemSummaryQu...
+ Jun 2022 252933 174 1 19140 WebCreateNewTopic 2810 ...
+ May 2022 407838 164 0 33870 WebCreateNewTopic 3439 ...
+ Apr 2022 358165 125 0 24761 WebCreateNewTopic 3290 ...
+ Mar 2022 408094 185 1 30487 WebCreateNewTopic 3322 ...
Item15150 r 1 24 Jun 2022 - 15:52 -- MichaelDaum Tasks.Item15150 For now tempalte webs (those starting with an underscore) can only be one single web, that is they cannot contain any subwebs underneath. We need... Since rev(-1): Tasks.Item15150 For now tempalte webs (those starting with an underscore) can only be one single web, that is they cannot contain any subwebs underneath. We need... Since rev(5): Tasks.Item15150 For now tempalte webs (those starting with an underscore) can only be one single web, that is they cannot contain any subwebs underneath. We need...
Item13883 r 218 24 Jun 2022 - 08:29 -- MichaelDaum %META:FIELD{name="WaitingFor" title="WaitingFor" value=""}%
-%META:FIELD{name="Checkins" value="%25GITREF%7bdistro:a628fb3a133f%7d...
+%META:FIELD{name="Checkins" value="%25GITREF%7bdistro:a628fb3a133f%7d...
%META:FIELD{name="TargetRelease" title="TargetRelease" value="minor"}...
%META:FIELD{name="trunkCheckins" title="trunkCheckins" value=""}%
-%META:FIELD{name="masterCheckins" value="%25GITREF%7bdistro:c994933c2...
Since rev(216): Tasks.Item13883 Since rev(5): Tasks.Item13883
- Main.GeorgeClark 03 Dec 2015
-


%COMMENT%
%META:FIELD{name="WaitingFor" title="WaitingFor" value=""}%
-%META:FIELD{name="Checkins" value="%25GITREF%7bdistro:a628fb3a133f%7d...
Item15149 r 1 24 Jun 2022 - 08:26 -- MichaelDaum Tasks.Item15149 * bring back DOC_PARENT * better heading anchors of methods in a class * enable linking to methods of a class, not only the class itself... Since rev(-1): Tasks.Item15149 * bring back DOC_PARENT * better heading anchors of methods in a class * enable linking to methods of a class, not only the class itself... Since rev(5): Tasks.Item15149 * bring back DOC_PARENT * better heading anchors of methods in a class * enable linking to methods of a class, not only the class itself...
HallOfFame r 2 22 Jun 2022 - 12:10 -- MichaelDaum Tasks.HallOfFame
- Foswiki Subversion Activity
+ Hall of Fame
+%X% Note this information is outdated. Most of the action goes on at ...
+



The following tables show contributions to the Foswiki subversion
Since rev(0): Tasks.HallOfFame Hall of Fame Note this information is outdated. Most of the action goes on at github. Foswiki does not use subversion anymore. The following ... Since rev(5): Tasks.HallOfFame Hall of Fame Note this information is outdated. Most of the action goes on at github. Foswiki does not use subversion anymore. The following ...
Item15077 r 2 22 Jun 2022 - 11:14 -- MichaelDaum %META:FIELD{name="AppliesTo" title="AppliesTo" value="Extension"}%
-%META:FIELD{name="Component" title="Component" value=""}%
+%META:FIELD{name="Component" title="Component" value="JQueryPlugin"}%
%META:FIELD{name="Priority" title=" Priority " value="Normal"}%
Since rev(0): Tasks.Item15077 The two functions showTab() and hideTab() didn't properly work at all, i.e. don't call switchTab() in every case. Main.MichaelDaum 05 Apr 202... Since rev(5): Tasks.Item15077 The two functions showTab() and hideTab() didn't properly work at all, i.e. don't call switchTab() in every case. Main.MichaelDaum 05 Apr 202...
FixesReleaseNotesTml r 11 22 Jun 2022 - 11:12 -- MichaelDaum nosearch="on"
- order="formfield(Priority)"
+ order="topic"
limit="URLPARAM{"limit" default="%LIMIT%"}"
Since rev(9): Tasks.FixesReleaseNotesTml Release Notes This page lists items waiting for release in the next n/a patch minor major Security %SEARCH{ "( CurrentSt... Since rev(5): This page lists items waiting for release in the next
-URLPARAM{"type" default="n/a"}
-

n/a
major
-release.
Item15148 r 4 22 Jun 2022 - 11:06 -- MichaelDaum %META:FIELD{name="Component" title="Component" value=""}%
-%META:FIELD{name="Priority" title=" Priority " value="Normal"}%
+%META:FIELD{name="Priority" title=" Priority " value="Enhancement"}...
%META:FIELD{name="CurrentState" title="CurrentState" value="Waiting f...
Since rev(2): Tasks.Item15148 Plugins and skins use * VERSION: a version id, mostly float (1.23) or a tripple dot version (1.2.3) * RELEASE: the date when this extension... Since rev(5): Tasks.Item15148 Plugins and skins use * VERSION: a version id, mostly float (1.23) or a tripple dot version (1.2.3) * RELEASE: the date when this extension...
Item15145 r 7 20 Jun 2022 - 11:05 -- MichaelDaum %META:FIELD{name="WaitingFor" title="WaitingFor" value=""}%
-%META:FIELD{name="Checkins" value="%25GITREF%7bdistro:1d2546074535%7d...
+%META:FIELD{name="Checkins" value="%25GITREF%7bdistro:1d2546074535%7d...
%META:FIELD{name="TargetRelease" title="TargetRelease" value="patch"}...
%META:FIELD{name="trunkCheckins" title="trunkCheckins" value=""}%
-%META:FIELD{name="masterCheckins" value="%25GITREF%7bdistro:1d2546074...
Since rev(5): Tasks.Item15145 Basically modern browsers support it for a long time now using CGI.pm supports it as well. Basically, you only need to read the filepath paramet... Since rev(5): %META:FIELD{name="Priority" title=" Priority " value="Normal"}%
-%META:FIELD{name="CurrentState" title="CurrentState" value="Waiting f...
+%META:FIELD{name="CurrentState" title="CurrentState" value="Being Wor...
%META:FIELD{name="WaitingFor" title="WaitingFor" value=""}%
-%META:FIELD{name="Checkins" title="Checkins" value="%25GITREF%7bdistr...
+%META:FIELD{name="Checkins" value="%25GITREF%7bdistro:1d2546074535%7d...
Item15147 r 1 16 Jun 2022 - 11:06 -- MichaelDaum Tasks.Item15147 Main.MichaelDaum 16 Jun 2022 Since rev(-1): Tasks.Item15147 Main.MichaelDaum 16 Jun 2022 Since rev(5): Tasks.Item15147 Main.MichaelDaum 16 Jun 2022
Item15146 r 1 16 Jun 2022 - 10:59 -- MichaelDaum Tasks.Item15146 If a dependency package is used 100% of code being executed, then put the use a "use ...", not a "require ..." for performance reasons. Main.Mi... Since rev(-1): Tasks.Item15146 If a dependency package is used 100% of code being executed, then put the use a "use ...", not a "require ..." for performance reasons. Main.Mi... Since rev(5): Tasks.Item15146 If a dependency package is used 100% of code being executed, then put the use a "use ...", not a "require ..." for performance reasons. Main.Mi...
Item14993 r 3 13 Jun 2022 - 12:17 -- KennethLavrsen %USERSWEB%.MichaelDaum 17 Nov 2020
+



+Michael. Thanks for fixing this. I applied the current github master ...
+


+ %USERSWEB%.KennethLavrsen 13 Jun 2022
%COMMENT%
Since rev(1): Tasks.Item14993 * added dependency in HistoryPlugin 1.20 ... yet to be released atm Main.MichaelDaum 16 Nov 2020 See also Item14995 .MichaelDaum 1... Since rev(5): Tasks.Item14993 * added dependency in HistoryPlugin 1.20 ... yet to be released atm Main.MichaelDaum 16 Nov 2020 See also Item14995 .MichaelDaum 1...
Item9012 r 4 13 Jun 2022 - 08:41 -- MichaelDaum %META:FORM{name="ItemTemplate"}%
-%META:FIELD{name="Summary" title="Summary" value="Make TwistyPlugin's...
+%META:FIELD{name="Summary" title="Summary" value="make TwistyPlugin's...
%META:FIELD{name="ReportedBy" title="ReportedBy" value="Main.ArthurCl...
%META:FIELD{name="Priority" title=" Priority " value="Enhancement"}
-%META:FIELD{name="CurrentState" title="CurrentState" value="Confirmed...
Since rev(2): Tasks.Item9012 After code freeze. 1 Deprecate mode="div" and use mode="block" 1 Deprecate mode="span" and use mode="inline" "Deprecate" means existing code... Since rev(5): Tasks.Item9012 After code freeze. 1 Deprecate mode="div" and use mode="block" 1 Deprecate mode="span" and use mode="inline" "Deprecate" means existing code...
Item15144 r 3 13 Jun 2022 - 08:41 -- MichaelDaum %META:FIELD{name="Priority" title=" Priority " value="Enhancement"}
-%META:FIELD{name="CurrentState" title="CurrentState" value="Confirmed...
+%META:FIELD{name="CurrentState" title="CurrentState" value="Waiting f...
%META:FIELD{name="WaitingFor" title="WaitingFor" value=""}%
-%META:FIELD{name="Checkins" title="Checkins" value=""}%
+%META:FIELD{name="Checkins" title="Checkins" value="%25GITREF%7bdistr...
Since rev(1): Tasks.Item15144 These files ar empty: pub/System/TwistyPlugin/jquery.twisty.css pub/System/TwistyPlugin/jquery.twisty.uncompressed.css If they're supposed to be ... Since rev(5): Tasks.Item15144 These files ar empty: pub/System/TwistyPlugin/jquery.twisty.css pub/System/TwistyPlugin/jquery.twisty.uncompressed.css If they're supposed to be ...
Item2077 r 4 13 Jun 2022 - 08:09 -- MichaelDaum Main.ArthurClemens 16 Sep 2009
+




+As part of the initialization process of TwistyPlugin will those elem...
+An alternative twisty solution is Extensions.JQTwistyContrib which op...
+



+Twisty Heading
Since rev(2): Tasks.Item2077 Hi there, in a construct like this (TWISTY header) TWISTY{prefix="" mode="div" link="This text will not be printed!!" showimgleft=" This text will... Since rev(5): Tasks.Item2077 Hi there, in a construct like this (TWISTY header) TWISTY{prefix="" mode="div" link="This text will not be printed!!" showimgleft=" This text will...
Item11790 r 3 13 Jun 2022 - 07:55 -- MichaelDaum Main.RichMorin 25 Apr 2012
+




+Developer required
+ %USERSWEB%.MichaelDaum 13 Jun 2022
%COMMENT%
%META:FORM{name="ItemTemplate"}%
-%META:FIELD{name="Summary" attributes="M" title="Summary" value="jump...
Since rev(1): Tasks.Item11790 Let's say that I have some number of nested TWISTYs, some of which are closed. If I follow a link to an item, I'd like the enclosing TWISTY(s) to... Since rev(5): Tasks.Item11790 Let's say that I have some number of nested TWISTYs, some of which are closed. If I follow a link to an item, I'd like the enclosing TWISTY(s) to...
Item11327 r 3 13 Jun 2022 - 07:54 -- MichaelDaum Main.JayenAshar 04 Dec 2011
+




+FW*COMPRESSED aren't supported anymore. Use JQueryPlugin's debug mode...
+ %USERSWEB%.MichaelDaum 13 Jun 2022
%COMMENT%
%META:FORM{name="ItemTemplate"}%
-%META:FIELD{name="Summary" attributes="M" title="Summary" value="Syst...
Since rev(1): Tasks.Item11327 While FWSRC is working, FWCOMPRESSED and FWUNCOMPRESSED don't seem to be working. Also, FW*COMPRESSED only appears in System.TwistyPlugin and ma... Since rev(5): Tasks.Item11327 While FWSRC is working, FWCOMPRESSED and FWUNCOMPRESSED don't seem to be working. Also, FW*COMPRESSED only appears in System.TwistyPlugin and ma...
Item5532 r 8 12 Jun 2022 - 18:05 -- MichaelDaum KJL 02 Jun 2008
+




+Closing due to lack of actions.
+ %USERSWEB%.MichaelDaum 12 Jun 2022
+%COMMENT%
+

Since rev(6): Tasks.Item5532 I was going to try to use twistie to build a UI from sections that are used in several places, and noticed the following 1 TWISTYTOGGLE{id="log... Since rev(5): KJL 02 Jun 2008
+




+Closing due to lack of actions.
+ %USERSWEB%.MichaelDaum 12 Jun 2022
+%COMMENT%
+

Item11399 r 4 12 Jun 2022 - 18:04 -- MichaelDaum Main.VickiBrown 01 Jan 2012
+




+Closing due to lack of actions.
+ %USERSWEB%.MichaelDaum 12 Jun 2022
%COMMENT%
%META:FIELD{name="Priority" title=" Priority " value="Enhancement"}
-%META:FIELD{name="CurrentState" title="CurrentState" value="Needs Dev...
Since rev(2): Tasks.Item11399 Extensions.TwistyPlugin has several overrides for setting defaults, including TWISTYPLUGIN_TWISTYSHOWLINK and TWISTYPLUGIN_TWISTYHIDELINK. Pl... Since rev(5): Tasks.Item11399 Extensions.TwistyPlugin has several overrides for setting defaults, including TWISTYPLUGIN_TWISTYSHOWLINK and TWISTYPLUGIN_TWISTYHIDELINK. Pl...

Rev test

1511

-- PaulHarvey - 13 Aug 2010

I'm not sure that "horrible monster" is doing what you think. The results are similar to what I got using CALC. No + or - anywhere in the output is suspicious. I don't think it's actually a diff.

-- VickiBrown - 13 Aug 2010

I don't quite agree - the $percentINCLUDE is correctly calculating the rev number -2 - however I would agree that the $changes() token isn't very useful in its output; probably, that's a bug

-- PaulHarvey - 14 Aug 2010

Okay, now it should be fixed (the example, that is)

-- PaulHarvey - 17 Aug 2010

I've raised Item9502 for the crash this example causes on 1.1 - separate from the issues that Vicki raises.

-- SvenDowideit - 19 Aug 2010
 
Topic revision: r12 - 31 Jan 2018, GeorgeClark
The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy