function setSearchLo(className,left){ $('#example_filter').addClass("search-dataTables"+className); $('#example_filter').css({'left':left}); $('#example_filter label').addClass("dataTables-label"); $('#example_filter input').addClass("dataTables-input"); } function autoFlashHeight(){ var infoHeight = $(".contactInfo").height(); var headerHeight = $(".header").height(); var cateHeight = $(".contactCate").height(); var groupcHeight = $(".groupCate").height(); var lockHeight = $(".lockCate").height(); var contactTab = $(".contactTab").height(); var seCensor = $(".seCensor").height(); var btnList = $(".reportButton").height(); $(".autoHeight").height($(window).height()); $(".autoHeightL1").height($(window).height()-lockHeight-53); $(".autoHeightL2").height($(window).height()-cateHeight-86); $(".autoHeightL3").height($(window).height()-groupcHeight-77); $(".autoHeightR1").height($(window).height()-infoHeight-contactTab-2); $(".autoHeightR2").height($(window).height()-headerHeight-contactTab-17); $(".autoHeightR3").height($(window).height()-contactTab); $(".autoHeightR4").height($(window).height()-infoHeight-48); $(".autoHeightR5").height($(window).height()-48); $(".autoHeightI1").height($(window).height()-144); $(".autoHeightI2").height($(window).height()-132); $(".mailAutoHeigh").height($(window).height()-75); $(".censorHeight").height(seCensor-btnList-27); }; $(window).resize(autoFlashHeight); $(function(){ var infoHeight = $(".contactInfo").height(); $(".zhzdFir").click(function () { $(this).toggleClass("now").siblings(".zhzdMenu").slideToggle("fast") }); $(".amInput").children("label").children("input:checkbox").click(function(){ if($(this).is(":checked")) { // 当前未选中 $(".amInput").find("input:checked").removeAttr("checked"); $(this).attr("checked", "checked"); } }); $(".pmInput").children("label").children("input:checkbox").click(function(){ if($(this).is(":checked")) { // 当前未选中 $(".pmInput").find("input:checked").removeAttr("checked"); $(this).attr("checked", "checked"); } }); $('*[data-toggle=ctooltip]').mouseover(function() { $(this).ctooltip('show'); }); $("#openRecallInput").click(function(){ $(this).parent(".toolItem").hide().siblings(".toolItem").show(); }); /*顶部提醒*/ $("#openRemind").click(function(){ $(this).toggleClass("focus").siblings(".remindList").toggle("fast"); $(".remind").toggleClass("focus") } ); /*顶部提醒*/ $("#closeST").click(function(){ $(".searchTips").hide(); }); // $('.tipFather').hover(function() { // $(".tipContent").removeClass('tipConactive'); // }, function() { // $(".tipContent").addClass('tipConactive'); // }); $(".sortAddup").hover(function () { $(this).siblings("ul,div").animate({opacity:'0.2'},0); $(this).addClass("focus").find(".sec").show(); }, function () { $(this).siblings("ul,div").animate({opacity:'1'},0); $(this).removeClass("focus").find("dl").hide(); } ); $(".rmDone").click(function(){ $(this).parent().parent("th").removeClass().toggleClass("grM"); }); $(".rmUdone").click(function(){ $(this).parent().parent("th").removeClass().toggleClass("reM"); }); $(".rmClear").click(function(){ $(this).parent().parent("th").removeClass(); }); $(".smileImg").click(function(){ $(this).siblings(".smileItem").toggle(); }); $(".demandBoard .tab a").click(function(){ $(this).addClass("focus").siblings().removeClass("focus"); $(".boardList .entry ").hide().eq($(".demandBoard .tab a").index(this)).show();}); /*档案库类别折叠2*/ $(".snavLeve0 li").click(function(){ $(this).children("h4").addClass("focus"); $(this).children(".snavLeve1").slideDown(); $(this).siblings("li").children("h4").removeClass("focus"); $(this).siblings("li").children(".snavLeve1").slideUp(); }); /*侧滑窗口*/ $(".opensidebar").click(function(){ $(".wrapDetil").animate({width:"702"}).addClass("open"); }); // $("body").click(function(event){ // var e = event || window.event; //浏览器兼容性 // var elem = event.target || e.srcElement; // while (elem) { //循环判断至跟节点,防止点击的是div子元素 // if (elem.className == "opensidebar" || elem.className == 'wrapDetil open') { // return false; // } // elem = elem.parentNode; // } // $(".wrapDetil").animate({width:"0"}).removeClass("open")// 关闭处理 // }); $("body").click(function(event){ var e = event || window.event; //浏览器兼容性 if(!$(event.target).is('a')) { var elem = event.target || e.srcElement; while (elem) { //循环判断至跟节点,防止点击的是div子元素 if (elem.className == "opensidebar" || elem.className == 'wrapDetil open') { return false; } elem = elem.parentNode; } $(".wrapDetil").animate({width:"0"}).removeClass("open")// 关闭处理 } }); /*侧滑窗口*/ }); function slideupInfo(c){ $(c).parent(".addRecord").hide().siblings(".addRecord").show(); $('.contactInfo').slideUp(); $('.lockRecord').toggleClass("autoHeightR1").height($(window).height()-53); }; function slidedownInfo(a){ var infoHeight = $(".contactInfo").height(); $(a).parent(".addRecord").hide().siblings(".addRecord").show(); $('.contactInfo').slideDown(); $('.lockRecord').toggleClass("autoHeightR1").height($(window).height()-infoHeight-48); }; /* ======================================================================== * Bootstrap: modal.js v3.3.0 * http://getbootstrap.com/javascript/#modals * ======================================================================== * Copyright 2011-2014 Twitter, Inc. * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) * ======================================================================== */ +function ($) { 'use strict'; // MODAL CLASS DEFINITION // ====================== var Modal = function (element, options) { this.options = options this.$body = $(document.body) this.$element = $(element) this.$backdrop = this.isShown = null this.scrollbarWidth = 0 if (this.options.remote) { this.$element .find('.modal-content') .load(this.options.remote, $.proxy(function () { this.$element.trigger('loaded.bs.modal') }, this)) } } Modal.VERSION = '3.3.0' Modal.TRANSITION_DURATION = 300 Modal.BACKDROP_TRANSITION_DURATION = 150 Modal.DEFAULTS = { backdrop: true, keyboard: true, show: true } Modal.prototype.toggle = function (_relatedTarget) { return this.isShown ? this.hide() : this.show(_relatedTarget) } Modal.prototype.show = function (_relatedTarget) { var that = this var e = $.Event('show.bs.modal', { relatedTarget: _relatedTarget }) this.$element.trigger(e) if (this.isShown || e.isDefaultPrevented()) return this.isShown = true this.checkScrollbar() this.$body.addClass('modal-open') this.setScrollbar() this.escape() this.$element.on('click.dismiss.bs.modal', '[data-dismiss="modal"]', $.proxy(this.hide, this)) this.backdrop(function () { var transition = $.support.transition && that.$element.hasClass('fade') if (!that.$element.parent().length) { that.$element.appendTo(that.$body) // don't move modals dom position } that.$element .show() .scrollTop(0) if (transition) { that.$element[0].offsetWidth // force reflow } that.$element .addClass('in') .attr('aria-hidden', false) that.enforceFocus() var e = $.Event('shown.bs.modal', { relatedTarget: _relatedTarget }) transition ? that.$element.find('.modal-dialog') // wait for modal to slide in .one('bsTransitionEnd', function () { that.$element.trigger('focus').trigger(e) }) .emulateTransitionEnd(Modal.TRANSITION_DURATION) : that.$element.trigger('focus').trigger(e) }) } Modal.prototype.hide = function (e) { if (e) e.preventDefault() e = $.Event('hide.bs.modal') this.$element.trigger(e) if (!this.isShown || e.isDefaultPrevented()) return this.isShown = false this.escape() $(document).off('focusin.bs.modal') this.$element .removeClass('in') .attr('aria-hidden', true) .off('click.dismiss.bs.modal') $.support.transition && this.$element.hasClass('fade') ? this.$element .one('bsTransitionEnd', $.proxy(this.hideModal, this)) .emulateTransitionEnd(Modal.TRANSITION_DURATION) : this.hideModal() } Modal.prototype.enforceFocus = function () { $(document) .off('focusin.bs.modal') // guard against infinite focus loop .on('focusin.bs.modal', $.proxy(function (e) { if (this.$element[0] !== e.target && !this.$element.has(e.target).length) { this.$element.trigger('focus') } }, this)) } Modal.prototype.escape = function () { if (this.isShown && this.options.keyboard) { this.$element.on('keydown.dismiss.bs.modal', $.proxy(function (e) { e.which == 27 && this.hide() }, this)) } else if (!this.isShown) { this.$element.off('keydown.dismiss.bs.modal') } } Modal.prototype.hideModal = function () { var that = this this.$element.hide() this.backdrop(function () { that.$body.removeClass('modal-open') that.resetScrollbar() that.$element.trigger('hidden.bs.modal') }) } Modal.prototype.removeBackdrop = function () { this.$backdrop && this.$backdrop.remove() this.$backdrop = null } Modal.prototype.backdrop = function (callback) { var that = this var animate = this.$element.hasClass('fade') ? 'fade' : '' if (this.isShown && this.options.backdrop) { var doAnimate = $.support.transition && animate this.$backdrop = $('
') .prependTo(this.$element) .on('click.dismiss.bs.modal', $.proxy(function (e) { if (e.target !== e.currentTarget) return this.options.backdrop == 'static' ? this.$element[0].focus.call(this.$element[0]) : this.hide.call(this) }, this)) if (doAnimate) this.$backdrop[0].offsetWidth // force reflow this.$backdrop.addClass('in') if (!callback) return doAnimate ? this.$backdrop .one('bsTransitionEnd', callback) .emulateTransitionEnd(Modal.BACKDROP_TRANSITION_DURATION) : callback() } else if (!this.isShown && this.$backdrop) { this.$backdrop.removeClass('in') var callbackRemove = function () { that.removeBackdrop() callback && callback() } $.support.transition && this.$element.hasClass('fade') ? this.$backdrop .one('bsTransitionEnd', callbackRemove) .emulateTransitionEnd(Modal.BACKDROP_TRANSITION_DURATION) : callbackRemove() } else if (callback) { callback() } } Modal.prototype.checkScrollbar = function () { this.scrollbarWidth = this.measureScrollbar() } Modal.prototype.setScrollbar = function () { var bodyPad = parseInt((this.$body.css('padding-right') || 0), 10) if (this.scrollbarWidth) this.$body.css('padding-right', bodyPad + this.scrollbarWidth) } Modal.prototype.resetScrollbar = function () { this.$body.css('padding-right', '') } Modal.prototype.measureScrollbar = function () { // thx walsh if (document.body.clientWidth >= window.innerWidth) return 0 var scrollDiv = document.createElement('div') scrollDiv.className = 'modal-scrollbar-measure' this.$body.append(scrollDiv) var scrollbarWidth = scrollDiv.offsetWidth - scrollDiv.clientWidth this.$body[0].removeChild(scrollDiv) return scrollbarWidth } // MODAL PLUGIN DEFINITION // ======================= function Plugin(option, _relatedTarget) { return this.each(function () { var $this = $(this) var data = $this.data('bs.modal') var options = $.extend({}, Modal.DEFAULTS, $this.data(), typeof option == 'object' && option) if (!data) $this.data('bs.modal', (data = new Modal(this, options))) if (typeof option == 'string') data[option](_relatedTarget) else if (options.show) data.show(_relatedTarget) }) } var old = $.fn.modal $.fn.modal = Plugin $.fn.modal.Constructor = Modal // MODAL NO CONFLICT // ================= $.fn.modal.noConflict = function () { $.fn.modal = old return this } // MODAL DATA-API // ============== $(document).on('click.bs.modal.data-api', '[data-toggle="modal"]', function (e) { var $this = $(this) var href = $this.attr('href') var $target = $($this.attr('data-target') || (href && href.replace(/.*(?=#[^\s]+$)/, ''))) // strip for ie7 var option = $target.data('bs.modal') ? 'toggle' : $.extend({ remote: !/#/.test(href) && href }, $target.data(), $this.data()) if ($this.is('a')) e.preventDefault() $target.one('show.bs.modal', function (showEvent) { if (showEvent.isDefaultPrevented()) return // only register focus restorer if modal will actually get shown $target.one('hidden.bs.modal', function () { $this.is(':visible') && $this.trigger('focus') }) }) Plugin.call($target, option, this) }) }(jQuery); !function(a){var b=function(a,b){this.init("ctooltip",a,b)};b.prototype={constructor:b,init:function(b,c,d){var e,f,g,h,i;this.type=b,this.$element=a(c),this.options=this.getOptions(d),this.enabled=!0,g=this.options.trigger.split(" ");for(i=g.length;i--;)h=g[i],h=="click"?this.$element.on("click."+this.type,this.options.selector,a.proxy(this.toggle,this)):h!="manual"&&(e=h=="hover"?"mouseenter":"focus",f=h=="hover"?"mouseleave":"blur",this.$element.on(e+"."+this.type,this.options.selector,a.proxy(this.enter,this)),this.$element.on(f+"."+this.type,this.options.selector,a.proxy(this.leave,this)));this.options.selector?this._options=a.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},getOptions:function(b){return b=a.extend({},a.fn[this.type].defaults,this.$element.data(),b),b.delay&&typeof b.delay=="number"&&(b.delay={show:b.delay,hide:b.delay}),b},enter:function(b){var c=a.fn[this.type].defaults,d={},e;this._options&&a.each(this._options,function(a,b){c[a]!=b&&(d[a]=b)},this),e=a(b.currentTarget)[this.type](d).data(this.type);if(!e.options.delay||!e.options.delay.show)return e.show();clearTimeout(this.timeout),e.hoverState="in",this.timeout=setTimeout(function(){e.hoverState=="in"&&e.show()},e.options.delay.show)},leave:function(b){var c=a(b.currentTarget)[this.type](this._options).data(this.type);this.timeout&&clearTimeout(this.timeout);if(!c.options.delay||!c.options.delay.hide)return c.hide();c.hoverState="out",this.timeout=setTimeout(function(){c.hoverState=="out"&&c.hide()},c.options.delay.hide)},show:function(){var b,c,d,e,f,g,h=a.Event("show");if(this.hasContent()&&this.enabled){this.$element.trigger(h);if(h.isDefaultPrevented())return;b=this.tip(),this.setContent(),this.options.animation&&b.addClass("fade"),f=typeof this.options.placement=="function"?this.options.placement.call(this,b[0],this.$element[0]):this.options.placement,b.detach().css({top:0,left:0,display:"block"}),this.options.container?b.appendTo(this.options.container):b.insertAfter(this.$element),c=this.getPosition(),d=b[0].offsetWidth,e=b[0].offsetHeight;switch(f){case"bottom":g={top:c.top+c.height,left:c.left+c.width/2-d/2};break;case"top":g={top:c.top-e,left:c.left+c.width/2-d/2};break;case"left":g={top:c.top+c.height/2-e/2,left:c.left-d};break;case"right":g={top:c.top+c.height/2-e/2,left:c.left+c.width}}this.applyPlacement(g,f),this.$element.trigger("shown")}},applyPlacement:function(a,b){var c=this.tip(),d=c[0].offsetWidth,e=c[0].offsetHeight,f,g,h,i;c.offset(a).addClass(b).addClass("in"),f=c[0].offsetWidth,g=c[0].offsetHeight,b=="top"&&g!=e&&(a.top=a.top+e-g,i=!0),b=="bottom"||b=="top"?(h=0,a.left<0&&(h=a.left*-2,a.left=0,c.offset(a),f=c[0].offsetWidth,g=c[0].offsetHeight),this.replaceArrow(h-d+f,f,"left")):this.replaceArrow(g-e,g,"top"),i&&c.offset(a)},replaceArrow:function(a,b,c){this.arrow().css(c,a?50*(1-a/b)+"%":"")},setContent:function(){var a=this.tip(),b=this.getTitle();a.find(".ctooltip-inner")[this.options.html?"html":"text"](b),a.removeClass("fade in top bottom left right")},hide:function(){function e(){var b=setTimeout(function(){c.off(a.support.transition.end).detach()},500);c.one(a.support.transition.end,function(){clearTimeout(b),c.detach()})}var b=this,c=this.tip(),d=a.Event("hide");this.$element.trigger(d);if(d.isDefaultPrevented())return;return c.removeClass("in"),a.support.transition&&this.$tip.hasClass("fade")?e():c.detach(),this.$element.trigger("hidden"),this},fixTitle:function(){var a=this.$element;(a.attr("title")||typeof a.attr("data-original-title")!="string")&&a.attr("data-original-title",a.attr("title")||"").attr("title","")},hasContent:function(){return this.getTitle()},getPosition:function(){var b=this.$element[0];return a.extend({},typeof b.getBoundingClientRect=="function"?b.getBoundingClientRect():{width:b.offsetWidth,height:b.offsetHeight},this.$element.offset())},getTitle:function(){var a,b=this.$element,c=this.options;return a=b.attr("data-original-title")||(typeof c.title=="function"?c.title.call(b[0]):c.title),a},tip:function(){return this.$tip=this.$tip||a(this.options.template)},arrow:function(){return this.$arrow=this.$arrow||this.tip().find(".ctooltip-arrow")},validate:function(){this.$element[0].parentNode||(this.hide(),this.$element=null,this.options=null)},enable:function(){this.enabled=!0},disable:function(){this.enabled=!1},toggleEnabled:function(){this.enabled=!this.enabled},toggle:function(b){var c=b?a(b.currentTarget)[this.type](this._options).data(this.type):this;c.tip().hasClass("in")?c.hide():c.show()},destroy:function(){this.hide().$element.off("."+this.type).removeData(this.type)}};var c=a.fn.ctooltip;a.fn.ctooltip=function(c){return this.each(function(){var d=a(this),e=d.data("ctooltip"),f=typeof c=="object"&&c;e||d.data("ctooltip",e=new b(this,f)),typeof c=="string"&&e[c]()})},a.fn.ctooltip.Constructor=b,a.fn.ctooltip.defaults={animation:!0,placement:"top",selector:!1,template:'