Giter Club home page Giter Club logo

flutter-survey-app's People

Contributors

nmint8m avatar

Stargazers

 avatar

Watchers

 avatar

Forkers

nguyentu9

flutter-survey-app's Issues

Release 0.2.0

Acceptance Criteria

To release version 0.2.0:

  • Create a release branch
  • Make sure that the app works as expected

[UI] As a user, I can see the rating scale question

Why

The user can see the rating scale question and select one option. The rating scale is a scale from 1 to 10, presenting via a range of numbers from left to right on the screen.

The user chooses the answer by tapping on one number.

Acceptance criteria

Show a range of numbers from 1 to 10.

After the user chooses the answer, the chosen scales will be highlighted. The unchosen will be blurred.

Design

[Integration] As a user, I can submit the answers after finish the survey

Why

After choosing the Submit button on the last question screen, the user can send the answers to the server and finish the survey.

Acceptance criteria

After choosing the Submit button on the last question screen, gather all the answers of the user and post them to the server.

Follow the API document for /api/v1/responses.

  • If the response returns successfully, show the thank screen with animation and redirect to the home screen. At this point, reload the home screen, to get the available list of surveys that the user can take.

  • If the response returns with failure, show the error alert with a message.

Resources

[Integration] As an anonymous user, I can see the login screen

Why

To provide the anonymous user with the identity verification method, show the login screen where the user can input his/her email and password, then access the main application's features.

Acceptance criteria

It is recommended to have a format verification for the email input.

The first time the user taps the Log in button, if the value in the email input is NOT an email, show a default warning message.

In case the first time the user taps the Log in button, if the value in the email input is an email, then show nothing.

The email warning message is:

  • Empty email: Please enter your email!
  • Wrong email format: Wrong email format..

The first time the user taps the Log in button, if the value in the password input is shorter than 8 characters, then show a default warning message.

The password warning message is:

  • Empty password: Please enter your password!
  • <8 characters: The password should longer 8 characters.

Design

[UI] As an anonymous user, I can see the login screen

Why

To provide the anonymous user with the identity verification method, show the login screen where the user can input his/her email and password, then access the main application's features.

Acceptance criteria

After performing the splash screen, show the Nimble logo in the center, then the Nimble logo animates vertically to the top, and the login form fades in with the following:

  • Two text fields for inputting credentials: one for email and one for password
  • One log-in button

Design

[Integration] As a user, I can see the questions in the survey and answer them

Why

After choosing the Start Survey button on the survey detail screen, the user can load all the questions in the survey, and start answering them.

Acceptance criteria

After choosing the Start Survey button on the survey detail screen, send an API request to get the question list.

Follow the API document for /api/v1/surveys/{survey-id}`.

  • If the response returns with success, navigate to the first question screen.

  • If the response returns with failure, show the error alert with a message.

The user answers the question and goes to the next question by tapping on the next button at the bottom right corner of the question screen.

The user cannot go back to the previous question.

Resources

[UI] As a user, I can see the general UI for question

Why

Since there are different types of questions in the survey (choice questions, rating questions, yes/no questions, multiple choices, etc.) and these types have some standard user interfaces. The user can see the general UI for a question.

Acceptance criteria

In a question screen, the user can see:

  • Background image of the survey
  • Close button on the top right corner
  • Question index
  • Question text
  • (Answers will be implemented in other tasks)
  • If the question is the last question of the survey, show the Submit Survey button in the bottom right corner. If not, show the next button instead.

Design

Release 0.3.0

Acceptance Criteria

To release version 0.3.0:

  • Create a release branch
  • Make sure that the app works as expected

[UI] As a user, I can logout the application

Why

The user can logout the application when he/she has done using it.

Acceptance criteria

Show the right sidebar on top of the home screen when the user taps on the profile image. The right sidebar is performed with sliding animation.

On the right sidebar, show:

  • Name of the user
  • Profile image of the user
  • Logout option
  • Build version and build number of the application

Design

[Integration] As a user, I can see the profile information on home screen and on right sidebar

Why

As a user, I can see the profile information on the home screen and on the right sidebar.

Acceptance criteria

Get the user's profile after logging in success. Follow the API document for /api/v1/me.

If the response returns with success, bind the profile email and profile image URL into:

  • The profile image on the home screen

If the response returns with failure, keep those information blank.

Resources

[UI] As a user, I can see the survey detail screen

Why

On the home screen, because of the limitation of the screen size, the user only sees the brief of the survey.

The survey detail screen is for showing full information about the survey.

Acceptance criteria

On the survey detail screen, show:

  • Full title of the survey
  • Full description of the survey
  • Back button on the top left corner
  • Start Survey button in the bottom right corner

When the user taps on the back button, navigate back to the home screen.

When the user taps on the Start Survey button, navigate to the first question screen.

Design

[Backend] As a user, I can see the survey detail screen

Why

On the home screen, because of the limitation of the screen size, the user only sees the brief of the survey.

The survey detail screen is for showing full information about the survey.

Acceptance criteria

When the user taps on a survey item on the home screen, navigate to the survey detail screen of the chosen item.

Use the value of API /api/v1/surveys, which is for title and description to map on the survey detail screen.

[Backend] As an anonymous user, I can login into the application

Why

To provide a user security mechanism to access server resources, we propose the OAuth 2 standard.

Acceptance criteria

After the user taps the Login button, we will send a request to the server.

After receiving succeed response, save the values of access_token and refresh_token locally for later use.

Response:

{
  "data": {
    "id": 10,
    "type": "token",
    "attributes": {
      "access_token": "lbxD2K2BjbYtNzz8xjvh2FvSKx838KBCf79q773kq2c",
      "token_type": "Bearer",
      "expires_in": 7200,
      "refresh_token": "3zJz2oW0njxlj_I3ghyUBF7ZfdQKYXd2n0ODlMkAjHc",
      "created_at": 1597169495
    }
  }
}

Resources

[Integration] As a user, I can logout the application

Why

The user can log out the application when he/she has done used it.

Acceptance criteria

Use the value of the access token which has been saved locally to log out.

Follow the API document for /api/v1/oauth/revoke.

If the response returns with success:

  • Navigate to the login screen
  • Remove the user's tokens which have been saved locally inside the application

If the response returns with failure, show the error alert with a message.

Resources

Release 0.4.0

Acceptance Criteria

To release version 0.4.0:

  • Create a release branch
  • Make sure that the app works as expected

Configure CI for the project

Why

To improve production quality, continuous integration (CI) takes an important part in the development process.

Acceptance criteria

Set up a CI pipeline that satisfies the development standard.

  • Build application in CI
  • Run unit tests and UI tests in CI
  • Support linting for checking code convention

[Integration] As an anonymous user, I can see the forgot password screen

Why

The user may forget his/her password after a long time using the application. So as to provide the user a method to get back his/her password, the application requires the user to fill registered email.

Acceptance criteria

After the user fills the email and taps the Reset button, call /api/v1/passwords with email as parameter, follow this document.

If the response returns with success, show the message pop-up with:

  • Title: Check your email
  • Description: The message that API returns

If the response returns with failure, show the error alert with message.

Resources

Configure CD for the project

Why

To improve production quality, continuous deployment (CD) plays an important part in the development process.

Acceptance criteria

Set up a CD pipeline that satisfies the development standard.

[Integration] As a user, I can close the survey at any time

Why

While taking a survey, the user can close it at any time and do it later by tapping on the close button in the top right corner.

Acceptance criteria

Show the default warning pop up:

  • Title: Warning!
  • Description: Are you sure you want to quit the survey?
  • Yes and Cancel options

If the user chooses Yes, close the survey and navigation back to the home screen.

If the user chooses Cancel, dismiss the pop-up and continue answering the survey.

[UI] As a user, I can see the likert scales question

Why

The user can see the likert scale question and select one option. The likert scale is a scale from 1 to 5, starting at "not at all likely" scaling up to "extremely likely", presenting via 5 thumb-up from left to right on the screen.

The user chooses the answer by tapping on one option.

Acceptance criteria

Show 5 thumbs-up as 5 levels of the likert scale.

There are 4 types of likert:

  • Thumbs up
  • Smiley.
  • Star
  • Heart

After the user chooses the answer, the chosen option, and all the scales in front of it will be highlighted. The unchosen will be blurred.

Except for the smiley type, ONLY the selected option will be highlighted, the rest will be blurred.

Design

Release 0.1.0

Acceptance Criteria

To release version 0.1.0:

  • Create a release branch
  • Make sure that the app works as expected

[UI] As a user, I can see the animation when loading and showing surveys

Why

The user can see a list of the surveys which have not been finished by the users on the home screen. The user can see the animation when loading and showing surveys.

Acceptance criteria

Show the skeleton animation for all the information on the home screen (including the date information and profile image) when preparing to show the data.

Show the loading indicator when preparing to show the data.

When the user can navigate to the next/previous item by swiping the page to one side, the new item will fade in while the old one fades out.

Design

[UI] As an anonymous user, I can see the forgot password screen

Why

The user may forget his/her password after a long time of using the application. To provide the user a method to get back his/her password, the application requires the user to fill registered email.

Acceptance criteria

After the user taps on the Forgot? button on the login screen, navigate to the forgot password screen.

In the forgot password screen, show:

  • Nimble company logo
  • Forgot password instruction
  • A text field for inputting registered email
  • A Reset button

It is recommended to have a format verification for the email input

Design

[Backend] Build a core networking service

Why

To benefit the developers for the networking implementation, we should build a core network layer.

Acceptance criteria

Building a core network layer that fulfills these technical goals:

  • provide a simple interface to make network requests; attach basic headers to network requests; also provide customization points
  • provide basics of response data decoding
  • provide basics of a response error decoding
  • provide an API that makes it easy to stub/mock network requests for testing purposes

Integrate the core network layer to support the following build environments:

Resourses

[Integration] As a user, I can see the survey detail screen

Why

On the home screen, because of the limitation of the screen size, the user only sees the brief of the survey.

The survey detail screen is for showing full information about the survey.

Acceptance criteria

When the user taps on a survey item on the home screen, navigate to the survey detail screen of the chosen item.

Use the value of API /api/v1/surveys, which is for title and description to map on the survey detail screen.

[Integration] As an anonymous user, I can perform the OAuth while login into the application

Why

To provide a user security mechanism to access server resources, we propose the OAuth 2 standard.

Acceptance criteria

After the user taps the Login button, we will send a request to the server.

After receiving succeed response, save the values of access_token and refresh_token locally for later use.

Response:

{
  "data": {
    "id": 10,
    "type": "token",
    "attributes": {
      "access_token": "lbxD2K2BjbYtNzz8xjvh2FvSKx838KBCf79q773kq2c",
      "token_type": "Bearer",
      "expires_in": 7200,
      "refresh_token": "3zJz2oW0njxlj_I3ghyUBF7ZfdQKYXd2n0ODlMkAjHc",
      "created_at": 1597169495
    }
  }
}

Resources

[UI] As a user, I can see the available surveys on the home screen

Why

The user can see a list of the surveys which have not been finished by the users on the home screen. The user can only see one item on the list at a time.

Acceptance criteria

Show a series of small indicator dots representing the available item in the order they were opened. A solid dot denotes the current page. Users cannot tap on a specific dot to go to a specific page.

Show a horizontal collection view page. Each page contains the title and description of the survey.

The screen's background is according to the cover image URL of the current survey onscreen.

The user can navigate to the next/previous item by swiping the page to one side.

A circle button to go to take the survey.

Design

[Integration] As a user, I can receive a new access token when the old access token expires

Why

Due to security reasons, the OAuth 2 mechanism provides a short-lived access token and a long-lived refresh token. When the access token expires, use the refresh token to get a new access token.

Acceptance criteria

Use the value of the refresh token which has been saved locally, to get a new access token when the old one expires.

Follow the API document for /api/v1/oauth/token.

After receiving succeed response, save the new values of access_token locally for later use.

Resources

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.