Wiki source code of How to use an Embedded D2WList
Last modified by Ravi Mendis on 2010/02/03 21:04
Show last authors
| author | version | line-number | content |
|---|---|---|---|
| 1 | == How to use an Embedded D2WList == | ||
| 2 | |||
| 3 | In //ERDivaLookExample// {{code language="none"}}Studio.movies{{/code}} is displayed as an embedded D2W list: | ||
| 4 | |||
| 5 | [[image:attach:Picture 1.png]] | ||
| 6 | |||
| 7 | You use it by setting the following rules: | ||
| 8 | |||
| 9 | |=((( | ||
| 10 | LHS | ||
| 11 | )))|=((( | ||
| 12 | key | ||
| 13 | )))|=((( | ||
| 14 | RHS | ||
| 15 | ))) | ||
| 16 | |((( | ||
| 17 | entity.name = 'Studio' and task = 'inspect' and propertyKey = 'movies' | ||
| 18 | )))|((( | ||
| 19 | **componentName** | ||
| 20 | )))|((( | ||
| 21 | //ERDEditableList// | ||
| 22 | ))) | ||
| 23 | |((( | ||
| 24 | pageConfiguration = 'ListEmbeddedMovie' and parentPageConfiguration like '*Studio' | ||
| 25 | )))|((( | ||
| 26 | **displayPropertyKeys** | ||
| 27 | )))|((( | ||
| 28 | //("title","category","rated")// | ||
| 29 | ))) | ||
| 30 | |||
| 31 | All embedded D2WList pages have pageConfigurations beginning with //ListEmbedded//. | ||
| 32 | They also are assigned a **parentPageConfiguration**. | ||
| 33 | |||
| 34 | So the particular setting for a embedded list can be identified using both these keys, as seen in the second rule listed above. | ||
| 35 | |||
| 36 | === How to make the list Editable === | ||
| 37 | |||
| 38 | To be able to add items to the list use a rule like the following: | ||
| 39 | |||
| 40 | |=((( | ||
| 41 | LHS | ||
| 42 | )))|=((( | ||
| 43 | key | ||
| 44 | )))|=((( | ||
| 45 | RHS | ||
| 46 | ))) | ||
| 47 | |((( | ||
| 48 | pageConfiguration = 'ListEmbeddedMovie' and parentPageConfiguration like '*Studio' | ||
| 49 | )))|((( | ||
| 50 | **showActions** | ||
| 51 | )))|((( | ||
| 52 | true | ||
| 53 | ))) | ||
| 54 | |||
| 55 | To be able to delete items from the list, use a rule like: | ||
| 56 | |||
| 57 | |=((( | ||
| 58 | LHS | ||
| 59 | )))|=((( | ||
| 60 | key | ||
| 61 | )))|=((( | ||
| 62 | RHS | ||
| 63 | ))) | ||
| 64 | |((( | ||
| 65 | pageConfiguration = 'ListEmbeddedMovie' and parentPageConfiguration like '*Studio' | ||
| 66 | )))|((( | ||
| 67 | **isEntityDeletable** | ||
| 68 | )))|((( | ||
| 69 | true | ||
| 70 | ))) |