diff --git a/eform-client/package.json b/eform-client/package.json index 74c23c7ae4..50a3e21ccf 100644 --- a/eform-client/package.json +++ b/eform-client/package.json @@ -10,7 +10,9 @@ "pree2e": "webdriver-manager update --standalone false --gecko false", "e2e": "protractor", "build": "ng build --aot -prod", - "server": "node server.js" + "server": "node server.js", + "winserver-install": "node svc.js install", + "winserver-uninstall": "node svc.js uninstall" }, "private": true, "dependencies": { @@ -35,7 +37,7 @@ "ng2-dnd": "^4.2.0", "ngx-bootstrap": "^1.6.6", "pnotify": "^3.2.0", - "rxjs": "^5.1.0", + "rxjs": "^5.4.2", "trumbowyg": "^2.5.1", "ts-helpers": "^1.1.1", "wowjs": "^1.1.3", diff --git a/eform-client/src/app/modules/advanced/components/entity-search-pagination/entity-search-pagination.component.ts b/eform-client/src/app/modules/advanced/components/entity-search-pagination/entity-search-pagination.component.ts index 480b545e63..ab42772f6c 100644 --- a/eform-client/src/app/modules/advanced/components/entity-search-pagination/entity-search-pagination.component.ts +++ b/eform-client/src/app/modules/advanced/components/entity-search-pagination/entity-search-pagination.component.ts @@ -1,6 +1,5 @@ import {Component, EventEmitter, Input, OnChanges, OnInit, Output} from '@angular/core'; -import {Observable} from 'rxjs/Observable'; -import 'rxjs/add/observable/range'; +import { Observable } from 'rxjs/Rx'; @Component({ selector: 'entity-search-pagination', diff --git a/eform-client/svc.js b/eform-client/svc.js new file mode 100644 index 0000000000..f497fd1d36 --- /dev/null +++ b/eform-client/svc.js @@ -0,0 +1,34 @@ +var Service = require('node-windows').Service; + +// Create a new service object +var svc = new Service({ + name: 'eForm angular', + description: 'eForm angular frontend application', + script: 'server.js' +}); + +// Listen for the "install" event, which indicates the +// process is available as a service. +svc.on('install', function () { + console.log('Installation complete.'); + console.log('The service exists: ', svc.exists); + svc.start(); +}); + +// Listen for the "uninstall" event so we know when it's done. +svc.on('uninstall', function () { + console.log('Uninstall complete.'); + console.log('The service exists: ', svc.exists); +}); + +var args = process.argv.slice(2); +switch (args[0]) { + case 'install': + console.log('Service will be installed'); + svc.install(); + break; + case 'uninstall': + console.log('Service will be uninstalled'); + svc.uninstall(); + break; +}