Stock Market, Market Cap

Stock Market, Market Cap

Stock Market, Market Cap – Economic Data Series | FRED | St. Louis Fed Skip to main content You cannot exclude all these filters. Please remove one.’); $(‘.modal-message’).removeClass(‘hidden’); $(‘#exclude-button’).prop(‘disabled’, true); } }); /***** Sort dropdown *****/ $(‘#order_by_options-dropdown li a’).on(‘click’, function(e) { e.preventDefault(); if (!$(this).parent().hasClass(‘go-back’)){ var order_by_form = $(‘#tags-related-search-form’); order_by_form.find(“input[name=’ob’]”).val($(this).data(‘order-by’)); order_by_form.find(“input[name=’od’]”).val(null); order_by_form.find(“input[name=’pageID’]”).val(1); order_by_form.submit(); } }); var current_sort = $(“input[name=’ob’]”).val(); $(‘.sort-checked’).html(”); if (!current_sort) current_sort = “pv”; $(“.sort-checked-“+current_sort).html(‘‘); var orderByText = $(‘#order-by-btn’).text(); $(‘#sort-by-text’).text(orderByText.replace(“Sort by”,”)); /***** VIEW ALL MODAL *****/ $(‘#viewallModal’).on(‘hide.bs.modal’, function () { $(‘.alpha .alphabet button’).removeClass(‘active’); $(‘.alpha .alphabet button’).removeClass(‘disabled’); $(this).removeData(‘bs.modal’); }); $(‘body’).on(‘hidden.bs.modal’, ‘.viewallModal’, function () { $(this).removeData(‘bs.modal’); }); $(‘#viewallModal’).on(‘show.bs.modal’, function(e) { $(‘#tags-related-search-form’).find(“input[name=’tt’]”).val(”); $(‘#viewallModal .modal-header .modal-title’).html(‘Loading Filters ….’); $(‘#viewallModal #tag-search-view-all’).val(”); $(‘.modal-tag-list’).html(”); $(‘.alpha .alphabet button’).removeClass(‘active’); $(‘.alpha .alphabet button’).removeClass(‘disabled’); $(‘.form-control-clear’).addClass(‘hidden’); var group = $(e.relatedTarget).data(‘group’); $(‘#tags-related-search-form’).find(“input[name=’tg’]”).val(group); var ajaxurl = document.location.toString().replace(/?.*/, “”); ajaxurl += ‘?’+$(‘#tags-related-search-form’).serialize()+’&to=tag&viewall=1&request_order=’+request_order+’&rts=1&ts=’+Math.random().toString(36).substr(2, 5); var jqxhr = $.getJSON(ajaxurl, function(json) { parseTags(json,true); }); }); $(‘#tag-search-view-all’).on(‘keyup’, function(event) { $(‘.modal-tag-list’).html(”); var tag_search = $(‘#tag-search-view-all’).val(); var group = $(‘#viewallModal .modal-header .modal-title’).attr(‘id’); var ajaxurl = document.location.toString().replace(/?.*/, “”); $(‘#tags-related-search-form’).find(“input[name=’tg’]”).val(group); $(‘#tags-related-search-form’).find(“input[name=’tt’]”).val(tag_search); ajaxurl += ‘?’+$(‘#tags-related-search-form’).serialize()+’&to=tag&request_order=’+request_order+’&rts=1′; var jqxhr = $.getJSON(ajaxurl, function(json) { if (json.some_related_tags != ‘false’) { parseTags(json,true, true); } }); }); $(‘.has-clear input[type=”text”]’).on(‘input propertychange’, function() { var $this = $(this); var visible = Boolean($this.val()); $this.siblings(‘.form-control-clear’).toggleClass(‘hidden’, !visible); }).trigger(‘propertychange’); $(‘.form-control-clear’).click(function() { $(this).siblings(‘input[type=”text”]’).val(”) .trigger(‘propertychange’).focus(); var group = $(‘#viewallModal .modal-header .modal-title’).attr(‘id’); $(‘#tags-related-search-form’).find(“input[name=’tg’]”).val(group); $(‘#tags-related-search-form’).find(“input[name=’tt’]”).val(”); var ajaxurl = document.location.toString().replace(/?.*/, “”); ajaxurl += ‘?’+$(‘#tags-related-search-form’).serialize()+’&request_order=’+request_order+’&rts=1&ts=’+Math.random().toString(36).substr(2, 5); var jqxhr = $.getJSON(ajaxurl, function(json) { $(‘.form-control-clear’).addClass(‘hidden’); parseTags(json,true,false); }); }); /***** Helper function to get results *****/ function getResults(isSearch) { var ajaxurl = document.location.toString().replace(/?.*/, “”); ajaxurl += ‘?’+$(‘#tags-related-search-form’).serialize()+’&request_order=’+request_order+’&rts=1′; var jqxhr = $.getJSON(ajaxurl, function(json) { parseTags(json,true,isSearch); }); } /***** Clicked a alpha letter filter in view all modal *****/ function filterResults(letter){ $(‘.tag-block’).hide(); $(‘.modal-tag-list .tag-name’).filter(function() { var firstChar = $(this).text().charAt(0).toUpperCase(); if (firstChar >= ‘0’ && firstChar <= '9') firstChar = "#"; return firstChar === letter; }).closest('.tag-block').show(); } $('.btn-toolbar button').on('click',function(){ var letter = $(this).text(); $('.btn-default').removeClass('active'); $(this).addClass('active'); filterResults(letter); }); /***** Clicked a Exclude button in exclude modal *****/ $('#exclude-button').click(function() { $(this).addClass("loading"); $(this).removeClass("btn-primary"); var included = [], excluded = []; $(".exclude-tag-check").each(function () { if ($(this).is(':checked')) { excluded.push($(this).val()); } else { included.push($(this).val()); } }); var queryParameters = {}, queryString = location.search.substring(1), re = /([^&=]+)=([^&]*)/g, m; while (m = re.exec(queryString)) { queryParameters[decodeURIComponent(m[1])] = decodeURIComponent(m[2]); } queryParameters['t'] = included.join(';'); queryParameters['et'] = excluded.join(';'); $('#tags-related-search-form').find("input[name='t']").val(included.join(';')); $('#tags-related-search-form').find("input[name='et']").val(excluded.join(';')); get_tags('clicked'); }); function get_tags(isClicked) { var getUrlParameter = function getUrlParameter(sParam) { var sPageURL = decodeURIComponent(window.location.search.substring(1)), sURLVariables = sPageURL.split('&'), sParameterName, i; for (i = 0; i < sURLVariables.length; i++) { sParameterName = sURLVariables[i].split('='); if (sParameterName[0] === sParam) { return sParameterName[1] === undefined ? true : sParameterName[1]; } } }; $.ajax({ url: document.location.toString().replace(/?.*/, ""), datatype: 'json', data: $('#tags-related-search-form').serialize()+'&request_order='+request_order+'&rts=1', success: function(data) { var data = jQuery.parseJSON(data); if ((data) && request_order != data.request_order) { return false; } if (isClicked) { $('#exclude-button').addClass("hide-loading"); $(".done").addClass("finish"); } var queryParameters = {}, queryString = location.search.substring(1), re = /([^&=]+)=([^&]*)/g, m; while (m = re.exec(queryString)) { queryParameters[decodeURIComponent(m[1])] = decodeURIComponent(m[2]); } if ((isClicked == 'clicked') && (data.some_related_tags == 'false') && ($('#tags-related-search-form').find("input[name='et']").val())) { queryParameters['t'] = $('#tags-related-search-form').find("input[name='t']").val()+';'+$('#tags-related-search-form').find("input[name='et']").val(); queryParameters['no_result'] = 'true'; location.search = $.param(queryParameters); } else { if(getUrlParameter('no_result') == 'true') { $('.message-container').html('

Filtering returned no results, filters have been reset’); } if (isClicked == ‘clicked’) { queryParameters[‘t’] = $(‘#tags-related-search-form’).find(“input[name=’t’]”).val(); queryParameters[‘et’] = $(‘#tags-related-search-form’).find(“input[name=’et’]”).val(); queryParameters[‘st’] = $(‘#tags-related-search-form’).find(“input[name=’st’]”).val(); location.search = $.param(queryParameters); } parseTags(data); } } }); } function display_related_tags(event) { if (!$(‘#tags-related-search-form’).length) { } if ((event === undefined) || (event.type != ‘keyup’)) { request_order = 0; } else { request_order++; } if (tmp > 0) { clearTimeout(tmp); } get_tags(); return false; } /****** function that parses the json returned from ajax call into markup for views ****/ function parseTags(jsonData, viewall, isSearch) { if ((typeof viewall) == ‘undefined’) { viewall = false; } if ((typeof isSearch) == ‘undefined’) { isSearch = false; } if ((jsonData.related_tags === null) || ((typeof jsonData.related_tags) == ‘undefined’)) { return false; } Object.keys(jsonData.related_tags).forEach(function(key) { var tagGroupArray = jsonData.related_tags[key]; var tags=[]; var groupName=key; var alpha ={}; var onetag=”; var capTag=”; for (i=0;i < tagGroupArray.length; i++) { capTag = (tagGroupArray[i].notes) ? tagGroupArray[i].notes : tagGroupArray[i].capitalized_tag; var addtl_info = 'data-toggle="popover" title="Popover Header" data-content="Some content inside the popover"'; onetag = ''+ ''+capTag +''+ '‘+ ((tagGroupArray[i].series_count != 0) ? ‘ (‘+tagGroupArray[i].series_count+’)’ : ”) + ”; tags.push(onetag); groupName = tagGroupArray[i].group_name; } if (viewall) { createViewAllModal(tags,groupName, key, isSearch); } else { createSidePanelGroup(tags,groupName,key); createDrawerGroup(tags,groupName,key); } }); } /**** functions to display the appropriate content(drawer, sidepanel, view all modal) ****/ function createDrawerGroup(tags,group,groupAbbr) { var drawerBlock = $(‘.tag-drawer-group-item’).clone(); drawerBlock.removeClass(‘hidden’); drawerBlock.removeClass(‘tag-drawer-group-item’); drawerBlock.find(‘.group-tag-name’).text(group); drawerBlock.find(‘.group-tag-name-all’).text(“View All “+group); drawerBlock.find(‘.group-tag-name-all’).attr(“data-group”,groupAbbr); var onetag = ‘

  • ‘+tags.join(‘
  • ‘)+”; $(drawerBlock).insertBefore(“.need-help-seperator”); $(onetag).insertAfter(drawerBlock.find(‘.see-all’)); $(‘.drawer-dropdown-trigger’).prop(“disabled”, false); $(‘.drawer-dropdown-trigger span.badge’).removeClass(‘hidden’); $(‘.drawer-dropdown-trigger span.badge’).text($(‘.selected-count’).text()); if (tags.length 5) panel.find(‘.view-all-tags’).removeClass(‘hidden’); $(‘#related-tags’).html($(‘#related-tags’).html()+panel.html()); } function createViewAllModal(tags,groupName, groupAbbr, isSearch) { $(‘.modal-tag-list’).html(”); $(‘#viewallModal .modal-header .modal-title’).html(‘View All ‘+groupName); $(‘#viewallModal .modal-header .modal-title’).attr(‘id’, groupAbbr); $(‘.modal-tag-list’).html(”+tags.join(”)+”); if (isSearch !== true){ var $p = $(‘.modal-tag-list .tag-name’); $(‘.btn-toolbar button’).addClass(function(){ var a = this.textContent; return $p.filter(function(){ var firstChar = this.textContent.charAt(0); if (firstChar >= ‘0’ && firstChar = 30) { var firstCharacterWithResults = $(‘.alpha .alphabet button:not(“.disabled”):first’); firstCharacterWithResults.addClass(‘active’); filterResults(firstCharacterWithResults.text()); } } }); function show_more_related_tags() { $(‘.related-tags-group’).each(function() { if ($(this).find(‘li’).length > max_related_tags) { $(this).find(‘li:gt(‘ + (max_related_tags – 1) + ‘)’).hide(); $(this).append(‘

    Show More

    ‘); $(‘.related-tags-group-show-more’).click(function() { $(this).closest(‘.related-tags-group’).find(‘li:gt(‘ + (max_related_tags – 1) + ‘)’).show(‘slide’,{‘direction’:’up’}); $(this).remove(); return false; }); } }); } ]]>

  • Related Post

    Be the first to comment

    Leave a Reply

    Your email address will not be published.


    *