<script setup lang="ts">
import { usePageSearch, type PageHooks, type PageEvents } from "/@/hooks/page";
import contentConfig from "./config/content.config";
import searchConfig from "./config/search.config";
import { useRouter } from "vue-router"

const PageName = "combindProductManager";
const router = useRouter()

const hooks: PageHooks = {
  pageSearchHook: () => usePageSearch(undefined, undefined, searchConfig)
};

const events: PageEvents = {
  content: { 
    preview: ({ id }) => router.push('/invoiceInOut/combindProductManagerDetail?id=' + id),
    create: () => router.push('/invoiceInOut/combindProductManagerDetail')
   }
};
</script>

<template>
  <PageAuth :pageName="PageName">
    <PageContainer
      :hooks="hooks"
      :events="events"
      :contentConfig="contentConfig"
      :search-config="searchConfig"
    />
  </PageAuth>
</template>
