| | 101 | If fact and methods are configured like: |
| | 102 | |
| | 103 | {{{#!python |
| | 104 | report_options = Storage( |
| | 105 | fact = [field1, field2, field3], |
| | 106 | methods = [method1, method2], |
| | 107 | ... |
| | 108 | ) |
| | 109 | }}} |
| | 110 | |
| | 111 | then S3Report will automatically provide a selection of all (mathematically) meaningful field-method-combinations. Some of these combinations may not be relevant for the use-case, though. To specify field-method-combinations instead, you can configure it like: |
| | 112 | |
| | 113 | {{{#!python |
| | 114 | report_options = Storage( |
| | 115 | fact = [ |
| | 116 | (field1, method1), |
| | 117 | (field2, method1), |
| | 118 | (field2, method2), |
| | 119 | (field3, method1), |
| | 120 | ], |
| | 121 | ... |
| | 122 | ) |
| | 123 | }}} |
| | 124 | |
| | 125 | Optionally, you can define a custom label for each combination (which will be used in the select list): |
| | 126 | |
| | 127 | {{{#!python |
| | 128 | report_options = Storage( |
| | 129 | fact = [ |
| | 130 | (field1, method1, T("My Report A")), |
| | 131 | (field2, method1, T("My Report B")), |
| | 132 | (field2, method2, T("My Report C")), |
| | 133 | (field3, method1, T("My Report D")), |
| | 134 | ], |
| | 135 | ... |
| | 136 | ) |
| | 137 | }}} |
| | 138 | |