Criação do botao para upload csv

pull/20/head
adriano 2022-11-04 12:11:56 -03:00
parent bde6058455
commit eaafacc4b4
2 changed files with 3 additions and 5 deletions

View File

@ -6,3 +6,5 @@ export const store = async (req: Request, res: Response): Promise<Response> => {
return res.status(200).json({ message: "contacts imported" }); return res.status(200).json({ message: "contacts imported" });
}; };

View File

@ -6,11 +6,7 @@ import * as ImportPhoneContactsController from "../controllers/ImportPhoneContac
const contactRoutes = express.Router(); const contactRoutes = express.Router();
contactRoutes.post( contactRoutes.post("/contacts/import", isAuth, ImportPhoneContactsController.store);
"/contacts/import",
isAuth,
ImportPhoneContactsController.store
);
contactRoutes.get("/contacts", isAuth, ContactController.index); contactRoutes.get("/contacts", isAuth, ContactController.index);