updated the component and device api's to have as be a parameter for the function

This commit is contained in:
csawatzky 2025-04-22 14:33:19 -06:00
parent c617ebf868
commit b62c7dbe5c
39 changed files with 346 additions and 651 deletions

View file

@ -147,7 +147,7 @@ export default function GrainNodeInteractions(props: Props) {
settings.defaultMutations = [pond.Mutator.MUTATOR_EMC];
settings.grainType = grain;
componentAPI
.update(device.id(), settings, [binKey], ["bin"])
.update(device.id(), settings, [binKey], ["bin"], as)
.then(resp => {
openSnack("EMC set on cable " + cable.name());
updateComponentCallback(cable.key());
@ -157,7 +157,7 @@ export default function GrainNodeInteractions(props: Props) {
const submit = () => {
componentAPI
.update(device.id(), cable.settings, [binKey], ["bin"])
.update(device.id(), cable.settings, [binKey], ["bin"], as)
.then(resp => {
//after updating the component update the interactions with the new subtypes
//TODO-CS: make function to update multiple interactions at once to avoid this loop if it becomes a problem