Project

General

Profile

« Previous | Next » 

Revision 61005

Added by Antonis Lempesis 5 months ago

adapted mooore queries

View differences:

data.service.ts
37 37
  }
38 38

  
39 39
  public getCountryOAData(countryCode: string): Observable<RawData> {
40
    const countryOADataQuery = `{"series":[{"query":{"name":"oso.results.oa_percentage.country", "parameters":["publication","${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.oa_percentage.country", "parameters":["dataset","${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.oa_percentage.country", "parameters":["software","${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.oa_percentage.country", "parameters":["other","${countryCode}"],"profile":"${this.profileName}"}}],"verbose":true}`;
40
    const countryOADataQuery = `{"series":[{"query":{"name":"oso.results.oa_percentage.country", "parameters":["${countryCode}","publication"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.oa_percentage.country", "parameters":["${countryCode}","dataset"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.oa_percentage.country", "parameters":["${countryCode}","software"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.oa_percentage.country", "parameters":["${countryCode}","other"],"profile":"${this.profileName}"}}],"verbose":true}`;
41 41
    return this.httpClient.get<RawData>(this.apiURL + encodeURIComponent(countryOADataQuery), headerOptions);
42 42
  }
43 43

  
......
85 85
  }
86 86

  
87 87
  public getCountryPageOverviewData(countryCode: string): Observable<RawData> {
88
    const countryPageOverviewDataQuery = `{"series":[{"query":{"name":"oso.results.oa_percentage.country", "parameters":["publication","${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.oa_percentage.deposited.country", "parameters":["publication","${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.oa_percentage.country", "parameters":["dataset","${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.oa_percentage.deposited.country", "parameters":["dataset","${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.repositories.doar_re3data.validated.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.journals.doaj.validated.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.oa_policies.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.rnd.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.funder.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.funding_organizations.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.ec_funded_organizations.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}}],"verbose":true}`;
88
    const countryPageOverviewDataQuery = `{"series":[{"query":{"name":"oso.results.oa_percentage.country", "parameters":["${countryCode}","publication"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.oa_percentage.deposited.country", "parameters":["publication","${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.oa_percentage.country", "parameters":["${countryCode}","dataset"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.oa_percentage.deposited.country", "parameters":["dataset","${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.repositories.doar_re3data.validated.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.journals.doaj.validated.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.oa_policies.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.rnd.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.funder.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.funding_organizations.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.ec_funded_organizations.country", "parameters":["${countryCode}"],"profile":"${this.profileName}"}}],"verbose":true}`;
89 89
    return this.httpClient.get<RawData>(this.apiURL + encodeURIComponent(countryPageOverviewDataQuery), headerOptions);
90 90
  }
91 91

  
......
135 135
    if (content === 'affiliated') {
136 136
      indicatorsTableDataQuery = `{"series":[{"query":{"name":"oso.results.pid_percentage.affiliated.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.licence_percentage.affiliated.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.green_percentage.affiliated.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.gold_percentage.affiliated.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}}],"verbose":true}`;
137 137
    } else if (content === 'affiliated_peer_reviewed') {
138
      indicatorsTableDataQuery = `{"series":[{"query":{"name":"oso.results.pid_percentage.affiliated.peer_reviewed.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.licence_percentage.affiliated.peer_reviewed.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.green_percentage.affiliated.peer_reviewed.bycountry","parameters":["${type}","${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.gold_percentage.affiliated.peer_reviewed.bycountry","parameters":["${type}","${type}"],"profile":"${this.profileName}"}}],"verbose":true}`;
138
      indicatorsTableDataQuery = `{"series":[{"query":{"name":"oso.results.pid_percentage.affiliated.peer_reviewed.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.licence_percentage.affiliated.peer_reviewed.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.green_percentage.affiliated.peer_reviewed.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.gold_percentage.affiliated.peer_reviewed.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}}],"verbose":true}`;
139 139
    } else if (content === 'deposited') {
140
      indicatorsTableDataQuery = `{"series":[{"query":{"name":"oso.results.pid_percentage.deposited.bycountry","parameters":["${type}","${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.licence_percentage.deposited.bycountry","parameters":["${type}","${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.green_percentage.deposited.bycountry","parameters":["${type}","${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.gold_percentage.deposited.bycountry","parameters":["${type}","${type}"],"profile":"${this.profileName}"}}],"verbose":true}`;
140
      indicatorsTableDataQuery = `{"series":[{"query":{"name":"oso.results.pid_percentage.deposited.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.licence_percentage.deposited.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.green_percentage.deposited.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.gold_percentage.deposited.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}}],"verbose":true}`;
141 141
    } else if (content === 'deposited_peer_reviewed') {
142
      indicatorsTableDataQuery = `{"series":[{"query":{"name":"oso.results.pid_percentage.deposited.peer_reviewed.bycountry","parameters":["${type}","${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.licence_percentage.deposited.peer_reviewed.bycountry","parameters":["${type}","${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.green_percentage.deposited.peer_reviewed.bycountry","parameters":["${type}","${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.gold_percentage.deposited.peer_reviewed.bycountry","parameters":["${type}","${type}"],"profile":"${this.profileName}"}}],"verbose":true}`;
142
      indicatorsTableDataQuery = `{"series":[{"query":{"name":"oso.results.pid_percentage.deposited.peer_reviewed.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.licence_percentage.deposited.peer_reviewed.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.green_percentage.deposited.peer_reviewed.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}},{"query":{"name":"oso.results.gold_percentage.deposited.peer_reviewed.bycountry","parameters":["${type}"],"profile":"${this.profileName}"}}],"verbose":true}`;
143 143
    }
144 144
    return this.httpClient.get<RawData>(this.apiURL + encodeURIComponent(indicatorsTableDataQuery), headerOptions);
145 145
  }

Also available in: Unified diff