NO-JIRA replace templateFn with htmlTemplate
This commit is contained in:
parent
4974f2a9f0
commit
ab1d7a218e
|
@ -34,6 +34,9 @@ var Artemis;
|
|||
items="$ctrl.addresses">
|
||||
</pf-table-view>
|
||||
<div ng-include="'plugin/artemispagination.html'"></div>
|
||||
<script type="text/ng-template" id="addresses-anchor-column-template">
|
||||
<a href="#" ng-click="$ctrl.handleColAction(key, item)">{{value}}</a>
|
||||
</script>
|
||||
<script type="text/ng-template" id="addresses-instructions.html">
|
||||
<div>
|
||||
<p>
|
||||
|
@ -57,7 +60,7 @@ var Artemis;
|
|||
.name;
|
||||
|
||||
|
||||
function AddressesController($scope, workspace, jolokia, localStorage, artemisMessage, $location, $timeout, $filter, $sanitize, pagination, artemisAddress) {
|
||||
function AddressesController($scope, workspace, jolokia, localStorage, artemisMessage, $location, $timeout, $filter, pagination, artemisAddress) {
|
||||
var ctrl = this;
|
||||
ctrl.pagination = pagination;
|
||||
ctrl.pagination.reset();
|
||||
|
@ -149,7 +152,7 @@ var Artemis;
|
|||
{ header: 'ID', itemField: 'id' },
|
||||
{ header: 'Name', itemField: 'name' },
|
||||
{ header: 'Routing Types', itemField: 'routingTypes' },
|
||||
{ header: 'Queue Count', itemField: 'queueCount' , templateFn: function(value, item) { return '<a href="#" onclick="selectQueues(' + item.idx + ')">' + $sanitize(value) + '</a>' }}
|
||||
{ header: 'Queue Count', itemField: 'queueCount' , htmlTemplate: 'addresses-anchor-column-template', colActionFn: (item) => selectQueues(item.idx) }
|
||||
];
|
||||
|
||||
ctrl.refresh = function () {
|
||||
|
@ -247,7 +250,7 @@ var Artemis;
|
|||
|
||||
ctrl.pagination.load();
|
||||
}
|
||||
AddressesController.$inject = ['$scope', 'workspace', 'jolokia', 'localStorage', 'artemisMessage', '$location', '$timeout', '$filter', '$sanitize', 'pagination', 'artemisAddress'];
|
||||
AddressesController.$inject = ['$scope', 'workspace', 'jolokia', 'localStorage', 'artemisMessage', '$location', '$timeout', '$filter', 'pagination', 'artemisAddress'];
|
||||
|
||||
|
||||
})(Artemis || (Artemis = {}));
|
|
@ -46,7 +46,10 @@ var Artemis;
|
|||
<p>Are you sure you want to continue.</p>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/ng-template" id="connections-anchor-column-template">
|
||||
<a href="#" ng-click="$ctrl.handleColAction(key, item)">{{value}}</a>
|
||||
</script>
|
||||
<script type="text/ng-template" id="connections-instructions.html">
|
||||
<div>
|
||||
<p>
|
||||
|
@ -69,7 +72,7 @@ var Artemis;
|
|||
.name;
|
||||
|
||||
|
||||
function ConnectionsController($scope, workspace, jolokia, localStorage, artemisMessage, $location, $timeout, $filter, $sanitize, pagination, artemisConnection, artemisSession) {
|
||||
function ConnectionsController($scope, workspace, jolokia, localStorage, artemisMessage, $location, $timeout, $filter, pagination, artemisConnection, artemisSession) {
|
||||
var ctrl = this;
|
||||
ctrl.pagination = pagination;
|
||||
ctrl.pagination.reset();
|
||||
|
@ -170,7 +173,8 @@ var Artemis;
|
|||
{ header: 'Client ID', itemField: 'clientID' },
|
||||
{ header: 'Users', itemField: 'users' },
|
||||
{ header: 'protocol', itemField: 'protocol' },
|
||||
{ header: 'Session Count', itemField: 'sessionCount', templateFn: function(value, item) { return '<a href="#" onclick="selectSessions(' + item.idx + ')">' + $sanitize(value) + '</a>' }},
|
||||
{ header: 'Session Count', itemField: 'sessionCount', htmlTemplate: 'connections-anchor-column-template', colActionFn: (item) => selectSessions(item.idx) },
|
||||
|
||||
{ header: 'Remote Address', itemField: 'remoteAddress' },
|
||||
{ header: 'Local Address', itemField: 'localAddress' },
|
||||
{ header: 'Creation Time', itemField: 'creationTime' }
|
||||
|
@ -270,7 +274,7 @@ var Artemis;
|
|||
|
||||
ctrl.pagination.load();
|
||||
}
|
||||
ConnectionsController.$inject = ['$scope', 'workspace', 'jolokia', 'localStorage', 'artemisMessage', '$location', '$timeout', '$filter', '$sanitize', 'pagination', 'artemisConnection', 'artemisSession'];
|
||||
ConnectionsController.$inject = ['$scope', 'workspace', 'jolokia', 'localStorage', 'artemisMessage', '$location', '$timeout', '$filter', 'pagination', 'artemisConnection', 'artemisSession'];
|
||||
|
||||
|
||||
})(Artemis || (Artemis = {}));
|
|
@ -45,6 +45,9 @@ var Artemis;
|
|||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/ng-template" id="consumers-anchor-column-template">
|
||||
<a href="#" ng-click="$ctrl.handleColAction(key, item)">{{value}}</a>
|
||||
</script>
|
||||
<script type="text/ng-template" id="consumers-instructions.html">
|
||||
<div>
|
||||
<p>
|
||||
|
@ -67,7 +70,7 @@ var Artemis;
|
|||
.name;
|
||||
|
||||
|
||||
function ConsumersController($scope, workspace, jolokia, localStorage, artemisMessage, $location, $timeout, $filter, $sanitize, pagination, artemisConsumer, artemisQueue, artemisAddress, artemisSession) {
|
||||
function ConsumersController($scope, workspace, jolokia, localStorage, artemisMessage, $location, $timeout, $filter, pagination, artemisConsumer, artemisQueue, artemisAddress, artemisSession) {
|
||||
var ctrl = this;
|
||||
ctrl.pagination = pagination;
|
||||
ctrl.pagination.reset();
|
||||
|
@ -168,14 +171,14 @@ var Artemis;
|
|||
};
|
||||
ctrl.tableColumns = [
|
||||
{ header: 'ID', itemField: 'id' },
|
||||
{ header: 'Session', itemField: 'session' , templateFn: function(value, item) { return '<a href="#" onclick="selectSession(' + item.idx + ')">' + $sanitize(value) + '</a>' }},
|
||||
{ header: 'Session', itemField: 'session' , htmlTemplate: 'consumers-anchor-column-template', colActionFn: (item) => selectSession(item.idx) },
|
||||
{ header: 'Client ID', itemField: 'clientID' },
|
||||
{ header: 'Validated User', itemField: 'validatedUser' },
|
||||
{ header: 'Protocol', itemField: 'protocol' },
|
||||
{ header: 'Queue', itemField: 'queue', templateFn: function(value, item) { return '<a href="#" onclick="selectQueue(' + item.idx + ')">' + $sanitize(value) + '</a>' }},
|
||||
{ header: 'Queue', itemField: 'queueName', htmlTemplate: 'consumers-anchor-column-template', colActionFn: (item) => selectQueue(item.idx) },
|
||||
{ header: 'Queue Type', itemField: 'queueType' },
|
||||
{ header: 'Filter', itemField: 'filter' },
|
||||
{ header: 'Address', itemField: 'address' , templateFn: function(value, item) { return '<a href="#" onclick="selectAddress(' + item.idx + ')">' + $sanitize(value) + '</a>' }},
|
||||
{ header: 'Address', itemField: 'addressName' , htmlTemplate: 'consumers-anchor-column-template', colActionFn: (item) => selectAddress(item.idx) },
|
||||
{ header: 'Remote Address', itemField: 'remoteAddress' },
|
||||
{ header: 'Local Address', itemField: 'localAddress' },
|
||||
{ header: 'Creation Time', itemField: 'creationTime' }
|
||||
|
@ -288,6 +291,8 @@ var Artemis;
|
|||
ctrl.consumers = [];
|
||||
angular.forEach(data["data"], function (value, idx) {
|
||||
value.idx = idx;
|
||||
value.addressName = value.address;
|
||||
value.queueName = value.queue;
|
||||
ctrl.consumers.push(value);
|
||||
});
|
||||
ctrl.pagination.page(data["count"]);
|
||||
|
@ -298,7 +303,7 @@ var Artemis;
|
|||
|
||||
ctrl.pagination.load();
|
||||
}
|
||||
ConsumersController.$inject = ['$scope', 'workspace', 'jolokia', 'localStorage', 'artemisMessage', '$location', '$timeout', '$filter', '$sanitize', 'pagination', 'artemisConsumer', 'artemisQueue', 'artemisAddress', 'artemisSession'];
|
||||
ConsumersController.$inject = ['$scope', 'workspace', 'jolokia', 'localStorage', 'artemisMessage', '$location', '$timeout', '$filter', 'pagination', 'artemisConsumer', 'artemisQueue', 'artemisAddress', 'artemisSession'];
|
||||
|
||||
|
||||
})(Artemis || (Artemis = {}));
|
|
@ -33,6 +33,9 @@ var Artemis;
|
|||
items="$ctrl.producers">
|
||||
</pf-table-view>
|
||||
<div ng-include="'plugin/artemispagination.html'"></div>
|
||||
<script type="text/ng-template" id="producers-anchor-column-template">
|
||||
<a href="#" ng-click="$ctrl.handleColAction(key, item)">{{value}}</a>
|
||||
</script>
|
||||
<script type="text/ng-template" id="producers-instructions.html">
|
||||
<div>
|
||||
<p>
|
||||
|
@ -54,7 +57,7 @@ var Artemis;
|
|||
.name;
|
||||
|
||||
|
||||
function ProducersController($scope, workspace, jolokia, localStorage, artemisMessage, $location, $timeout, $filter, $sanitize, pagination, artemisProducer, artemisAddress, artemisSession) {
|
||||
function ProducersController($scope, workspace, jolokia, localStorage, artemisMessage, $location, $timeout, $filter, pagination, artemisProducer, artemisAddress, artemisSession) {
|
||||
var ctrl = this;
|
||||
ctrl.pagination = pagination;
|
||||
ctrl.pagination.reset();
|
||||
|
@ -137,12 +140,12 @@ var Artemis;
|
|||
};
|
||||
ctrl.tableColumns = [
|
||||
{ header: 'ID', itemField: 'id' },
|
||||
{ header: 'Session', itemField: 'session' , templateFn: function(value, item) { return '<a href="#" onclick="selectSession(' + item.idx + ')">' + $sanitize(value) + '</a>' }},
|
||||
{ header: 'Session', itemField: 'session' , htmlTemplate: 'producers-anchor-column-template', colActionFn: (item) => selectSession(item.idx) },
|
||||
{ header: 'Client ID', itemField: 'clientID' },
|
||||
{ header: 'Protocol', itemField: 'protocol' },
|
||||
{ header: 'User', itemField: 'user' },
|
||||
{ header: 'Validated User', name: 'validatedUser'},
|
||||
{ header: 'Address', itemField: 'address', templateFn: function(value, item) { return '<a href="#" onclick="selectAddress(' + item.idx + ')">' + $sanitize(value) + '</a>' }},
|
||||
{ header: 'Address', itemField: 'addressName' , htmlTemplate: 'producers-anchor-column-template', colActionFn: (item) => selectAddress(item.idx) },
|
||||
{ header: 'Remote Address', itemField: 'remoteAddress' },
|
||||
{ header: 'Local Address', itemField: 'localAddress' }
|
||||
];
|
||||
|
@ -219,6 +222,7 @@ var Artemis;
|
|||
ctrl.producers = [];
|
||||
angular.forEach(data["data"], function (value, idx) {
|
||||
value.idx = idx;
|
||||
value.addressName = value.address;
|
||||
ctrl.producers.push(value);
|
||||
});
|
||||
ctrl.pagination.page(data["count"]);
|
||||
|
@ -229,7 +233,7 @@ var Artemis;
|
|||
|
||||
ctrl.pagination.load();
|
||||
}
|
||||
ProducersController.$inject = ['$scope', 'workspace', 'jolokia', 'localStorage', 'artemisMessage', '$location', '$timeout', '$filter', '$sanitize', 'pagination', 'artemisProducer', 'artemisAddress', 'artemisSession'];
|
||||
ProducersController.$inject = ['$scope', 'workspace', 'jolokia', 'localStorage', 'artemisMessage', '$location', '$timeout', '$filter', 'pagination', 'artemisProducer', 'artemisAddress', 'artemisSession'];
|
||||
|
||||
|
||||
})(Artemis || (Artemis = {}));
|
|
@ -34,6 +34,9 @@ var Artemis;
|
|||
items="$ctrl.queues">
|
||||
</pf-table-view>
|
||||
<div ng-include="'plugin/artemispagination.html'"></div>
|
||||
<script type="text/ng-template" id="queues-anchor-column-template">
|
||||
<a href="#" ng-click="$ctrl.handleColAction(key, item)">{{value}}</a>
|
||||
</script>
|
||||
<script type="text/ng-template" id="queues-instructions.html">
|
||||
<div>
|
||||
<p>
|
||||
|
@ -57,7 +60,7 @@ var Artemis;
|
|||
.name;
|
||||
|
||||
|
||||
function QueuesController($scope, workspace, jolokia, localStorage, artemisMessage, $location, $timeout, $filter, $sanitize, pagination, artemisQueue, artemisAddress) {
|
||||
function QueuesController($scope, workspace, jolokia, localStorage, artemisMessage, $location, $timeout, $filter, pagination, artemisQueue, artemisAddress) {
|
||||
var ctrl = this;
|
||||
ctrl.pagination = pagination;
|
||||
ctrl.pagination.reset();
|
||||
|
@ -183,23 +186,15 @@ var Artemis;
|
|||
};
|
||||
ctrl.tableColumns = [
|
||||
{ header: 'ID', itemField: 'id' },
|
||||
{ header: 'Name', itemField: 'name',
|
||||
templateFn: function(value, item) { return '<a href="#" onclick="selectQueue(' + item.idx + ')">' + $sanitize(value) + '</a>' }
|
||||
},
|
||||
{ header: 'Address', itemField: 'address',
|
||||
templateFn: function(value, item) { return '<a href="#" onclick="selectAddress(' + item.idx + ')">' + $sanitize(value) + '</a>' }
|
||||
},
|
||||
{ header: 'Name', itemField: 'name', htmlTemplate: 'queues-anchor-column-template', colActionFn: (item) => selectQueue(item.idx) },
|
||||
{ header: 'Address', itemField: 'address', htmlTemplate: 'queues-anchor-column-template', colActionFn: (item) => selectAddress(item.idx) },
|
||||
{ header: 'Routing Type', itemField: 'routingType'},
|
||||
{ header: 'Filter', itemField: 'filter' },
|
||||
{ header: 'Durable', itemField: 'durable' },
|
||||
{ header: 'Max Consumers', itemField: 'maxConsumers' },
|
||||
{ header: 'Purge On No Consumers', itemField: 'purgeOnNoConsumers' },
|
||||
{ header: 'Consumer Count', itemField: 'consumerCount' ,
|
||||
templateFn: function(value, item) { return '<a href="#" onclick="selectConsumers(' + item.idx + ')">' + $sanitize(value) + '</a>' }
|
||||
},
|
||||
{ header: 'Message Count', itemField: 'messageCount',
|
||||
templateFn: function(value, item) { return '<a href="#" onclick="browseQueue(' + item.idx + ')" title="Browse Messages">' + value + '</a>' }
|
||||
},
|
||||
{ header: 'Consumer Count', itemField: 'consumerCount', htmlTemplate: 'queues-anchor-column-template', colActionFn: (item) => selectConsumers(item.idx) },
|
||||
{ header: 'Message Count', itemField: 'messageCount', htmlTemplate: 'queues-anchor-column-template', colActionFn: (item) => browseQueue(item.idx) },
|
||||
{ header: 'Paused', itemField: 'paused' },
|
||||
{ header: 'Temporary', itemField: 'temporary' },
|
||||
{ header: 'Auto Created', itemField: 'autoCreated' },
|
||||
|
@ -353,7 +348,7 @@ var Artemis;
|
|||
|
||||
ctrl.pagination.load();
|
||||
}
|
||||
QueuesController.$inject = ['$scope', 'workspace', 'jolokia', 'localStorage', 'artemisMessage', '$location', '$timeout', '$filter', '$sanitize', 'pagination', 'artemisQueue', 'artemisAddress'];
|
||||
QueuesController.$inject = ['$scope', 'workspace', 'jolokia', 'localStorage', 'artemisMessage', '$location', '$timeout', '$filter', 'pagination', 'artemisQueue', 'artemisAddress'];
|
||||
|
||||
|
||||
})(Artemis || (Artemis = {}));
|
|
@ -46,6 +46,9 @@ var Artemis;
|
|||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/ng-template" id="sessions-anchor-column-template">
|
||||
<a href="#" ng-click="$ctrl.handleColAction(key, item)">{{value}}</a>
|
||||
</script>
|
||||
<script type="text/ng-template" id="sessions-instructions.html">
|
||||
<div>
|
||||
<p>
|
||||
|
@ -68,7 +71,7 @@ var Artemis;
|
|||
.name;
|
||||
|
||||
|
||||
function SessionsController($scope, workspace, jolokia, localStorage, artemisMessage, $location, $timeout, $filter, $sanitize, pagination, artemisConnection, artemisSession, artemisConsumer, artemisProducer) {
|
||||
function SessionsController($scope, workspace, jolokia, localStorage, artemisMessage, $location, $timeout, $filter, pagination, artemisConnection, artemisSession, artemisConsumer, artemisProducer) {
|
||||
var ctrl = this;
|
||||
ctrl.pagination = pagination;
|
||||
ctrl.pagination.reset();
|
||||
|
@ -162,11 +165,11 @@ var Artemis;
|
|||
};
|
||||
ctrl.tableColumns = [
|
||||
{ header: 'ID', itemField: 'id' },
|
||||
{ header: 'Connection', itemField: 'connectionID', templateFn: function(value, item) { return '<a href="#" onclick="selectConnection(' + item.idx + ')">' + $sanitize(value) + '</a>' }},
|
||||
{ header: 'Connection', itemField: 'connectionID', htmlTemplate: 'sessions-anchor-column-template', colActionFn: (item) => selectConnection(item.idx) },
|
||||
{ header: 'User', itemField: 'user' },
|
||||
{ header: 'Validated User', itemField: 'validatedUser' },
|
||||
{ header: 'Consumer Count', itemField: 'consumerCount', templateFn: function(value, item) { return '<a href="#" onclick="selectConsumers(' + item.idx + ')">' + $sanitize(value) + '</a>' }},
|
||||
{ header: 'Producer Count', itemField: 'producerCount', templateFn: function(value, item) { return '<a href="#" onclick="selectProducers(' + item.idx + ')">' + $sanitize(value) + '</a>' }},
|
||||
{ header: 'Consumer Count', itemField: 'consumerCount', htmlTemplate: 'sessions-anchor-column-template', colActionFn: (item) => selectConsumers(item.idx) },
|
||||
{ header: 'Producer Count', itemField: 'producerCount', htmlTemplate: 'sessions-anchor-column-template', colActionFn: (item) => selectProducers(item.idx) },
|
||||
{ header: 'Creation Time', itemField: 'creationTime' }
|
||||
];
|
||||
|
||||
|
@ -287,7 +290,7 @@ var Artemis;
|
|||
|
||||
ctrl.pagination.load();
|
||||
}
|
||||
SessionsController.$inject = ['$scope', 'workspace', 'jolokia', 'localStorage', 'artemisMessage', '$location', '$timeout', '$filter', '$sanitize', 'pagination', 'artemisConnection', 'artemisSession', 'artemisConsumer', 'artemisProducer'];
|
||||
SessionsController.$inject = ['$scope', 'workspace', 'jolokia', 'localStorage', 'artemisMessage', '$location', '$timeout', '$filter', 'pagination', 'artemisConnection', 'artemisSession', 'artemisConsumer', 'artemisProducer'];
|
||||
|
||||
|
||||
})(Artemis || (Artemis = {}));
|
Loading…
Reference in New Issue