[MKDoc-dev] Updated Events Component Patch
Bruno Postle
bruno at mkdoc.com
Wed Nov 10 18:52:32 GMT 2004
On Sun 07-Nov-2004 at 15:02 -0500, Sam Tregar wrote:
> I've added a couple final bugfixes, one to address removing
> time-ranges from documents and one to handle document deletion. This
> patch is against the mkdoc-1-6 branch.
Finally I've tried the patch, I've commited it to the 1.6 CVS
branch.
I haven't quite figured this out, but the 'Move component'
functionality leaves the Document_TimeRange table in a bit of a
mess - This doesn't actually have any negative effects on the
user-interface or emails.
Here is an example, this is the table beforehand, notice that there
is one timerange component in each of documents 8 and 9:
+----+-------------+---------------------+---------------------+
| ID | Document_ID | FromDate | ToDate |
+----+-------------+---------------------+---------------------+
| 1 | 8 | 2004-10-28 08:13:00 | 2004-11-04 14:43:00 |
| 3 | 11 | 2004-12-25 00:00:00 | 2004-12-26 00:00:00 |
| 4 | 12 | 2005-01-01 00:00:00 | 2005-01-02 00:00:00 |
| 6 | 13 | 2005-02-15 00:00:00 | 2005-06-19 23:00:00 |
| 7 | 13 | 2005-06-19 23:00:00 | 2005-06-24 23:00:00 |
| 12 | 9 | 2004-11-28 00:00:00 | 2005-11-29 00:00:00 |
+----+-------------+---------------------+---------------------+
I have moved the timerange component from document 9 to document 8
but the table has two new entries, one for each document:
+----+-------------+---------------------+---------------------+
| ID | Document_ID | FromDate | ToDate |
+----+-------------+---------------------+---------------------+
| 1 | 8 | 2004-10-28 08:13:00 | 2004-11-04 14:43:00 |
| 14 | 8 | 2004-11-28 00:00:00 | 2005-11-29 00:00:00 |
| 3 | 11 | 2004-12-25 00:00:00 | 2004-12-26 00:00:00 |
| 4 | 12 | 2005-01-01 00:00:00 | 2005-01-02 00:00:00 |
| 6 | 13 | 2005-02-15 00:00:00 | 2005-06-19 23:00:00 |
| 7 | 13 | 2005-06-19 23:00:00 | 2005-06-24 23:00:00 |
| 13 | 9 | 2004-10-28 08:13:00 | 2004-11-04 14:43:00 |
| 12 | 9 | 2004-11-28 00:00:00 | 2005-11-29 00:00:00 |
+----+-------------+---------------------+---------------------+
Document 8 is correct, but document 9 now has two bogus entries.
Also if I move any component (text, whatever) from a document that
contains one or more TimeRange components, those TimeRange
components are duplicated in the Document_TimeRange table.
I haven't tried 'Copy component' yet ;-)
The emails look good, I will probably change it around a little bit,
I think the document description should appear in each entry and the
TimeRange Title should be appended to the Document Title.
So instead of this:
> Trumpets and Raspberries
> <http://www.example.com/events/theatre/trumpets-raspberries/>
> Matinee performace
> (November 28, 2004 at 20:00 GMT/BST - November 28, 2005 at 22:00 GMT/BST)
It would look something like this:
> Trumpets and Raspberries - Matinee performace
> <http://www.example.com/events/theatre/trumpets-raspberries/>
> This is a play about two men who work in a car factory.
> (November 28, 2004 at 20:00 GMT/BST - November 28, 2005 at 22:00 GMT/BST)
--
Bruno
More information about the MKDoc-dev
mailing list