Giter Club home page Giter Club logo

surveyserver's Introduction

SurveyServer

  • 설문조사 백엔드 : Springboot + JPA + MySQL -> with NAT

실행영상

화면 기록 2021-04-06 오후 4 36 29


Rest API

주소 타입 기능
protocol:://addr:port/survey/createSurvey POST 설문생성
protocol:://addr:port/survey/getSurveyTitle GET 만들어진 설문 전체 조회
protocol:://addr:port/survey/getSurveyDetail?titleId= GET 타이틀 아이디에 해당하는 설문 상세조회
protocol:://addr:port/survey/getResult?userId=&titleId= GET 타이틀 아이디에 해당하는 결과 상세조회
protocol:://addr:port/survey/addResult POST 설문 답변 등록
설문생성 JSON 예시
{ 
    "title": {
        "title":"선택이 필요합니다."
    } ,
    "questions":[
        {
            "question_id":1,
            "question_msg":"야식은 무엇을 먹을까요?",
            "answers" : [
                {
                    "answer_id":1,
                    "answer_msg":"1.치킨"
                },
                {
                    "answer_id":2,
                    "answer_msg":"2.족발"
                },
                {
                    "answer_id":3,
                    "answer_msg":"3.굶기"
                }
            ]
        } , 
        {
            "question_id":2,
            "question_msg":"오늘은 몇시에잘까요?",
            "answers" : [
                {
                    "answer_id":1,
                    "answer_msg":"22시59분"
                },
                {
                    "answer_id":2,
                    "answer_msg":"23시59분"
                },
                {
                    "answer_id":3,
                    "answer_msg":"내일자요"
                }
            ]
        },
        {
            "question_id":3,
            "question_msg":"어느 커피숍을 갈까요?",
            "answers" : [
                {
                    "answer_id":1,
                    "answer_msg":"스타벅스"
                },
                {
                    "answer_id":2,
                    "answer_msg":"이디야"
                },
                {
                    "answer_id":3,
                    "answer_msg":"메가"
                }
            ]
        }
    ]
}
설문 답변 등록 JSON 예시
{
    "userId":202104061549,
    "titleId":1,
    "userAnsList":[
        {
            "questionId":1,
            "answerId":2
        },
        {
            "questionId":2,
            "answerId":1
        }
    ],
    "countList":null
}


DB [ Table & Column ]

테이블명 간단설명
survey_title 설문의 아이디와 제목
survey_question 문항의 아이디와 내용
survey_answer 세부문항의 아이디와 내용
survey_user 유저의 아이디와 답변
테이블명 컬럼명 타입 설명 기본키 or 복합키
survey_title id bigint 설문의 아이디
title varchar(1024) 설문의 제목
survey_question id bigint 설문의 아이디
question_id bigint 문항의 아이디
question_msg varchar(1024) 문항의 내용
survey_answer id bigint 설문의 아이디
question_id bigint 문항의 아이디
answer_id bigint 세부문항의 아이디
answer_msg varchar(1024) 세부문항의 내용
survey_user user_id bigint 유저의 아이디
id bigint 설문의 아이디
question_id bigint 문항의 아이디
answer_id bigint 세부문항의 아이디

surveyserver's People

Contributors

devhyeon0312 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.