<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
    <th:block th:include="include :: header('工具库')"/>
</head>
<body class="white-bg">
<div class="form-horizontal m wrapper wrapper-content animated fadeInRight ibox-content">
    <div class="col-sm-12 search-collapse">
        <form id="formId">
            <div class="select-list">
                <ul>
                    <li>
                        <label>订单号：</label>
                        <input type="text" name="orderCode"/>
                    </li>
                    <li>
                        <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i
                                class="fa fa-search"></i>&nbsp;搜索</a>
                        <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i
                                class="fa fa-refresh"></i>重置</a>
                    </li>
                </ul>
            </div>
        </form>
    </div>
    <div class="form-group">
        <table id="bootstrap-table"></table>
    </div>
</div>
<th:block th:include="include :: footer"/>
<script th:inline="javascript">
    var certificateType = [[${@dict.getType('zhengzai_certificate_type')}]];
    var options = {
        url: [[${url_info}]],
        modalName: "入场人信息",
        orderSc: "desc",
        orderItem: "created_at",
        updateUrl: [[${url_single}]] + "/{id}",
        columns: [
            {
                field: 'orderTicketEntitiesId',
                title: '票单id'
            }, {
                field: 'enterName',
                title: '入场人姓名'
            }, {
                field: 'enterMobile',
                title: '入场人手机号'
            }, {
                field: 'enterIdCode',
                title: '入场人证件号'
            }, {
                field: 'enterType',
                title: '证件类型',
                formatter: function(value, row, index) {
                    return $.table.selectDictLabel(certificateType, value);
                }
            },
            {
                title: '操作',
                align: 'center',
                formatter: function (value, row, index) {
                    var actions = [];
                    actions.push('<a class="btn btn-success btn-xs " href="javascript:void(0)" onclick="$.operate.edit(\'' + row.orderTicketEntitiesId + '\')"><i class="fa fa-edit"></i>修改</a> ');
                    return actions.join('');
                }
            }]
    };
    $.table.init(options);
    // }
</script>
</body>
</html>
