Skip to content
GitLab
  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • Genesys Backend Genesys Backend
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 26
    • Issues 26
    • List
    • Boards
    • Service Desk
    • Milestones
  • Deployments
    • Deployments
    • Releases
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Genesys PGR
  • Genesys BackendGenesys Backend
  • Issues
  • #289
Closed
Open
Created Jul 25, 2018 by Matija Obreza@mobrezaOwner

Keep average PDCI in FaoInstitute

Maintain average PDCI score in FaoInsitute entity.

Add Double fields pdciMin, pdciMax, pdciAvg to FaoInstitute (update liquibase).

These values should be updated in the org.genesys2.server.service.worker.AccessionCounter method process:

FaoInstitute institute = instituteService.findInstitute(forProcessing.getObj());
if (institute != null) {
	LOG.info("Updating count for {}", institute.getCode());
	genesysService.updateAccessionCount(institute);
        // Add
	genesysService.updatePDCI(institute);
}

Implement method genesysService.updatePDCI(FaoInstitute) based on genesysService.statisticsPDCI(FaoInstitute).

Remove method genesysService.statisticsPDCI(FaoInstitute) and refactor code to use the numbers stored in FaoInstitute entity. This means fix the code in genesysService.statisticsPDCI(Organization) -- just use numbers from the entity, don't query the database. You will need to use institute.accessionCount instead of (Long) overall[3] (which contains the count).

Update mvc.AccessionController and remove the call to statisticsService, use values from institute in the JSP.

Edited Jul 26, 2018 by Matija Obreza
Assignee
Assign to
Time tracking