import { createTableComponent } from '../Factory/createTableComponent';
import {
  fetch,
  update,
  deleteItem,
  setRefetch,
  deleteItemsByIds,
} from '../../stores/publish_events/publish_eventsSlice';
import { loadColumns } from './configurePublish_eventsCols';
import type { PublishEvent } from '../../types/entities';

const TablePublish_events = createTableComponent<PublishEvent>({
  entityName: 'publish_events',
  sliceSelector: (state) => state.publish_events,
  fetchAction: fetch,
  updateAction: update,
  deleteAction: deleteItem,
  deleteByIdsAction: deleteItemsByIds,
  setRefetchAction: setRefetch,
  loadColumnsFunction: loadColumns,
});

export default TablePublish_events;
