成都创新互联网站制作重庆分公司

解决select2在bootstrapmodal中不能正常使用问题

select2在bootstrap modal中不能正常使用问题

设置CSS

        .select2-drop {
            z-index: 10050 !important;
        }

        .select2-search-choice-close {
            margin-top: 0 !important;
            right: 2px !important;
            min-height: 10px;
        }

        .select2-search-choice-close:before {
            color: black !important;
        }

        /*防止select2不会自动失去焦点*/
        .select2-container {
            z-index: 16000 !important;
        }

        .select2-drop-mask {
            z-index: 15990 !important;
        }

        .select2-drop-active {
            z-index: 15995 !important;
        }

设置下拉

$("#User").select2(
  {dropdownParent: $("#Modal")}
)

分享题目:解决select2在bootstrapmodal中不能正常使用问题
地址分享:http://cxhlcq.com/article/jcdhgh.html

其他资讯

在线咨询

微信咨询

电话咨询

028-86922220(工作日)

18980820575(7×24)

提交需求

返回顶部