| 145 | | |
| 146 | | ==== Link Actuation Options ==== |
| 147 | | |
| 148 | | The RESTful methods can handle the link-table in a number of different ways, depending on the CRUD method and the configured option: |
| 149 | | - ''replace'': hides the link table and always operates on the component table |
| 150 | | - ''hide'': hides the component table and always operates on the link table |
| 151 | | - ''link'': operates on the component table for single-record requests, and on the link table for summary requests (=without record ID) and delete |
| 152 | | - ''embed'': operates on the link table, embeds the component record in single-record requests |
| 153 | | |
| 154 | | The following table gives an overview of link actuation in S3CRUD: |
| 155 | | |
| 156 | | ||= CRUD Method =||||||||= Link Actuation Option =|| |
| 157 | | ||= =||='''replace'''=||='''hide'''=||='''link'''=||='''embed'''=|| |
| 158 | | ||='''create'''=|| create-form for component || create-form for link || create-form for link || create-form for link with component embedded || |
| 159 | | ||='''read'''=|| read-view of component || read-view of link || read-view of component || read-view of link (with component embedded^2^) || |
| 160 | | ||='''update'''=|| update-form for component || update-form for link || update-form for component || update-form for link with component embedded || |
| 161 | | ||='''delete'''=|| deletes both, component and link || deletes the link || deletes the link^1^ || deletes the link^1^ || |
| 162 | | ||='''list'''=|| list view of component || list view of link || list view of link || list view of link (with component embedded^2^) || |
| 163 | | |
| 164 | | * ^1^ = deletes the component together with the last link if ''autodelete'' option is set |
| 165 | | * ^2^ = not implemented yet |
| 166 | | |
| 167 | | Other RESTful methods such as S3Search or S3Report may have their own definitions. |
| 189 | | Important: if you specify a widget for embedding (e.g. S3AddPersonWidget), then you must ensure that the foreign key in the link-table doesn't also use either this widget or any other widget validator! |
| | 168 | '''Important''': if you specify a widget for embedding (e.g. S3AddPersonWidget), then you must ensure that the foreign key in the link-table doesn't also use either this widget or any other widget validator! |
| | 169 | |
| | 170 | ==== Link Actuation Options ==== |
| | 171 | |
| | 172 | S3CRUD can handle the link-table in a number of different ways, depending on the method and the configured option: |
| | 173 | - ''replace'': hides the link table and always operates on the component table |
| | 174 | - ''hide'': hides the component table and always operates on the link table |
| | 175 | - ''link'': operates on the component table for single-record requests, and on the link table for summary requests (=without record ID) and delete |
| | 176 | - ''embed'': operates on the link table, embeds the component record in single-record requests |
| | 177 | |
| | 178 | The following table gives an overview of link actuation in S3CRUD: |
| | 179 | |
| | 180 | ||= CRUD Method =||||||||= Link Actuation Option =|| |
| | 181 | ||= =||='''replace'''=||='''hide'''=||='''link'''=||='''embed'''=|| |
| | 182 | ||='''create'''=|| create-form for component || create-form for link || create-form for link || create-form for link with component embedded || |
| | 183 | ||='''read'''=|| read-view of component || read-view of link || read-view of component || read-view of link (with component embedded^2^) || |
| | 184 | ||='''update'''=|| update-form for component || update-form for link || update-form for component || update-form for link with component embedded || |
| | 185 | ||='''delete'''=|| deletes both, component and link || deletes the link || deletes the link^1^ || deletes the link^1^ || |
| | 186 | ||='''list'''=|| list view of component || list view of link || list view of link || list view of link (with component embedded^2^) || |
| | 187 | |
| | 188 | * ^1^ = deletes the component together with the last link if ''autodelete'' option is set |
| | 189 | * ^2^ = not implemented yet |