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

build: Release 4.30.3 - Typescript migrations, filter storage mode responses by submission id #123

Merged
merged 31 commits into from
Aug 12, 2020

Conversation

arshadali172
Copy link
Contributor

New

  • Remove allowSms beta flag
  • Filter Storage Mode Responses by Submission Id
  • Show error upon FileReader failure

Fix

  • Phone validation now only accepts 8 digit #s starting with 8 or 9
  • Fix myInfoError typo

Improved

  • Setup jest for use with Typescript tests
  • Updating contributing, readme, license for open source
  • Several backend files migrated to TypeScript.

mantariksh and others added 30 commits August 5, 2020 09:22
* feat: add _id to all relevant types

* fix: omit id when declaring new document

* refactor: change any to Document['_id']
* feat: remove allowSms

* feat: add script to remove allowSms flag
* refactor: use LogicType instead of LOGIC_TYPES

* refactor: type logic module

* refactor: prefix interface names with I

* refactor: add interface containing fieldValue

* test: add logic type to tests

* refactor: add isPreventSubmitLogic function

* docs: document IClientFieldSchema

* refactor: make everything an arrow function
Bumps [lodash](https://github.com/lodash/lodash) from 4.17.15 to 4.17.19.
- [Release notes](https://github.com/lodash/lodash/releases)
- [Commits](lodash/lodash@4.17.15...4.17.19)

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [uuid](https://github.com/uuidjs/uuid) from 8.2.0 to 8.3.0.
- [Release notes](https://github.com/uuidjs/uuid/releases)
- [Changelog](https://github.com/uuidjs/uuid/blob/master/CHANGELOG.md)
- [Commits](uuidjs/uuid@v8.2.0...v8.3.0)

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
#101)

* fix: phone validation now only accepts 8 digit #s starting with 8 or 9

* fix: perform mobile validation checks only in mobile validation fn
Bumps [url-loader](https://github.com/webpack-contrib/url-loader) from 1.1.2 to 4.1.0.
- [Release notes](https://github.com/webpack-contrib/url-loader/releases)
- [Changelog](https://github.com/webpack-contrib/url-loader/blob/master/CHANGELOG.md)
- [Commits](webpack-contrib/url-loader@v1.1.2...v4.1.0)

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* contributing guidelines

* full open source license

* contact email address
Bumps [angular](https://github.com/angular/angular.js) from 1.7.9 to 1.8.0.
- [Release notes](https://github.com/angular/angular.js/releases)
- [Changelog](https://github.com/angular/angular.js/blob/master/CHANGELOG.md)
- [Commits](angular/angular.js@v1.7.9...v1.8.0)

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [angular-cookies](https://github.com/angular/angular.js) from 1.7.9 to 1.8.0.
- [Release notes](https://github.com/angular/angular.js/releases)
- [Changelog](https://github.com/angular/angular.js/blob/master/CHANGELOG.md)
- [Commits](angular/angular.js@v1.7.9...v1.8.0)

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [webpack-cli](https://github.com/webpack/webpack-cli) from 3.3.11 to 3.3.12.
- [Release notes](https://github.com/webpack/webpack-cli/releases)
- [Changelog](https://github.com/webpack/webpack-cli/blob/v3.3.12/CHANGELOG.md)
- [Commits](webpack/webpack-cli@v3.3.11...v3.3.12)

Signed-off-by: dependabot[bot] <[email protected]>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* feat: correct discriminated field schema typings' inheritance

* chore: add typings for uid-generator

* feat: add validation error if table field does not have any columns

* feat(FieldSchema): add instance method getQuestion

* test(FormModel): add getQuestion field instance method tests

* refactor: retrieve field question using instance method

* feat: delete question.js

* feat(BaseField): add comment to getQuestion instance method

* test: migrate form field tests to form_fields.schema.spec

* test: use ObjectIds for field ids instead of string

was causing schema building to fail due to expecting a document instead of an object

* test: use objectId instead of string when building mongoose schemas
* chore: add ts-jest and dependencies

* chore: expand tsconfig to `test` directory

* chore: add jest config and script to run Typescript tests

* chore: improve import sort linting autogrouping

* tests: convert submission.server.model tests to Typescript

* chore: add jest-mongodb present to jest setup

This allows for use of mongodb without any setting up or tearing down of mongodb between tests

* test: migrate myinfo service test to Typescript

* feat: remove usage of spec in db-handler

* build: add specific tsconfig for building that ignores tests

* chore: add jest-mongodb-config and migrate SmsCountModel tests

With this, we can eventually stop using `npm run download-binary` and delete `tests/end-to-end/helpers/get-mongo-binary.js` since the config automatically retrieves that information for us.

* chore: add documentation to gitignore

* fix: check mongoose MD5 binary when starting jest tests

* refactor: convert form_fields schema tests to Typescript
* refactor: extract showAttachmentError

* refactor: replace object with boolean

* feat: only set success values upon success

* feat: show error on FileReader failure

* feat: only remove spinner upon success or failure

* refactor: use ng-class instead of jquery

* docs: document onerror

* chore: update error wording

Co-authored-by: Yuan Ruo <[email protected]>

* refactor: move fieldValue assignment together with file

* chore: remove double full stop

Co-authored-by: Antariksh Mahajan <[email protected]>
Co-authored-by: Yuan Ruo <[email protected]>
@arshadali172 arshadali172 changed the title build: Release 4.30.3 build: Release 4.30.3: Typescript migrations, filter storage mode responses by submission id Aug 12, 2020
@arshadali172
Copy link
Contributor Author

arshadali172 commented Aug 12, 2020

Tests

@karrui

  • Email mode: check that you don't have the allowSms beta flag, and you can see the "Verified" option for mobile fields. Submit a form with a verified mobile number and check that the email response has the [verified] prefix.
  • Storage mode: check that you don't have the allowSms beta flag, and you can see the "Verified" option for mobile fields. Submit a form with a verified mobile number and check that the response in the Data tab has the [verified] prefix. Download the responses CSV and make sure the answer appears correctly (there won't be a [verified] prefix in the column header).
  • Upload an attachment from Google Drive on an Android phone. The error should show as per the screenshot.
  • On both desktop and mobile, upload a valid attachment. The UI should behave correctly. Make sure that this works for .zip files.
  • On both desktop and mobile, upload an attachment which exceeds the maximum allowed size. You should see the correct error message, and you should subsequently be able to upload a valid attachment and submit the form.
  • On both desktop and mobile, upload an attachment of an invalid file type (e.g. .js). You should see the correct error message, and you should subsequently be able to upload a valid attachment and submit the form.

@karrui
Copy link
Contributor

karrui commented Aug 12, 2020

Tests

@mantariksh

  • Ensure that phone number field for Singapore numbers start with 8 and 9
  • Submit a form with all fields.
    • The responses sent to the admin/form-filler email for email forms should have the correct questions for all fields (table fields should be ${title} (${column titles separated by comma})
    • The responses sent to the results tab for storage mode forms should also display the correct questions.

@karrui
Copy link
Contributor

karrui commented Aug 12, 2020

Tests

@arshadali172

  • Test filtering submissions by reference ID

@karrui karrui changed the title build: Release 4.30.3: Typescript migrations, filter storage mode responses by submission id build: Release 4.30.3 - Typescript migrations, filter storage mode responses by submission id Aug 12, 2020
@arshadali172
Copy link
Contributor Author

arshadali172 commented Aug 12, 2020

@liangyuanruo
General tests on IE/Intranet

  • covid templates not horizontally aligned in form creation modal
    image

  • download/copy secret key buttons
    image

@karrui
Copy link
Contributor

karrui commented Aug 12, 2020

Mobile fields do not show country flags. Probably due to #90.

* Revert url loader

* Update package-lock

Co-authored-by: Arshad Ali <[email protected]>
@arshadali172 arshadali172 requested a review from karrui August 12, 2020 07:09
@arshadali172 arshadali172 merged commit 14e0f43 into release Aug 12, 2020
@liangyuanruo liangyuanruo deleted the release-4.30.3 branch January 6, 2021 08:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants