From 577e8950acc58c65decf717d16260548488cc8f4 Mon Sep 17 00:00:00 2001 From: Sahil Malhotra <88040167+smalho01@users.noreply.github.com> Date: Thu, 3 Mar 2022 07:35:57 -0500 Subject: [PATCH] Revert "Fork Auto Sync" --- .dockerignore | 4 ++ .github/auto_assign.yml | 15 +++++++ .github/workflows/ForkSync.yml | 22 ++++++++++ .github/workflows/docker-cd.yml | 2 +- .../QuestionnaireForm/QuestionnaireForm.jsx | 43 +++++++++++-------- 5 files changed, 68 insertions(+), 18 deletions(-) create mode 100644 .dockerignore create mode 100644 .github/auto_assign.yml create mode 100644 .github/workflows/ForkSync.yml diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 00000000..65d599df --- /dev/null +++ b/.dockerignore @@ -0,0 +1,4 @@ +.git +node_modules +logs +databaseData \ No newline at end of file diff --git a/.github/auto_assign.yml b/.github/auto_assign.yml new file mode 100644 index 00000000..fb672fb5 --- /dev/null +++ b/.github/auto_assign.yml @@ -0,0 +1,15 @@ +# Set to true to add reviewers to pull requests +addReviewers: true + +# Set to true to add assignees to pull requests +addAssignees: false + +# A list of reviewers to be added to pull requests (GitHub user name) +reviewers: + - zacharyrobin + - kierk + - KeeyanGhoreshi + - smalho01 + +# A number of reviewers added to the pull request, Set to 0 to add all reviewers +numberOfReviewers: 0 diff --git a/.github/workflows/ForkSync.yml b/.github/workflows/ForkSync.yml new file mode 100644 index 00000000..bb1ca4cc --- /dev/null +++ b/.github/workflows/ForkSync.yml @@ -0,0 +1,22 @@ +name: Sync Fork + +on: + schedule: + - cron: '30 14 * * 1' # every Monday at 14:30 UCT + workflow_dispatch: # on button click for manual testing + +jobs: + sync: + + runs-on: ubuntu-latest + + steps: + - uses: tgymnich/fork-sync@v1.4 #1.4 is stable but may need to be updated + with: + owner: HL7-DaVinci + base: master # Upstream + head: master # local + ignore_fail: true + auto_merge: false + pr_title: Fork Auto Sync + pr_message: Upstream repository has been updated - Please review changes diff --git a/.github/workflows/docker-cd.yml b/.github/workflows/docker-cd.yml index 229cebb3..226d1fe1 100644 --- a/.github/workflows/docker-cd.yml +++ b/.github/workflows/docker-cd.yml @@ -23,4 +23,4 @@ jobs: with: context: . push: true - tags: smalho01234/dtr:latest + tags: codexrems/dtr:REMSvlatest diff --git a/src/components/QuestionnaireForm/QuestionnaireForm.jsx b/src/components/QuestionnaireForm/QuestionnaireForm.jsx index 0d1c96c0..e59f7405 100644 --- a/src/components/QuestionnaireForm/QuestionnaireForm.jsx +++ b/src/components/QuestionnaireForm/QuestionnaireForm.jsx @@ -1010,17 +1010,6 @@ export default class QuestionnaireForm extends Component { } // For HIMSS Demo with Mettle always use GCS as payor info - const insurer = { - resourceType: "Organization", - id: "org1234", - name: "GCS", - identifier: [ - { - system: "urn:ietf:rfc:3986", - value: "2.16.840.1.113883.13.34.110.1.150.2" - } - ] - }; const managingOrg = { resourceType: "Organization", id: "org1111", @@ -1064,7 +1053,6 @@ export default class QuestionnaireForm extends Component { if (priorAuthBundle && this.isPriorAuthBundleValid(priorAuthBundle)) { priorAuthBundle.entry.unshift({ resource: managingOrg }); priorAuthBundle.entry.unshift({ resource: facility }); - priorAuthBundle.entry.unshift({ resource: insurer }); priorAuthBundle.entry.unshift({ resource: this.props.deviceRequest }); priorAuthBundle.entry.unshift({ resource: qr }); @@ -1096,9 +1084,6 @@ export default class QuestionnaireForm extends Component { // TODO: make this organization reference: this.makeReference(priorAuthBundle, "Practitioner") }, - insurer: { - reference: this.makeReference(priorAuthBundle, "Organization") - }, facility: { reference: this.makeReference(priorAuthBundle, "Location") }, @@ -1177,6 +1162,19 @@ export default class QuestionnaireForm extends Component { } ] }; + + const signature = { + resourceType: "Signature", + type: [ + { + system: "urn:iso-astm:E1762-95:2013", + code: "1.2.840.10065.1.12.1.14", + display: "Source Signature" + } + ], + when: new Date(Date.now()).toISOString(), + who: this.makeReference(priorAuthBundle, "Practitioner") + } var sequence = 1; priorAuthBundle.entry.forEach(function (entry, index) { if (entry.resource.resourceType == "Condition") { @@ -1186,8 +1184,19 @@ export default class QuestionnaireForm extends Component { }); } }); - console.log(priorAuthClaim); - + priorAuthBundle.timestamp = new Date(Date.now()).toISOString() + priorAuthBundle.language = "en"; + priorAuthBundle.id = shortid.generate(); + priorAuthBundle.meta = { + lastUpdated: Date.now() + } + priorAuthBundle.implicitRules = "http://build.fhir.org/ig/HL7/davinci-pas/StructureDefinition-profile-pas-request-bundle" + priorAuthBundle.identifier = { + use: "official", + system: "urn:uuid:mitre-drls", + value: shortid.generate() + } + priorAuthBundle.signature = signature; priorAuthBundle.entry.unshift({ resource: priorAuthClaim }); this.props.setPriorAuthClaim(priorAuthBundle);