diff --git a/src/Squidex.Store.MongoDb/Apps/MongoAppClientEntity.cs b/src/Squidex.Store.MongoDb/Apps/MongoAppClientEntity.cs index 32f3412aa..c482cf1ab 100644 --- a/src/Squidex.Store.MongoDb/Apps/MongoAppClientEntity.cs +++ b/src/Squidex.Store.MongoDb/Apps/MongoAppClientEntity.cs @@ -32,7 +32,7 @@ namespace Squidex.Store.MongoDb.Apps string IAppClientEntity.Name { - get { return Name ?? Id; } + get { return !string.IsNullOrWhiteSpace(Name) ? Name : Id; } } } } diff --git a/src/Squidex.Store.MongoDb/History/MessagesEN.cs b/src/Squidex.Store.MongoDb/History/MessagesEN.cs index 0e90aed42..54d8ffd02 100644 --- a/src/Squidex.Store.MongoDb/History/MessagesEN.cs +++ b/src/Squidex.Store.MongoDb/History/MessagesEN.cs @@ -35,7 +35,7 @@ namespace Squidex.Store.MongoDb.History }, { TypeNameRegistry.GetName(), - "renamed client {[Id]} to {[Name]}" + "named client {[Id]} as {[Name]}" }, { TypeNameRegistry.GetName(), diff --git a/src/Squidex/app/features/settings/pages/clients/client.component.html b/src/Squidex/app/features/settings/pages/clients/client.component.html index ffc4215b4..f5b8f9886 100644 --- a/src/Squidex/app/features/settings/pages/clients/client.component.html +++ b/src/Squidex/app/features/settings/pages/clients/client.component.html @@ -18,7 +18,7 @@ - + diff --git a/src/Squidex/app/features/settings/pages/clients/client.component.ts b/src/Squidex/app/features/settings/pages/clients/client.component.ts index bcdfdd4d0..eae009b45 100644 --- a/src/Squidex/app/features/settings/pages/clients/client.component.ts +++ b/src/Squidex/app/features/settings/pages/clients/client.component.ts @@ -6,7 +6,7 @@ */ import { Component, EventEmitter, Input, Output } from '@angular/core'; -import { FormBuilder, FormGroup } from '@angular/forms'; +import { FormBuilder, FormGroup, Validators } from '@angular/forms'; import { AccessTokenDto, @@ -61,7 +61,9 @@ export class ClientComponent { public renameForm: FormGroup = this.formBuilder.group({ - name: [''] + name: ['', + Validators.required + ] }); constructor( diff --git a/src/Squidex/app/shared/components/history.component.ts b/src/Squidex/app/shared/components/history.component.ts index 0176a54e5..18bb9a458 100644 --- a/src/Squidex/app/shared/components/history.component.ts +++ b/src/Squidex/app/shared/components/history.component.ts @@ -82,7 +82,7 @@ export class HistoryComponent extends AppComponentBase implements OnDestroy, OnI } }); - message = message.replace(/{([^\s:]*)}/, (match: string, marker: string) => { + message = message.replace(/{([^}]*)}/g, (match: string, marker: string) => { return `${marker}`; });