将滚动条添加到我的JQuery UI对话框中

时间:2015-08-24 12:39:01

标签: javascript jquery html css

这是我的对话:

enter image description here

有很多字段,所以不是添加滚动条,所以一切都可以适合那里的对话框简单地#34;结束"并继续将它们添加到对话框之外。

这是我的HTML代码:

<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
<link rel="stylesheet" href="../css/pure/pure-min.css">
<link rel="stylesheet" type="text/css"
    href="../css/jquery/jquery-ui.theme.css">
</head>
<body>
    <div id="divCadastrarNotaFiscal">
        <form class="pure-form pure-form-stacked" id="formCadastrar">
            <fieldset>
                <label>Órgão</label> <input readonly="readonly" size="3" value="03">
                <label>Unidade Orçamentaria</label> <input name="" size="3"
                    maxlength="3"> <label>Número do Empenho</label> <input
                    name="" size="10" maxlength="10"> <label>Número da
                    Liquidação</label> <input name="" size="10" maxlength="10"> <label>Credor</label>
                <input name="" size="18" maxlength="18"> <label>Serie
                    da Nota Fiscal</label> <input name="" size="2" maxlength="2"> <label>Número
                    da Nota Fiscal</label> <input name="" size="10" maxlength="10"> <label>Data
                    da Nota Fiscal</label> <input name="" size="10" maxlength="10"> <label>Valor
                    do Desconto</label> <input name="NTFSC_VALORDESCONTO" size="12"
                    maxlength="12" class="double"> <label>Codigo de
                    Verificação NFISS</label> <input name="" size="20" maxlength="20">
                <label>Valor da Nota</label> <input name="NTFSC_VALORNOTA" size="12"
                    maxlength="12" class="double"> <label>Valor Liquido</label>
                <input name="NTFSC_VALORLIQUIDO" size="12" maxlength="12"
                    class="double"> <label>Núm. NFE</label> <input name=""
                    size="44" maxlength="44"> <label>Comprovante da
                    Sefaz/MT</label> <input name="" size="9" maxlength="9"> <label>Modelo</label>
                <select name="NTFSC_MODELO">
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="55">55</option>
                </select> <label>Objeto</label>
                <textarea cols="100" rows="4" name="NTFSC_OBJETO"></textarea>
                <label>Arquivo PDF</label> <input type="file"
                    class="custom-file-input"> <input type="button"
                    value="Cadastrar" class="pure-button pure-button-primary"
                    id="botaoCadastrar">
            </fieldset>
        </form>
    </div>
    <script src="../js/jquery/jquery.js"></script>
    <script src="../js/jquery/jquery-ui.min.js"></script>
    <script src="../js/cadastrarNotaFiscal.js"></script>
</body>
</html>

我的cadastrarNotaFiscal.js文件:

$(document)
        .ready(
                function() {
                    $("#divCadastrarNotaFiscal")
                            .dialog(
                                    {
                                        modal : true,
                                        buttons : [ {
                                            id : "dialogFechar",
                                            text : "Fechar",
                                            click : function() {
                                                $(this).empty();
                                                $(this).dialog("destroy");
                                            }
                                        } ],
                                        width : $(window).width() * 0.75,
                                        height : $(window).height() * 0.75,
                                        resizable : false,
                                        show : {
                                            effect : "blind",
                                            duration : 300
                                        },
                                        hide : {
                                            effect : "explode",
                                            duration : 300
                                        },
                                        close : function(event, ui) {
                                            $(this).empty();
                                            $(this).dialog("destroy");
                                        },
                                        open : function(event, ui) {
                                            document
                                                    .getElementById("divCadastrarNotaFiscal").style.color = "black";
                                            document
                                                    .getElementById("dialogFechar").style.fontSize = "10px";
                                        }
                                    });
                });

有什么建议吗?

奖金问题:为什么关闭按钮出现在那里而不是&#34; X&#34;在右上角?

0 个答案:

没有答案
相关问题