Skip to content

Commit 121f778

Browse files
committed
Toggle running when watching openrpa instances
1 parent f4a7a58 commit 121f778

5 files changed

Lines changed: 18 additions & 3 deletions

File tree

OpenFlow/src/public/Controllers.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2880,6 +2880,7 @@ export class FilesCtrl extends entitiesCtrl<Base> {
28802880
}
28812881
export class EntitiesCtrl extends entitiesCtrl<Base> {
28822882
public collections: any;
2883+
public showrunning: boolean = false;
28832884
constructor(
28842885
public $rootScope: ng.IRootScopeService,
28852886
public $scope: ng.IScope,
@@ -2904,6 +2905,7 @@ export class EntitiesCtrl extends entitiesCtrl<Base> {
29042905
this.orderby = this.userdata.data.EntitiesCtrl.orderby;
29052906
this.searchstring = this.userdata.data.EntitiesCtrl.searchstring;
29062907
this.basequeryas = this.userdata.data.EntitiesCtrl.basequeryas;
2908+
this.showrunning = this.userdata.data.EntitiesCtrl.showrunning;
29072909
} else {
29082910
if (NoderedUtil.IsNullEmpty(this.collection)) {
29092911
this.$location.path("/Entities/entities");
@@ -2922,6 +2924,13 @@ export class EntitiesCtrl extends entitiesCtrl<Base> {
29222924
return;
29232925
}
29242926
if (!this.$scope.$$phase) { this.$scope.$apply(); }
2927+
this.preloadData = () => {
2928+
if (this.showrunning) {
2929+
this.basequery = { "state": { "$in": ["idle", "running"] } };
2930+
} else {
2931+
this.basequery = {};
2932+
}
2933+
};
29252934
WebSocketClientService.onSignedin(async (user: TokenUser) => {
29262935
try {
29272936
if (this.collection == "audit") {
@@ -2946,6 +2955,7 @@ export class EntitiesCtrl extends entitiesCtrl<Base> {
29462955
this.userdata.data.EntitiesCtrl.orderby = this.orderby;
29472956
this.userdata.data.EntitiesCtrl.searchstring = this.searchstring;
29482957
this.userdata.data.EntitiesCtrl.basequeryas = this.basequeryas;
2958+
this.userdata.data.EntitiesCtrl.showrunning = this.showrunning;
29492959
if (!this.$scope.$$phase) { this.$scope.$apply(); }
29502960
}
29512961
SelectCollection() {

OpenFlow/src/public/Entities.html

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,11 @@
1515
</div>
1616
<div class=" col-md-6 text-right" id="entitiestools">
1717
<i class="fas fa-cog fa-spin" ng-show="ctrl.loading==true"></i>
18+
<div ng-show="ctrl.collection == 'openrpa_instances'">
19+
<input type="checkbox" id="checkbox-1" ng-model="ctrl.showrunning" ng-change="ctrl.loadData()">
20+
<label for="checkbox-1"><span translate lib="web">running</span></label>
21+
</div>
22+
1823
<a ng-href="#/Deleted/{{ctrl.collection}}" class="btn btn-info" ng-show="ctrl.loading == false"><em
1924
class="fas fa-undo"></em></a>
2025
<em class="fas fa-undo btn disabled" ng-show="ctrl.loading == true"></em>

OpenFlowNodeRED/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@openiap/nodered",
3-
"version": "1.3.71",
3+
"version": "1.3.72",
44
"description": "Simple wrapper around NodeRed, RabbitMQ and MongoDB to support a more scaleable NodeRed implementation.\r Also the \"backend\" for [OpenRPA](https://github.com/skadefro/OpenRPA)",
55
"main": "index.js",
66
"scripts": {

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
1.3.71
1+
1.3.72

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@openiap/openflow",
3-
"version": "1.3.71",
3+
"version": "1.3.72",
44
"description": "Simple wrapper around NodeRed, RabbitMQ and MongoDB to support a more scaleable NodeRed implementation.\r Also the \"backend\" for [OpenRPA](https://github.com/skadefro/OpenRPA)",
55
"main": "index.js",
66
"scripts": {

0 commit comments

Comments
 (0)