mirror of
https://github.com/nextcloud/server.git
synced 2026-04-29 10:03:32 -04:00
fix(settings): Don't show built-in textprocessing task types in textprocessing settings
TaskProcessing is transparent to textprocessing providers and TextProcessing can use Taskprocessing providers so these are unnecessary Signed-off-by: Marcel Klehr <mklehr@gmx.net> Signed-off-by: Julien Veyssier <julien-nc@posteo.net>
This commit is contained in:
parent
b06302e024
commit
a2b087421e
1 changed files with 9 additions and 1 deletions
|
|
@ -148,7 +148,15 @@ export default {
|
|||
return Object.keys(this.settings['ai.textprocessing_provider_preferences']).length > 0 && Array.isArray(this.textProcessingTaskTypes)
|
||||
},
|
||||
tpTaskTypes() {
|
||||
return Object.keys(this.settings['ai.textprocessing_provider_preferences']).filter(type => !!this.getTextProcessingTaskType(type))
|
||||
const builtinTextProcessingTypes = [
|
||||
'\\OCP\\TextProcessing\\FreePromptTaskType',
|
||||
'\\OCP\\TextProcessing\\HeadlineTaskType',
|
||||
'\\OCP\\TextProcessing\\SummaryTaskType',
|
||||
'\\OCP\\TextProcessing\\TopicsTaskType',
|
||||
]
|
||||
return Object.keys(this.settings['ai.textprocessing_provider_preferences'])
|
||||
.filter(type => !!this.getTextProcessingTaskType(type))
|
||||
.filter(type => !builtinTextProcessingTypes.includes(type))
|
||||
},
|
||||
hasText2ImageProviders() {
|
||||
return this.text2imageProviders.length > 0
|
||||
|
|
|
|||
Loading…
Reference in a new issue