diff --git a/app/[locale]/(protected)/contributor/agenda-setting/calender-view.tsx b/app/[locale]/(protected)/contributor/agenda-setting/calender-view.tsx
index 833a2129..13d5db6a 100644
--- a/app/[locale]/(protected)/contributor/agenda-setting/calender-view.tsx
+++ b/app/[locale]/(protected)/contributor/agenda-setting/calender-view.tsx
@@ -575,7 +575,7 @@ const CalendarView = ({ categories }: CalendarViewProps) => {
- {roleId == 11 || roleId == 2 || roleId == 12 ? (
+ {roleId == 3 || roleId == 11 || roleId == 2 || roleId == 12 ? (
-
+
@@ -624,6 +630,38 @@ export default function FormImageDetail() {
) : (
""
)} */}
+
+ {detail?.isPublish == false && detail.isPublishOnPolda == true ? (
+
+ publishToMabes()}
+ type="button"
+ color="primary"
+ >
+ Publish
+
+
+ ) : (
+ ""
+ )}
+
+ {/* {detail?.isPublish == true ? (
+
+ ) : (
+ ""
+ )} */}
{Number(detail?.needApprovalFromLevel) == Number(userLevelId) ? (
Number(detail?.uploadedById) == Number(userId) ? (
""
diff --git a/service/content/content.ts b/service/content/content.ts
index 7d2a4e0f..e40c5826 100644
--- a/service/content/content.ts
+++ b/service/content/content.ts
@@ -196,6 +196,11 @@ export async function rejectFiles(data: any) {
return httpPostInterceptor(url, data);
}
+export async function publishMedia(id: any) {
+ const url = `media/public/publish-to-mabes?id=${id}`;
+ return httpPostInterceptor(url);
+}
+
export async function saveContentRewrite(data: any) {
const url = "media/rewrite";
return httpPostInterceptor(url, data);