Correctly parsing the datasources
This commit is contained in:
parent
9ca226a0b8
commit
34bb58c60a
|
@ -56,13 +56,13 @@ public class RepositoryController {
|
|||
produces = MediaType.APPLICATION_JSON_VALUE)
|
||||
@ResponseBody
|
||||
@PreAuthorize("hasRole('ROLE_ADMIN')")
|
||||
public List<RepositorySnippet> searchRegisteredRepositories(@RequestParam("country") String country,
|
||||
@RequestParam("typology") String typology,
|
||||
@RequestParam("englishName") String englishName,
|
||||
@RequestParam("officialName") String officialName,
|
||||
public List<RepositorySnippet> searchRegisteredRepositories(@RequestParam(name="country", required=false) String country,
|
||||
@RequestParam(name="typology", required=false) String typology,
|
||||
@RequestParam(name="englishName", required=false) String englishName,
|
||||
@RequestParam(name="officialName", required=false) String officialName,
|
||||
@RequestParam("requestSortBy") String requestSortBy,
|
||||
@RequestParam("order") String order,
|
||||
@PathVariable("page)") int page,
|
||||
@PathVariable("page") int page,
|
||||
@PathVariable("size") int pageSize) throws Exception {
|
||||
|
||||
return repositoryService.searchRegisteredRepositories(country, typology, englishName, officialName, requestSortBy, order, page, pageSize);
|
||||
|
|
|
@ -0,0 +1,51 @@
|
|||
package eu.dnetlib.repo.manager.domain;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
public class Organization implements Serializable {
|
||||
private String country;
|
||||
private String legalname;
|
||||
private String websiteurl;
|
||||
private String legalshortname;
|
||||
private String logourl;
|
||||
|
||||
public String getCountry() {
|
||||
return country;
|
||||
}
|
||||
|
||||
public void setCountry(String country) {
|
||||
this.country = country;
|
||||
}
|
||||
|
||||
public String getLegalname() {
|
||||
return legalname;
|
||||
}
|
||||
|
||||
public void setLegalname(String legalname) {
|
||||
this.legalname = legalname;
|
||||
}
|
||||
|
||||
public String getWebsiteurl() {
|
||||
return websiteurl;
|
||||
}
|
||||
|
||||
public void setWebsiteurl(String websiteurl) {
|
||||
this.websiteurl = websiteurl;
|
||||
}
|
||||
|
||||
public String getLegalshortname() {
|
||||
return legalshortname;
|
||||
}
|
||||
|
||||
public void setLegalshortname(String legalshortname) {
|
||||
this.legalshortname = legalshortname;
|
||||
}
|
||||
|
||||
public String getLogourl() {
|
||||
return logourl;
|
||||
}
|
||||
|
||||
public void setLogourl(String logourl) {
|
||||
this.logourl = logourl;
|
||||
}
|
||||
}
|
|
@ -8,8 +8,10 @@ public class RepositorySnippet implements IsSerializable {
|
|||
private String officialname;
|
||||
private String englishname;
|
||||
private String websiteurl;
|
||||
private String typology;
|
||||
private String registeredby;
|
||||
|
||||
private Organization[] organizations;
|
||||
private String registrationdate;
|
||||
|
||||
public RepositorySnippet() {}
|
||||
|
||||
|
@ -52,4 +54,28 @@ public class RepositorySnippet implements IsSerializable {
|
|||
public void setRegisteredby(String registeredby) {
|
||||
this.registeredby = registeredby;
|
||||
}
|
||||
|
||||
public String getTypology() {
|
||||
return typology;
|
||||
}
|
||||
|
||||
public void setTypology(String typology) {
|
||||
this.typology = typology;
|
||||
}
|
||||
|
||||
public Organization[] getOrganizations() {
|
||||
return organizations;
|
||||
}
|
||||
|
||||
public void setOrganizations(Organization[] organizations) {
|
||||
this.organizations = organizations;
|
||||
}
|
||||
|
||||
public String getRegistrationdate() {
|
||||
return registrationdate;
|
||||
}
|
||||
|
||||
public void setRegistrationdate(String registrationdate) {
|
||||
this.registrationdate = registrationdate;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue