<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head th:replace="/common/template :: header(~{::title},~{::link},~{::style})">
</head>
<body>
    <div class="layui-form timo-compile">
    <form th:action="@{/bss/vatInvoice/edit}">
        <input type="hidden" name="id" th:if="${bssVatInvoice}" th:value="${bssVatInvoice.id}">
        <div class="layui-form-item">
            <label class="layui-form-label">发票类型</label>
            <div class="layui-input-inline">
                <select id="invoiceType" name="invoiceType" lay-filter="invoiceType" >
                    <option th:selected="${bssVatInvoice.invoiceType} eq '0'" value="0">增值税普通发票</option>
                    <option th:selected="${bssVatInvoice.invoiceType} eq '1'" value="1">增值税专用发票</option>
                </select>
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">发票代码</label>
            <div class="layui-input-inline">
                <input class="layui-input" type="text" name="invoiceCode" placeholder="请输入发票代码" th:value="${bssVatInvoice.invoiceCode}">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">发票号码</label>
            <div class="layui-input-inline">
                <input class="layui-input" type="text" name="invoiceNo" placeholder="请输入发票号码" th:value="${bssVatInvoice.invoiceNo}">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">发票日期</label>
            <div class="layui-input-inline">
                <input class="layui-input" type="text" name="invoiceDate" placeholder="请输入发票日期" th:value="${bssVatInvoice.invoiceDate}">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">校验码</label>
            <div class="layui-input-inline">
                <input class="layui-input" type="text" name="checkCode" placeholder="请输入校验码" th:value="${bssVatInvoice.checkCode}">
            </div>
        </div>
        <!--<div class="layui-form-item">
            <label class="layui-form-label">机器编码</label>
            <div class="layui-input-inline">
                <input class="layui-input" type="text" name="machineNo" placeholder="请输入机器编码" th:value="${bssVatInvoice.machineNo}">
            </div>
        </div>-->
        <div class="layui-form-item">
            <label class="layui-form-label">发票金额</label>
            <div class="layui-input-inline">
                <input class="layui-input" type="text" name="invoiceMoney" placeholder="请输入发票金额" th:value="${bssVatInvoice.invoiceMoney}">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">税额</label>
            <div class="layui-input-inline">
                <input class="layui-input" type="text" name="taxAmount" placeholder="请输入税额" th:value="${bssVatInvoice.taxAmount}">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">总金额</label>
            <div class="layui-input-inline">
                <input class="layui-input" type="text" name="totalAmount" placeholder="请输入总金额" th:value="${bssVatInvoice.totalAmount}">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">总金额(大写)</label>
            <div class="layui-input-inline">
                <input class="layui-input" type="text" name="totalAmountCn" placeholder="请输入总金额(大写)" th:value="${bssVatInvoice.totalAmountCn}">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">购买方纳税人信息</label>
            <div class="layui-input-inline">
                <input class="layui-input" type="text" name="buyTaxInfo" placeholder="请输入购买方纳税人信息" th:value="${bssVatInvoice.buyTaxInfo?.name}">
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">销售方纳税人信息</label>
            <div class="layui-input-inline">
                <input class="layui-input" type="text" name="salerTaxInfo" placeholder="请输入销售方纳税人信息" th:value="${bssVatInvoice.salerTaxInfo?.name}">
            </div>
        </div>
        <div class="layui-form-item layui-form-text">
            <label class="layui-form-label">备注</label>
            <div class="layui-input-block">
                <textarea placeholder="请输入内容" class="layui-textarea" name="remark">[[${bssVatInvoice.remark}]]</textarea>
            </div>
        </div>
        <div class="layui-form-item timo-finally">
            <button class="layui-btn ajax-submit"><i class="fa fa-check-circle"></i> 保存</button>
            <button class="layui-btn btn-secondary close-popup"><i class="fa fa-times-circle"></i> 关闭</button>
        </div>
    </form>
</div>
<script th:replace="/common/template :: script"></script>
</body>
</html>