Skip to content

Commit 30d7aa3

Browse files
author
Richard Jones
committed
merge from HEAD
1 parent 696a8fa commit 30d7aa3

File tree

2 files changed

+41
-1
lines changed

2 files changed

+41
-1
lines changed

CHANGES.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
This file contains the changes to the Roundup system over time. The entries
22
are given with the most recent entry first.
33

4-
2004-??-?? 0.7.??
4+
2004-??-?? 0.7.12
55
Fixed:
66
- handle capitalisation of class names in text hyperlinking (sf bug
77
1101043)

doc/customizing.txt

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2455,6 +2455,46 @@ the database.
24552455
Adding a new field to the classic schema
24562456
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
24572457

2458+
This example shows how to add a simple field (a due date) to the default
2459+
classic schema. It does not add any additional behaviour, such as enforcing
2460+
the due date, or causing automatic actions to fire if the due date passes.
2461+
2462+
2463+
1. modify the schema::
2464+
2465+
issue = IssueClass(db, "issue",
2466+
assignedto=Link("user"), topic=Multilink("keyword"),
2467+
priority=Link("priority"), status=Link("status"),
2468+
due_dat=Date())
2469+
2470+
2. add an edit field to the issue.item.html template::
2471+
2472+
<tr>
2473+
<th>Due Date</th>
2474+
<td tal:content="structure context/due_date/field" />
2475+
</tr>
2476+
2477+
3. add the property to the issue.index.html page::
2478+
2479+
(in the heading row)
2480+
<th tal:condition="request/show/due_date">Due Date</th>
2481+
(in the data row)
2482+
<td tal:condition="request/show/priority" tal:content="i/due_date" />
2483+
2484+
4. add the property to the issue.search.html page::
2485+
2486+
<tr tal:define="name string:due_date">
2487+
<th i18n:translate="">Due Date:</th>
2488+
<td metal:use-macro="search_input"></td>
2489+
<td metal:use-macro="column_input"></td>
2490+
<td metal:use-macro="sort_input"></td>
2491+
<td metal:use-macro="group_input"></td>
2492+
</tr>
2493+
2494+
2495+
Adding a new constrained field to the classic schema
2496+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2497+
24582498
This example shows how to add a new constrained property (i.e. a
24592499
selection of distinct values) to your tracker.
24602500

0 commit comments

Comments
 (0)