Edgewall Software
Modify

Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#8492 closed defect (fixed)

wiki_diff: old_version=0 shows the last change instead of all changes since Initial Version

Reported by: Luis Bruno <me+trac@…> Owned by: Christian Boos
Priority: low Milestone: 0.12
Component: wiki system Version: 0.11.5
Severity: minor Keywords:
Cc: lbruno@… Branch:
Release Notes:
API Changes:
Internal Changes:

Description

I'm generating links to old_version=-1, but that's a hack.

I'm doing an ISO9001-like plugin. After one version of a page gets approved, I can easily generate a link to the changes since the last approval to today. But if a page is getting its first approval, old_version=0 doesn't work: I get page.version - 1.

Attachments (1)

8492-diff-v0 (2.1 KB ) - added by Christian Boos 15 years ago.
Enable old_version == 0 to be considered as a valid old revision for a Wiki page.

Download all attachments as: .zip

Change History (8)

comment:1 by Christian Boos, 15 years ago

Milestone: 0.11.6
Resolution: worksforme
Status: newclosed

First version is version 1.

All changes since version 0 should show everything as added lines, not terribly useful so I'm not sure it's worth fixing.

comment:2 by Luis Bruno <me+trac@…>, 15 years ago

Owner: set to Christian Boos

Imagine an approval workflow: you work over several versions of /wiki/Procedure2.1, and submit version 42 for approval. I'm going to show everything as green lines (or in my case, with a black changebar). After that you work some more and produce version 51, and you submit it for approval. Then I'd show a diff between 42 and 51.

You're suggesting I present a diff from version 1 to 42 in the first case?

comment:3 by Christian Boos, 15 years ago

Milestone: 0.12

Ok, I understand the use case now. Would you mind testing the following patch?

by Christian Boos, 15 years ago

Attachment: 8492-diff-v0 added

Enable old_version == 0 to be considered as a valid old revision for a Wiki page.

comment:4 by Luis Bruno <me+trac@…>, 15 years ago

I'll test and report later, at around 20h00 GMT. Thank you for having a look into this! Kind regards, —lbruno.

comment:5 by Christian Boos, 15 years ago

Resolution: worksforme
Status: closedreopened

Well, on my side, the tests were OK. Re-open if necessary.

comment:6 by Christian Boos, 15 years ago

Resolution: fixed
Status: reopenedclosed

Patch applied in r8384.

comment:7 by Luis Bruno <me+trac@…>, 15 years ago

My ISP decided that last night was a good night to suck, so I couldn't report. The patch is A-OK.

Thank you for your kind attention! Best regards, —lbruno

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Christian Boos.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from Christian Boos to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.