Browse Source

Notification when field updated.

pull/381/head
Sebastian Stehle 7 years ago
parent
commit
b6847bbda8
  1. 2
      src/Squidex/app/features/rules/pages/events/rule-events-page.component.html
  2. 4
      src/Squidex/app/features/schemas/pages/schema/field.component.ts
  3. 2
      src/Squidex/app/framework/angular/forms/tag-editor.component.html

2
src/Squidex/app/features/rules/pages/events/rule-events-page.component.html

@ -70,7 +70,7 @@
Next: <ng-container *ngIf="event.nextAttempt">{{event.nextAttempt | sqxFromNow}}</ng-container>
</div>
<div class="col-3 text-right">
<button type="button" class="btn btn-danger btn-sm mr-1" (click)="cancel(event)" [class.hidden]="!event.nextAttempt">
<button type="button" class="btn btn-outline-danger btn-sm mr-1" (click)="cancel(event)" [class.hidden]="!event.nextAttempt">
Cancel
</button>

4
src/Squidex/app/features/schemas/pages/schema/field.component.ts

@ -11,6 +11,7 @@ import { FormBuilder } from '@angular/forms';
import {
createProperties,
DialogModel,
DialogService,
EditFieldForm,
fadeAnimation,
ImmutableArray,
@ -53,6 +54,7 @@ export class FieldComponent implements OnChanges {
public addFieldDialog = new DialogModel();
constructor(
private readonly dialogs: DialogService,
private readonly formBuilder: FormBuilder,
private readonly schemasState: SchemasState
) {
@ -115,6 +117,8 @@ export class FieldComponent implements OnChanges {
this.schemasState.updateField(this.schema, this.field, { properties })
.subscribe(() => {
this.editForm.submitCompleted();
this.dialogs.notifyInfo('Field saved successfully.');
}, error => {
this.editForm.submitFailed(error);
});

2
src/Squidex/app/framework/angular/forms/tag-editor.component.html

@ -3,7 +3,7 @@
[class.focus]="snapshot.hasFocus"
[class.disabled]="addInput.disabled">
<span class="item" *ngFor="let item of snapshot.items; let i = index" [class.disabled]="addInput.disabled">
{{item}} <i class="icon-close" *ngIf="!addInput.disabled" (click)="remove(i)"></i>
{{item}} <i class="icon-close" (click)="remove(i)"></i>
</span>
<input type="text" class="blank" #input

Loading…
Cancel
Save