change: disable price display on recipe detail
Signed-off-by: pakintada@gmail.com <Pakin>
This commit is contained in:
parent
c7de46109c
commit
828089ed2f
1 changed files with 2 additions and 46 deletions
|
|
@ -348,50 +348,6 @@
|
||||||
</Card.Root>
|
</Card.Root>
|
||||||
|
|
||||||
<!-- Price Information Card -->
|
<!-- Price Information Card -->
|
||||||
<Card.Root class="mb-4">
|
|
||||||
<Card.Header>
|
|
||||||
<Card.Title>Price Information</Card.Title>
|
|
||||||
</Card.Header>
|
|
||||||
<Card.Content class="space-y-4">
|
|
||||||
<div class="space-y-4">
|
|
||||||
<!-- Current Price -->
|
|
||||||
<div class="space-y-2">
|
|
||||||
<Label for="tabs-menu-price">Price</Label>
|
|
||||||
<Input id="tabs-menu-price" value={menuCurrentPrice} />
|
|
||||||
</div>
|
|
||||||
|
|
||||||
{#if showSheetPrice}
|
|
||||||
<!-- Sheet Price (when different) -->
|
|
||||||
<div class="space-y-2">
|
|
||||||
<Label for="tabs-menu-sheet-price">Price from Sheet</Label>
|
|
||||||
<div class="flex flex-row gap-2">
|
|
||||||
<Input
|
|
||||||
id="tabs-menu-sheet-price"
|
|
||||||
bind:value={sheetPriceValue}
|
|
||||||
disabled={!canEditSheetPrice}
|
|
||||||
/>
|
|
||||||
{#if canEditSheetPrice}
|
|
||||||
<Button onclick={saveSheetPrice} class="btn-sm">
|
|
||||||
Save
|
|
||||||
</Button>
|
|
||||||
{/if}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{/if}
|
|
||||||
|
|
||||||
<!-- Disabled by Price -->
|
|
||||||
<div class="space-y-2">
|
|
||||||
<div class="flex flex-row items-center gap-2">
|
|
||||||
<Checkbox
|
|
||||||
id="disable-menu-by-price"
|
|
||||||
checked={isMenuHideByPrice}
|
|
||||||
/>
|
|
||||||
<span>Disabled by Price</span>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</Card.Content>
|
|
||||||
</Card.Root>
|
|
||||||
|
|
||||||
<!-- Additional Recipe Data Card -->
|
<!-- Additional Recipe Data Card -->
|
||||||
<Card.Root>
|
<Card.Root>
|
||||||
|
|
@ -403,7 +359,7 @@
|
||||||
<div class="space-y-3">
|
<div class="space-y-3">
|
||||||
<div class="space-y-2">
|
<div class="space-y-2">
|
||||||
<Label for="tabs-last-change">Last Change</Label>
|
<Label for="tabs-last-change">Last Change</Label>
|
||||||
<span id="tabs-last-change" class="text-sm text-muted-foreground block">
|
<span id="tabs-last-change" class="block text-sm text-muted-foreground">
|
||||||
{recipeData.LastChange ?? 'N/A'}
|
{recipeData.LastChange ?? 'N/A'}
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -412,7 +368,7 @@
|
||||||
<Input
|
<Input
|
||||||
id="tabs-total-time"
|
id="tabs-total-time"
|
||||||
type="number"
|
type="number"
|
||||||
value={String(recipeData.total_time ?? '')}
|
value={String((recipeData.total_time ?? 1000) / 1000)}
|
||||||
oninput={(e) => {
|
oninput={(e) => {
|
||||||
const input = e.target as HTMLInputElement | null;
|
const input = e.target as HTMLInputElement | null;
|
||||||
if (input && input.value !== '') {
|
if (input && input.value !== '') {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue