Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dev/core#561 Convert grant search fields to use datepicker #13211

Merged
merged 2 commits into from
Jan 10, 2019

Conversation

eileenmcnaughton
Copy link
Contributor

@eileenmcnaughton eileenmcnaughton commented Dec 2, 2018

Overview

Converts grant date search date files to use jcalendar

Before

screenshot 2018-12-03 11 28 34

After

screenshot 2018-12-03 11 36 29

Technical Details

#13210 is a pre-requisite

Takes some of the approach form #13013 (leaving out the default handling part & with some tweaks)

Comments

The grant fields are actually date fields not datetime - which would be more appropriate IMHO - so the change from date+time to date is appropriate here.

@civibot
Copy link

civibot bot commented Dec 2, 2018

(Standard links)

@civibot civibot bot added the master label Dec 2, 2018
@eileenmcnaughton eileenmcnaughton changed the title Search grant dev/core#561 Convert grant search fields to use datepicker Dec 2, 2018
@eileenmcnaughton
Copy link
Contributor Author

@seamuslee001 ping

@seamuslee001
Copy link
Contributor

Ok will look shortly @eileenmcnaughton

@seamuslee001
Copy link
Contributor

@eileenmcnaughton can you rebase this now pls

@seamuslee001
Copy link
Contributor

@eileenmcnaughton i note that in the change we have lost the date not set checkbox, is that a specific thing your changing here?

@eileenmcnaughton
Copy link
Contributor Author

@seamuslee001 that checkbox seems to achieve the same thing as the little x you get with datepicker

@seamuslee001
Copy link
Contributor

@eileenmcnaughton i think there is actually a functional difference because a clear date picker box means include dates and rows with no dates whereas looking at the implementation of a checkbox it looks like its about actually querying that the column is NULL https://github.com/civicrm/civicrm-core/pull/13211/files#diff-f5e872367f13e067d643ef634b73ba14R136

@eileenmcnaughton
Copy link
Contributor Author

@seamuslee001 OK - I've returned the ugliness

@seamuslee001
Copy link
Contributor

@eileenmcnaughton do we need to worry about smart groups built off this form?

@eileenmcnaughton
Copy link
Contributor Author

@seamuslee001 argh - is that possible?

@seamuslee001
Copy link
Contributor

@eileenmcnaughton not sure just assumed that it was the case with searches maybe not maybe only limited to contact based searches

@seamuslee001
Copy link
Contributor

seamuslee001 commented Dec 3, 2018

(CiviCRM Review Template WORD-1.2)

  • General standards
    • (r-explain) Pass
    • (r-user) Pass
    • (r-doc) Pass
    • (r-run) unknown Tested the grant search form and confirmed that the change works, Advanced Search Grants panel form has broken tho
  • Developer standards

@seamuslee001
Copy link
Contributor

@eileenmcnaughton It looks like we have broken the tab on Advanced Search tho for grants

@eileenmcnaughton eileenmcnaughton force-pushed the search_grant branch 3 times, most recently from ac4397a to fb178bc Compare December 4, 2018 10:39
@eileenmcnaughton
Copy link
Contributor Author

@seamuslee001 I looked a bit further & the date range stuff uses jcalendar :-( - worse it's used in lots of places. My currently thinking is that it's best to mature an approach for switching across (& for handling smart group data) before replacing instances elsewhere - as a bit of an 'unloved corner' grant feels like a good place to develop this approach - I've tinkered a little here but it is not complete from a formatting pov, a post process pov or a conversion pov.

@eileenmcnaughton eileenmcnaughton force-pushed the search_grant branch 3 times, most recently from b972b26 to 1765248 Compare December 4, 2018 10:50
@JoeMurray
Copy link
Contributor

Tested on dmaster and functionally looks fine on Find Grants and on Advanced Search, including creating a Smart Group.

@monishdeb could you put in some love on this PR to advance the formatting, post process and conversion areas that @eileenmcnaughton mentions? I hope looking at the code the meaning of her points becomes clearer.

@eileenmcnaughton eileenmcnaughton force-pushed the search_grant branch 2 times, most recently from e1be97f to e897889 Compare January 4, 2019 03:56
@eileenmcnaughton
Copy link
Contributor Author

@seamuslee001 I've fixed this up & I'm happy it's working as far as it goes. I've decided to remove the patch that does the 'in-form' conversion in favour of an upgrade conversion & am working on that as a separate patch

@seamuslee001
Copy link
Contributor

I tested this along with #13395 and confirmed that an existing smart group creating from the date fields on grant forms are changed correctly and the new form works well. I think we should merge this and the Routine one and then look through some of the others @colemanw @monishdeb

@eileenmcnaughton
Copy link
Contributor Author

thanks @seamuslee001 I think it woud be good if once this is merged someone could attempt the campaign search form & try to apply similar methodology where possible

@colemanw
Copy link
Member

colemanw commented Jan 8, 2019

Thanks for the testing @seamuslee001. I left a note for @eileenmcnaughton on the other PR and will merge both once that's resolved.

@colemanw colemanw merged commit 237f449 into civicrm:master Jan 10, 2019
@colemanw colemanw deleted the search_grant branch January 10, 2019 02:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants