Headless CMS and Content Managment Hub
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

78 lines
3.2 KiB

<sqx-title message="Rules"></sqx-title>
<sqx-panel desiredWidth="54rem" showSidebar="true">
<ng-container title>
Rules
</ng-container>
<ng-container menu>
<button type="button" class="btn btn-text-secondary mr-1" (click)="reload()" title="Refresh Rules (CTRL + SHIFT + R)">
<i class="icon-reset"></i> Refresh
</button>
<sqx-shortcut keys="ctrl+shift+r" (trigger)="reload()"></sqx-shortcut>
<ng-container *ngIf="rulesState.canCreate | async">
<sqx-shortcut keys="ctrl+shift+g" (trigger)="buttonNew.click()"></sqx-shortcut>
<button type="button" class="btn btn-success" #buttonNew (click)="createNew()" title="New Rule (CTRL + M)">
<i class="icon-plus"></i> New
</button>
</ng-container>
</ng-container>
<ng-container content>
<ng-container *ngIf="ruleActions && ruleTriggers && (rulesState.isLoaded | async) && (rulesState.rules | async); let rules">
<div class="table-items-row table-items-row-empty" *ngIf="rules.length === 0">
No rule created yet.
<button type="button" class="btn btn-success btn-sm ml-2" (click)="createNew()" *ngIf="rulesState.canCreate | async">
<i class="icon icon-plus"></i> Add Rule
</button>
</div>
<table class="table table-items table-fixed">
<sqx-rule *ngFor="let rule of rules; trackBy: trackByRule"
[rule]="rule"
[ruleActions]="ruleActions"
[ruleTriggers]="ruleTriggers"
(delete)="delete(rule)"
(editAction)="editAction(rule)"
(editTrigger)="editTrigger(rule)"
(toggle)="toggle(rule)">
</sqx-rule>
</table>
<ng-container *sqxModal="addRuleDialog">
<sqx-rule-wizard
[schemas]="schemasState.schemas | async"
[rule]="wizardRule"
[ruleActions]="ruleActions"
[ruleTriggers]="ruleTriggers"
[mode]="wizardMode"
(complete)="addRuleDialog.hide()">
</sqx-rule-wizard>
</ng-container>
</ng-container>
</ng-container>
<ng-container sidebar>
<div class="panel-nav">
<ng-container *ngIf="rulesState.canReadEvents | async">
<a class="panel-link panel-link-gray" routerLink="events" routerLinkActive="active" title="History" titlePosition="left">
<i class="icon-time"></i>
</a>
</ng-container>
<a class="panel-link" routerLink="help" routerLinkActive="active" title="Help" titlePosition="left" #helpLink>
<i class="icon-help2"></i>
</a>
<sqx-onboarding-tooltip helpId="help" [for]="helpLink" position="left-top" after="180000">
Click the help icon to show a context specific help page. Go to <a href="https://docs.squidex.io" sqxExternalLink>https://docs.squidex.io</a> for the full documentation.
</sqx-onboarding-tooltip>
</div>
</ng-container>
</sqx-panel>
<router-outlet></router-outlet>