<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org" xmlns:sptg="http://www.thymeleaf.org">
    <head>
        <script th:replace="common/head"></script>
        <link xmlns:th="http://www.thymeleaf.org" rel="stylesheet" th:href="${'/css/estate/access.css'}" media="all">
    </head>
    <body style="margin: 10px">
        <div class="layui-card layui-fluid">
            <div class="layui-card-body">
<!--                <div class="layui-form" lay-filter="">-->
<!--                    <div class="layui-row" style="padding: 5px">-->
<!--                        <div class="layui-col-xs6 layui-col-sm6 layui-col-md6">-->
<!--                            <label class="layui-form-label">缴费日期</label>-->
<!--                            <div class="layui-input-block">-->
<!--                                <input th:value="${bills.billsDate}" id="dateSelector" placeholder="请选择账单日期"  class="layui-input" name="billsDate">-->
<!--                            </div>-->
<!--                        </div>-->
<!--                        <div class="layui-col-xs6 layui-col-sm6 layui-col-md4">-->
<!--                            <label class="layui-form-label">支付状态</label>-->
<!--                            <div class="layui-input-block">-->
<!--                                <select id="status" name="status">-->
<!--                                    <option></option>-->
<!--                                    <option th:selected="${bills.status==1}" value="1">未支付</option>-->
<!--                                    <option th:selected="${bills.status==2}" value="2">已支付</option>-->
<!--                                </select>-->
<!--                            </div>-->
<!--                        </div>-->
<!--                    </div>-->

<!--                    <div class="layui-form-item">-->
<!--                        <div class="layui-form" lay-filter="agency_filter">-->
<!--                            <label class="layui-form-label"><span class="must">*</span>所属社区</label>-->
<!--                            <div class="layui-input-inline">-->
<!--                                <div id="agency_id"></div>-->
<!--                            </div>-->
<!--                        </div>-->
<!--                        <div class="layui-form" lay-filter="residential_filter">-->
<!--                            <label class="layui-form-label"><span class="must">*</span>所属小区</label>-->
<!--                            <div class="layui-input-inline">-->
<!--                                <div id="residential_id"></div>-->
<!--                            </div>-->
<!--                        </div>-->
<!--                    </div>-->

<!--                    <div class="layui-form-item">-->
<!--                        <div class="layui-form" lay-filter="building_filter">-->
<!--                            <label class="layui-form-label"><span class="must">*</span>所属楼栋</label>-->
<!--                            <div class="layui-input-inline">-->
<!--                                <div id="building_id"></div>-->
<!--                            </div>-->
<!--                        </div>-->
<!--                        <div class="layui-form" lay-filter="unit_filter">-->
<!--                            <label class="layui-form-label"><span class="must">*</span>所属单元</label>-->
<!--                            <div class="layui-input-inline">-->
<!--                                <div id="unit_id"></div>-->
<!--                            </div>-->
<!--                        </div>-->
<!--                    </div>-->

<!--                    <div class="layui-form-item">-->
<!--                        <div class="layui-form" lay-filter="floor_filter">-->
<!--                            <label class="layui-form-label"><span class="must">*</span>所属楼层</label>-->
<!--                            <div class="layui-input-inline">-->
<!--                                <div id="floor_id"></div>-->
<!--                            </div>-->
<!--                        </div>-->
<!--                        <div class="layui-form" lay-filter="room_filter">-->
<!--                            <label class="layui-form-label"><span class="must">*</span>所属房间</label>-->
<!--                            <div class="layui-input-inline">-->
<!--                                <div id="room_id"></div>-->
<!--                            </div>-->
<!--                        </div>-->
<!--                    </div>-->

<!--                    <div  style="display: none" >-->
<!--                        <div class="item right" >id :</div>-->
<!--                        <input th:value="${bills.id}" class="layui-input" placeholder="请输入id" name="id">-->
<!--                    </div>-->
<!--                    &lt;!&ndash;                <table id="itemTable" lay-filter="itemTable"></table>&ndash;&gt;-->
<!--                    <table style="width: 100%;margin-top: 10px;margin-bottom: 20px" border="1">-->
<!--                        <tr style="background: rgb(135,226,225);height: 35px;font-size: 18px">-->
<!--                            <th style="width: 20%">缴费项</th>-->
<!--                            <th style="width: 20%">缴费金额</th>-->
<!--                            <th style="width: 40%">备注</th>-->
<!--                            <th style="width: 10%">操作</th>-->
<!--                        </tr>-->
<!--                        <tr th:each="item : ${bills.itemList}" style="text-align: center;height: 30px">-->
<!--                            <td th:text="${item.itemName}"></td>-->
<!--                            <td th:text="${item.itemFee}+'￥'"></td>-->
<!--                            <td th:text="${item.itemDesc==null? '无':item.itemDesc}"></td>-->
<!--                            <td><div class="layui-btn layui-btn-danger layui-btn-xs">删除</div></td>-->
<!--                        </tr>-->
<!--                        <tr style="text-align: center;height: 30px;">-->
<!--                            <td style="padding-left:20px"><input  class="full"  type="text" name="title"   placeholder="请输入缴费项名称"></td>-->
<!--                            <td style="padding-left:20px"><input  class="full"  type="number" name="price"   placeholder="缴费金额" ></td>-->
<!--                            <td style="padding-left:20px"><input  class="full" type="text" name="desc"   placeholder="缴费说明"></td>-->
<!--                            <td><div class="layui-btn  layui-btn-xs" >添加</div></td>-->
<!--                        </tr>-->
<!--                    </table>-->
<!--                    <div >-->
<!--                        <div class="layui-input-block">-->
<!--                            <button class="layui-btn" lay-submit lay-filter="submit_edit" >修改</button>-->
<!--                            <button type="reset" class="layui-btn layui-btn-primary" id="cancel_btn">取消</button>-->
<!--                        </div>-->
<!--                    </div>-->
<!--                </div>-->

                <form class="layui-form layuiadmin-card-header-auto layui-card-header">
                    <div class="layui-row" style="padding: 5px">
                        <div class="layui-col-xs6 layui-col-sm6 layui-col-md6">
                            <label class="layui-form-label">缴费日期</label>
                            <div class="layui-input-block">
                                <input th:value="${bills.billsDate}" id="dateSelector" placeholder="请选择账单日期"  class="layui-input" name="billsDate">
                            </div>
                        </div>
                    </div>
                    <div class="layui-form-item">
                        <div class="layui-col-xs6 layui-col-sm6 layui-col-md4">
                            <label class="layui-form-label">支付状态</label>
                            <div th:value="${bills.status}" class="layui-input-block">
                                <select  name="status">
                                    <option></option>
                                    <option th:selected="${bills.status==1}" value="1">未支付</option>
                                    <option th:selected="${bills.status==2}" value="2">已支付</option>
                                </select>
                            </div>
                        </div>
                    </div>

                    <div class="layui-form-item">
                        <div class="layui-form">
                            <label class="layui-form-label"><span class="must">*</span>总费用</label>
                            <div class="layui-input-inline">
                                <input th:value="${bills.totalFee}" id="total_fee" name="totalFee" type="number" placeholder="请输入总费用"  class="layui-input">
                            </div>
                        </div>
                    </div>

                    <div class="layui-row" style="padding: 5px">

                        <div class="layui-col-xs6 layui-col-sm6 layui-col-md6" lay-filter="residential_filter">
                            <label class="layui-form-label">小区名称</label>
                            <div class="layui-input-block">
                                <input th:value="${bills.residentialName}" class="layui-input" placeholder="请输入小区名称" name="residentialName">
                            </div>
                        </div>
                        <div class="layui-col-xs6 layui-col-sm6 layui-col-md6">
                            <label class="layui-form-label">楼栋名称</label>
                            <div class="layui-input-block">
                                <input th:value="${bills.buildingName}" class="layui-input" placeholder="请输入楼栋名称" name="buildingName">
                            </div>
                        </div>
                    </div>
                    <div class="layui-row" style="padding: 5px">

                        <div class="layui-col-xs6 layui-col-sm6 layui-col-md6">
                            <label class="layui-form-label">单元名称</label>
                            <div class="layui-input-block">
                                <input th:value="${bills.unitName}" class="layui-input" placeholder="请输入单元名称" name="unitName">
                            </div>
                        </div>
                        <div class="layui-col-xs6 layui-col-sm6 layui-col-md6">
                            <label class="layui-form-label">房间名称</label>
                            <div class="layui-input-block">
                                <input th:value="${bills.roomName}" class="layui-input" placeholder="请输入房间名称" name="roomName">
                            </div>
                        </div>
                    </div>

                    <div  style="display: none" >
                        <div class="item right" >id :</div>
                        <input th:value="${bills.id}" class="layui-input" placeholder="请输入id" name="id">
                    </div>
                    <!--                <table id="itemTable" lay-filter="itemTable"></table>-->
                    <table style="width: 100%;margin-top: 10px;margin-bottom: 20px" border="1">
                        <tr style="background: rgb(135,226,225);height: 35px;font-size: 18px">
                            <th style="width: 20%">缴费项</th>
                            <th style="width: 20%">缴费金额</th>
                            <th style="width: 40%">备注</th>
<!--                            <th style="width: 10%">操作</th>-->
                        </tr>
<!--                        <tr th:each="item : ${bills.itemList}" style="text-align: center;height: 30px">-->
<!--                            <td th:text="${item.itemName}"></td>-->
<!--                            <td th:text="${item.itemFee}+'￥'"></td>-->
<!--                            <td th:text="${item.itemDesc==null? '无':item.itemDesc}"></td>-->
<!--&lt;!&ndash;                            <td><div class="layui-btn layui-btn-danger layui-btn-xs" id="delete_bills_item">删除</div></td>&ndash;&gt;-->
<!--                        </tr>-->
                        <tr style="text-align: center;height: 70px;" th:if="${bills.itemList[0].itemName !=null}">
                            <td style="padding-left:20px"><input th:value="${bills.itemList[0].itemName}" class="full"  type="text" name="itemName"   placeholder="请输入缴费项名称"></td>
                            <td style="padding-left:20px"><input th:value="${bills.itemList[0].itemFee}" class="full"  type="number" name="itemFee"   placeholder="缴费金额" ></td>
                            <td style="padding-left:20px"><input th:value="${bills.itemList[0].itemDesc==null? '无': bills.itemList[0].itemDesc}" class="full" type="text" name="itemDesc"   placeholder="缴费说明"></td>
<!--                            <td><div class="layui-btn  layui-btn-xs" >添加</div></td>-->
                        </tr>
                    </table>
                    <div >
                        <div class="layui-input-block">
                            <button class="layui-btn" type="button" lay-submit lay-filter="submit_edit" >修改</button>
                            <button type="reset" class="layui-btn layui-btn-primary" id="cancel_btn">取消</button>
                        </div>
                    </div>
                </form>


            </div>
        </div>
        <!-- javascript -->
        <script type="text/javascript" th:src="@{'/layui/layui.js'}"></script>
        <script type="text/javascript">
            layui.config({
                base: '/' //静态资源所在路径
            });
        </script>
        <script type="text/javascript" th:src="@{'/js/estate/bills-edit.js'}"></script>
    </body>
    <style>
        .full{
            border: none;
            width: 100%;
            background: rgba(255, 255, 255, 0);
        }
    </style>

</html>