Wiki source code of Development-Examples-List Components
Last modified by Pascal Robert on 2010/09/13 00:31
Show last authors
author | version | line-number | content |
---|---|---|---|
1 | So you have a title and a "list" of objects. The list has a minimum and maximum number of objects to display. If there is "too many" objects there is a "more..." link. | ||
2 | |||
3 | Here is the html: | ||
4 | |||
5 | {{code}} | ||
6 | |||
7 | <webobject name="HasData"> | ||
8 | <webobject name="Title"></webobject> | ||
9 | <br> | ||
10 | <webobject name="Items"> | ||
11 | <webobject name = "Item"></webobject><br> | ||
12 | </webobject> | ||
13 | <webobject name="HasMore"> | ||
14 | <webobject name = "MoreLink"><span class = "Label"><small><webobject name = "MoreCount"></webobject> more...</small></span></webobject><br> | ||
15 | </webobject> | ||
16 | <div class = "Space"></div> | ||
17 | </webobject> | ||
18 | |||
19 | {{/code}} | ||
20 | |||
21 | And here is the wod: | ||
22 | |||
23 | {{code}} | ||
24 | |||
25 | HasData: WOConditional { | ||
26 | condition = hasData; | ||
27 | }; | ||
28 | |||
29 | Title: SpanString { | ||
30 | value = title.toUpperCase; | ||
31 | isSmall = true; | ||
32 | isBold = true; | ||
33 | class = "Label"; | ||
34 | }; | ||
35 | |||
36 | Items: WORepetition { | ||
37 | count = count; | ||
38 | index = index; | ||
39 | }; | ||
40 | |||
41 | Item: SZLink { | ||
42 | value = item; | ||
43 | description = description; | ||
44 | altDescription = altDescription; | ||
45 | href = href; | ||
46 | pageName = pageName; | ||
47 | isSmall = true; | ||
48 | class = "Label"; | ||
49 | }; | ||
50 | |||
51 | HasMore: WOConditional { | ||
52 | condition = hasMore; | ||
53 | }; | ||
54 | |||
55 | MoreCount: SpanString { | ||
56 | value = moreCount; | ||
57 | }; | ||
58 | |||
59 | MoreLink: WOHyperlink { | ||
60 | action = displayMore; | ||
61 | }; | ||
62 | |||
63 | {{/code}} |