Rebuild time
This commit is contained in:
@@ -464,6 +464,7 @@ const EditWorkflow = (props) => {
|
||||
<span>
|
||||
<Button
|
||||
id="ai-generate-button"
|
||||
style={{marginLeft: 10, }}
|
||||
disabled={
|
||||
name.length === 0 ||
|
||||
aiGenerateLoading === true ||
|
||||
@@ -484,7 +485,7 @@ const EditWorkflow = (props) => {
|
||||
// check AI enabled for local installations (not cloud)
|
||||
if (!isCloud && (!userdata?.ai_enabled || userdata?.ai_enabled === false)) {
|
||||
// Toast with onclick
|
||||
toast.info("AI credits haven't been applied and no Local AI is not enabled. Click here to set it up!", {
|
||||
toast.info("Local AI is not enabled, and no cloud AI credits added. Click here to set it up!", {
|
||||
autoClose: 10000,
|
||||
onClick: () => {
|
||||
window.open("/docs/AI#self-hosting-models", "_blank")
|
||||
|
||||
@@ -131,8 +131,15 @@ const WorkflowGenerationModal = (props) => {
|
||||
.then((response) => {
|
||||
return response.json().then((json) => {
|
||||
if (response.status !== 200) {
|
||||
toast.error(json.message || "Unexpected response. Please contact support@shuffler.io if this persists.");
|
||||
toast.error(json.reason || "Unexpected response. Please contact support@shuffler.io if this persists.", {
|
||||
autoClose: 10000,
|
||||
onClick: () => {
|
||||
window.open("/docs/AI#self-hosting-models", "_blank")
|
||||
}
|
||||
})
|
||||
|
||||
setIsAiEditing(false);
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -265,4 +272,4 @@ const WorkflowGenerationModal = (props) => {
|
||||
);
|
||||
};
|
||||
|
||||
export default WorkflowGenerationModal;
|
||||
export default WorkflowGenerationModal;
|
||||
|
||||
@@ -11992,7 +11992,19 @@ const AngularWorkflow = (defaultprops) => {
|
||||
const json = await response.json();
|
||||
|
||||
if (response.status !== 200) {
|
||||
toast(json.message || "Unexpected response");
|
||||
if (json.reason !== undefined && json.reason !== null && json.reason.length > 0) {
|
||||
toast.error("Workflow generation failed: " + json.reason)
|
||||
}
|
||||
|
||||
if (!isCloud) {
|
||||
toast.info("Click here to set up a local LLM!", {
|
||||
autoClose: 10000,
|
||||
onClick: () => {
|
||||
window.open("/docs/AI#self-hosting-models", "_blank")
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -20969,10 +20981,10 @@ const AngularWorkflow = (defaultprops) => {
|
||||
</Tooltip>
|
||||
: null}
|
||||
|
||||
{userdata.support == true ?
|
||||
{userdata.support == true || !isCloud ?
|
||||
<Tooltip
|
||||
color="secondary"
|
||||
title="Generate workflow (support only)"
|
||||
title="Generate workflow (requires LLM model)"
|
||||
placement="top-start"
|
||||
>
|
||||
<span>
|
||||
|
||||
Reference in New Issue
Block a user