mirror of
https://github.com/IT4Change/gradido.git
synced 2025-12-13 07:45:54 +00:00
Merge pull request #968 from gradido/community-production
refactor: In Production only Show one Community
This commit is contained in:
commit
e58c5726cb
@ -11,6 +11,7 @@ const server = {
|
||||
LOGIN_API_URL: process.env.LOGIN_API_URL || 'http://login-server:1201/',
|
||||
COMMUNITY_API_URL: process.env.COMMUNITY_API_URL || 'http://nginx/api/',
|
||||
GDT_API_URL: process.env.GDT_API_URL || 'https://gdt.gradido.net',
|
||||
PRODUCTION: process.env.NODE_ENV === 'production' || false,
|
||||
}
|
||||
|
||||
const database = {
|
||||
|
||||
@ -19,9 +19,17 @@ export class CommunityResolver {
|
||||
|
||||
@Query(() => [Community])
|
||||
async communities(): Promise<Community[]> {
|
||||
const communities: Community[] = []
|
||||
|
||||
communities.push(
|
||||
if (CONFIG.PRODUCTION)
|
||||
return [
|
||||
new Community({
|
||||
id: 3,
|
||||
name: 'Gradido-Akademie',
|
||||
description: 'Freies Institut für Wirtschaftsbionik.',
|
||||
url: 'https://gradido.net',
|
||||
registerUrl: 'https://gdd1.gradido.com/vue/register-community',
|
||||
}),
|
||||
]
|
||||
return [
|
||||
new Community({
|
||||
id: 1,
|
||||
name: 'Gradido Entwicklung',
|
||||
@ -43,7 +51,6 @@ export class CommunityResolver {
|
||||
url: 'https://gradido.net',
|
||||
registerUrl: 'https://gdd1.gradido.com/vue/register-community',
|
||||
}),
|
||||
)
|
||||
return communities
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user