Commit Graph

123 Commits

Author SHA1 Message Date
Kelly McDonald 06dedd8a32 Add short_title to study, change update_study task to use kw arguments and add the short_title to the update_study script 2021-03-02 10:03:53 -05:00
Dan Funk 3e0541fa15
Merge pull request #250 from sartography/206-extend-study-access
206 extend study access
2021-03-01 14:55:38 -05:00
mike cullerton 5c3d791bf3 UVA asked us to remove the extra whitespace in emails.
We removed the string replacement of '\n' -> '<br>' to solve this.
This means you can't purposely add blank lines any more.
Trade offs.
2021-02-25 11:08:08 -05:00
Kelly McDonald f592a8a0b0 Added a few more tests - I think I need to test one more script endpoint 2021-02-25 09:07:46 -05:00
Kelly McDonald 9bd3aa8dcb service and scripts with working test - still needs a few more tests to try out, but should work to get Mike going 2021-02-24 12:55:23 -05:00
Kelly McDonald c795dd7aea Merge branch 'dev' into 206-extend-study-access 2021-02-24 12:16:35 -05:00
Kelly McDonald 3dbe39c6fe initial checkin of changes for branch 2021-02-24 12:05:06 -05:00
Dan Funk 53fa49e668
Merge pull request #243 from sartography/183-remove-study-approval-code
Remove Approvals per ticket 183
2021-02-22 18:12:02 -05:00
Kelly McDonald 003bf2f9b9 Remove Approvals per ticket 183 2021-02-16 09:05:29 -05:00
mike cullerton d8bd203139 The email script was failing validation because of missing parameters in scripts.email.do_task_validate_only.
I added a test in tests.test_email_script to make sure we get the default email_address.
I also found and fixed a bug in workflow_service.populate_form_with_random_data where we would overwrite default_values with random text because of a missing continue.
(We don't want to continue if we have repeating fields though.)
2021-02-11 15:36:12 -05:00
mike cullerton d7a3afe8f4 changed the template to use the responsive html email template at https://github.com/leemunroe/responsive-html-email-template
added method get_cr_connect_wrapper to render our new html email template. This takes the email text generated from the task element documentation as the email_body.
2021-01-27 17:12:03 -05:00
mike cullerton 909af9b8d6 Change HTML emails so they look like the CR-Connect website. Add logo, color, style, etc.
Cleaned up email script a little.
Also, email script no longer uses services.mails. It uses email_service directly now.
2021-01-26 09:19:28 -05:00
mike cullerton 0c47d09972 Ticket 143. Test whether file is uploaded. 2021-01-04 10:53:21 -05:00
Dan Funk 386feddeed
Merge pull request #214 from sartography/validate-hide-expression-103
Modified study_info do_task_validate_only so that we take the default…
2020-12-31 10:53:27 -05:00
Dan efdbbcbc72 StudyInfo sometimes returns arrays of items, each item in the array should be coverted to a Box dictionary if possible. 2020-12-30 14:51:51 -05:00
mike cullerton f29429f0d0 Modified study_info do_task_validate_only so that we take the default path in ind_update workflow. 2020-12-30 10:04:10 -05:00
Dan e5a38874f6 A hard or soft reset should also cause a 'cancel_notify' which will kick off any CANCEL events. If this happens during
a hard or soft reset, and an error is thrown trying to fulfil a cancel event, the reset should still fire.
Sending emails still had a number of issues correctly parsing it's arguments.  This is corrected.
2020-12-29 18:05:13 -05:00
Dan Funk e54404e424
Merge pull request #205 from sartography/test-email-script
Test email script
2020-12-14 11:28:14 -05:00
mike cullerton 7defc2b02f Tests for uid in logs. Currently we test for uid in a response. This covers ApiError.
Currently, we don't have a test for Sentry. Unsure how to do this.
Also added a script, service and test workflow to help. (Also to learn about adding a script and service.)
2020-12-11 17:47:53 -05:00
mike cullerton 32c5060a31 No longer use eval on the email address. It is already parsed.
Tests for single and multiple emails, and email error checking.
Still need to figure out how to implement multiple emails.
2020-12-09 12:11:46 -05:00
mike cullerton 730d0ca18f Email script now uses an email address instead of a UVA LDAP user_id. 2020-12-07 16:23:41 -05:00
Dan b83ab1bcd1 Move data store base into its own file. 2020-11-18 15:34:50 -05:00
Kelly McDonald 70425eee0d Add last_updated field - change the api signature to be closer to what we need going forward, but retain the old methods for testing the script get/set through the API 2020-11-13 12:03:29 -05:00
Kelly McDonald 7c2c725840 save before changing how API works 2020-11-13 09:58:21 -05:00
Kelly McDonald 9a4d167dcd Add in api changes 2020-11-11 09:44:58 -05:00
Kelly McDonald cef221be32 Refactor to reuse code 2020-11-10 11:32:59 -05:00
Kelly McDonald 3ba11f5e6b add user_data_get/set and alter test so that it ensures that we don't grab study_data stuff from the user_data calls
change the test to mock up the user.
2020-11-10 10:32:37 -05:00
Kelly McDonald 245124779e Add mostly-working elements of the data-store, compare with dev to see why db is not working after running tests 2020-11-10 08:21:46 -05:00
Kelly McDonald e598994d34 Change the study_sponsors script so that we can actually call it :
var = study_info('sponsors')

to keep it more in line with other scripts that we have
2020-11-05 10:31:47 -05:00
Kelly McDonald 2931f45187 Add 'sponsors' to study_info call 2020-11-04 14:34:10 -05:00
Dan Funk b544334f45 1. Updating Personnel BPMN diagram to debug some issues.
2. Disabling the token timeout for now, to see if this corrects the issues Alex is having with lost work.
3. Raising more thoughtful error messages for unknown lookup options.
4. Providing better validation of default values and injecting the correct value for defaults related to enum lists of all types.
5. Bumping Spiffworkflow library which contains some better error messages and checks.
2020-09-01 15:58:50 -04:00
Dan Funk 5be35e8bab Adding a study sponsors script to return details about study sponsors 2020-08-25 10:30:46 -04:00
Dan Funk 8f5488d910 Don't raise an error when validating workflows that use the ldap script. 2020-08-17 15:45:37 -04:00
Dan Funk c12e2b97f3 calling ldap with no argument will return information about the current user. 2020-08-13 21:09:52 -04:00
Dan Funk e8067fe34e adding additional data to the study details returned during validation/shield testing. 2020-08-12 17:04:59 -04:00
Aaron Louie c25536dcca Makes Sonar happy. 2020-08-04 16:42:35 -04:00
Aaron Louie 2846bf9451 Fleshes out fake PB response, so workflows that pull from PB actually trigger validation errors 2020-08-04 15:50:29 -04:00
Dan Funk 9704cbcb26 Modifications to the ldap scripts to bring them back in line with what Kelly is doing with the evaluation process. 2020-07-30 13:35:20 -04:00
Dan Funk a6ec0c92c7 Merge remote-tracking branch 'origin/dev' into cr-connect-106-augment-eval-methods 2020-07-30 11:38:47 -04:00
Dan Funk 2905fc6173 Merge branch 'feature/ldap_lookup_script' of github.com:sartography/cr-connect-workflow into feature/ldap_lookup_script 2020-07-30 11:17:48 -04:00
Kelly McDonald d617af8565 All tests are passing - may need to refactor a bit, / remove comments 2020-07-28 11:02:49 -04:00
Kelly McDonald cc55aed89c Change exception name 2020-07-27 12:18:28 -04:00
Kelly McDonald a124e13c6a Replace all legacy style calls with new calls.
Still having issues where we try to eval an empty definition, not quite sure why there is a difference from what we had before. I may need to revert some of it and determine what is going on.
2020-07-24 14:33:24 -04:00
Kelly McDonald f5ab283538 Test of adding in the ability of augmenting the workflow to include internal scripts like StudyInfo
This is the first waypoint on a larger effort to make all of the 'special scripts' that currently require a shebang to be just another python function.
2020-07-24 12:08:46 -04:00
Carlos Lopez 41cbce8e01 Updating bpmn test 2020-07-21 21:08:08 -06:00
Carlos Lopez 522f848682 Addressing feedback 2020-07-21 20:54:03 -06:00
Carlos Lopez 313770d538 Ldap lookup script 2020-07-21 20:54:03 -06:00
Carlos Lopez a39cacdf00 Ldap lookup script 2020-07-19 21:53:18 -06:00
Dan Funk 6c6c5d315d Fixing a stupid mistake where I used an unquoted value in the mock data for validation, which created a dict that could not be serilized. 2020-07-16 13:28:00 -04:00
Dan Funk 419c05e46c
Merge branch 'dev' into fix/more-info-in-exceptions 2020-07-06 12:51:24 -04:00