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 175 20 Mar 2019 - 15:05 -- UnknownUser * BobKrzaczek: Item614
- * BramVanOosterhout: Item1087 Item1099 Item12553 Item12554 It...
+ * BramVanOosterhout: Item1087 Item1099 Item12553 Item12554 It...
* BrendanB: Item8533
* ChristianFerbar: Item11351 Item11352
+ * ChristianKern: Item14765
Since rev(173): * BobKrzaczek: Item614
- * BramVanOosterhout: Item1087 Item1099 Item12553 Item12554 It...
+ * BramVanOosterhout: Item1087 Item1099 Item12553 Item12554 It...
* BrendanB: Item8533
* ChristianFerbar: Item11351 Item11352
+ * ChristianKern: Item14765
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 386 20 Mar 2019 - 02:00 -- AdminUser }%
- Mar 2019 176641 18 0 11380 WebCreateNewTopic 2623 W...
+ Mar 2019 182848 18 0 11762 WebCreateNewTopic 2780 W...
Feb 2019 235045 52 0 9340 WebCreateNewTopic 3190 We...
Since rev(384): 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...
+ Mar 2019 182848 18 0 11762 WebCreateNewTopic 2780 W...
+ Feb 2019 235045 52 0 9340 WebCreateNewTopic 3190 We...
+ Jan 2019 222386 52 0 11185 WebCreateNewTopic 4259 W...
+ Dec 2018 269320 37 0 8289 WebCreateNewTopic 5735 We...
Item14828 r 2 14 Mar 2019 - 16:17 -- MichaelDaum Main.FrankHoellering 14 Mar 2019
+




+Yes that's fixing it. This should do as well:
+



+return Foswiki::Plugins::JQueryPlugin::getIconService() getIconUrlPa...
+


Since rev(0): Tasks.Item14828 I did a fresh foswiki 2.0.6 install with version 6.01 version of the classification plugin. Then I created a new Web with the _ClassificationTemp... Since rev(5): Tasks.Item14828 I did a fresh foswiki 2.0.6 install with version 6.01 version of the classification plugin. Then I created a new Web with the _ClassificationTemp...
Item14827 r 1 11 Mar 2019 - 18:15 -- MichaelDaum Tasks.Item14827 See Support.Question1981 . Main.MichaelDaum 11 Mar 2019 Since rev(-1): Tasks.Item14827 See Support.Question1981 . Main.MichaelDaum 11 Mar 2019 Since rev(5): Tasks.Item14827 See Support.Question1981 . Main.MichaelDaum 11 Mar 2019
Item14826 r 8 06 Mar 2019 - 11:00 -- MichaelDaum %USERSWEB%.EdMcDonagh 06 Mar 2019
+



+I've edited it and manually appended formtemplate=TaskItem14826Form ...
+


+ %USERSWEB%.MichaelDaum 06 Mar 2019
%COMMENT%
Since rev(6): Tasks.Item14826 Date picker in form appears at point date field was before scrolling. With a long form this causes usability issues! * In Chrome, Edge, the da... Since rev(5): %USERSWEB%.EdMcDonagh 05 Mar 2019
+



+I can confirm the problem. It is caused by the date picker being embe...
+


+This is an error in the JSCalendar third party component that the jqu...
+

Item14825 r 1 28 Feb 2019 - 15:53 -- EdMcDonagh Tasks.Item14825 If I have a table on a topic with a CALC that counts up items in a column like this: When Who 02 Jan 2019 Sally 03 Jan 2019 John ... Since rev(-1): Tasks.Item14825 If I have a table on a topic with a CALC that counts up items in a column like this: When Who 02 Jan 2019 Sally 03 Jan 2019 John ... Since rev(5): Tasks.Item14825 If I have a table on a topic with a CALC that counts up items in a column like this: When Who 02 Jan 2019 Sally 03 Jan 2019 John ...
Item14824 r 1 19 Feb 2019 - 09:35 -- MichaelDaum Tasks.Item14824 Not guests are equal, however the first that gets a login page will have caused it to be cached. All other guests get the cached version instead ... Since rev(-1): Tasks.Item14824 Not guests are equal, however the first that gets a login page will have caused it to be cached. All other guests get the cached version instead ... Since rev(5): Tasks.Item14824 Not guests are equal, however the first that gets a login page will have caused it to be cached. All other guests get the cached version instead ...
Item14823 r 4 19 Feb 2019 - 09:30 -- MichaelDaum Main.CrawfordCurrie 19 Feb 2019 10:11
+



+Yes I think so. I some times use a ?cover=dbdump to check out what is...
+


+view.dbdump.tmpl:
+


Since rev(2): Tasks.Item14823 Plugins and contribs can register arbitrary metadata using Foswiki::Meta::registerMETA and this is then loaded by the DBCacheContrib. However the... Since rev(5): Tasks.Item14823 Plugins and contribs can register arbitrary metadata using Foswiki::Meta::registerMETA and this is then loaded by the DBCacheContrib. However the...
Item14822 r 1 14 Feb 2019 - 12:41 -- MichaelDaum Tasks.Item14822 renamed css and js files not to be blocked by fanboy banlist Main.MichaelDaum 14 Feb 2019 Since rev(-1): Tasks.Item14822 renamed css and js files not to be blocked by fanboy banlist Main.MichaelDaum 14 Feb 2019 Since rev(5): Tasks.Item14822 renamed css and js files not to be blocked by fanboy banlist Main.MichaelDaum 14 Feb 2019
Item14820 r 1 14 Feb 2019 - 09:18 -- MichaelDaum Tasks.Item14820 This mechanism is a side product of the abandoned AngularPlugin work. It makes use of the jsonTemplate REST handler of RenderPlugin to load foswi... Since rev(-1): Tasks.Item14820 This mechanism is a side product of the abandoned AngularPlugin work. It makes use of the jsonTemplate REST handler of RenderPlugin to load foswi... Since rev(5): Tasks.Item14820 This mechanism is a side product of the abandoned AngularPlugin work. It makes use of the jsonTemplate REST handler of RenderPlugin to load foswi...
Item14821 r 1 14 Feb 2019 - 09:13 -- MichaelDaum Tasks.Item14821 Main.MichaelDaum 14 Feb 2019 Since rev(-1): Tasks.Item14821 Main.MichaelDaum 14 Feb 2019 Since rev(5): Tasks.Item14821 Main.MichaelDaum 14 Feb 2019
Item14684 r 5 12 Feb 2019 - 14:41 -- MichaelDaum %USERSWEB%.AlexAnder 11 Jan 2019
+



+This has been fixed in the latest release.
+


+ %USERSWEB%.MichaelDaum 12 Feb 2019
%COMMENT%
Since rev(3): Tasks.Item14684 GITREF{"DiffPlugin:d483bdfb40a5"} removed the diff.nat.tmpl template, however there is no corresponding checkin to the NatSkin. Newly installed N... Since rev(5):
Item14787 r 2 12 Feb 2019 - 14:40 -- MichaelDaum Main.GinoNaumann 19 Nov 2018
+




+TopicActions in diff mode have been reworked in the latest release.
+ %USERSWEB%.MichaelDaum 12 Feb 2019
%COMMENT%
%META:FIELD{name="Priority" title=" Priority " value="Normal"}%
-%META:FIELD{name="CurrentState" title="CurrentState" value="New"}%
Since rev(0): Tasks.Item14787 Item14787 We have NatSkin 5.01 and Foswiki 2.1.6 in action. If we want to look our old revisions of the topic, we are clicking on the revinfo l... Since rev(5): Tasks.Item14787 Item14787 We have NatSkin 5.01 and Foswiki 2.1.6 in action. If we want to look our old revisions of the topic, we are clicking on the revinfo l...
Item14788 r 2 12 Feb 2019 - 14:39 -- MichaelDaum Main.GinoNaumann 19 Nov 2018
+




+Should be fine in latest NatSkin version now. Please reopen when the ...
+ %USERSWEB%.MichaelDaum 12 Feb 2019
%COMMENT%
%META:FIELD{name="Priority" title=" Priority " value="Normal"}%
-%META:FIELD{name="CurrentState" title="CurrentState" value="New"}%
Since rev(0): Tasks.Item14788 We have NatSkin 5.01 and Foswiki 2.1.6 in action. I noticed, that the icon NEXT_ICON is missing. By the way, the i class of LAST_ICON is wrong. Y... Since rev(5): Tasks.Item14788 We have NatSkin 5.01 and Foswiki 2.1.6 in action. I noticed, that the icon NEXT_ICON is missing. By the way, the i class of LAST_ICON is wrong. Y...
Item14297 r 4 12 Feb 2019 - 14:37 -- MichaelDaum PaulMerchantJr
+




+This has been reverted not to break inline scripts.
+ %USERSWEB%.MichaelDaum 12 Feb 2019
%COMMENT%
%META:FIELD{name="Priority" title=" Priority " value="Normal"}%
-%META:FIELD{name="CurrentState" title="CurrentState" value="Confirmed...
Since rev(2): Tasks.Item14297 The NatSkin templates released on Jan. 23 relocates the rendering of the script zone from the page header to the end of the page body. I suspect... Since rev(5): Tasks.Item14297 The NatSkin templates released on Jan. 23 relocates the rendering of the script zone from the page header to the end of the page body. I suspect...
Item14354 r 6 12 Feb 2019 - 14:36 -- MichaelDaum %USERSWEB%.SebastienTremblay 28 Jul 2017
+



+Looking at https://demo.michaeldaumconsulting.com/bin/view/Sandbox/We...
+the error doesn't seem to be present anymore in the latest NatSkin ve...
+



+ %USERSWEB%.MichaelDaum 12 Feb 2019
Since rev(4): Tasks.Item14354 The template for WebCreateNewTopic ( newtopic.nat.tmpl ) is broken in the latest release (25 Jan 2017) . It results in an empty page. I haven't i... Since rev(5): %USERSWEB%.SebastienTremblay 28 Jul 2017
+



+Looking at https://demo.michaeldaumconsulting.com/bin/view/Sandbox/We...
+the error doesn't seem to be present anymore in the latest NatSkin ve...
+



+ %USERSWEB%.MichaelDaum 12 Feb 2019
Item14355 r 4 12 Feb 2019 - 12:52 -- MichaelDaum %META:TOPICPARENT{name="NatSkin"}%
-

- Main.PeterFarmer 27 Mar 2017
The TMPL:DEF macro for no_such_attachment in message.nat.tmpl expects...
%TMPL:END%
+ Main.PeterFarmer 27 Mar 2017
Since rev(2): Tasks.Item14355 The TMPL:DEF macro for no_such_attachment in message.nat.tmpl expects 2 parameters when only one appears to be supplied (in Foswiki 2.1.2) . The ... Since rev(5): Tasks.Item14355 The TMPL:DEF macro for no_such_attachment in message.nat.tmpl expects 2 parameters when only one appears to be supplied (in Foswiki 2.1.2) . The ...
Item12732 r 3 12 Feb 2019 - 12:51 -- MichaelDaum %USERSWEB%.GeorgeClark 23 Dec 2014
+



+Seems fixed by now.
+


+ %USERSWEB%.MichaelDaum 12 Feb 2019
%COMMENT%
Since rev(1): Tasks.Item12732 The "Help" tab in "Edit topic preferences" just shows a Help title and the processing.gif graphic. It seems there are two problems here: 1. Th... Since rev(5): Tasks.Item12732 The "Help" tab in "Edit topic preferences" just shows a Help title and the processing.gif graphic. It seems there are two problems here: 1. Th...
Item14552 r 4 12 Feb 2019 - 12:50 -- MichaelDaum %META:FIELD{name="Priority" title=" Priority " value="Enhancement"}
-%META:FIELD{name="CurrentState" title="CurrentState" value="Being Wor...
+%META:FIELD{name="CurrentState" title="CurrentState" value="Closed"}%
%META:FIELD{name="WaitingFor" title="WaitingFor" value=""}%
-%META:FIELD{name="Checkins" value="%25GITREF%7bNatSkin:7d718146832d%7...
+%META:FIELD{name="Checkins" title="Checkins" value="%25GITREF%7bNatSk...
Since rev(2): Tasks.Item14552 Main.MichaelDaum 04 Dec 2017 Since rev(5): Tasks.Item14552 Main.MichaelDaum 04 Dec 2017
Item14693 r 14 12 Feb 2019 - 12:41 -- MichaelDaum * %Y% MetaDataPlugin
- * ClassificationPlugin
+ * %Y% NatSkinPlugin
- * NatSkinPlugin
+ * ClassificationPlugin
Not all of above plugins are currently broken. Most of them had a loc...
Since rev(12): Tasks.Item14693 Main.MichaelDaum 28 May 2018 Greetings; I updated the DBCache Plugin, and now I have to disable it for my Foswiki to work. When DBCache is en... Since rev(5): %USERSWEB%.PaulHarrison 02 Jun 2018
+



+Known issue. See also Support.Question1942
+


+Quickfix:
+

Rev test

384

-- 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 - This page was cached on 20 Mar 2019 - 20:05.

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