Aaron Louie
f177e33ad6
Tiny tweak
2020-03-11 15:31:23 -04:00
Aaron Louie
3262833102
Requires login
2020-03-11 15:27:22 -04:00
Aaron Louie
e977ee9e0d
Updates task counts when getting workflow
2020-03-11 15:16:42 -04:00
Aaron Louie
bbfe9291e0
Adds endpoint to get workflow stats. Adds a test for the endpoint.
2020-03-11 14:28:53 -04:00
Aaron Louie
be17c2159c
Adds workflow stats and task events models and schemas. Updates workflow stats and logs task completion when task data is updated.
2020-03-10 21:29:57 -04:00
Aaron Louie
f1b6718068
Adds task counts
2020-03-10 15:46:14 -04:00
Dan Funk
e91d7aff2f
Fixes #11 : adding a delete endpoint for studies. It won't delete studies that have workflows, you have to delete those first)
...
Removing the "default" error response from the api.yml, it was all noise.
2020-03-09 15:12:40 -04:00
Dan Funk
95750d4fb0
Merge branch 'feature/pb_services' of github.com:sartography/cr-connect-workflow into feature/pb_services
2020-03-09 12:41:42 -04:00
Dan Funk
3b39f3875d
Fix data being over-written in the study_info.
2020-03-09 12:41:35 -04:00
Aaron Louie
acad0023d2
Fixes a bug in get_study_workflows and adds a test covering it
2020-03-06 10:52:41 -05:00
Dan Funk
9fcd6f38f4
Merge remote-tracking branch 'origin/master' into feature/pb_services
2020-03-05 17:13:41 -05:00
Dan Funk
e501fb31fd
Cleaning up swagger docs.
2020-03-05 17:10:00 -05:00
Dan Funk
906bacff6a
Expose a flag on the workflow model in the api to shown if it is using the latest spec. Added a soft_reset and hard_reset onto the workflow endpoint that will allow you to cause a hard or soft reset.
2020-03-05 16:45:44 -05:00
Dan Funk
7b21b78987
Workflow Processor will deserialize workflows using the version of the BPMN files used during creation, but allows for both a soft and hard reset - soft resets will use the new workflow without a restart and will retain full history. A hard-reset will restart the workflow from scratch, but will retain the data from the last completed task. Workflows have a complex version number associated with them that is used during the deserialization to find the correct files.
2020-03-05 15:38:30 -05:00
Aaron Louie
e07ad8d21c
Updates training session BPMN files. Fixes PB status enums.
2020-03-05 14:21:03 -05:00
Dan Funk
697d930eab
Modify the workflow processor to accept a workflow model - so it can take on more of the responsibilities of updating this model and managing versions.
...
Changing the version information so that it includes the numbers of the files used to generate the serialized workflow.
2020-03-05 13:25:28 -05:00
Dan Funk
70611e2c1d
Adding the version of the specification used to create a workflow to the workflow api endpoint. Though the exact content of this version is likely to change.
...
Split the API specific models out from the workflow models to help me keep this straight.
Added tests to help me understand the errors thrown the and resolution path when a workflow specification changes in the midst of a running workflow.
2020-03-05 11:18:20 -05:00
Dan Funk
78b6f040eb
Add the ability to forcibly restart a workflow, while retaining that workflows data.
...
A workflow specification knows it's version number, which is generated by the version of the files that make it up.
A workflow specification version number is the primary file (the lead BPMN) followed by a consistency ordered version each extra file associated with the workflow. A change in any file modifies the specifications version.
2020-03-04 17:08:45 -05:00
Dan Funk
c5cee4761e
Improve version handling of files. Consolidate more of this logic in FileService. Place the version on the actual data model, not the file model, so the file model remains the same, and we just version the data associated with it.
2020-03-04 13:40:25 -05:00
Aaron Louie
f258090a0b
Fixes broken unit test
2020-03-04 09:54:00 -05:00
Aaron Louie
8cbd6f892f
WIP: Mocks study details PB endpoint response
2020-03-03 20:56:46 -05:00
Aaron Louie
01720a8bbf
Replaces migration and fixes broken tests
2020-03-03 16:02:01 -05:00
Aaron Louie
93168482c2
Merge remote-tracking branch 'origin/master'
2020-03-03 15:46:24 -05:00
Aaron Louie
668de6c4dc
Edits Protocol Builder statuses
2020-03-03 15:46:20 -05:00
Dan Funk
94f828dfd6
Adding a simple endpoint that describes what scripts are currently available, along with a brief description.
2020-03-03 15:30:42 -05:00
Dan Funk
7194d7d374
Standardizing the script tasks that can be executed on the server, adding tons of error messages for when things go wrong. All scripts must exist in side of the crc/scripts directory.
...
Adding a new script that script tasks can use to add in data about the study.
Moving all the test workflow specifications out of the main load.
fixing a pile of tests so they can find workflow specs that are now moved into the test directory.
2020-03-03 13:52:45 -05:00
Aaron Louie
f7416065da
Merge remote-tracking branch 'origin/master'
2020-03-02 13:16:43 -05:00
Aaron Louie
a24b67d5db
Updates DSP BPMN
2020-03-02 13:16:36 -05:00
Aaron Louie
b0c4996fb3
Populates documentation.
2020-03-02 13:14:03 -05:00
Dan Funk
5e3fdaaa94
New set of "Tools" api endpoints, that provides a way to quickly render markdown or word documents by uploading json data and a template to populate.
...
Improved Error messages / Error processing. You can now just throw an APIError anywhere, and it will be properly serialized and returned.
2020-02-29 17:22:38 -05:00
Aaron Louie
5f944af0d7
Adds CR Connect training workflow specs
2020-02-28 15:39:44 -05:00
Aaron Louie
8611a23ad3
Renaming to snake case for consistency
2020-02-28 11:54:11 -05:00
Aaron Louie
f4a0c32cec
Fixes path to testing config file
2020-02-28 11:33:08 -05:00
Aaron Louie
dc53939eb1
Merge remote-tracking branch 'origin/master' into feature/protocol-builder
2020-02-28 11:17:17 -05:00
Aaron Louie
4534b0c2df
Updates study model to better match Protocol Builder. Deletes all migrations and starts over, since Alembic has problems migrating changes to existing column constraints.
2020-02-28 11:14:30 -05:00
Aaron Louie
0cc59d0974
Adds study inactive flag. Sets study to inactive if not found in Protocol Builder.
2020-02-27 11:17:58 -05:00
Aaron Louie
f3068e68db
Adds user to example data. Requires login before adding/updating a study.
2020-02-27 10:30:16 -05:00
Aaron Louie
27d7afb656
Adds Protocol Builder models and schemas. Reorganizes and cleans up some files.
2020-02-27 09:54:46 -05:00
Aaron Louie
3ef4860391
Adds user_uid and investigator_ids fields to Study. Gets studies from protocol builder and adds them if they aren't already in the database
2020-02-26 18:06:51 -05:00
Dan Funk
c6eb2d937d
Enable autoescape security feature for processing markdown data in descriptions from the BPMN Diagrams
2020-02-25 16:21:47 -05:00
Dan Funk
1e8a095760
Fixing a rogue comma that made something a tuple and not a string, which drives me CRAZY.
2020-02-25 12:01:25 -05:00
Aaron Louie
002207cbca
Adds redirect URL to login handler
2020-02-24 16:59:16 -05:00
Aaron Louie
443d38a9a1
Prevents duplication of study on update.
2020-02-21 11:24:51 -05:00
Aaron Louie
eb6354db6e
Moves sso_backdoor parameters to query string. Prevents duplication of user on update.
2020-02-21 11:24:39 -05:00
Aaron Louie
9f4301712e
Merge remote-tracking branch 'origin/master'
2020-02-20 17:23:17 -05:00
Aaron Louie
a6e0809183
Adds SSO attributes. Prevents uid duplication errors.
2020-02-20 17:23:10 -05:00
Dan Funk
d3c51af1f5
Merge branch 'master' of github.com:sartography/cr-connect-workflow
2020-02-20 16:04:44 -05:00
Dan Funk
af35f182f6
Random Fact updated with a markdown set of examples
2020-02-20 16:04:38 -05:00
Aaron Louie
0cda7c66e5
Merge remote-tracking branch 'origin/master'
2020-02-20 15:43:34 -05:00
Aaron Louie
581434b453
Adds SSO header attributes
2020-02-20 15:43:29 -05:00
Dan Funk
a94596112d
Fixing a rogue comma that made something a tuple and not a string, which drives me CRAZY.
2020-02-20 14:35:21 -05:00
Dan Funk
2cc6010c8d
Protocol builder connections
2020-02-20 13:30:04 -05:00
Dan Funk
1a9b5b50e5
Merge branch 'master' of github.com:sartography/cr-connect-workflow
2020-02-18 16:39:11 -05:00
Dan Funk
a642593e3d
Adding support to handle Single Sign On (Shibboleth) authentication using Flask SSO and an attribute map that has worked in the past with UVA's implementation. Aside from the new user endpoint, nothing requires authentication, but soon everything will expect it. I'm setting up a backdoor we can use for development and staging that will cause a round-robin affair that should make this relatively painless. Dropped "RestException" as we had two ways or raising errors, and that was silly.
2020-02-18 16:38:56 -05:00
Aaron Louie
6075a32d07
Edits default value
2020-02-18 10:17:14 -05:00
Aaron Louie
16db1e3504
Adds default_value to Task schema
2020-02-18 10:14:03 -05:00
Aaron Louie
5a53ddb88c
Fixes vulnerability identified by SonarCloud
2020-02-12 11:07:01 -05:00
Aaron Louie
5f461d9e87
Fixes FactService
2020-02-11 22:13:46 -05:00
Aaron Louie
b0b1a6e5e8
Saves form field key
2020-02-11 15:03:25 -05:00
Aaron Louie
0a3a932c50
Comments out study workflow for now. Fixes failing unit tests.
2020-02-11 13:40:14 -05:00
Aaron Louie
0ef1a178ed
Merge branch 'master' into feature/crc_demo_workflows
2020-02-11 13:30:57 -05:00
Aaron Louie
f58ed5b6ee
Adds another user task at the end
2020-02-11 12:14:10 -05:00
Dan Funk
709bae76b2
Removing a rogue comma that was causing havoc. Also, don't fail if a mock already exists in the test database.
2020-02-11 11:11:21 -05:00
Dan Funk
879a248002
Adding a test to assure the file creation occurs as expected via the API.
2020-02-10 20:54:22 -05:00
Aaron Louie
359fb4a2f3
Adds draft demo workflow specs
2020-02-10 17:19:11 -05:00
Aaron Louie
f128e7206b
Adds placeholder scripts for testing
2020-02-10 17:18:51 -05:00
Dan Funk
9f0eb8477a
Fix for a bug in the File service where it was being overly restrictive.
2020-02-10 16:27:57 -05:00
Dan Funk
1d24ebe382
Provide a script for generating word documents from template files. Refractored file managment into a service to make it easier to programatically add files. Modified the workflow_processor to inject the study_id and workflow_id into the running workflow so that this meta-information is avialable at the task level.
2020-02-10 16:19:23 -05:00
Aaron Louie
fd9c685979
Handles processes with multiple top-level elements
2020-02-10 15:20:45 -05:00
Aaron Louie
f142d02a30
Adds workflow_spec_id back in to WorkflowApi
2020-02-07 12:36:08 -05:00
Dan Funk
eae6c8dd1a
update to last commit, left an extra column on workflow model that does not need to exist.
2020-02-07 11:57:48 -05:00
Dan Funk
e1148e1b3d
Merge branch 'master' of github.com:sartography/cr-connect-workflow
2020-02-07 11:34:57 -05:00
Dan Funk
9bd93748be
Returning better cleaner information about workflow with the workflow endpoint. Removes the get_all_tasks and get_user_tasks endpoints as tasks are returned with the workflow. Workflow endpoint also includes the last task and next_task, which may or may not be user tasks. The task "type" returned is now the class name of the task_spec, rather than just the word "task".
2020-02-07 11:34:44 -05:00
Aaron Louie
9fb3a96a50
Fixes instance path
2020-02-06 14:36:02 -05:00
Aaron Louie
71dac70e1f
Updates list of allowed files. Removes unnecessary migrations. Note this will require a full wipe & reset of the database to work.
2020-02-05 17:23:37 -05:00
Aaron Louie
5a6d589e6d
Adds form_field_key to API
2020-02-05 15:06:19 -05:00
Aaron Louie
58982ab306
Merge remote-tracking branch 'origin/feature/update-task-data' into feature/update-task-data
2020-02-05 14:55:59 -05:00
Aaron Louie
933a235471
Adds multiple and single file upload form controls
2020-02-05 14:55:52 -05:00
Aaron Louie
654f39e7fd
Adds form field key to file model.
2020-02-05 14:55:31 -05:00
Dan Funk
ff63978da0
read the instance/config.py file in IF it exists.
2020-02-05 13:43:59 -05:00
Aaron Louie
e1e866a2b3
Gets docker-compose working.
...
You'll need to add a .env file to the same directory as the docker-compose.yml file that sets the values for DB_USER and DB_PASS.
2020-02-04 21:42:09 -05:00
Dan Funk
ec4df2b3fa
Cleaning up the tests and making it easier to test workflows without adding them to the example data structure.
2020-02-04 16:49:28 -05:00
Dan Funk
b1a81957ef
Merge branch 'feature/update-task-data' of github.com:sartography/cr-connect-workflow into feature/update-task-data
2020-02-04 15:45:05 -05:00
Dan Funk
9e6fbfee79
Followup on Postgres - had some failing tests that needed cleaning up now that we are using a real database.
2020-02-04 15:44:06 -05:00
Aaron Louie
3ee0426ba9
Adds workflow_id to file endpoints.
2020-02-04 14:26:53 -05:00
Aaron Louie
098ecb3e87
Wipes out old migrations, since changing foreign key constraints in SQLite requires a full database reset anyways.
2020-02-04 09:57:02 -05:00
Aaron Louie
e717c25a25
Study ID is an integer. Task ID is a string.
2020-02-03 22:29:41 -05:00
Aaron Louie
0368657549
Adds ability to get FileModel records by study and task
2020-02-03 21:56:18 -05:00
Dan Funk
8fbbed4feb
You must all "do engine steps" when completing a task so that it will kick off any automatic tasks/decisions/etc... this will update remaining tasks. Added some tests for parallel, since I wrote them trying to debug this.
2020-02-03 15:15:36 -05:00
Aaron Louie
8cc04aaad2
Adds task data to Task schema
2020-02-03 10:49:48 -05:00
Aaron Louie
e4b2a7a641
Adds endpoint to retrieve all user tasks for a workflow, regardless of state
2020-01-31 12:40:08 -05:00
Aaron Louie
8d39a96606
Adds workflow spec & BPMN with parallel tasks
2020-01-31 12:01:41 -05:00
Aaron Louie
918a6d5ab7
Removes unsupported read-only flag on File schema for now
2020-01-31 11:33:31 -05:00
Aaron Louie
a0e60ddd77
Renames endpoint methods for clarity. Adds endpoint for just updating file info.
2020-01-31 10:39:19 -05:00
Dan Funk
3fb831bae4
When you create a study, all possible workflows are then associated with that study.
2020-01-30 09:11:17 -05:00
Dan Funk
acca1523b7
adding an api call for getting a single workflow spec.
2020-01-28 10:14:06 -05:00
Aaron Louie
a3b6e4fc7f
Fixes import paths
2020-01-24 11:52:52 -05:00
Aaron Louie
50dfa561a9
Fixes import paths, which were screwing up stuff.
2020-01-24 09:29:50 -05:00
Aaron Louie
6faabea8a4
Deletes related files and workflows when a workflow spec is deleted.
2020-01-24 09:26:17 -05:00
Aaron Louie
6aa3d711ce
Adds endpoint to delete workflow spec
2020-01-23 16:05:09 -05:00
Dan Funk
45f2e52c86
Merge branch 'feature/update-task-data' of github.com:sartography/cr-connect-workflow into feature/update-task-data
2020-01-23 15:35:51 -05:00
Dan Funk
95b75f864d
You can now add multiple files to a workflow spec, and if properly linked, you can associate a DMN file with a BPMN to process decision tables.
2020-01-23 15:32:53 -05:00
Aaron Louie
91e33a1768
Deletes associated file_data records when deleting a file.
2020-01-23 12:17:58 -05:00
Aaron Louie
42fa2880d0
Adds type hint
2020-01-23 10:55:07 -05:00
Aaron Louie
7fc2e87b84
Adds primary process ID to workflow spec
2020-01-23 10:54:41 -05:00
Aaron Louie
803e4be008
Stores workflow JSON
2020-01-23 10:53:59 -05:00
Aaron Louie
fd21f4f301
Fixes breaking changes from SpiffWorkflow
2020-01-22 16:51:25 -05:00
Aaron Louie
6158243053
Fixes modify workflow method
2020-01-21 15:24:17 -05:00
Aaron Louie
c11bf3d286
Adds workflow spec name field
2020-01-21 15:22:44 -05:00
Aaron Louie
bf97095933
Adds type hinting back in
2020-01-21 15:21:33 -05:00
Dan Funk
2ffe32afdd
Merge branch 'feature/update-task-data' of github.com:sartography/cr-connect-workflow into feature/update-task-data
2020-01-14 15:40:03 -05:00
Dan Funk
900819e647
fixing failed run
2020-01-14 15:39:54 -05:00
Aaron Louie
21fe50ed08
Import api before Connexion does its thing.
2020-01-14 15:26:39 -05:00
Aaron Louie
7ce48e8deb
Removes type hinting, in case that's breaking something.
2020-01-14 15:10:43 -05:00
Aaron Louie
054bd88760
Fixes path to api methods
2020-01-14 14:55:10 -05:00
Aaron Louie
790b0dfc3a
Adds endpoint for modifying existing workflow spec
2020-01-14 14:10:53 -05:00
Aaron Louie
fe15799ee1
Adds type hinting to db and session to fix Pycharm autocomplete. Replaces db.session with session.
2020-01-14 11:45:12 -05:00
Dan Funk
6361e94af5
Allow submitting data and progressing to the next task in a workflow.
2020-01-14 11:02:44 -05:00
Aaron Louie
75881bf1d3
Adds endpoint for adding a workflow specification
2020-01-13 21:43:09 -05:00
Aaron Louie
53d72bdaae
Includes workflow spec id
2020-01-13 17:52:37 -05:00
Dan Funk
a3d7ba8114
WIP
2020-01-07 13:23:46 -05:00
Aaron Louie
872f3fca1b
Returns workflow spec id with Workflow schema
2020-01-06 09:18:13 -05:00
Aaron Louie
e75da611ca
Adds endpoints for creating and updating a Study.
2020-01-03 11:44:24 -05:00
Dan Funk
e316d02f02
Adding a missing file.
2020-01-02 12:22:15 -05:00
Dan Funk
c4cbaeb64e
Refactor models into seperate directories
2019-12-31 16:32:47 -05:00
Dan Funk
9a195bedad
Fixing some caching issues and places where the updates were not being processed completed. And updates to the docker file.
2019-12-31 11:31:30 -05:00
Dan Funk
0685b282e8
Don't put foreign key constraints on primary keys.
2019-12-30 16:00:33 -05:00
Dan Funk
115a88347f
Stupid tag
2019-12-30 13:34:18 -05:00
Dan Funk
fb465531ca
Add the ability to delete a workflow.
2019-12-30 13:15:39 -05:00
Dan Funk
b54bd49cf4
Allow for clearing out the database.
2019-12-30 13:03:57 -05:00
Dan Funk
91a91e9677
Read workflow configuration from the database, and not from a file.
...
And dropping the API call in the Fact Service so we aren't hitting external apis for the time being.
2019-12-30 11:07:26 -05:00
Dan Funk
2ac2514e32
merge conflicts
2019-12-27 13:53:29 -05:00
Dan Funk
0b71833946
Adding file management. Files are stored in the database along with basic meta data.
2019-12-27 13:50:03 -05:00
Aaron Louie
ddd0422392
Adds some fields with some Formly-specific logic
2019-12-20 15:39:40 -05:00
Aaron Louie
9b6599505d
Adds task title and documentation
2019-12-20 15:39:02 -05:00
Aaron Louie
dc13855593
Adds properties and validation to form
2019-12-20 14:32:04 -05:00
Dan Funk
bb6ab4b8e8
Tasks can have forms and they are returned correctly.
2019-12-19 11:58:51 -05:00
Dan Funk
bc9bfb658e
Merge branch 'master' of github.com:sartography/cr-connect-workflow
2019-12-18 15:32:17 -05:00
Dan Funk
0dc422c7f6
we need a commit at the end, but I don't really believe that.
2019-12-18 15:32:06 -05:00
Aaron Louie
bfff4f515a
Auto stash before merge of "master" and "origin/master"
2019-12-18 15:24:01 -05:00
Dan Funk
53a8811769
Add workflow to study
2019-12-18 15:22:46 -05:00
Dan Funk
fbbd6c6659
Adding a workflow from a spec
2019-12-18 14:42:40 -05:00
Dan Funk
a734578327
re-building migrations.
2019-12-18 14:16:26 -05:00
Dan Funk
9861f6baf3
Lots and lots of random stuff as I organize code and get things to make sense.
2019-12-18 14:02:17 -05:00