<!--设置计提期限-->
<div class="modal fade" id="deadline" data-backdrop="static">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title">设置计提期限</h5>
            </div>
            <div class="modal-body">
                <p>请设置付（扣）款项 <b>本期应付</b> 的计提期限</p>
                <div class="form-group">
                    <label for="formGroupExampleInput">限制模式为：</label>
                    <div>
                        <div class="form-check form-check-inline">
                            <input class="form-check-input" type="radio" name="dl-type" id="inlineRadio1" value="0">
                            <label class="form-check-label" for="inlineRadio1">无</label>
                        </div>
                        <div class="form-check form-check-inline">
                            <input class="form-check-input" type="radio" name="dl-type" id="inlineRadio2" value="1">
                            <label class="form-check-label" for="inlineRadio2">计量期数</label>
                        </div>
                        <div class="form-check form-check-inline">
                            <input class="form-check-input" type="radio" name="dl-type" id="inlineRadio3" value="2">
                            <label class="form-check-label" for="inlineRadio3">计量金额</label>
                        </div>
                    </div>
                </div>
                <!--计量期数模式-->
                <div class="form-group" dl-type="1">
                    <label>限制期数</label>
                    <input class="form-control" id="stage-count" type="number">
                </div>
                <!--计量金额模式-->
                <div class="form-group" dl-type="2">
                    <label for="formGroupExampleInput"></label>
                    <div>
                        <div class="form-check form-check-inline">
                            <input class="form-check-input" type="radio" name="tp-type" id="ilRadio1" value="gather">
                            <label class="form-check-label" for="ilRadio1">累计完成计量金额</label>
                        </div>
                        <div class="form-check form-check-inline">
                            <input class="form-check-input" type="radio" name="tp-type" id="ilRadio2" value="contract">
                            <label class="form-check-label" for="ilRadio2">累计合同计量金额</label>
                        </div>
                        <div class="form-check form-check-inline">
                            <input class="form-check-input" type="radio" name="tp-type" id="ilRadio3" value="qc">
                            <label class="form-check-label" for="ilRadio3">累计变更计量金额</label>
                        </div>
                    </div>
                </div>
                <div class="form-group" dl-type="2">
                    <label>限制金额</label>
                    <input class="form-control" id="tp" type="number">
                </div>
                <!--公用提示-->
                <div id="dl-hint">
                    <p>设置为：</p>
                    <p id="range-hint" class="pl-3 text-danger">当 累计完成计量金额 >= 50000.00 时</p>
                    <p class="pl-3">当期金额直接计量至（扣款限额 - 截止上期金额）</p>
                </div>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-secondary" data-dismiss="modal">关闭</button>
                <% if (!stage.readOnly) { %>
                <button type="button" class="btn btn-primary" id="deadline-ok">确定</button>
                <% } %>
            </div>
        </div>
    </div>
</div>
<!--附件-->
<div class="modal fade" id="file" data-backdrop="static">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title">附件</h5>
            </div>
            <div class="modal-body">
                <% if (uploadPermission) { %>
                <div class="form-group">
                    <label for="formGroupExampleInput">大小限制：10MB，支持<span data-toggle="tooltip" data-placement="bottom" title="doc,docx,xls,xlsx,ppt,pptx,pdf">office等文档格式</span>、<span data-toggle="tooltip" data-placement="bottom" title="jpg,png,bmp">图片格式</span>、<span data-toggle="tooltip" data-placement="bottom" title="rar,zip">压缩包格式</span></label>
                    <input type="file" class="form-control" id="upload-file" multiple>
                </div>
                <% } %>
                <div class="modal-height-500" style="overflow:auto;">
                    <table class="table table-sm table-bordered" style="word-break:break-all; table-layout: fixed">
                        <thead>
                        <tr><th width="240">文件名</th><th>上传人</th><th>上传时间</th><th width="40">操作</th></tr>
                        </thead>
                        <tbody id="pay-attList">
                        <tr>
                            <td>XXXX.jpg</td><td>张三</td><td>2018-01-01</td><td><a href="#" target="_blank" title="下载"><i class="fa fa-download "></i></a> <a class="text-danger" href="#" target="_blank" title="删除"><i class="fa fa-remove "></i></a></td>
                        </tr>
                        <tr>
                            <td>YYYY.jpg</td><td>李四</td><td>2018-01-01</td><td><a href="#" target="_blank" title="下载"><i class="fa fa-download "></i></a></td>
                        </tr>
                        </tbody>
                    </table>
                </div>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-secondary" data-dismiss="modal">关闭</button>
                <!--<button type="button" class="btn btn-primary" id="upload-file-btn">确定</button>-->
            </div>
        </div>
    </div>
</div>
<!--明细-->
<div class="modal fade" id="detail" data-backdrop="static">
    <div class="modal-dialog modal-lg" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title">章节明细</h5>
            </div>
            <div class="modal-body">
                <table class="table table-sm table-bordered">
                    <thead>
                    <tr class="text-center"><th>章节名称</th><th>本期合同计量金额</th><th>本期变更计量金额</th><th>本期完成计量基金</th><th>累计完成计量金额</th></tr>
                    </thead>
                    <tbody id="detail-list"></tbody>
                </table>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-secondary" data-dismiss="modal">关闭</button>
            </div>
        </div>
    </div>
</div>
<% include ./audit_modal.ejs %>
