diff --git a/SivStudies/src/org/labkey/sivstudies/query/DefaultDatasetTrigger.java b/SivStudies/src/org/labkey/sivstudies/query/DefaultDatasetTrigger.java index fea3c889..88434efe 100644 --- a/SivStudies/src/org/labkey/sivstudies/query/DefaultDatasetTrigger.java +++ b/SivStudies/src/org/labkey/sivstudies/query/DefaultDatasetTrigger.java @@ -7,6 +7,7 @@ import org.labkey.api.data.TableInfo; import org.labkey.api.data.triggers.Trigger; import org.labkey.api.data.triggers.TriggerFactory; +import org.labkey.api.query.QueryUpdateService; import org.labkey.api.query.ValidationException; import org.labkey.api.security.User; import org.labkey.api.util.logging.LogHelper; @@ -35,9 +36,9 @@ public Factory() } @Override - public void beforeInsert(TableInfo table, Container c, User user, @Nullable Map newRow, ValidationException errors, Map extraContext) throws ValidationException + public void beforeInsert(TableInfo table, Container c, User user, @Nullable QueryUpdateService.InsertOption insertOption, @Nullable Map newRow, ValidationException errors, Map extraContext) throws ValidationException { - beforeInsert(table, c, user, newRow, errors, extraContext, null); + beforeInsert(table, c, user, insertOption, newRow, errors, extraContext, null); } @Override @@ -64,13 +65,13 @@ protected void afterUpsert(TableInfo table, Container c, User user, @Nullable Ma } @Override - public void beforeInsert(TableInfo table, Container c, User user, @Nullable Map newRow, ValidationException errors, Map extraContext, @Nullable Map existingRecord) throws ValidationException + public void beforeInsert(TableInfo table, Container c, User user, @Nullable QueryUpdateService.InsertOption insertOption, @Nullable Map newRow, ValidationException errors, Map extraContext, @Nullable Map existingRecord) throws ValidationException { beforeUpsert(table, c, user, newRow, existingRecord, errors, extraContext); } @Override - public void beforeUpdate(TableInfo table, Container c, User user, @Nullable Map newRow, @Nullable Map oldRow, ValidationException errors, Map extraContext) throws ValidationException + public void beforeUpdate(TableInfo table, Container c, User user, @Nullable QueryUpdateService.InsertOption insertOption, @Nullable Map newRow, @Nullable Map oldRow, ValidationException errors, Map extraContext) throws ValidationException { beforeUpsert(table, c, user, newRow, oldRow, errors, extraContext); } diff --git a/SivStudies/src/org/labkey/sivstudies/query/ViralLoadsTriggerFactory.java b/SivStudies/src/org/labkey/sivstudies/query/ViralLoadsTriggerFactory.java index faab87fe..051c6224 100644 --- a/SivStudies/src/org/labkey/sivstudies/query/ViralLoadsTriggerFactory.java +++ b/SivStudies/src/org/labkey/sivstudies/query/ViralLoadsTriggerFactory.java @@ -8,6 +8,7 @@ import org.labkey.api.data.TableInfo; import org.labkey.api.data.triggers.Trigger; import org.labkey.api.data.triggers.TriggerFactory; +import org.labkey.api.query.QueryUpdateService; import org.labkey.api.query.SimpleValidationError; import org.labkey.api.query.ValidationException; import org.labkey.api.security.User; @@ -15,7 +16,6 @@ import java.util.Collection; import java.util.List; import java.util.Map; -import java.util.regex.Pattern; public class ViralLoadsTriggerFactory implements TriggerFactory { @@ -33,19 +33,19 @@ public ViralLoadsTriggerFactory() public static class ViralLoadTrigger implements Trigger { @Override - public void beforeInsert(TableInfo table, Container c, User user, @Nullable Map newRow, ValidationException errors, Map extraContext) throws ValidationException + public void beforeInsert(TableInfo table, Container c, User user, @Nullable QueryUpdateService.InsertOption insertOption, @Nullable Map newRow, ValidationException errors, Map extraContext) throws ValidationException { - beforeInsert(table, c, user, newRow, errors, extraContext, null); + beforeInsert(table, c, user, insertOption, newRow, errors, extraContext, null); } @Override - public void beforeInsert(TableInfo table, Container c, User user, @Nullable Map newRow, ValidationException errors, Map extraContext, @Nullable Map existingRecord) throws ValidationException + public void beforeInsert(TableInfo table, Container c, User user, @Nullable QueryUpdateService.InsertOption insertOption, @Nullable Map newRow, ValidationException errors, Map extraContext, @Nullable Map existingRecord) throws ValidationException { handlePVL(newRow, c, errors); } @Override - public void beforeUpdate(TableInfo table, Container c, User user, @Nullable Map newRow, @Nullable Map oldRow, ValidationException errors, Map extraContext) throws ValidationException + public void beforeUpdate(TableInfo table, Container c, User user, @Nullable QueryUpdateService.InsertOption insertOption, @Nullable Map newRow, @Nullable Map oldRow, ValidationException errors, Map extraContext) throws ValidationException { handlePVL(newRow, c, errors); }