feat(marketing): Refactor marketing wizard steps and add data collection methods

- Moved all marketing wizard step components to `create/_components` directory
- Added `collectData` static method to each step component for data retrieval
- Reorganized file structure to improve component modularity
- Prepared steps for dynamic data collection in wizard workflow
- Added VSCode settings file for project configuration
- Introduced new CMS-related components and services
- Updated API endpoints and added new query hooks
This commit is contained in:
AmirReza Jamali
2025-11-09 14:53:36 +03:30
parent f9bd7fce4b
commit cdc8cde6a4
26 changed files with 414 additions and 63 deletions
+22
View File
@@ -0,0 +1,22 @@
import { API_ENDPOINTS } from "@/lib/api";
import { cmsService } from "@/lib/api/services/cms-service";
import { useMutation, useQuery } from "@tanstack/react-query";
import { useMemo } from "react";
export const useGetCmsList = () => {
const queryKey = useMemo(() => [API_ENDPOINTS.CMS.BASE()], []);
return useQuery({
queryKey,
queryFn: cmsService.getCms,
});
};
export const useCreateCms = () => {
const mutationKey = useMemo(
() => [API_ENDPOINTS.CMS.BASE(), "Create cms"],
[],
);
return useMutation({
mutationKey,
mutationFn: cmsService.createCms,
});
};