Project

General

Profile

« Previous | Next » 

Revision 61381

[Library]: Move angular 11 to trunk. Remove no needed files. Delete angular upgrade branches

View differences:

modules/uoa-services-library/trunk/ng-openaire-library/webpack.server.config.js
1
// Work around for https://github.com/angular/angular-cli/issues/7200
2

  
3
const path = require('path');
4
const webpack = require('webpack');
5

  
6
module.exports = {
7
  entry: {
8
    // This is our Express server for Dynamic universal
9
    server: './server.ts',
10
    // This is an example of Static prerendering (generative)
11
    prerender: './prerender.ts'
12
  },
13
  target: 'node',
14
  resolve: { extensions: ['.ts', '.js'] },
15
  // Make sure we include all node_modules etc
16
  externals: [/(node_modules|main\..*\.js)/,],
17
  optimization: {
18
    minimize: false
19
  },
20
  output: {
21
    // Puts the output at the root of the dist folder
22
    path: path.join(__dirname, 'dist'),
23
    filename: '[name].js'
24
  },
25
  module: {
26
    rules: [
27
      { test: /\.ts$/, loader: 'ts-loader' }
28
      ,{
29
        // Mark files inside `@angular/core` as using SystemJS style dynamic imports.
30
        // Removing this will cause deprecation warnings to appear.
31
        test: /(\\|\/)@angular(\\|\/)core(\\|\/).+\.js$/,
32
        parser: { system: true },
33
      },
34
    ]
35
  },
36
  plugins: [
37
    new webpack.ContextReplacementPlugin(
38
      // fixes WARNING Critical dependency: the request of a dependency is an expression
39
      /(.+)?angular(\\|\/)core(.+)?/,
40
      path.join(__dirname, 'src'), // location of your src
41
      {} // a map of your routes
42
    ),
43
    new webpack.ContextReplacementPlugin(
44
      // fixes WARNING Critical dependency: the request of a dependency is an expression
45
      /(.+)?express(\\|\/)(.+)?/,
46
      path.join(__dirname, 'src'),
47
      {}
48
    )
49
  ]
50
}
51
  
modules/uoa-services-library/trunk/ng-openaire-library/angular.json
1
{
2
  "$schema": "./node_modules/@angular-devkit/core/src/workspace/workspace-schema.json",
3
  "version": 1,
4
  "newProjectRoot": "projects",
5
  "projects": {
6
    "ng-openaire-library": {
7
      "root": "",
8
      "projectType": "application",
9
      "architect": {
10
        "build": {
11
          "builder": "@angular-devkit/build-angular:browser",
12
          "options": {
13
            "outputPath": "dist/browser",
14
            "index": "src/index.html",
15
            "main": "src/main.ts",
16
            "tsConfig": "src/tsconfig.app.json",
17
            "polyfills": "src/polyfills.ts",
18
            "assets": [
19
              {
20
                "glob": "**/*",
21
                "input": "src/assets",
22
                "output": "/assets"
23
              },
24
              {
25
                "glob": "favicon.ico",
26
                "input": "src",
27
                "output": "/"
28
              }
29
            ],
30
            "styles": [
31
              "src/styles.css",
32
              "node_modules/datatables.net-dt/css/jquery.dataTables.css"
33
            ],
34
            "scripts": [
35
              "node_modules/jquery/dist/jquery.js",
36
              "node_modules/datatables.net/js/jquery.dataTables.js"
37
            ]
38
          },
39
          "configurations": {
40
            "production": {
41
              "optimization": true,
42
              "outputHashing": "all",
43
              "sourceMap": false,
44
              "extractCss": true,
45
              "namedChunks": false,
46
              "aot": true,
47
              "extractLicenses": true,
48
              "vendorChunk": false,
49
              "buildOptimizer": true,
50
              "fileReplacements": [
51
                {
52
                  "replace": "src/environments/environment.ts",
53
                  "with": "src/environments/environment.prod.ts"
54
                }
55
              ]
56
            }
57
          }
58
        },
59
        "serve": {
60
          "builder": "@angular-devkit/build-angular:dev-server",
61
          "options": {
62
            "browserTarget": "ng-openaire-library:build"
63
          },
64
          "configurations": {
65
            "production": {
66
              "browserTarget": "ng-openaire-library:build:production"
67
            }
68
          }
69
        },
70
        "extract-i18n": {
71
          "builder": "@angular-devkit/build-angular:extract-i18n",
72
          "options": {
73
            "browserTarget": "ng-openaire-library:build"
74
          }
75
        },
76
        "test": {
77
          "builder": "@angular-devkit/build-angular:karma",
78
          "options": {
79
            "main": "src/test.ts",
80
            "karmaConfig": "./karma.conf.js",
81
            "polyfills": "src/polyfills.ts",
82
            "tsConfig": "src/tsconfig.spec.json",
83
            "scripts": [],
84
            "styles": [
85
              "src/styles.css"
86
            ],
87
            "assets": [
88
              {
89
                "glob": "**/*",
90
                "input": "src/assets",
91
                "output": "/assets"
92
              },
93
              {
94
                "glob": "favicon.ico",
95
                "input": "src",
96
                "output": "/"
97
              }
98
            ]
99
          }
100
        },
101
        "lint": {
102
          "builder": "@angular-devkit/build-angular:tslint",
103
          "options": {            
104
            "tsConfig": [
105
              "src/tsconfig.app.json"
106
            ],
107
            "exclude": [
108
              "**/node_modules/**"
109
            ]
110
          }
111
        },
112
        "server": {
113
          "builder": "@angular-devkit/build-angular:server",
114
          "options": {
115
            "outputPath": "dist/server",
116
            "main": "src/main.server.ts",
117
            "tsConfig": "src/tsconfig.server.json"
118
          },
119
          "configurations": {
120
            "production": {
121
              "fileReplacements": [
122
                {
123
                  "replace": "src/environments/environment.ts",
124
                  "with": "src/environments/environment.prod.ts"
125
                }
126
              ]
127
            }
128
          }
129
        }
130
      }
131
    },
132
    "ng-openaire-library-e2e": {
133
      "root": "",
134
      "projectType": "application",
135
      "cli": {},
136
      "schematics": {},
137
      "architect": {
138
        "e2e": {
139
          "builder": "@angular-devkit/build-angular:protractor",
140
          "options": {
141
            "protractorConfig": "./protractor.conf.js",
142
            "devServerTarget": "ng-openaire-library:serve"
143
          }
144
        },
145
        "lint": {
146
          "builder": "@angular-devkit/build-angular:tslint",
147
          "options": {
148
            "tsConfig": [],
149
            "exclude": [
150
              "**/node_modules/**"
151
            ]
152
          }
153
        }
154
      }
155
    }
156
  },
157
  "cli": {},
158
  "schematics": {
159
    "@schematics/angular:class": {
160
      "spec": false
161
    },
162
    "@schematics/angular:component": {
163
      "spec": false,
164
      "inlineStyle": true,
165
      "inlineTemplate": true,
166
      "prefix": "app",
167
      "styleext": "css"
168
    },
169
    "@schematics/angular:directive": {
170
      "spec": false,
171
      "prefix": "app"
172
    },
173
    "@schematics/angular:guard": {
174
      "spec": false
175
    },
176
    "@schematics/angular:module": {
177
      "spec": false
178
    },
179
    "@schematics/angular:pipe": {
180
      "spec": false
181
    },
182
    "@schematics/angular:service": {
183
      "spec": false
184
    }
185
  }
186
}
modules/uoa-services-library/trunk/ng-openaire-library/createLibrary.sh
1
rm -rf dist;
2
npm run packagr;
3
cd dist;
4
npm pack;
5
cd ..;
6 0

  
modules/uoa-services-library/trunk/ng-openaire-library/package.json
1
{
2
  "name": "ng-openaire-library",
3
  "version": "1.0.0",
4
  "license": "Openaire",
5
  "contributors": [
6
    "Argiro Kokogiannaki <argirok@di.uoa.gr>",
7
    "Konstantina Galouni <kgalouni@di.uoa.gr>"
8
  ],
9
  "scripts": {
10
    "ng": "ng",
11
    "start": "ng serve --disable-host-check --host 0.0.0.0",
12
    "build": "ng build",
13
    "lint": "ng lint ng-openaire-library",
14
    "build:client-and-server-bundles": "ng build --prod && ng run ng-openaire-library:server:production",
15
    "build:prerender": "npm run build:client-and-server-bundles && npm run webpack:server && npm run generate:prerender",
16
    "build:ssr": "npm run build:client-and-server-bundles && npm run webpack:server",
17
    "generate:prerender": "cd dist && node prerender",
18
    "webpack:server": "webpack --config webpack.server.config.js --progress --colors",
19
    "serve:prerender": "cd dist/browser && http-server",
20
    "serve:ssr": "node dist/server",
21
    "packagr": "ng-packagr -p ng-package.json"
22
  },
23
  "pre-commit": [],
24
  "private": true,
25
  "dependencies": {
26
    "@angular/animations": "7.2.14",
27
    "@angular/cdk": "^7.3.7",
28
    "@angular/common": "7.2.14",
29
    "@angular/compiler": "7.2.14",
30
    "@angular/core": "7.2.14",
31
    "@angular/forms": "7.2.14",
32
    "@angular/http": "7.2.14",
33
    "@angular/material": "^7.3.7",
34
    "@angular/platform-browser": "7.2.14",
35
    "@angular/platform-browser-dynamic": "7.2.14",
36
    "@angular/platform-server": "7.2.14",
37
    "@angular/router": "7.2.14",
38
    "@nguniversal/express-engine": "^6.0.0",
39
    "@nguniversal/module-map-ngfactory-loader": "^6.0.0",
40
    "@types/express": "^4.16.1",
41
    "angular-datatables": "^4.4.1",
42
    "citation-js": "^0.3.4",
43
    "clipboard": "^1.5.16",
44
    "core-js": "^2.4.1",
45
    "datatables.net": "^1.10.19",
46
    "datatables.net-dt": "^1.10.19",
47
    "jquery": "^3.4.1",
48
    "ngx-json-ld": "0.1.6",
49
    "ts-md5": "^1.2.0",
50
    "wikidata-sdk": "^5.2.9",
51
    "zone.js": "^0.8.26"
52
  },
53
  "devDependencies": {
54
    "@angular-devkit/build-angular": "0.11.4",
55
    "@angular/cli": "7.3.9",
56
    "@angular/compiler-cli": "7.2.14",
57
    "@angular/language-service": "7.2.14",
58
    "@types/datatables.net": "^1.10.17",
59
    "@types/jquery": "^3.3.29",
60
    "@types/node": "^8.0.30",
61
    "codelyzer": "^4.0.2",
62
    "cpy-cli": "^1.0.1",
63
    "http-server": "^0.10.0",
64
    "ng-packagr": "^1.6.0",
65
    "pre-commit": "^1.2.2",
66
    "reflect-metadata": "^0.1.10",
67
    "rxjs": "6.5.1",
68
    "rxjs-compat": "^6.5.1",
69
    "rxjs-tslint": "^0.1.7",
70
    "ts-loader": "^4.2.0",
71
    "tslint": "^5.7.0",
72
    "typescript": "3.2.4",
73
    "webpack-cli": "^3.3.2"
74
  }
75
}
modules/uoa-services-library/trunk/ng-openaire-library/tsconfig.json
1
{
2
  "compileOnSave": false,
3
  "compilerOptions": {
4
    "outDir": "./dist/out-tsc",
5
    "sourceMap": true,
6
    "declaration": false,
7
    "moduleResolution": "node",
8
    "emitDecoratorMetadata": true,
9
    "experimentalDecorators": true,
10
    "target": "es5",
11
    "typeRoots": [
12
      "node_modules/@types"
13
    ],
14
    "lib": [
15
      "es2017",
16
      "dom"
17
    ]
18
  }
19
}
modules/uoa-services-library/trunk/ng-openaire-library/ng-package.json
1
{
2
  "$schema": "./node_modules/ng-packagr/ng-package.schema.json",
3
  "lib": {
4
    "entryFile": "public_api.ts"
5
  }
6
}
modules/uoa-services-library/trunk/ng-openaire-library/tslint.json
1
{
2
  "rulesDirectory": [
3
    "node_modules/codelyzer"
4
  ],
5
  "rules": {
6
    "arrow-return-shorthand": true,
7
    "callable-types": true,
8
    "class-name": true,
9
    "comment-format": [
10
      true,
11
      "check-space"
12
    ],
13
    "curly": true,
14
    "deprecation": {
15
      "severity": "warn"
16
    },
17
    "eofline": true,
18
    "forin": true,
19
    "import-blacklist": [
20
      true,
21
      "rxjs/Rx",
22
      "rxjs/operators"
23
    ],
24
    "import-spacing": true,
25
    "indent": [
26
      true,
27
      "spaces"
28
    ],
29
    "interface-over-type-literal": true,
30
    "label-position": true,
31
    "max-line-length": [
32
      true,
33
      140
34
    ],
35
    "member-access": false,
36
    "member-ordering": [
37
      true,
38
      {
39
        "order": [
40
          "static-field",
41
          "instance-field",
42
          "static-method",
43
          "instance-method"
44
        ]
45
      }
46
    ],
47
    "no-arg": true,
48
    "no-bitwise": true,
49
    "no-console": [
50
      true,
51
      "debug",
52
      "info",
53
      "time",
54
      "timeEnd",
55
      "trace"
56
    ],
57
    "no-construct": true,
58
    "no-debugger": true,
59
    "no-duplicate-super": true,
60
    "no-empty": false,
61
    "no-empty-interface": true,
62
    "no-eval": true,
63
    "no-inferrable-types": [
64
      true,
65
      "ignore-params"
66
    ],
67
    "no-misused-new": true,
68
    "no-non-null-assertion": true,
69
    "no-shadowed-variable": true,
70
    "no-string-literal": false,
71
    "no-string-throw": true,
72
    "no-switch-case-fall-through": true,
73
    "no-trailing-whitespace": true,
74
    "no-unnecessary-initializer": true,
75
    "no-unused-expression": true,
76
    "no-use-before-declare": true,
77
    "no-var-keyword": true,
78
    "object-literal-sort-keys": false,
79
    "one-line": [
80
      true,
81
      "check-open-brace",
82
      "check-catch",
83
      "check-else",
84
      "check-whitespace"
85
    ],
86
    "prefer-const": true,
87
    "quotemark": [
88
      true,
89
      "single"
90
    ],
91
    "radix": true,
92
    "semicolon": [
93
      true,
94
      "always"
95
    ],
96
    "triple-equals": [
97
      true,
98
      "allow-null-check"
99
    ],
100
    "typedef-whitespace": [
101
      true,
102
      {
103
        "call-signature": "nospace",
104
        "index-signature": "nospace",
105
        "parameter": "nospace",
106
        "property-declaration": "nospace",
107
        "variable-declaration": "nospace"
108
      }
109
    ],
110
    "typeof-compare": true,
111
    "unified-signatures": true,
112
    "variable-name": false,
113
    "whitespace": [
114
      true,
115
      "check-branch",
116
      "check-decl",
117
      "check-operator",
118
      "check-separator",
119
      "check-type"
120
    ],
121
    "directive-selector": [
122
      true,
123
      "attribute",
124
      "app",
125
      "camelCase"
126
    ],
127
    "component-selector": [
128
      true,
129
      "element",
130
      "app",
131
      "kebab-case"
132
    ],
133
    "no-output-on-prefix": true,
134
    "use-input-property-decorator": true,
135
    "use-output-property-decorator": true,
136
    "use-host-property-decorator": true,
137
    "no-input-rename": true,
138
    "no-output-rename": true,
139
    "use-life-cycle-interface": true,
140
    "use-pipe-transform-interface": true,
141
    "component-class-suffix": true,
142
    "directive-class-suffix": true
143
  }
144
}
modules/uoa-services-library/trunk/ng-openaire-library/static.paths.ts
1
export const ROUTES = [
2
  '/',
3
  '/lazy',
4
  '/home',
5
  '/search/publication','/search/project','/search/dataset','/search/dataprovider','/search/organization',
6
  '/search/find',
7
  '/search/person','/search/publication','/search/project','/search/dataset','/search/dataprovider','/search/organization',
8
  '/search/find/people','/search/find/publications','/search/find/projects','/search/find/datasets','/search/find/dataproviders','/search/find/organizations',
9
  '/search/advanced/people','/search/advanced/publications','/search/advanced/projects','/search/advanced/datasets','/search/advanced/dataproviders','/search/advanced/organizations',
10
  '/participate/deposit-publications','/participate/deposit-datasets','/participate/deposit-publications-result','/participate/deposit-datasets-result','/participate/deposit-subject-result',
11
  '/search/content-providers','/search/content-providers-table','/search/entity-registries','/search/entity-registries-table','/search/journals','/search/journals-table',
12
  '/project-report','/claims','/myclaims','/participate/claim','/participate/direct-claim','/claims-project-manager',
13
  '/test','/user-info',
14
  '/error', '/*path'
15
];
modules/uoa-services-library/trunk/ng-openaire-library/prerender.ts
1
// Load zone.js for the server.
2
import 'zone.js/dist/zone-node';
3
import 'reflect-metadata';
4
import { readFileSync, writeFileSync, existsSync, mkdirSync } from 'fs';
5
import { join } from 'path';
6

  
7
import { enableProdMode } from '@angular/core';
8
// Faster server renders w/ Prod mode (dev mode never needed)
9
enableProdMode();
10

  
11
// Express Engine
12
import { ngExpressEngine } from '@nguniversal/express-engine';
13
// Import module map for lazy loading
14
import { provideModuleMap } from '@nguniversal/module-map-ngfactory-loader';
15
import { renderModuleFactory } from '@angular/platform-server';
16
import { ROUTES } from './static.paths';
17

  
18
// * NOTE :: leave this as require() since this file is built Dynamically from webpack
19
const { AppServerModuleNgFactory, LAZY_MODULE_MAP } = require('./dist/server/main');
20

  
21
const BROWSER_FOLDER = join(process.cwd(), 'browser');
22

  
23
// Load the index.html file containing referances to your application bundle.
24
const index = readFileSync(join('browser', 'index.html'), 'utf8');
25

  
26
let previousRender = Promise.resolve();
27

  
28
// Iterate each route path
29
ROUTES.forEach(route => {
30
  const fullPath = join(BROWSER_FOLDER, route);
31

  
32
  // Make sure the directory structure is there
33
  if(!existsSync(fullPath)){
34
    mkdirSync(fullPath);
35
  }
36

  
37
  // Writes rendered HTML to index.html, replacing the file if it already exists.
38
  previousRender = previousRender.then(_ => renderModuleFactory(AppServerModuleNgFactory, {
39
    document: index,
40
    url: route,
41
    extraProviders: [
42
      provideModuleMap(LAZY_MODULE_MAP)
43
    ]
44
  })).then(html => writeFileSync(join(fullPath, 'index.html'), html));
45
});
modules/uoa-services-library/trunk/ng-openaire-library/server.ts
1
import 'zone.js/dist/zone-node';
2
import 'reflect-metadata';
3
import { renderModuleFactory } from '@angular/platform-server';
4
import { enableProdMode } from '@angular/core';
5
// Express Engine
6
import {ngExpressEngine} from '@nguniversal/express-engine';
7
// Import module map for lazy loading
8
import {provideModuleMap} from '@nguniversal/module-map-ngfactory-loader';
9

  
10
import * as express from 'express';
11
import { join } from 'path';
12
import { readFileSync } from 'fs';
13

  
14
// Faster server renders w/ Prod mode (dev mode never needed)
15
enableProdMode();
16

  
17
// Express server
18
const app = express();
19

  
20
const PORT = process.env.PORT || 4000;
21
const DIST_FOLDER = join(process.cwd(), 'dist');
22

  
23
// Our index.html we'll use as our template
24
const template = readFileSync(join(DIST_FOLDER, 'browser', 'index.html')).toString();
25

  
26
// * NOTE :: leave this as require() since this file is built Dynamically from webpack
27
const { AppServerModuleNgFactory, LAZY_MODULE_MAP } = require('./dist/server/main');
28

  
29
/*
30
// Our Universal express-engine (found @ https://github.com/angular/universal/tree/master/modules/express-engine)
31
app.engine('html', ngExpressEngine({
32
  bootstrap: AppServerModuleNgFactory,
33
  providers: [
34
    provideModuleMap(LAZY_MODULE_MAP)
35
  ]
36
}));
37
*/
38

  
39
app.engine('html', (_, options, callback) => {
40
    let engine = ngExpressEngine({
41
        bootstrap: AppServerModuleNgFactory,
42
        providers: [
43
            { provide: 'request', useFactory: () => options.req, deps: [] },
44
            provideModuleMap(LAZY_MODULE_MAP)
45
        ]
46
    });
47
    engine(_, options, callback);
48
});
49

  
50
app.set('view engine', 'html');
51
app.set('views', join(DIST_FOLDER, 'browser'));
52

  
53
// Example Express Rest API endpoints
54
// app.get('/api/**', (req, res) => { });
55

  
56
// Server static files from /browser
57
app.get('*.*', express.static(join(DIST_FOLDER, 'browser'), {
58
  maxAge: '1y'
59
}));
60

  
61
// All regular routes use the Universal engine
62
app.get('*', (req, res) => {
63
  res.render('index', { req });
64
});
65

  
66
// Start up the Node server
67
app.listen(PORT, () => {
68
  console.log(`Node Express server listening on http://localhost:${PORT}`);
69
});
modules/uoa-services-library/trunk/ng-openaire-library/README.md
1
# Angular Universal & Anguar-CLI minimal starter
2

  
3
> This demo is built following the [Angular-CLI Wiki guide](https://github.com/angular/angular-cli/wiki/stories-universal-rendering)
4

  
5
We're utilizing packages from the [Angular Universal @nguniversal](https://github.com/angular/universal) repo, such as [ng-module-map-ngfactory-loader](https://github.com/angular/universal/tree/master/modules/module-map-ngfactory-loader) to enable Lazy Loading.
6

  
7
---
8

  
9
## Static or Dynamic
10
This repo demonstrates the use of 2 different forms of Server Side Rendering.
11

  
12
**Static** Also known as "prerendering"
13
* Happens at build time
14
* Renders your application and replaces the dist index.html with a version rendered at the route `/`.
15

  
16
**Dynamic**
17
* Happens at runtime
18
* Uses `ngExpressEngine` to render you application on the fly at the requested url.
19

  
20
---
21

  
22
## Installation
23
* `npm install` or `yarn`
24

  
25
---
26

  
27
## Development (Client-side only rendering)
28
* run `npm run start` which will start `ng serve` (project served at the standard: localhost:4200)
29

  
30
---
31

  
32
## Production 
33

  
34
Depending on whether you're publishing dynamic or static prerendering, run the build command, and then serve up your dist folder assets.
35

  
36
> **NOTE**: To deploy your **Static** site to a static hosting platform you will have to deploy the *`dist/browser`* folder, rather than the usual *`dist`*
37

  
38
ie: `npm run build:dynamic` or `npm run build:static`. All of the files that need to be served will be found within the `/dist` folder.
39

  
40

  
41

  
42
---
43

  
44
## Testing Universal (dynamic or static) builds -Locally-
45

  
46
**Dynamic** : **`npm run start:dynamic`**
47

  
48
Compiles your application and spins up a Node Express to dynamically serve your Universal application on `http://localhost:4000`.
49

  
50
**Static** : **`npm run start:static`**
51

  
52
- Compiles your application and prerenders your applications files, spinning up a demo http-server so you can view it on `http://127.0.0.1:8080`
53

  
54

  
modules/uoa-services-library/trunk/ng-openaire-library/public_api.ts
1
export * from './src/app/landingPages/publication/publication.module';
2
export * from './src/app/landingPages/dataset/dataset.module';
3
export * from './src/app/landingPages/project/project.module';
4
export * from './src/app/landingPages/project/project.service';
5
export * from './src/app/landingPages/project/projectService.module';
6
export * from './src/app/landingPages/dataProvider/dataProvider.module';
7
export * from './src/app/landingPages/organization/organization.module';
8
export * from './src/app/landingPages/software/software.module';
9
export * from './src/app/landingPages/htmlProjectReport/htmlProjectReport.module';
10
export * from './src/app/utils/configuration/configurationService.module';
11
export * from './src/app/utils/configuration/configuration.service';
12
export * from './src/app/sharedComponents/feedback/feedback.module';
13
export * from './src/app/sharedComponents/bottom.module';
14
export * from './src/app/sharedComponents/navigationBar.module';
15
export * from './src/app/sharedComponents/menu';
16
export * from './src/app/utils/properties/env-properties';
17
export * from './src/app/utils/properties/environment-specific.service';
18
export * from './src/app/utils/properties/environmentSpecificResolver';
19
export * from './src/app/sharedComponents/cookie-law/cookie-law.module';
20
export * from './src/app/searchPages/find/mainSearch.module';
21
export * from './src/app/login/user.module';
22
export * from './src/app/error/error.module';
23
export * from './src/app/reload/reload.module';
24
export * from './src/app/claims/myClaims/myClaims.module';
25
export * from './src/app/claims/claimsAdmin/claimsAdmin.module';
26
export * from './src/app/claims/claimsAdmin/claimsAdmin.component';
27
export * from './src/app/claims/directLinking/directLinking.module';
28
export * from './src/app/claims/linking/linkingGeneric.module';
29

  
30
export * from './src/app/deposit/deposit.module';
31
export * from './src/app/deposit/datasets/depositDatasets.module';
32
export * from './src/app/deposit/datasets/depositDatasetsResults.module';
33
export * from './src/app/deposit/datasets/depositBySubjectResults.module';
34
export * from './src/app/deposit/publications/depositPublicationsResults.module';
35
export * from './src/app/deposit/publications/depositPublications.module';
36
export * from './src/app/searchPages/simple/searchPublications.module';
37
export * from './src/app/searchPages/simple/searchDatasets.module';
38
export * from './src/app/searchPages/simple/searchSoftware.module';
39
export * from './src/app/searchPages/simple/searchProjects.module';
40
export * from './src/app/searchPages/simple/searchOrganizations.module';
41
export * from './src/app/searchPages/simple/searchDataProviders.module';
42
export * from './src/app/searchPages/advanced/advancedSearchPublications.module';
43
export * from './src/app/searchPages/advanced/advancedSearchDatasets.module';
44
export * from './src/app/searchPages/advanced/advancedSearchSoftware.module';
45
export * from './src/app/searchPages/advanced/advancedSearchProjects.module';
46
export * from './src/app/searchPages/advanced/advancedSearchOrganizations.module';
47
export * from './src/app/searchPages/advanced/advancedSearchDataProviders.module';
48
export * from './src/app/searchPages/dataProviders/entityRegistries.module';
49
export * from './src/app/searchPages/dataProviders/compatibleDataProviders.module';
50
export * from './src/app/searchPages/dataProviders/journals.module';
51
/* search utils*/
52
export {Filter, Value} from './src/app/searchPages/searchUtils/searchHelperClasses.class';
53
export {SearchUtilsClass} from './src/app/searchPages/searchUtils/searchUtils.class';
54
export{SearchFilterComponent} from './src/app/searchPages/searchUtils/searchFilter.component';
55
export {SearchFilterModalComponent} from './src/app/searchPages/searchUtils/searchFilterModal.component';
56
export {SearchFormModule} from  './src/app/searchPages/searchUtils/searchForm.module';
57
 export{SearchResultsModule} from './src/app/searchPages/searchUtils/searchResults.module';
58
export {SearchFilterModule} from './src/app/searchPages/searchUtils/searchFilter.module';
59
export{SearchPagingModule} from './src/app/searchPages/searchUtils/searchPaging.module';
60
export {SearchDownloadModule} from './src/app/searchPages/searchUtils/searchDownload.module';
61
/* Utils*/
62
//export {OpenaireProperties} from './src/app/utils/properties/openaireProperties';
63
export {SearchFields} from './src/app/utils/properties/searchFields';
64
//export {ErrorCodes} from './src/app/utils/properties/openaireProperties';
65
export {RouterHelper} from './src/app/utils/routerHelper.class';
66
export {NumberUtils} from './src/app/utils/number-utils.class';
67
export {PiwikService} from './src/app/utils/piwik/piwik.service';
68
export {LoadingModalModule} from './src/app/utils/modal/loadingModal.module';
69
export{ModalLoading} from './src/app/utils/modal/loading.component';
70
export {ModalModule} from './src/app/utils/modal/modal.module';
71
export {PagingModule} from './src/app/utils/paging.module';
72

  
73
export {PiwikServiceModule} from './src/app/utils/piwik/piwikService.module';
74

  
75
export {HelperModule} from './src/app/utils/helper/helper.module';
76
export {ErrorMessagesModule} from './src/app/utils/errorMessages.module';
77
export {DOI, StringUtils} from './src/app/utils/string-utils.class';
78

  
79
/*Services*/
80
export {SearchPublicationsService} from './src/app/services/searchPublications.service';
81
export {PublicationsServiceModule} from './src/app/services/publicationsService.module';
82
export {SearchDataprovidersService} from './src/app/services/searchDataproviders.service';
83
export {DataProvidersServiceModule} from './src/app/services/dataProvidersService.module';
84
export {SearchProjectsService} from './src/app/services/searchProjects.service';
85
export {ProjectsServiceModule} from './src/app/services/projectsService.module';
86
export {SearchDatasetsService} from './src/app/services/searchDatasets.service';
87
export {DatasetsServiceModule} from './src/app/services/datasetsService.module';
88
export {SearchOrganizationsService} from './src/app/services/searchOrganizations.service';
89
export {OrganizationsServiceModule} from './src/app/services/organizationsService.module';
90
export {ReportsServiceModule} from './src/app/services/reportsService.module';
91
export {RefineFieldResultsService} from './src/app/services/refineFieldResults.service';
92
export {RefineFieldResultsServiceModule} from './src/app/services/refineFieldResultsService.module';
93

  
94

  
95
export * from './src/app/login/freeGuard.guard';
96
export * from './src/app/login/loginGuard.guard';
97
export * from './src/app/login/adminLoginGuard.guard';
98
export * from './src/app/login/utils/helper.class';
99
export * from './src/app/utils/piwik/previousRouteRecorder.guard';
100
export * from './src/app/error/isRouteEnabled.guard';
101
export * from './src/app/error/error.module';
102
export {EnvironmentSpecificResolver} from './src/app/utils/properties/environmentSpecificResolver';
103
export {EnvironmentSpecificService } from './src/app/utils/properties/environment-specific.service';
modules/uoa-services-library/trunk/ng-openaire-library/src/polyfills.ts
1
/**
2
 * This file includes polyfills needed by Angular and is loaded before the app.
3
 * You can add your own extra polyfills to this file.
4
 *
5
 * This file is divided into 2 sections:
6
 *   1. Browser polyfills. These are applied before loading ZoneJS and are sorted by browsers.
7
 *   2. Application imports. Files imported after ZoneJS that should be loaded before your main
8
 *      file.
9
 *
10
 * The current setup is for so-called "evergreen" browsers; the last versions of browsers that
11
 * automatically update themselves. This includes Safari >= 10, Chrome >= 55 (including Opera),
12
 * Edge >= 13 on the desktop, and iOS 10 and Chrome on mobile.
13
 *
14
 * Learn more in https://angular.io/docs/ts/latest/guide/browser-support.html
15
 */
16

  
17
/***************************************************************************************************
18
 * BROWSER POLYFILLS
19
 */
20

  
21
/** IE9, IE10 and IE11 requires all of the following polyfills. **/
22
import 'core-js/es6/symbol';
23
import 'core-js/es6/object';
24
import 'core-js/es6/function';
25
import 'core-js/es6/parse-int';
26
import 'core-js/es6/parse-float';
27
import 'core-js/es6/number';
28
import 'core-js/es6/math';
29
import 'core-js/es6/string';
30
import 'core-js/es6/date';
31
import 'core-js/es6/array';
32
import 'core-js/es6/regexp';
33
import 'core-js/es6/map';
34
import 'core-js/es6/weak-map';
35
import 'core-js/es6/set';
36

  
37
/** IE10 and IE11 requires the following for NgClass support on SVG elements */
38
// import 'classlist.js';  // Run `npm install --save classlist.js`.
39

  
40
/** Evergreen browsers require these. **/
41
import 'core-js/es6/reflect';
42
import 'core-js/es7/reflect';
43

  
44

  
45
/**
46
 * Required to support Web Animations `@angular/animation`.
47
 * Needed for: All but Chrome, Firefox and Opera. http://caniuse.com/#feat=web-animation
48
 **/
49
// import 'web-animations-js';  // Run `npm install --save web-animations-js`.
50

  
51

  
52

  
53
/***************************************************************************************************
54
 * Zone JS is required by Angular itself.
55
 */
56
import 'zone.js/dist/zone';  // Included with Angular CLI.
57

  
58

  
59

  
60
/***************************************************************************************************
61
 * APPLICATION IMPORTS
62
 */
63

  
64
/**
65
 * Date, currency, decimal and percent pipes.
66
 * Needed for: All but Chrome, Firefox, Edge, IE11 and Safari 10
67
 */
68
// import 'intl';  // Run `npm install --save intl`.
69
/**
70
 * Need to import at least one locale-data with intl.
71
 */
72
// import 'intl/locale-data/jsonp/en';
modules/uoa-services-library/trunk/ng-openaire-library/src/tsconfig.app.json
1
{
2
  "extends": "../tsconfig.json",
3
  "compilerOptions": {
4
    "outDir": "../out-tsc/app",
5
    "baseUrl": "./",
6
    "module": "es2015",
7
    "types": [
8
      "node"
9
    ]
10
  },
11
  "exclude": [
12
    "test.ts",
13
    "**/*.spec.ts"
14
  ]
15
}
modules/uoa-services-library/trunk/ng-openaire-library/src/environments/environment.ts
1
// The file contents for the current environment will overwrite these during build.
2
// The build system defaults to the dev environment which uses `environment.ts`, but if you do
3
// `ng build --env=prod` then `environment.prod.ts` will be used instead.
4
// The list of which env maps to which file can be found in `.angular-cli.json`.
5

  
6
export const environment = {
7
  production: false
8
};
modules/uoa-services-library/trunk/ng-openaire-library/src/environments/environment.prod.ts
1
export const environment = {
2
  production: true
3
};
modules/uoa-services-library/trunk/ng-openaire-library/src/main.ts
1
import { enableProdMode } from '@angular/core';
2
import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
3

  
4
import { AppModule } from './app/app.module';
5
import { environment } from './environments/environment';
6

  
7
if (environment.production) {
8
  enableProdMode();
9
}
10

  
11
document.addEventListener('DOMContentLoaded', () => {
12
  platformBrowserDynamic().bootstrapModule(AppModule);
13
});
modules/uoa-services-library/trunk/ng-openaire-library/src/tsconfig.server.json
1
{
2
  "extends": "../tsconfig.json",
3
  "compilerOptions": {
4
    "outDir": "../out-tsc/app",
5
    "baseUrl": "./",
6
    // Set the module format to "commonjs":
7
    "module": "commonjs",
8
    "types": [
9
      "node"
10
    ]
11
  },
12
  "exclude": [
13
    "test.ts",
14
    "**/*.spec.ts"
15
  ],
16
  // Add "angularCompilerOptions" with the AppServerModule you wrote
17
  // set as the "entryModule".
18
  "angularCompilerOptions": {
19
    "entryModule": "app/app.server.module#AppServerModule"
20
  }
21
}
modules/uoa-services-library/trunk/ng-openaire-library/src/index.html
1
<!DOCTYPE html>
2
<html lang="en-gb" dir="ltr" vocab="http://schema.org/">
3
   <head>
4
      <!--link href="http://demo.openaire.eu" rel="canonical" /-->
5
      <meta charset="utf-8">
6
      <meta http-equiv="X-UA-Compatible" content="IE=edge">
7
      <meta name="viewport" content="width=device-width, initial-scale=1">
8
      <base href="/" />
9
      <meta http-equiv="content-type" content="text/html; charset=utf-8" />
10
      <meta name="description" content="open access, research, scientific publication, European Commission, EC, FP7, ERC, Horizon 2020, H2020, search, projects "/>
11

  
12
      <meta property="og:description" content="open access, research, scientific publication, European Commission, EC, FP7, ERC, Horizon 2020, H2020, search, projects "/>
13
      <meta property="og:title" content="Search OpenAIRE"/>
14
      <meta property="og:type" content="website"/>
15
      <meta property="og:url" content="https://demo.openaire.eu"/>
16
      <meta property="og:site_name" content="OpenAIRE"/>
17

  
18
      <meta property="og:image" content="assets/common/Symbol.png"/>
19
      <meta property="og:image:secure_url" content="assets/common/Symbol.png" />
20
      <meta property="og:image:type" content="image/png" />
21
      <meta property="og:image:width" content="360" />
22
      <meta property="og:image:height" content="359" />
23

  
24
      <link rel="apple-touch-icon" sizes="57x57" href="assets/logo/apple-icon-57x57.png">
25
      <link rel="apple-touch-icon" sizes="60x60" href="assets/logo/apple-icon-60x60.png">
26
      <link rel="apple-touch-icon" sizes="72x72" href="assets/logo/apple-icon-72x72.png">
27
      <link rel="apple-touch-icon" sizes="76x76" href="assets/logo/apple-icon-76x76.png">
28
      <link rel="apple-touch-icon" sizes="114x114" href="assets/logo/apple-icon-114x114.png">
29
      <link rel="apple-touch-icon" sizes="120x120" href="assets/logo/apple-icon-120x120.png">
30
      <link rel="apple-touch-icon" sizes="144x144" href="assets/logo/apple-icon-144x144.png">
31
      <link rel="apple-touch-icon" sizes="152x152" href="assets/logo/apple-icon-152x152.png">
32
      <link rel="apple-touch-icon" sizes="180x180" href="assets/logo/apple-icon-180x180.png">
33
      <link rel="icon" type="image/png" sizes="192x192"  href="assets/logo/android-icon-192x192.png">
34
      <link rel="icon" type="image/png" sizes="32x32" href="assets/logo/favicon-32x32.png">
35
      <link rel="icon" type="image/png" sizes="96x96" href="assets/logo/favicon-96x96.png">
36
      <link rel="icon" type="image/png" sizes="16x16" href="assets/logo/favicon-16x16.png">
37
      <link href="assets/logo/favicon.ico" rel="shortcut icon" type="image/vnd.microsoft.icon" />
38
      <link rel="manifest" href="assets/logo/manifest.json">
39
      <meta name="msapplication-TileColor" content="#ffffff">
40
      <meta name="msapplication-TileImage" content="/ms-icon-144x144.png">
41
      <meta name="theme-color" content="#ffffff">
42

  
43
      <title>Search OpenAIRE</title>
44
      <script>
45
      window.onerror = function (errorMsg, url, lineNumber, column, errorObj) {
46
        // console.log(errorMsg + " __" + url + " __" +  lineNumber + " __" +  column + " __" +  errorObj);
47
        if((errorMsg && errorMsg.indexOf("uikit.js") != -1) || url.indexOf("uikit.js") != -1 ){
48
          console.log("********UIKIT Error ***********");
49
          $.getScript("assets/common/uikit.js");
50
          $.getScript("assets/common/uikit-icons-max.js");
51
}
52

  
53
}
54
      </script>
55

  
56

  
57
       <!-- <script src="assets/jquery/jquery.min.js" type="text/javascript"></script> -->
58
       <script  src="assets/common/jquery.js"></script>
59
       <script  src="assets/citeproc.js"></script>
60
       <!-- <script  src="assets/common/uikit.js"></script> -->
61
       <script src="assets/common/uikit-icons-max.js"></script>
62
<script>
63
$(document).ready(function(){
64
  console.log("Is ready - load uikit ***")
65
    $.getScript("assets/common/uikit.js");
66
    $.getScript("assets/common/uikit-icons-max.js");
67
});
68

  
69
</script>
70
<script>
71
  var logoutClicked = function(){
72
    console.log("jqery logout!");
73
    // no
74
    // $("#logout1").load("https://dl067.madgik.di.uoa.gr/idp/profile/Logout");
75
    //yes
76
    // window.open('https://dl067.madgik.di.uoa.gr/idp/profile/Logout','_blank','toolbar=no,status=no,menubar=no,scrollbars=no,resizable=no,visible=none', '');
77

  
78
    // no
79
    var xmlHttp = null;
80

  
81
    xmlHttp = new XMLHttpRequest();
82
    xmlHttp.open( "GET", "https://dl067.madgik.di.uoa.gr/idp/profile/Logout", true );
83
    xmlHttp.send( null );
84

  
85
   };
86

  
87
</script>
88
       <!-- <script  src="assets/common/uikit.js"></script> -->
89
       <!-- <script src="assets/common/uikit-icons-max.js"></script> -->
90

  
91

  
92
      <link rel="stylesheet" href="assets/common/theme.css">
93
      <link rel="stylesheet" href="assets/common/custom.css">
94
      <link rel="stylesheet" href="assets/library.css">
95
      <link rel="stylesheet" href="assets/discover-custom.css">
96

  
97
      <!-- <script async src="assets/common/theme.js"></script> -->
98

  
99

  
100
             <!-- Google sitename markup-->
101
      <script type="application/ld+json">
102
         {
103
           "@context" : "http://schema.org",
104
           "@type" : "WebSite",
105
           "name" : "OpenAIRE",
106
             "url" : "http://demo.openaire.eu"
107
         }
108
      </script>
109
      <!-- End of Google sitename markup-->
110
      <!-- Google sitelinks search markup-->
111
      <script type="application/ld+json">
112
         {
113
           "@context": "http://schema.org",
114
           "@type": "WebSite",
115
           "url" : "http://demo.openaire.eu",
116
           "potentialAction": {
117
             "@type": "SearchAction",
118
             "target": "http://demo.openaire.eu/search/find/?keyword={search_term_string}",
119
             "query-input": "required name=search_term_string"
120
           }
121
         }
122
      </script>
123

  
124
      <script src="assets/clipboard.min.js"></script>
125
      <!--script type='text/javascript' src="node_modules/clipboard/dist/clipboard.min.js"></script-->
126
      <!--script src="https://cdn.jsdelivr.net/clipboard.js/1.5.12/clipboard.min.js"></script-->
127

  
128
      <!--script type='text/javascript' src='https://d1bxh8uas1mnw7.cloudfront.net/assets/embed.js'></script-->
129

  
130
      <!-- End of Google sitelinks search markup-->
131

  
132

  
133
 </head>
134
 <body class="" style="">
135

  
136
   <div class="uk-offcanvas-content uk-height-viewport">
137

  
138
      <app-root></app-root>
139
    </div>
140

  
141

  
142
  <script type="text/javascript"  >
143
  function loadAltmetrics(e,t,n){
144
    var d="createElement",c="getElementsByTagName",m="setAttribute",n=document.getElementById(e);
145
    return n&&n.parentNode&&n.parentNode.removeChild(n),n=document[d+"NS"]&&document.documentElement.namespaceURI,n=n?document[d+"NS"](n,"script"):document[d]("script"),n[m]("id",e),n[m]("src",t),(document[c]("head")[0]||document[c]("body")[0]).appendChild(n),n=new Image,void n[m]("src","https://d1uo4w7k31k5mn.cloudfront.net/donut/0.png")
146
  };
147
</script>
148
<!-- Go to www.addthis.com/dashboard to customize your tools -->
149
<!-- to update addThis: https://s7.addthis.com/js/300/addthis_widget.js#pubid=ra-559d24521cd8c080-->
150
<!-- <script type="text/javascript" src="https://s7.addthis.com/js/300/addthis_widget.js#pubid=ra-5a12dbd124e4e521"></script> -->
151
<script type="text/javascript" src="//s7.addthis.com/js/300/addthis_widget.js#pubid=ra-559d24521cd8c080"></script>
152
   </body>
153
</html>
modules/uoa-services-library/trunk/ng-openaire-library/src/styles.css
1
/* You can add global styles to this file, and also import other style files */
modules/uoa-services-library/trunk/ng-openaire-library/src/main.server.ts
1
export { AppServerModule } from './app/app.server.module';
modules/uoa-services-library/trunk/ng-openaire-library/src/app/contact-us/contact-us.module.ts
3 3
import {RouterModule} from '@angular/router';
4 4

  
5 5
import {ContactUsComponent} from './contact-us.component';
6
import {RecaptchaModule} from "ng-recaptcha";
7 6
import {ReactiveFormsModule} from "@angular/forms";
8 7
import {MatAutocompleteModule} from "@angular/material/autocomplete";
8
import {RecaptchaModule} from "ng-recaptcha";
9 9

  
10 10
@NgModule({
11 11
  imports: [
12 12
    CommonModule, RouterModule,
13
    RecaptchaModule.forRoot(), ReactiveFormsModule, MatAutocompleteModule],
14
    declarations: [
15
        ContactUsComponent
16
    ],
17
    providers: [],
18
    exports: [
19
        ContactUsComponent
20
    ]
13
    ReactiveFormsModule, MatAutocompleteModule, RecaptchaModule],
14
  declarations: [
15
    ContactUsComponent
16
  ],
17
  providers: [],
18
  exports: [
19
    ContactUsComponent
20
  ]
21 21
})
22 22

  
23 23
export class ContactUsModule {
modules/uoa-services-library/trunk/ng-openaire-library/src/app/role-verification/role-verification.component.ts
95 95
  public verification: any;
96 96
  public code: FormControl;
97 97
  private subs: any[] = [];
98
  @ViewChild('managerModal') managerModal: AlertModal;
99
  @ViewChild('memberModal') memberModal: AlertModal;
100
  @ViewChild('errorModal') errorModal: AlertModal;
98
  @ViewChild('managerModal', { static: true }) managerModal: AlertModal;
99
  @ViewChild('memberModal', { static: true }) memberModal: AlertModal;
100
  @ViewChild('errorModal', { static: true }) errorModal: AlertModal;
101 101
  public error: string = null;
102 102
  public loading: boolean = false;
103 103
  public isMember: boolean = false;
modules/uoa-services-library/trunk/ng-openaire-library/src/app/services/help-content.service.ts
1 1
/**
2 2
 * Created by stefania on 7/13/17.
3 3
 */
4
import { Injectable } from '@angular/core';
4
import {Injectable} from '@angular/core';
5 5
import {HttpClient, HttpErrorResponse} from "@angular/common/http";
6
import { Observable } from 'rxjs';
7
import { Page } from "../utils/entities/adminTool/page";
8
import { PageHelpContent } from "../utils/entities/adminTool/page-help-content";
9
import { Portal } from "../utils/entities/adminTool/portal";
10
import { Entity } from "../utils/entities/adminTool/entity";
11
import { DivId } from "../utils/entities/adminTool/divId";
12
import { DivHelpContent } from "../utils/entities/adminTool/div-help-content";
6
import {Observable, throwError} from 'rxjs';
7
import {Page} from "../utils/entities/adminTool/page";
8
import {PageHelpContent} from "../utils/entities/adminTool/page-help-content";
9
import {Portal} from "../utils/entities/adminTool/portal";
10
import {Entity} from "../utils/entities/adminTool/entity";
11
import {DivId} from "../utils/entities/adminTool/divId";
12
import {DivHelpContent} from "../utils/entities/adminTool/div-help-content";
13 13
import {StatisticsDisplay, StatisticsSummary} from '../connect/statistics/statisticsEntities';
14
import { CustomOptions } from './servicesUtils/customOptions.class';
14
import {CustomOptions} from './servicesUtils/customOptions.class';
15 15
import {catchError, map} from "rxjs/operators";
16 16
import {properties} from "../../../environments/environment";
17 17

  
......
373 373
    // in a real world app, we may send the error to some remote logging infrastructure
374 374
    // instead of just logging it to the console
375 375
    console.error(error);
376
    return Observable.throw(error.error || 'Server error');
376
    return throwError(error.error || 'Server error');
377 377
  }
378 378

  
379 379
  // getDataProviders() {
modules/uoa-services-library/trunk/ng-openaire-library/src/app/services/searchResearchResults.service.ts
204 204
        if (!Array.isArray(resData['pid'])) {
205 205
          if (resData['pid'].classid && resData['pid'].classid == 'doi') {
206 206
            if (resData['pid'].content != '' && resData['pid'].content != null) {
207
              result.DOIs.push(resData['pid'].content.replace("https://doi.org/", ""));
207
              result.DOIs.push((resData['pid'].content+"").replace("https://doi.org/", ""));
208 208
            }
209 209
          }
210 210
        } else {
......
538 538
      return entityType;
539 539
    }
540 540
  }
541

  
542
  public countCollectedResultsWithFundingInfo(datasourceId: string) {
543
    let url = properties.searchAPIURLLAst + "resources?query=" + encodeURIComponent("(oaftype=result and collectedfromdatasourceid exact \""+datasourceId+"\" and relprojectid=*)") + "&page=0&size=0&format=json";
544
    return this.http.get((properties.useCache) ? (properties.cacheUrl + encodeURIComponent(url)) : url)
545
      .pipe(map(res => res['meta']['total']));
546
  }
541 547
}
modules/uoa-services-library/trunk/ng-openaire-library/src/app/services/utilities.service.ts
1 1
import {Injectable} from '@angular/core';
2
import {Observable} from 'rxjs/Observable';
2
import {Observable} from 'rxjs';
3 3
import {CustomOptions} from './servicesUtils/customOptions.class';
4 4
import {HttpClient} from '@angular/common/http';
5 5

  
modules/uoa-services-library/trunk/ng-openaire-library/src/app/services/user-management.service.ts
5 5
import {map} from "rxjs/operators";
6 6
import {NavigationEnd, Router} from "@angular/router";
7 7
import {properties} from "../../../environments/environment";
8
import {el} from "@angular/platform-browser/testing/src/browser_util";
9 8
import {StringUtils} from "../utils/string-utils.class";
10 9

  
11 10
@Injectable({
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/find/searchAll.component.ts
113 113
  //new
114 114
  parameters = {};
115 115
  disableForms: boolean = true;
116
  @ViewChild (SearchResearchResultsComponent) searchResearchResultsComponent : SearchResearchResultsComponent ;
117
  @ViewChild (SearchProjectsComponent) searchProjectsComponent : SearchProjectsComponent ;
118
  @ViewChild (SearchDataProvidersComponent) searchDataprovidersComponent : SearchDataProvidersComponent ;
119
  @ViewChild (SearchOrganizationsComponent) searchOrganizationsComponent : SearchOrganizationsComponent ;
116
  @ViewChild(SearchResearchResultsComponent) searchResearchResultsComponent : SearchResearchResultsComponent ;
117
  @ViewChild(SearchProjectsComponent) searchProjectsComponent : SearchProjectsComponent ;
118
  @ViewChild(SearchDataProvidersComponent) searchDataprovidersComponent : SearchDataProvidersComponent ;
119
  @ViewChild(SearchOrganizationsComponent) searchOrganizationsComponent : SearchOrganizationsComponent ;
120 120
  constructor(private route: ActivatedRoute,
121 121
              private _router: Router,
122 122
              private _searchResearchResultsService: SearchResearchResultsService,
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchDataProviders.component.ts
75 75
  @Input() type: "all" | "registries" | "journals" | "compatible" | "deposit" = "all";
76 76
  public refineFields: string[];
77 77
  pageTitle;
78
  @ViewChild(NewSearchPageComponent) searchPage: NewSearchPageComponent;
78
  @ViewChild(NewSearchPageComponent, { static: true }) searchPage: NewSearchPageComponent;
79 79
  @Input() simpleView: boolean = true;
80 80
  @Input() simpleSearchLink: string = "";
81 81
  advancedSearchLink: string = "";
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchOrganizations.component.ts
65 65

  
66 66
  @Input() customFilter:SearchCustomFilter= null;
67 67
  public refineFields: string[] = this.searchFields.ORGANIZATION_REFINE_FIELDS;
68
  @ViewChild(NewSearchPageComponent) searchPage: NewSearchPageComponent;
68
  @ViewChild(NewSearchPageComponent, { static: true }) searchPage: NewSearchPageComponent;
69 69
  @Input() simpleView: boolean = true;
70 70
  @Input() simpleSearchLink: string = "";
71 71
  advancedSearchLink: string = "";
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchProjects.component.ts
70 70
  public pagingLimit: number = 0;
71 71
  public isPiwikEnabled;
72 72
  public refineFields: string[] = this.searchFields.PROJECT_REFINE_FIELDS;
73
  @ViewChild(NewSearchPageComponent) searchPage: NewSearchPageComponent;
73
  @ViewChild(NewSearchPageComponent, { static: true }) searchPage: NewSearchPageComponent;
74 74
  @Input() simpleView: boolean = true;
75 75
  @Input() simpleSearchLink: string = "";
76 76
  advancedSearchLink: string = "";
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchUtils/browseEntities.module.ts
2 2
import { CommonModule }        from '@angular/common';
3 3
import { FormsModule }         from '@angular/forms';
4 4
import { RouterModule } from '@angular/router';
5
import { MatSelectModule } from "@angular/material";
5
import { MatSelectModule } from "@angular/material/select";
6 6

  
7 7
import {RefineFieldResultsServiceModule} from '../../services/refineFieldResultsService.module';
8 8

  
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchUtils/entitiesSelection.component.ts
4 4
import {SearchCustomFilter} from "./searchUtils.class";
5 5
import {ConfigurationService} from "../../utils/configuration/configuration.service";
6 6
import {Router} from "@angular/router";
7
import {MatSelect} from "@angular/material";
7
import { MatSelect } from "@angular/material/select";
8 8
import {Subscription} from "rxjs";
9 9
import {properties} from '../../../../environments/environment';
10 10

  
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchUtils/searchFilter.module.ts
5 5
import {SearchFilterComponent} from './searchFilter.component';
6 6
import{SearchFilterModalComponent} from './searchFilterModal.component';
7 7
import {ModalModule} from '../../utils/modal/modal.module';
8
import {MatSelectModule} from "@angular/material";
8
import { MatSelectModule } from "@angular/material/select";
9 9
import {RouterModule} from "@angular/router";
10 10

  
11 11
@NgModule({
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchUtils/searchSorting.module.ts
4 4
import { RouterModule }       from '@angular/router';
5 5

  
6 6
import{SearchSortingComponent} from './searchSorting.component';
7
import {MatSelectModule} from "@angular/material";
7
import { MatSelectModule } from "@angular/material/select";
8 8

  
9 9
@NgModule({
10 10
  imports: [
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchUtils/dateFilter.module.ts
3 3
import { FormsModule, ReactiveFormsModule }         from '@angular/forms';
4 4
import { MyDatePickerModule } from '../../utils/my-date-picker/my-date-picker.module';
5 5
import {DateFilterComponent} from './dateFilter.component';
6
import {MatNativeDateModule, MatSelectModule} from '@angular/material';
6
import { MatNativeDateModule } from '@angular/material/core';
7
import { MatSelectModule } from '@angular/material/select';
7 8
import {MatDatepickerModule} from '@angular/material/datepicker';
8
import {MatFormFieldModule} from '@angular/material';
9
import {MatInputModule} from '@angular/material';
9
import { MatFormFieldModule } from '@angular/material/form-field';
10
import { MatInputModule } from '@angular/material/input';
10 11
@NgModule({
11 12
  imports: [
12 13
    CommonModule, FormsModule, ReactiveFormsModule, MyDatePickerModule,
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchUtils/searchResultsPerPage.module.ts
4 4
import { RouterModule }       from '@angular/router';
5 5

  
6 6
import {SearchResultsPerPageComponent} from './searchResultsPerPage.component';
7
import {MatSelectModule} from "@angular/material";
7
import { MatSelectModule } from "@angular/material/select";
8 8

  
9 9
@NgModule({
10 10
  imports: [
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchUtils/advancedSearchForm.module.ts
10 10
import {SearchFormModule} from './searchForm.module';
11 11
import {QuickSelectionsModule} from "./quick-selections.module";
12 12
import {EntitiesSelectionModule} from "./entitiesSelection.module";
13
import {MatSelectModule} from "@angular/material";
13
import { MatSelectModule } from "@angular/material/select";
14 14

  
15 15

  
16 16
@NgModule({
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchUtils/quick-selections.module.ts
3 3
import {FormsModule, ReactiveFormsModule} from '@angular/forms';
4 4
import {RouterModule} from '@angular/router';
5 5
import {QuickSelectionsComponent} from "./quick-selections.component";
6
import {MatCheckboxModule, MatSlideToggleModule} from "@angular/material";
6
import { MatCheckboxModule } from "@angular/material/checkbox";
7
import { MatSlideToggleModule } from "@angular/material/slide-toggle";
7 8
import {SearchFilterModule} from "./searchFilter.module";
8 9

  
9 10
@NgModule({
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchUtils/searchFilter.component.ts
9 9
} from '@angular/core';
10 10
import { Filter, Value} from './searchHelperClasses.class';
11 11
import {ActivatedRoute, Router} from "@angular/router";
12
import 'rxjs/add/operator/filter';
13 12
import {SearchFields} from "../../utils/properties/searchFields";
14 13
@Component({
15 14
    selector: 'search-filter',
modules/uoa-services-library/trunk/ng-openaire-library/src/app/searchPages/searchUtils/entitiesSelection.module.ts
3 3
import {FormsModule, ReactiveFormsModule} from '@angular/forms';
4 4
import {RouterModule} from '@angular/router';
5 5
import {EntitiesSelectionComponent} from "./entitiesSelection.component";
6
import {MatSelectModule} from "@angular/material";
... This diff was truncated because it exceeds the maximum size that can be displayed.

Also available in: Unified diff