Mass Action Adoption Rows Doesn't Work - SFX V2 - 16.0.5

Makes no sense

<skuid__page unsavedchangeswarning="yes" personalizationmode="server" showsidebar="true" showheader="true" title="Production Management">
	<models>
		<model id="Accounts" limit="" query="false" createrowifnonefound="false" datasource="salesforce" sobject="Account" type="aggregate">
			<groupby method="simple">
				<field id="Industry" name="Industry"/>
			</groupby>
			<fields/>
			<conditions/>
			<actions/>
		</model>
		<model id="Contacts" limit="" query="false" createrowifnonefound="false" datasource="salesforce" sobject="Contact">
			<fields>
				<field id="Name"/>
			</fields>
			<conditions/>
			<actions/>
		</model>
		<model id="ContactsSelected" limit="" query="false" createrowifnonefound="false" datasource="salesforce" sobject="Contact">
			<fields>
				<field id="Name"/>
			</fields>
			<conditions/>
			<actions/>
		</model>
	</models>
	<components>
		<skuid__buttonSet model="Accounts" uniqueid="sk-2XZ1-21061">
			<groups>
				<skuid__buttonGroup uniqueId="sk-2XZ1-21059">
					<buttons>
						<skuid__button label="View Contacts" uniqueId="sk-2XZ1-21060">
							<actions>
								<action type="requeryModels" behavior="standard">
									<models>
										<model>Contacts</model>
									</models>
								</action>
								<action type="openSlidingPanel" openbehavior="open">
									<skuid__slidingPanel uniqueid="sk-1tTU-8998823" size="900px" origin="top" behavior="overlay">
										<components>
											<skuid__table allowColumnFreezing="dragDrop" model="Contacts" uniqueid="sk-1tTZ-911775" mode="readonly" showSaveCancel="false" pageSize="Infinity" showListFooter="false" enableDrawers="false" title="Contacts">
												<fields>
													<field id="Name" uniqueid="fi-2Wp4-176812" redirectType="customurl" window="self"/>
												</fields>
												<massActions>
													<action type="multi" label="Select">
														<actions>
															<action type="adoptRows" sourcemodel="Contacts" targetmodel="ContactsSelected" affectedrows="context"/>
														</actions>
													</action>
												</massActions>
											</skuid__table>
											<skuid__table allowColumnFreezing="dragDrop" model="ContactsSelected" uniqueid="sk-2XO1-349184" mode="readonly" title="Contacts Selected" showSaveCancel="false">
												<fields>
													<field id="Name" uniqueid="fi-2XOj-358002"/>
												</fields>
											</skuid__table>
										</components>
									</skuid__slidingPanel>
								</action>
							</actions>
						</skuid__button>
					</buttons>
				</skuid__buttonGroup>
			</groups>
		</skuid__buttonSet>
		<skuid__wrapper uniqueid="sk-20ih-1276097609">
			<components>
				<skuid__table allowColumnFreezing="dragDrop" model="Accounts" uniqueid="sk-1tBb-3029537609" mode="readonly" pageSize="Infinity" rowActionsOnLeft="true" showListFooter="false" showSaveCancel="false">
					<actions>
						<action type="multi" label="View Contacts">
							<actions>
								<action type="requeryModels" behavior="standard">
									<models>
										<model>Contacts</model>
									</models>
								</action>
								<action type="openSlidingPanel" openbehavior="open">
									<skuid__slidingPanel uniqueid="sk-1tTU-899881676097" size="900px" origin="top" behavior="overlay">
										<components>
											<skuid__table allowColumnFreezing="dragDrop" model="Contacts" uniqueid="sk-1tTZ-911775" mode="readonly" showSaveCancel="false" pageSize="Infinity" showListFooter="false" enableDrawers="false" title="Contacts">
												<fields>
													<field id="Name" uniqueid="fi-2Wp4-1768760912" redirectType="customurl" window="self"/>
												</fields>
												<massActions>
													<action type="multi" label="Select">
														<actions>
															<action type="adoptRows" sourcemodel="Contacts" targetmodel="ContactsSelected" affectedrows="context"/>
														</actions>
													</action>
												</massActions>
												<exportProperties useTableColumns="true"/>
											</skuid__table>
											<skuid__table allowColumnFreezing="dragDrop" model="ContactsSelected" uniqueid="sk-2XO1-3497609184" mode="readonly" title="Contacts Selected" showSaveCancel="false">
												<fields>
													<field id="Name" uniqueid="fi-2XOj-3587609002"/>
												</fields>
												<exportProperties useTableColumns="true"/>
											</skuid__table>
										</components>
									</skuid__slidingPanel>
								</action>
							</actions>
						</action>
					</actions>
					<exportProperties useTableColumns="true"/>
					<filtering enableSearch="false"/>
					<sorting enable="false"/>
				</skuid__table>
			</components>
			<background/>
		</skuid__wrapper>
	</components>
	<resources>
		<actionsequences/>
		<javascript/>
	</resources>
</skuid__page>

Ready for the wonkiness?

The problem with your page is that the Mass Action is on a Table that has been created by a in Context Generating Scenario. If you pull your Mass Action table out onto the base page it will work fine.

When your table is generated within a Context Generating Scenario - the single parent context overrides the mass action context set and is incorrectly applied to your adopt row action (or update row or create row…). We’ve seen this bug before and call it CORE-1337

Examples of Context Generating Scenarios.

  • Table is in popup generated from Header Button
  • Table is in deck card
  • Table is in sliding panel generated from another table row action

Workaround: A row action will correctly capture context to the single row. So here is the work around. have your Mass Action simply update a UI only field. Then create a Model action on update row that does your adopt row action.

1 Like

Awesome! There’s always a work around. Approx. eta of fix?