refactor(weknoracloud): update credential handling and configuration
- Replaced references to Docreader credentials with WeKnoraCloud credentials across multiple services and handlers. - Introduced a new CredentialsConfig structure to manage third-party provider credentials, specifically for WeKnoraCloud. - Updated database schema to include a credentials column for storing WeKnoraCloud AppID and AppSecret. - Enhanced methods for retrieving and utilizing WeKnoraCloud credentials, ensuring proper encryption and decryption during storage and retrieval. This update improves the management of WeKnoraCloud credentials, streamlining the integration and enhancing security measures.
This commit is contained in:
@@ -89,7 +89,7 @@ func (e *weKnoraCloudEngine) FileTypes(_ bool) []string {
|
||||
return []string{"docx", "doc", "pdf", "md", "markdown", "xlsx", "xls", "pptx", "ppt"}
|
||||
}
|
||||
func (e *weKnoraCloudEngine) CheckAvailable(docreaderConnected bool, overrides map[string]string) (bool, string) {
|
||||
if overrides["docreader_app_id"] != "" {
|
||||
if overrides["weknoracloud_app_id"] != "" {
|
||||
return true, ""
|
||||
}
|
||||
return false, "WeKnora Cloud credentials not configured. Go to Settings → WeKnora Cloud to set up."
|
||||
|
||||
Reference in New Issue
Block a user