Commit Graph

8 Commits

Author SHA1 Message Date
Alexis Degrugillier
d229216ccc Split the search into values
Before, the search was a single value.
Now it is splited in chuncks when separated by spaces.
Except if they are enclosed by single quotes or double quotes.

For some reasons, the unit tests are working for both single and double quotes but the
search box isn't. It is working only with single quotes.
We need to investigate the reason of this behavior.

See #823
2015-04-22 00:24:22 -04:00
Alexis Degrugillier
96d5d9d034 Fix DAO exception
Change the name and messages
2015-03-05 13:29:41 +01:00
Alexis Degrugillier
5b90e1f4a0 Introduce user queries objects
There is now an object to manipulate user queries. It allows to move logic to handle those from the view and the controller in the model.
Thus making the view and the controller easier to read.
I introduced a new interface to start using dependency injection. There is still some rough edges but we are moving in the right direction.
The new object is fully tested but it still need some improvements, for instance, it is still tied to the search object.
There might be a better way to do that.
2015-03-05 13:29:41 +01:00
Alexis Degrugillier
50b6a02578 Add search default raw value
Before, the default value was undefined. Now it always has a value even when no value is provided.
2015-02-21 09:46:25 -05:00
Alexis Degrugillier
964e67d4a4 Add a test to verify if the search input is stored correctly 2015-02-12 21:08:37 -05:00
Alexis Degrugillier
f30ded2f86 Extract the search code from the context
I figured that the code for the search could be extracted from the context to have separation of concern.
It supports multiple keywords. It suports also multiple tag keywords.
2015-02-11 21:49:21 -05:00
Alexis Degrugillier
4bb8548ecc Add a way to parse search string to extract keywords
This feature is not in use at the moment, but it will be handy to reorganize the query building process. It allows to have more than one keyword in the search box.
Full tests are available as well.

It probably needs a refactoring later, but I think this is the first step to make the application full object oriented and testable.
2015-02-08 20:53:36 -05:00
Alexis Degrugillier
b17cdadf15 Add the first unit test
Add phpunit configuration to run tests and add the first running test to validate the configuration
2015-01-17 10:42:24 -05:00