-
-
Токены формы
- {
- setTitleToken("")
- setCurrentIdToken(false)
- }}
- target={"#tokenModal"}
- toggle={"modal"}
- />
-
-
-
+ // async function editTokenForm(tokenForm) {
+ // const response = await editTokenFormApi(cookies.token, formId, tokenForm, titleToken)
- {tokens ?
- tokens.map((item, i) =>
-
-
-
- {item.name}
-
-
- {item.id}
-
-
-
- {/*
item.id !== tokenForm));
+ } else if (response.status === 401) {
+ // navigate("/enter")
+ setUser(false);
+ } else {
+ console.log(response);
+ }
+ }
+
+ return (
+
+
+
+
+
+
Токены формы
+ {
+ setTitleToken("");
+ setCurrentIdToken(false);
+ }}
+ target={"#tokenModal"}
+ toggle={"modal"}
+ />
+
+
+
+
+ {tokens ? (
+ tokens.map((item, i) => (
+
+
+
+ {item.name}
+
+
+ {item.id}
+
+
+
+ {/* {
setCurrentIdToken(item.id)
}}>
*/}
- {
- QRCode.toDataURL(
- `http://localhost:3000/forms/${item.id}`,
- {},
- (err , url) => {
- setQrcodeUrl(url)
- }
- )
- }}
- data-bs-toggle="modal"
- data-bs-target={`#qrModal`}>
-
- removeTokenForm(item.id)}>
-
-
{
- const aElem = document.createElement('a');
- aElem.href = qrCodeUrl
- aElem.download = `${item.name}.png`
- aElem.click()
- }},
- {text: "Отмена", class: "main__white", dismiss: "modal", action: () => {}}
- ]}
- BodyModal={
-
- }
- />
-
- )
- :
-
}
-
newFormToken()},
- {text: "Отмена", class: "main__white", dismiss: "modal", action: () => {}}
- ]}
- BodyModal={
-
- }
- />
-
+
{
+ QRCode.toDataURL(
+ `http://minerva.krbl.ru/forms/${item.id}`,
+ {},
+ (err, url) => {
+ setQrcodeUrl(url);
+ }
+ );
+ }}
+ data-bs-toggle="modal"
+ data-bs-target={`#qrModal`}
+ >
+
removeTokenForm(item.id)}
+ >
+
{
+ const aElem = document.createElement("a");
+ aElem.href = qrCodeUrl;
+ aElem.download = `${item.name}.png`;
+ aElem.click();
+ },
+ },
+ {
+ text: "Отмена",
+ class: "main__white",
+ dismiss: "modal",
+ action: () => {},
+ },
+ ]}
+ BodyModal={}
+ />
+
+ ))
+ ) : (
+
+ )}
+
newFormToken(),
+ },
+ {
+ text: "Отмена",
+ class: "main__white",
+ dismiss: "modal",
+ action: () => {},
+ },
+ ]}
+ BodyModal={
+
+ }
+ />
+
- )
-}
+
+
+ );
+};
-export default TokensForm;
\ No newline at end of file
+export default TokensForm;