@@ -114,7 +114,17 @@ export default function Award({
|
||||
)}
|
||||
</td>
|
||||
<td className="pr-4 whitespace-nowrap">
|
||||
{money(q.total_minor)}
|
||||
{money(q.total_minor, q.currency)}
|
||||
{q.reference_amounts &&
|
||||
q.exchange_basis && (
|
||||
<p className="text-xs">
|
||||
Referência para alçadas:{' '}
|
||||
{money(
|
||||
q.reference_amounts
|
||||
.total_minor,
|
||||
)}
|
||||
</p>
|
||||
)}
|
||||
</td>
|
||||
<td className="pr-4">
|
||||
{q.evaluation_count} /{' '}
|
||||
@@ -199,8 +209,11 @@ export default function Award({
|
||||
.map((q) => (
|
||||
<option key={q.id} value={q.id}>
|
||||
{q.supplier.name} ·{' '}
|
||||
{money(q.total_minor)} ·{' '}
|
||||
{q.score?.toFixed(2)} / 10
|
||||
{money(
|
||||
q.total_minor,
|
||||
q.currency,
|
||||
)}{' '}
|
||||
· {q.score?.toFixed(2)} / 10
|
||||
</option>
|
||||
))}
|
||||
</select>
|
||||
|
||||
@@ -7,6 +7,8 @@ import type { AiPreparation } from '@/components/ai-preparation-preview';
|
||||
import { ComparisonPolicySummary } from '@/components/comparison-policy-summary';
|
||||
import type { ComparisonPolicy } from '@/components/comparison-policy-summary';
|
||||
import { QuotationCommercialTerms } from '@/components/quotation-commercial-terms';
|
||||
import { ExchangeSummary } from '@/components/quotation-exchange-panel';
|
||||
import type { ExchangeBasis } from '@/components/quotation-exchange-panel';
|
||||
import type { CommercialTerms } from '@/components/quotation-commercial-terms';
|
||||
import { PageTitle, Panel, Status } from '@/components/procurement';
|
||||
import { Button } from '@/components/ui/button';
|
||||
@@ -33,6 +35,12 @@ type Analysis = {
|
||||
answers: Answer[];
|
||||
};
|
||||
type ComparisonRow = {
|
||||
exchange_basis?: ExchangeBasis;
|
||||
reference_amounts?: {
|
||||
subtotal_minor: number;
|
||||
tax_minor: number;
|
||||
total_minor: number;
|
||||
} | null;
|
||||
commercial_terms?: CommercialTerms | null;
|
||||
id: number;
|
||||
reference: string;
|
||||
@@ -208,6 +216,11 @@ export default function ReviewReport({
|
||||
<Printer className="size-4" />
|
||||
Imprimir esta consulta
|
||||
</Button>
|
||||
<Button asChild variant="outline">
|
||||
<a href={`/requisicoes/${r.id}/relatorio.csv`}>
|
||||
Exportar conferência completa (CSV)
|
||||
</a>
|
||||
</Button>
|
||||
</div>
|
||||
}
|
||||
/>
|
||||
@@ -399,7 +412,24 @@ export default function ReviewReport({
|
||||
</strong>
|
||||
<QuotationCommercialTerms
|
||||
terms={row.commercial_terms}
|
||||
currency={row.currency}
|
||||
/>
|
||||
{row.exchange_basis && (
|
||||
<ExchangeSummary
|
||||
basis={row.exchange_basis}
|
||||
/>
|
||||
)}
|
||||
{row.reference_amounts && (
|
||||
<p className="text-sm">
|
||||
Referência para comparação e
|
||||
alçadas:{' '}
|
||||
{money(
|
||||
row.reference_amounts
|
||||
.total_minor,
|
||||
'MZN',
|
||||
)}
|
||||
</p>
|
||||
)}
|
||||
</section>
|
||||
))}
|
||||
{report.comparison.rows.map((row) => (
|
||||
|
||||
@@ -5,6 +5,7 @@ import { QuotationCommercialTerms } from '@/components/quotation-commercial-term
|
||||
import { PageTitle, Panel } from '@/components/procurement';
|
||||
import { Button } from '@/components/ui/button';
|
||||
import { date, money, roleLabels } from '@/types/procurement';
|
||||
import { ExchangeSummary } from '@/components/quotation-exchange-panel';
|
||||
import type { PurchaseOrder } from '@/types/purchase';
|
||||
import OrderCancellationRequest, {
|
||||
type OrderCancellationState,
|
||||
@@ -196,13 +197,19 @@ export default function OrderShow({
|
||||
{Number(item.quantity)} {item.unit}
|
||||
</td>
|
||||
<td className="pr-4 whitespace-nowrap">
|
||||
{money(item.unit_price_minor)}
|
||||
{money(
|
||||
item.unit_price_minor,
|
||||
order.currency,
|
||||
)}
|
||||
</td>
|
||||
<td className="pr-4">
|
||||
{Number(item.tax_rate)}%
|
||||
</td>
|
||||
<td className="whitespace-nowrap">
|
||||
{money(item.total_minor)}
|
||||
{money(
|
||||
item.total_minor,
|
||||
order.currency,
|
||||
)}
|
||||
</td>
|
||||
</tr>
|
||||
))}
|
||||
@@ -212,17 +219,28 @@ export default function OrderShow({
|
||||
<dl className="mt-5 ml-auto max-w-sm space-y-3 text-sm">
|
||||
<div className="flex justify-between gap-4">
|
||||
<dt>Subtotal sem IVA</dt>
|
||||
<dd>{money(order.subtotal_minor)}</dd>
|
||||
<dd>
|
||||
{money(order.subtotal_minor, order.currency)}
|
||||
</dd>
|
||||
</div>
|
||||
<div className="flex justify-between gap-4">
|
||||
<dt>IVA</dt>
|
||||
<dd>{money(order.tax_minor)}</dd>
|
||||
<dd>{money(order.tax_minor, order.currency)}</dd>
|
||||
</div>
|
||||
<div className="flex justify-between gap-4 border-t pt-3 font-semibold">
|
||||
<dt>Total com IVA</dt>
|
||||
<dd>{money(order.total_minor)}</dd>
|
||||
<dd>{money(order.total_minor, order.currency)}</dd>
|
||||
</div>
|
||||
</dl>
|
||||
{snapshot.exchange_basis && (
|
||||
<ExchangeSummary basis={snapshot.exchange_basis} />
|
||||
)}
|
||||
{snapshot.reference_amounts && (
|
||||
<p className="mt-3 text-sm">
|
||||
Referência orçamental:{' '}
|
||||
{money(snapshot.reference_amounts.total_minor)}
|
||||
</p>
|
||||
)}
|
||||
</Panel>
|
||||
<Panel title="Fundamento e matriz congelada">
|
||||
{snapshot.comparison_policy && (
|
||||
@@ -246,11 +264,13 @@ export default function OrderShow({
|
||||
: `${row.score.toFixed(2)} / 10`}
|
||||
</p>
|
||||
<p className="mt-1 text-muted-foreground">
|
||||
{money(row.total_minor)} com IVA ·{' '}
|
||||
{row.evaluation_count} avaliações elegíveis
|
||||
{money(row.total_minor, row.currency)} com
|
||||
IVA · {row.evaluation_count} avaliações
|
||||
elegíveis
|
||||
</p>
|
||||
<QuotationCommercialTerms
|
||||
terms={row.commercial_terms}
|
||||
currency={row.currency}
|
||||
/>
|
||||
{row.evaluations.map((e) => (
|
||||
<p
|
||||
|
||||
Reference in New Issue
Block a user