mirror of
https://github.com/Kingsrook/qqq.git
synced 2025-07-18 13:10:44 +00:00
PRDONE-170 - Adding support for passing in custom ScriptUtls for scripts.
This commit is contained in:
@ -70,6 +70,12 @@ public class RunAssociatedScriptAction
|
|||||||
{
|
{
|
||||||
executeCodeInput.getContext().put("output", input.getOutputObject());
|
executeCodeInput.getContext().put("output", input.getOutputObject());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(input.getScriptUtils() != null)
|
||||||
|
{
|
||||||
|
executeCodeInput.getContext().put("scriptUtils", input.getScriptUtils());
|
||||||
|
}
|
||||||
|
|
||||||
executeCodeInput.setCodeReference(new QCodeReference().withInlineCode(scriptRevision.getContents()).withCodeType(QCodeType.JAVA_SCRIPT)); // todo - code type as attribute of script!!
|
executeCodeInput.setCodeReference(new QCodeReference().withInlineCode(scriptRevision.getContents()).withCodeType(QCodeType.JAVA_SCRIPT)); // todo - code type as attribute of script!!
|
||||||
|
|
||||||
/////////////////////////////////////////////////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////////////////////////////////////////////////
|
||||||
|
@ -40,6 +40,8 @@ public class RunAssociatedScriptInput extends AbstractTableActionInput
|
|||||||
|
|
||||||
private Serializable outputObject;
|
private Serializable outputObject;
|
||||||
|
|
||||||
|
private Serializable scriptUtils;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*******************************************************************************
|
/*******************************************************************************
|
||||||
@ -152,6 +154,7 @@ public class RunAssociatedScriptInput extends AbstractTableActionInput
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*******************************************************************************
|
/*******************************************************************************
|
||||||
** Getter for logger
|
** Getter for logger
|
||||||
*******************************************************************************/
|
*******************************************************************************/
|
||||||
@ -182,4 +185,24 @@ public class RunAssociatedScriptInput extends AbstractTableActionInput
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Getter for scriptUtils
|
||||||
|
**
|
||||||
|
*******************************************************************************/
|
||||||
|
public Serializable getScriptUtils()
|
||||||
|
{
|
||||||
|
return scriptUtils;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/*******************************************************************************
|
||||||
|
** Setter for scriptUtils
|
||||||
|
**
|
||||||
|
*******************************************************************************/
|
||||||
|
public void setScriptUtils(Serializable scriptUtils)
|
||||||
|
{
|
||||||
|
this.scriptUtils = scriptUtils;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user