37 lines
964 B
TypeScript
37 lines
964 B
TypeScript
|
|
import { Plus } from "lucide-react";
|
||
|
|
import { CompanySearchFilter } from "@/types/company";
|
||
|
|
import { Button } from "@/components/ui/button";
|
||
|
|
|
||
|
|
interface CompanyToolbarProps {
|
||
|
|
searchFilter: CompanySearchFilter;
|
||
|
|
totalCount: number;
|
||
|
|
filteredCount: number;
|
||
|
|
onSearchChange: (filter: Partial<CompanySearchFilter>) => void;
|
||
|
|
onSearchClear: () => void;
|
||
|
|
onCreateClick: () => void;
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 회사 관리 툴바 컴포넌트
|
||
|
|
* 검색, 필터링, 등록 기능 제공
|
||
|
|
*/
|
||
|
|
export function CompanyToolbar({ onCreateClick }: CompanyToolbarProps) {
|
||
|
|
// 검색어 변경 처리
|
||
|
|
|
||
|
|
// 상태 필터 변경 처리
|
||
|
|
|
||
|
|
// 검색 조건이 있는지 확인
|
||
|
|
|
||
|
|
return (
|
||
|
|
<div className="space-y-4">
|
||
|
|
{/* 상단: 제목과 등록 버튼 */}
|
||
|
|
<div className="flex items-center justify-end">
|
||
|
|
<Button onClick={onCreateClick} className="gap-2">
|
||
|
|
<Plus className="h-4 w-4" />
|
||
|
|
회사 등록
|
||
|
|
</Button>
|
||
|
|
</div>
|
||
|
|
</div>
|
||
|
|
);
|
||
|
|
}
|