GithubHelp home page GithubHelp logo

user-survey's Introduction

User Survey

This simple project allow for the anonymous creation/taking surveys. Consist of 2 services and mongo db.

  • survey hexagonal service
  • cobra interactive cli

Survey service runs on port :8000 as RESTful service and Cobra client interact with it through API.

Run the services

docker-compose build will build the Dockerfiles of both the services

docker-compose run client sh will start the Cobra cli in interactive terminal.

Cli commands

+++++++++++++++++++++++++++++++++++++


Usage:
  cli [command]

Available Commands:
  create      Create a new survey
  help        Help about any command
  show        Show results of a survey
  take        Take a survey

Flags:
  -h, --help   help for cli

Use "cli [command] --help" for more information about a command.

Create a new Survey

cli create

+++++++++++++++++++++++++++++++++++++
Title: Music
Question 0:  Do you like Trance?
Question 1:  Do you like Classical?
Question 2:  Do you like American Pop?
Survey result:
 Location: /api/surveys/607d2491ff515ded51cd49a5
 Survey: 607d2491ff515ded51cd49a5

Take a survey

cli take

+++++++++++++++++++++++++++++++++++++
๐ŸŒถ Music
Please fill the Survey.
โœ” Yes
โœ” Yes
โœ” No
Survey result:
 Location: /api/surveys/607d2491ff515ded51cd49a5/results/607d24eaff515ded51cd49a6
 Survey: 607d2491ff515ded51cd49a5
 Result: 607d24eaff515ded51cd49a6

Show results of a survey

cli show -s 607d2491ff515ded51cd49a5

+++++++++++++++++++++++++++++++++++++
Use the arrow keys to navigate: โ†“ โ†‘ โ†’ โ†  and / toggles search
Survey Titles?
  ๐ŸŒถ Music (607d24eaff515ded51cd49a6)
    Music (607d254aff515ded51cd49a7)

--------- Survey ----------
Title:        Music

        0        Do you like Trance?
        true

        1        Do you like Classical?
        true

        2        Do you like American Pop?
        false

user-survey's People

Contributors

reoxey avatar

Watchers

James Cloos avatar  avatar

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.