feat: add client take survey page (#626)

Fixes: #269
This commit is contained in:
Muskan Khedia
2020-07-13 16:41:01 +05:30
committed by GitHub
parent cdb6a46de7
commit 767d2cd235
9 changed files with 332 additions and 7 deletions
+16
View File
@@ -227,4 +227,20 @@ export class ClientsService {
getSurveys(clientId: string) {
return this.http.get(`/surveys/scorecards/clients/${clientId}`);
}
/**
* returns the list of survey types and questions
*/
getAllSurveysType() {
return this.http.get('/surveys');
}
/**
* returns the response from the post request for that survey
* @param surveyId
* @param surveyData Survey Data submitted by client
*/
createNewSurvey(surveyId: Number, surveyData: any) {
return this.http.post(`/surveys/scorecards/${surveyId}`, surveyData);
}
}