banda-health / openmrs-module-openhmis.plm Goto Github PK
View Code? Open in Web Editor NEWThe OpenHMIS Persistent List Manager Module
The OpenHMIS Persistent List Manager Module
Admin pages to add/edit/delete lists and list items.
This method should return a PersistentList object by key only, if the list is not found it should throw an exception. This will allow modules that don't care what the implementation type is to get a list by name only.
Need to determine how best to test types that rely on the database. I don't think the DB calls should be mocked, but can we rely on a test DB or should the creation of it be part of the test.
The tests currently do not run when the 'clean install' actions are executed. They should be.
Getting this error when attempting to load the module service:
Unable to refresh the WebApplicationContext
Error creating bean with name 'serviceContext$child#16' defined in URL [jar:file:/C:/Users/akmad/AppData/Local/Temp/1342526793904.openmrs-lib-cache/openhmis-plm/lib/openhmis-plm-api-0.5-SNAPSHOT.jar!/moduleApplicationContext.xml]: Cannot create inner bean 'org.openmrs.module.openhmis.plm.impl.PersistentListServiceImpl#52259927' of type [org.openmrs.module.openhmis.plm.impl.PersistentListServiceImpl] while setting bean property 'moduleService' with key [1]; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'org.openmrs.module.openhmis.plm.impl.PersistentListServiceImpl#52259927' defined in URL [jar:file:/C:/Users/akmad/AppData/Local/Temp/1342526793904.openmrs-lib-cache/openhmis-plm/lib/openhmis-plm-api-0.5-SNAPSHOT.jar!/moduleApplicationContext.xml]: Unsatisfied dependency expressed through constructor argument with index 0 of type [org.openmrs.module.openhmis.plm.PersistentListServiceProvider]: Could not convert constructor argument value of type [java.lang.String] to required type [org.openmrs.module.openhmis.plm.PersistentListServiceProvider]: Failed to convert value of type 'java.lang.String' to required type 'org.openmrs.module.openhmis.plm.PersistentListServiceProvider'; nested exception is java.lang.IllegalStateException: Cannot convert value of type [java.lang.String] to required type [org.openmrs.module.openhmis.plm.PersistentListServiceProvider]: no matching editors or conversion strategy found
org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveInnerBean(BeanDefinitionValueResolver.java:281)
The DatabaseServiceProviderTest removeList test should check that there is a list with the specified key before removing it. There should also be another list in the table to ensure that only the specified list is removed.
The service tests that rely on a properly configured Spring sub-system are not working.
The Liquibase format seems to be more flexible and implicitly supports rolling back changes.
Currently, an item can only be added to the end of a list. There needs to be at least interface-level support for inserting an item to an arbitrary location within the list. List implementations can choose to not support this but the Queue and Stack lists should support it.
Previously had errors with creating the FK's, now it appears to be trying to create tables that already exist.
Current Error Information:
ModuleFactory.startModuleInternal(603) |2012-07-17 14:22:16,491| Error while trying to start module: openhmis-plm
org.openmrs.module.ModuleException: Unable to update data model using liquibase.xml. Module: OpenHMIS Persistent List Manager Module
at org.openmrs.module.ModuleFactory.runLiquibase(ModuleFactory.java:774)
at org.openmrs.module.ModuleFactory.startModuleInternal(ModuleFactory.java:547)
at org.openmrs.api.context.Daemon$1.run(Daemon.java:57)
Caused by: liquibase.exception.MigrationFailedException: Migration failed for change set liquibase.xml::openhmis.plm-2012-07-05-15:03::ibewes:
Reason: liquibase.exception.DatabaseException: Error executing SQL CREATE TABLE plm_list
(id
INT AUTO_INCREMENT NOT NULL, key
VARCHAR(250) NOT NULL, list_provider
VARCHAR(500) NOT NULL, description
VARCHAR(500) NULL, date_created
DATETIME NOT NULL, CONSTRAINT PK_PLM_LIST
PRIMARY KEY (id
), UNIQUE (key
)): Table 'plm_list' already exists:
Caused By: Error executing SQL CREATE TABLE plm_list
(id
INT AUTO_INCREMENT NOT NULL, key
VARCHAR(250) NOT NULL, list_provider
VARCHAR(500) NOT NULL, description
VARCHAR(500) NULL, date_created
DATETIME NOT NULL, CONSTRAINT PK_PLM_LIST
PRIMARY KEY (id
), UNIQUE (key
)): Table 'plm_list' already exists:
Caused By: Table 'plm_list' already exists
These tests should be added for the PersistentListServiceImpl and PersistentListBase.
Custom lists may have some type of ordering that does not work with just a single integer value (for example, a priority queue). While the absolute order must be maintained in the item_order column, to properly load a custom list from the database the list should be able to save some custom order information in the database.
While the SQL scripts to create the required database tables have been created, the hibernate mapping file to map between the DB and objects has not yet been created.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.