Update doc-survey-widget.tsx
This commit is contained in:
parent
bd425f9144
commit
160d5c9396
|
@ -299,6 +299,10 @@ const SurveyFinished = (props: {
|
|||
);
|
||||
};
|
||||
|
||||
const generateRandomSurveyId = () => {
|
||||
return Math.random().toString(36).substring(7);
|
||||
};
|
||||
|
||||
const createSurvey = async ({ body }: { body: DocSurveyCreateDto }) => {
|
||||
const response = await fetch(`${DOC_SURVEY_URL}?surveyId=${generateRandomSurveyId()}`, {
|
||||
method: "POST",
|
||||
|
|
Loading…
Reference in a new issue