Minor fixes to app creation process
This commit is contained in:
@@ -6673,6 +6673,7 @@ func createFs(basepath, pathname string) (billy.Filesystem, error) {
|
|||||||
|
|
||||||
// Hotloads new apps from a folder
|
// Hotloads new apps from a folder
|
||||||
func handleAppHotload(location string, forceUpdate bool) error {
|
func handleAppHotload(location string, forceUpdate bool) error {
|
||||||
|
|
||||||
basepath := "base"
|
basepath := "base"
|
||||||
fs, err := createFs(basepath, location)
|
fs, err := createFs(basepath, location)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@@ -6695,7 +6696,11 @@ func handleAppHotload(location string, forceUpdate bool) error {
|
|||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
||||||
cacheKey := fmt.Sprintf("workflowapps-sorted")
|
cacheKey := fmt.Sprintf("workflowapps-sorted-100")
|
||||||
|
requestCache.Delete(cacheKey)
|
||||||
|
cacheKey = fmt.Sprintf("workflowapps-sorted-500")
|
||||||
|
requestCache.Delete(cacheKey)
|
||||||
|
cacheKey = fmt.Sprintf("workflowapps-sorted")
|
||||||
requestCache.Delete(cacheKey)
|
requestCache.Delete(cacheKey)
|
||||||
|
|
||||||
return nil
|
return nil
|
||||||
|
|||||||
@@ -214,7 +214,7 @@ type WorkflowAppActionParameter struct {
|
|||||||
Description string `json:"description" datastore:"description,noindex" yaml:"description"`
|
Description string `json:"description" datastore:"description,noindex" yaml:"description"`
|
||||||
ID string `json:"id" datastore:"id" yaml:"id,omitempty"`
|
ID string `json:"id" datastore:"id" yaml:"id,omitempty"`
|
||||||
Name string `json:"name" datastore:"name" yaml:"name"`
|
Name string `json:"name" datastore:"name" yaml:"name"`
|
||||||
Example string `json:"example" datastore:"example" yaml:"example"`
|
Example string `json:"example" datastore:"example,noindex" yaml:"example"`
|
||||||
Value string `json:"value" datastore:"value,noindex" yaml:"value,omitempty"`
|
Value string `json:"value" datastore:"value,noindex" yaml:"value,omitempty"`
|
||||||
Multiline bool `json:"multiline" datastore:"multiline" yaml:"multiline"`
|
Multiline bool `json:"multiline" datastore:"multiline" yaml:"multiline"`
|
||||||
Options []string `json:"options" datastore:"options" yaml:"options"`
|
Options []string `json:"options" datastore:"options" yaml:"options"`
|
||||||
@@ -259,12 +259,12 @@ type WorkflowAppAction struct {
|
|||||||
} `json:"execution_variable" datastore:"execution_variables"`
|
} `json:"execution_variable" datastore:"execution_variables"`
|
||||||
Returns struct {
|
Returns struct {
|
||||||
Description string `json:"description" datastore:"returns" yaml:"description,omitempty"`
|
Description string `json:"description" datastore:"returns" yaml:"description,omitempty"`
|
||||||
Example string `json:"example" datastore:"example" yaml:"example"`
|
Example string `json:"example" datastore:"example,noindex" yaml:"example"`
|
||||||
ID string `json:"id" datastore:"id" yaml:"id,omitempty"`
|
ID string `json:"id" datastore:"id" yaml:"id,omitempty"`
|
||||||
Schema SchemaDefinition `json:"schema" datastore:"schema" yaml:"schema"`
|
Schema SchemaDefinition `json:"schema" datastore:"schema" yaml:"schema"`
|
||||||
} `json:"returns" datastore:"returns"`
|
} `json:"returns" datastore:"returns"`
|
||||||
AuthenticationId string `json:"authentication_id" datastore:"authentication_id"`
|
AuthenticationId string `json:"authentication_id" datastore:"authentication_id"`
|
||||||
Example string `json:"example" datastore:"example" yaml:"example"`
|
Example string `json:"example,noindex" datastore:"example" yaml:"example"`
|
||||||
AuthNotRequired bool `json:"auth_not_required" datastore:"auth_not_required" yaml:"auth_not_required"`
|
AuthNotRequired bool `json:"auth_not_required" datastore:"auth_not_required" yaml:"auth_not_required"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -327,7 +327,7 @@ type Action struct {
|
|||||||
} `json:"position,omitempty"`
|
} `json:"position,omitempty"`
|
||||||
Priority int `json:"priority,omitempty" datastore:"priority"`
|
Priority int `json:"priority,omitempty" datastore:"priority"`
|
||||||
AuthenticationId string `json:"authentication_id" datastore:"authentication_id"`
|
AuthenticationId string `json:"authentication_id" datastore:"authentication_id"`
|
||||||
Example string `json:"example,omitempty" datastore:"example"`
|
Example string `json:"example,omitempty" datastore:"example,noindex"`
|
||||||
AuthNotRequired bool `json:"auth_not_required,omitempty" datastore:"auth_not_required" yaml:"auth_not_required"`
|
AuthNotRequired bool `json:"auth_not_required,omitempty" datastore:"auth_not_required" yaml:"auth_not_required"`
|
||||||
Category string `json:"category" datastore:"category"`
|
Category string `json:"category" datastore:"category"`
|
||||||
}
|
}
|
||||||
@@ -461,7 +461,7 @@ type AuthenticationParams struct {
|
|||||||
Description string `json:"description" datastore:"description,noindex" yaml:"description"`
|
Description string `json:"description" datastore:"description,noindex" yaml:"description"`
|
||||||
ID string `json:"id" datastore:"id" yaml:"id"`
|
ID string `json:"id" datastore:"id" yaml:"id"`
|
||||||
Name string `json:"name" datastore:"name" yaml:"name"`
|
Name string `json:"name" datastore:"name" yaml:"name"`
|
||||||
Example string `json:"example" datastore:"example" yaml:"example"`
|
Example string `json:"example" datastore:"example,noindex" yaml:"example"`
|
||||||
Value string `json:"value,omitempty" datastore:"value,noindex" yaml:"value"`
|
Value string `json:"value,omitempty" datastore:"value,noindex" yaml:"value"`
|
||||||
Multiline bool `json:"multiline" datastore:"multiline" yaml:"multiline"`
|
Multiline bool `json:"multiline" datastore:"multiline" yaml:"multiline"`
|
||||||
Required bool `json:"required" datastore:"required" yaml:"required"`
|
Required bool `json:"required" datastore:"required" yaml:"required"`
|
||||||
@@ -6532,9 +6532,12 @@ func iterateAppGithubFolders(fs billy.Filesystem, dir []os.FileInfo, extra strin
|
|||||||
var err error
|
var err error
|
||||||
|
|
||||||
allapps := []WorkflowApp{}
|
allapps := []WorkflowApp{}
|
||||||
|
|
||||||
|
// These are slow apps to build with some funky mechanisms
|
||||||
reservedNames := []string{
|
reservedNames := []string{
|
||||||
"OWA",
|
"OWA",
|
||||||
"NLP",
|
"NLP",
|
||||||
|
"YARA",
|
||||||
}
|
}
|
||||||
|
|
||||||
buildLaterFirst := []buildLaterStruct{}
|
buildLaterFirst := []buildLaterStruct{}
|
||||||
|
|||||||
@@ -1238,6 +1238,7 @@ const AppCreator = (props) => {
|
|||||||
})
|
})
|
||||||
|
|
||||||
setActions(actions)
|
setActions(actions)
|
||||||
|
setActionAmount(actionAmount-1)
|
||||||
setUpdate(Math.random())
|
setUpdate(Math.random())
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1914,7 +1915,7 @@ const AppCreator = (props) => {
|
|||||||
{fileUploadEnabled ?
|
{fileUploadEnabled ?
|
||||||
<TextField
|
<TextField
|
||||||
required
|
required
|
||||||
style={{backgroundColor: inputColor, display: "inline-block",}}
|
style={{backgroundColor: inputColor, display: "inline-block", marginLeft: 10, maxWidth: 210, marginTop: 7, }}
|
||||||
placeholder={"file"}
|
placeholder={"file"}
|
||||||
margin="normal"
|
margin="normal"
|
||||||
variant="outlined"
|
variant="outlined"
|
||||||
|
|||||||
@@ -215,7 +215,7 @@ const Apps = (props) => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
runAppSearch("")
|
//runAppSearch("")
|
||||||
})
|
})
|
||||||
.catch(error => {
|
.catch(error => {
|
||||||
alert.error(error.toString())
|
alert.error(error.toString())
|
||||||
|
|||||||
Reference in New Issue
Block a user