Files
weiguang-jewelry-ledger/演示/周转金/public/index.html
T

90 lines
8.6 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<!doctype html>
<html lang="zh-CN">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="theme-color" content="#254e40">
<title>周转金日结 · 独立演示</title>
<link rel="stylesheet" href="/app.css">
<script src="/app.js" defer></script>
</head>
<body>
<div id="toast" role="status" aria-live="polite" hidden></div>
<header class="app-header">
<a class="brand" href="/" aria-label="周转金日结演示首页">
<span class="brand-mark" aria-hidden="true">麦</span>
<span><strong>周转金日结 <span class="brand-dot">·</span> 独立演示</strong><small>把今天赚的、垫的、该转的,一起对清楚。</small></span>
</a>
<span class="badge">本机试算</span>
</header>
<div class="demo-notice"><span class="notice-dot" aria-hidden="true"></span>示例数据,仅用于试算;当前账目保持原规则。</div>
<main>
<section class="toolbar" aria-label="演示日期与视角">
<label class="date-control">查看日期<input id="report-date" type="date" value="2026-11-01" required></label>
<div class="view-control"><span class="control-label">演示视角</span><div id="view-tabs" class="segmented" role="group" aria-label="选择演示视角"></div></div>
<div class="toolbar-actions"><button type="button" class="text-button" id="complex-scenario">试试复杂场景<span aria-hidden="true"> ↗</span></button><button type="button" class="text-button muted" id="reset-demo">重置演示</button></div>
</section>
<p class="view-disclaimer">视角切换只演示页面效果,不代表真实登录或权限验证。</p>
<div id="load-error" class="error page-error" role="alert" hidden><span></span><button type="button" id="retry-load">重新加载</button></div>
<div id="loading" class="loading-state" role="status">正在整理示例账目…</div>
<div id="dashboard" hidden>
<div class="page-heading"><div><p id="day-caption" class="eyebrow"></p><h1 id="page-title">今天的钱,对清楚了。</h1></div><div class="actions"><button type="button" data-open="opening-dialog">设置期初</button><button type="button" data-open="purchase-dialog">+ 新增购料</button><button type="button" data-open="order-dialog" class="primary">+ 新增销售</button></div></div>
<div id="scenario-note" class="scenario-note" hidden></div>
<section id="daily-summary" aria-label="当日日结"></section>
<section id="member-summary" aria-label="成员资金"></section>
<section id="material-pool" aria-label="材料池"></section>
<section id="activity" aria-label="账目明细"></section>
<p class="bottom-note">这个演示只接收“已交付、已收齐”的普通销售。只核对所选日,不登记转账或推断已经付款。</p>
</div>
</main>
<footer class="app-footer">麦麦珠宝 · 周转金日结演示 <span>独立示例空间,与当前正式账目分开。</span></footer>
<dialog id="purchase-dialog" aria-labelledby="purchase-title">
<form id="purchase-form">
<div class="dialog-heading"><div><p class="eyebrow">材料池</p><h2 id="purchase-title">新增购料</h2></div><button type="button" class="close-button" data-close aria-label="关闭新增购料">×</button></div>
<p class="dialog-description">谁付了钱,就记在谁的资金来源里。没用完的料继续留在材料池。</p>
<div class="form-grid"><label>购料日期<input name="date" type="date" required></label><label>付款人<select name="payer" required></select></label><label>购料克重(g)<input name="grams" type="number" inputmode="decimal" min="0.001" step="0.001" required placeholder="例如 10.000"></label><label>实付总额(元)<input name="total" type="number" inputmode="decimal" min="0.01" step="0.01" required placeholder="例如 10000.00"></label></div>
<div class="unit-price-preview"><span>自动购料单价</span><output id="purchase-unit-price">填入克重和总额后显示</output></div>
<label class="full-field">备注<input name="note" maxlength="200" placeholder="例如:补一批料,继续用于明天订单"></label>
<div class="form-error error" role="alert" hidden></div>
<div class="form-actions"><span>仅写入当前演示</span><button type="submit" class="primary">保存购料</button></div>
</form>
</dialog>
<dialog id="order-dialog" aria-labelledby="order-title">
<form id="order-form">
<div class="dialog-heading"><div><p class="eyebrow">已交付、已收齐</p><h2 id="order-title">新增销售</h2></div><button type="button" class="close-button" data-close aria-label="关闭新增销售">×</button></div>
<p class="dialog-description">只试算普通销售;每笔收入、材料和费用都记清实际收付款人。</p>
<div class="form-grid"><label>销售日期<input name="date" type="date" required></label><label>归属成员<select name="member" required></select></label><label>客户代号<input name="customer" maxlength="40" required placeholder="例如:小禾"></label><label>用料克重(g)<input name="grams" type="number" inputmode="decimal" min="0.001" step="0.001" required placeholder="例如 1.500"></label><label>销售实收(元)<input name="sale" type="number" inputmode="decimal" min="0.01" step="0.01" required placeholder="例如 2000.00"></label><label>收款渠道<select name="channel" required><option value="wechat">微信</option><option value="alipay">支付宝</option><option value="bank">银行卡</option><option value="cash">现金</option><option value="credit_card">信用卡</option></select></label><label>实际收款人<select name="collector" required></select></label><label>工费等支出(元)<input name="expenseAmount" type="number" inputmode="decimal" min="0" step="0.01" value="0.00" required></label><label>支出付款人<select name="expensePayer" required></select></label><label>材料来源<select name="materialSource"><option value="pool">共用材料池</option><option value="direct">订单单独购料</option></select></label></div>
<div id="direct-material-fields" class="inline-fields form-grid" hidden><label>单独购料金额(元)<input name="directMaterialCost" type="number" inputmode="decimal" min="0.01" step="0.01"></label><label>材料付款人<select name="directMaterialPayer"></select></label></div>
<p id="credit-card-note" class="form-note" hidden>信用卡统一由麦麦收款,6‰手续费由麦麦支付;费用计入这张订单。</p>
<p class="form-footnote">订单利润=销售实收-材料成本-工费等支出-信用卡手续费。</p>
<details class="section-details"><summary>亏损单的演示设置</summary><label class="check-field"><input name="allowLoss" type="checkbox">作为亏损待复核单登记,不自动向助理补利润。</label></details>
<div class="form-error error" role="alert" hidden></div>
<div class="form-actions"><span>保存后自动重算日结</span><button type="submit" class="primary">保存销售</button></div>
</form>
</dialog>
<dialog id="opening-dialog" aria-labelledby="opening-title" class="small-dialog">
<form id="opening-form">
<div class="dialog-heading"><div><p class="eyebrow">周转金</p><h2 id="opening-title">设置期初</h2></div><button type="button" class="close-button" data-close aria-label="关闭设置期初">×</button></div>
<p class="dialog-description">设置每个人的初期余额,作为每日对账参考。</p>
<div class="form-grid"><label>成员<select name="member" required></select></label><label>期初周转金(元)<input name="amount" type="number" inputmode="decimal" min="0" step="0.01" required></label></div>
<div class="form-error error" role="alert" hidden></div>
<div class="form-actions"><span>仅调整示例</span><button type="submit" class="primary">保存期初</button></div>
</form>
</dialog>
<dialog id="reset-dialog" aria-labelledby="reset-title" class="small-dialog">
<form id="reset-form">
<div class="dialog-heading"><div><p class="eyebrow">演示场景</p><h2 id="reset-title">重新开始这次试算?</h2></div><button type="button" class="close-button" data-close aria-label="取消重置">×</button></div>
<p id="reset-description" class="dialog-description"></p>
<div class="form-error error" role="alert" hidden></div>
<div class="form-actions"><button type="button" data-close>保留当前试算</button><button type="submit" class="primary" id="reset-confirm">重置演示</button></div>
</form>
</dialog>
</body>
</html>