mirror of
https://github.com/WDI-Ideas/rubix-admin-panel.git
synced 2026-04-28 21:55:50 +00:00
banner view updated
This commit is contained in:
@@ -149,11 +149,15 @@ export const rubixApi = createApi({
|
||||
|
||||
|
||||
|
||||
// ===============[ Learn Banners endpoints ]=======================
|
||||
// ===============[ Build Banners endpoints ]=======================
|
||||
getBuildBanner: builder.query({
|
||||
query: () => "/admin/build",
|
||||
providesTags: ["getBuildBanner"],
|
||||
}),
|
||||
getBuildBannerById: builder.query({
|
||||
query: (id) => `/admin/build/${id}`,
|
||||
providesTags: ["getBuildBannerById"],
|
||||
}),
|
||||
|
||||
|
||||
|
||||
@@ -162,6 +166,10 @@ export const rubixApi = createApi({
|
||||
query: () => "/admin/main-news",
|
||||
providesTags: ["getNewsBanner"],
|
||||
}),
|
||||
getNewsBannerById: builder.query({
|
||||
query: (id) => `/admin/main-news/${id}`,
|
||||
providesTags: ["getNewsBannerById"],
|
||||
}),
|
||||
|
||||
|
||||
// ================[ blog endpoints ]====================
|
||||
@@ -271,6 +279,13 @@ export const rubixApi = createApi({
|
||||
}),
|
||||
invalidatesTags: ["getEvents"],
|
||||
}),
|
||||
deleteEvents: builder.mutation({
|
||||
query: (blogId) => ({
|
||||
url: `/admin/events/${blogId}`,
|
||||
method: "DELETE",
|
||||
}),
|
||||
invalidatesTags: ["getEvents"],
|
||||
}),
|
||||
|
||||
|
||||
|
||||
@@ -301,8 +316,10 @@ export const {
|
||||
useUpdateLearnBannerStatusMutation,
|
||||
|
||||
useGetBuildBannerQuery,
|
||||
useGetBuildBannerByIdQuery,
|
||||
|
||||
useGetNewsBannerQuery,
|
||||
useGetNewsBannerByIdQuery,
|
||||
|
||||
useGetBlogQuery,
|
||||
useGetBlogByIdQuery,
|
||||
@@ -324,4 +341,5 @@ export const {
|
||||
useGetEventsQuery,
|
||||
useCreateEventsMutation,
|
||||
useUpdateEventsStatusMutation,
|
||||
useDeleteEventsMutation,
|
||||
} = rubixApi;
|
||||
|
||||
Reference in New Issue
Block a user