aboutsummaryrefslogtreecommitdiffstats
path: root/catalog-ui/src/app/ng2/components/logic/service-dependencies/service-dependencies.component.html
blob: d71a4fbecb3d9f30b597bdd6b67cb328f4c4e9c7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<div class="service-dependencies">
    <loader [display]="isLoading" [size]="'medium'" [relative]="true"></loader>
    <div class="checkbox-label-mark-as-dependent">
            <checkbox
                    class="checkbox-label"
                    data-tests-id="checkbox-mark-as-dependent"
                    [label]="'Mark as Dependent'"
                    (checkedChange)="onMarkAsDependent()"
                    [(checked)]="isDependent"
                    [disabled]="readonly">
            </checkbox>
    </div>
    <div class="i-sdc-designer-sidebar-section-content-item-rules-section" *ngIf="isDependent">

        <div class="i-sdc-designer-sidebar-section-content-item-rule" [ngClass]="{'hand': !readonly}"
             *ngFor="let rule of rulesList; let i = index">
            <div class="rule-details" [ngClass]="{'readonly': readonly}">
                <div class="rule-desc" (click)="!readonly && onSelectRule(i)" tooltips tooltip="{{rule.servicePropertyName + ' ' + getSymbol(rule.constraintOperator) + ' ' + (rule.sourceName ? rule.sourceName + ':' : '') + rule.value}}">
                    {{rule.servicePropertyName + ' ' + getSymbol(rule.constraintOperator) + ' ' + (rule.sourceName ? rule.sourceName + ':' : '') + rule.value}}
                </div>
                <span *ngIf="!readonly" class="sprite-new delete-btn delete-icon" (click)="openDeleteModal(i)" data-tests-id="delete-input-button"></span>
            </div>
        </div>

        <div class="w-sdc-designer-sidebar-section-footer" >
            <button
                    class="w-sdc-designer-sidebar-section-footer-action add-rule-btn tlv-btn blue"
                    data-tests-id="add-rule-button"
                    (click)="onAddRule()"
                    [disabled]="readonly">
                {{'SERVICE_DEPENDENCY_ADD_RULE' | translate}}
            </button>
        </div>
    </div>
</div>