RSS Git Download  Clone
Raw Blame History 4kB 104 lines
HTML rendered
<!--
<md-toolbar>
    <span class="md-toolbar-tools">
        <span class="p3xr-typography-ellipsis" title="{{$root.p3xr.ui.htmlEncode($ctrl.$stateParams.key)}}">{{ $ctrl.$stateParams.key }}</span>
        <span flex></span>
    </span>
</md-toolbar>
-->

<md-list flex md-theme="{{ $root.p3xr.state.theme}}">

    <md-list-item>
        <md-button class="md-button md-raised md-primary" ng-click="$ctrl.refresh()">
            <md-icon>refresh</md-icon>
            {{ $root.p3xr.strings.intention.reloadKey }}
        </md-button>

        <md-button class="md-button md-raised md-warn" ng-click="$ctrl.delete()">
            <md-icon>delete</md-icon>
            {{ $root.p3xr.strings.intention.delete }}
        </md-button>

        <md-button class="md-button md-raised md-accent" ng-click="$ctrl.rename({ $event: $event})">
            <md-icon>fingerprint</md-icon>
            {{ $root.p3xr.strings.intention.rename }}
        </md-button>

        <md-button class="md-button md-raised md-accent" ng-click="$ctrl.setTtl({ $event: $event})">
            <md-tooltip>{{ $root.p3xr.strings.label.ttlTitle  }}</md-tooltip>
            <md-icon>timer</md-icon>
            {{ $root.p3xr.strings.intention.ttl }}
        </md-button>
    </md-list-item>

    <md-divider></md-divider>

    <md-list-item>
        <p>{{ $root.p3xr.strings.page.key.label.key }}:&nbsp;</p>
        <span class="p3xr-typography-ellipsis" title="{{ $root.p3xr.ui.htmlEncode($ctrl.$stateParams.key) }}">{{ $ctrl.$stateParams.key }}</span>
    </md-list-item>

    <md-divider></md-divider>

    <md-list-item>
        <p>{{ $root.p3xr.strings.page.key.label.type }}:</p>
        {{ $root.p3xr.state.keysInfo[$ctrl.$stateParams.key].type }}
    </md-list-item>

    <md-divider></md-divider>

    <md-list-item>
        <p>{{ $root.p3xr.strings.page.key.label.encoding }}:</p>
        {{ $ctrl.response.encoding }}
    </md-list-item>

    <md-divider></md-divider>

    <md-list-item>
        <p>{{ $root.p3xr.strings.page.key.label.length }}:</p>
            <span ng-if="$root.p3xr.state.keysInfo[$ctrl.$stateParams.key].type === 'string'" style="opacity: 0.5">
                {{ $ctrl.charactersPrettyBytes($root.p3xr.state.keysInfo[$ctrl.$stateParams.key].length) }}
            &nbsp;
        </span>
        {{ $root.p3xr.state.keysInfo[$ctrl.$stateParams.key].length }}
        &nbsp;
        <span ng-if="$root.p3xr.state.keysInfo[$ctrl.$stateParams.key].type === 'string'">
                {{ $root.p3xr.strings.page.key.label.lengthString }}
        </span>
        <span ng-if="$root.p3xr.state.keysInfo[$ctrl.$stateParams.key].type !== 'string'">
            {{ $root.p3xr.strings.page.key.label.lengthItem }}
        </span>
    </md-list-item>

    <md-divider></md-divider>

    <md-list-item>
        <p title="{{ $root.p3xr.strings.page.key.label.ttlTitle  }}"><span class="p3xr-main-key-label-key-title">{{ $root.p3xr.strings.page.key.label.ttl }}</span>:</p>
        <span ng-if="$ctrl.response.ttl == -1">
            {{ $root.p3xr.strings.page.key.label.ttlNotExpire }}
        </span>
        <span ng-if="$ctrl.response.ttl != -1">
            <span style="opacity: 0.5">
                ({{ $ctrl.ttlParsed }})
            </span>
            {{ $ctrl.response.ttl }}
        </span>
    </md-list-item>


</md-list>


<md-divider></md-divider>


<span ng-switch="" on="$root.p3xr.state.keysInfo[$ctrl.$stateParams.key].type">
    <p3xr-main-key-string ng-switch-when="string" p3xr-value="$ctrl.response.value" p3xr-key="$ctrl.$stateParams.key"></p3xr-main-key-string>
    <p3xr-main-key-list ng-switch-when="list" p3xr-value="$ctrl.response.value" p3xr-key="$ctrl.$stateParams.key"></p3xr-main-key-list>
    <p3xr-main-key-hash ng-switch-when="hash" p3xr-value="$ctrl.response.value" p3xr-key="$ctrl.$stateParams.key"></p3xr-main-key-hash>
    <p3xr-main-key-set ng-switch-when="set" p3xr-value="$ctrl.response.value" p3xr-key="$ctrl.$stateParams.key"></p3xr-main-key-set>
    <p3xr-main-key-zset ng-switch-when="zset" p3xr-value="$ctrl.response.value" p3xr-key="$ctrl.$stateParams.key" p3xr-sorted-core="$ctrl.response.sortedScores"></p3xr-main-key-zset>
    </span>
 </span>