Changes
Co-authored-by: renee-png <262607627+renee-png@users.noreply.github.com>
This commit is contained in:
co-authored by
renee-png
parent
759e1e3373
commit
90f8b29299
@@ -7,11 +7,12 @@ import { Textarea } from "@/components/ui/textarea";
|
||||
import { Checkbox } from "@/components/ui/checkbox";
|
||||
import { supabase } from "@/integrations/supabase/client";
|
||||
import { useAuth } from "@/lib/auth";
|
||||
import { Plus, Trash2, Loader2, FilePlus, PlusCircle, CheckCircle2, Undo2 } from "lucide-react";
|
||||
import { Plus, Trash2, Loader2, FilePlus, PlusCircle, CheckCircle2, Undo2, Download } from "lucide-react";
|
||||
import { formatCurrency, formatDate } from "@/lib/format";
|
||||
import { ensureMarkedInvoicedPlaceholder } from "@/lib/invoice-generation";
|
||||
import { roundToSixth } from "@/lib/timer";
|
||||
import { toast } from "sonner";
|
||||
import { ImportUnbilledDialog } from "@/components/cases/import-unbilled-dialog";
|
||||
import {
|
||||
Select,
|
||||
SelectContent,
|
||||
@@ -57,6 +58,7 @@ export function CaseTimeTab({ caseRecord, onInvoice }: CaseTimeTabProps) {
|
||||
const [fees, setFees] = useState<FeeItem[]>([]);
|
||||
const [selectedFeeId, setSelectedFeeId] = useState<string>("");
|
||||
const [showNewFee, setShowNewFee] = useState(false);
|
||||
const [showImport, setShowImport] = useState(false);
|
||||
|
||||
const load = async () => {
|
||||
const { data, error } = await supabase
|
||||
@@ -181,6 +183,9 @@ export function CaseTimeTab({ caseRecord, onInvoice }: CaseTimeTabProps) {
|
||||
<FilePlus className="h-4 w-4 mr-2" /> Invoice case ({formatCurrency(totals.unbilled)})
|
||||
</Button>
|
||||
)}
|
||||
<Button variant="outline" onClick={() => setShowImport(true)}>
|
||||
<Download className="h-4 w-4 mr-2" /> Import open time
|
||||
</Button>
|
||||
<Button onClick={() => setShowForm((s) => !s)}>
|
||||
<Plus className="h-4 w-4 mr-2" /> {showForm ? "Cancel" : "Log time"}
|
||||
</Button>
|
||||
|
||||
Reference in New Issue
Block a user