You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@juddi.apache.org by al...@apache.org on 2013/03/26 02:17:48 UTC
svn commit: r1460942 [16/17] - in /juddi/branches/juddi-3.2.x:
juddi-client/src/main/java/org/apache/juddi/v3/client/crypto/
juddi-gui-dsig/ juddi-gui-dsig/nbproject/ juddi-gui-dsig/nbproject/configs/
juddi-gui-dsig/src/ juddi-gui-dsig/src/org/ juddi-g...
Added: juddi/branches/juddi-3.2.x/juddi-gui/web/js/jquery-ui-1.10.1.custom.min.js
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/web/js/jquery-ui-1.10.1.custom.min.js?rev=1460942&view=auto
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/web/js/jquery-ui-1.10.1.custom.min.js (added)
+++ juddi/branches/juddi-3.2.x/juddi-gui/web/js/jquery-ui-1.10.1.custom.min.js Tue Mar 26 01:17:45 2013
@@ -0,0 +1,6 @@
+/*! jQuery UI - v1.10.1 - 2013-03-02
+* http://jqueryui.com
+* Includes: jquery.ui.core.js, jquery.ui.widget.js, jquery.ui.mouse.js, jquery.ui.position.js, jquery.ui.draggable.js, jquery.ui.resizable.js, jquery.ui.accordion.js, jquery.ui.autocomplete.js, jquery.ui.button.js, jquery.ui.datepicker.js, jquery.ui.dialog.js, jquery.ui.menu.js, jquery.ui.progressbar.js, jquery.ui.slider.js, jquery.ui.spinner.js, jquery.ui.tooltip.js, jquery.ui.effect.js, jquery.ui.effect-blind.js, jquery.ui.effect-bounce.js, jquery.ui.effect-clip.js, jquery.ui.effect-drop.js, jquery.ui.effect-explode.js, jquery.ui.effect-fade.js, jquery.ui.effect-fold.js, jquery.ui.effect-highlight.js, jquery.ui.effect-pulsate.js, jquery.ui.effect-scale.js, jquery.ui.effect-shake.js, jquery.ui.effect-slide.js, jquery.ui.effect-transfer.js
+* Copyright (c) 2013 jQuery Foundation and other contributors Licensed MIT */
+
[... 3 lines stripped ...]
Added: juddi/branches/juddi-3.2.x/juddi-gui/web/js/jquery.jeditable.js
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/web/js/jquery.jeditable.js?rev=1460942&view=auto
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/web/js/jquery.jeditable.js (added)
+++ juddi/branches/juddi-3.2.x/juddi-gui/web/js/jquery.jeditable.js Tue Mar 26 01:17:45 2013
@@ -0,0 +1,543 @@
+/*
+ * Jeditable - jQuery in place edit plugin
+ *
+ * Copyright (c) 2006-2009 Mika Tuupola, Dylan Verheul
+ *
+ * Licensed under the MIT license:
+ * http://www.opensource.org/licenses/mit-license.php
+ *
+ * Project home:
+ * http://www.appelsiini.net/projects/jeditable
+ *
+ * Based on editable by Dylan Verheul <dylan_at_dyve.net>:
+ * http://www.dyve.net/jquery/?editable
+ *
+ */
+
+/**
+ * Version 1.7.1
+ *
+ * ** means there is basic unit tests for this parameter.
+ *
+ * @name Jeditable
+ * @type jQuery
+ * @param String target (POST) URL or function to send edited content to **
+ * @param Hash options additional options
+ * @param String options[method] method to use to send edited content (POST or PUT) **
+ * @param Function options[callback] Function to run after submitting edited content **
+ * @param String options[name] POST parameter name of edited content
+ * @param String options[id] POST parameter name of edited div id
+ * @param Hash options[submitdata] Extra parameters to send when submitting edited content.
+ * @param String options[type] text, textarea or select (or any 3rd party input type) **
+ * @param Integer options[rows] number of rows if using textarea **
+ * @param Integer options[cols] number of columns if using textarea **
+ * @param Mixed options[height] 'auto', 'none' or height in pixels **
+ * @param Mixed options[width] 'auto', 'none' or width in pixels **
+ * @param String options[loadurl] URL to fetch input content before editing **
+ * @param String options[loadtype] Request type for load url. Should be GET or POST.
+ * @param String options[loadtext] Text to display while loading external content.
+ * @param Mixed options[loaddata] Extra parameters to pass when fetching content before editing.
+ * @param Mixed options[data] Or content given as paramameter. String or function.**
+ * @param String options[indicator] indicator html to show when saving
+ * @param String options[tooltip] optional tooltip text via title attribute **
+ * @param String options[event] jQuery event such as 'click' of 'dblclick' **
+ * @param String options[submit] submit button value, empty means no button **
+ * @param String options[cancel] cancel button value, empty means no button **
+ * @param String options[cssclass] CSS class to apply to input form. 'inherit' to copy from parent. **
+ * @param String options[style] Style to apply to input form 'inherit' to copy from parent. **
+ * @param String options[select] true or false, when true text is highlighted ??
+ * @param String options[placeholder] Placeholder text or html to insert when element is empty. **
+ * @param String options[onblur] 'cancel', 'submit', 'ignore' or function ??
+ *
+ * @param Function options[onsubmit] function(settings, original) { ... } called before submit
+ * @param Function options[onreset] function(settings, original) { ... } called before reset
+ * @param Function options[onerror] function(settings, original, xhr) { ... } called on error
+ *
+ * @param Hash options[ajaxoptions] jQuery Ajax options. See docs.jquery.com.
+ *
+ */
+
+(function($) {
+
+ $.fn.editable = function(target, options) {
+
+ if ('disable' == target) {
+ $(this).data('disabled.editable', true);
+ return;
+ }
+ if ('enable' == target) {
+ $(this).data('disabled.editable', false);
+ return;
+ }
+ if ('destroy' == target) {
+ $(this)
+ .unbind($(this).data('event.editable'))
+ .removeData('disabled.editable')
+ .removeData('event.editable');
+ return;
+ }
+
+ var settings = $.extend({}, $.fn.editable.defaults, {target:target}, options);
+
+ /* setup some functions */
+ var plugin = $.editable.types[settings.type].plugin || function() { };
+ var submit = $.editable.types[settings.type].submit || function() { };
+ var buttons = $.editable.types[settings.type].buttons
+ || $.editable.types['defaults'].buttons;
+ var content = $.editable.types[settings.type].content
+ || $.editable.types['defaults'].content;
+ var element = $.editable.types[settings.type].element
+ || $.editable.types['defaults'].element;
+ var reset = $.editable.types[settings.type].reset
+ || $.editable.types['defaults'].reset;
+ var callback = settings.callback || function() { };
+ var onedit = settings.onedit || function() { };
+ var onsubmit = settings.onsubmit || function() { };
+ var onreset = settings.onreset || function() { };
+ var onerror = settings.onerror || reset;
+
+ /* show tooltip */
+ if (settings.tooltip) {
+ $(this).attr('title', settings.tooltip);
+ }
+
+ settings.autowidth = 'auto' == settings.width;
+ settings.autoheight = 'auto' == settings.height;
+
+ return this.each(function() {
+
+ /* save this to self because this changes when scope changes */
+ var self = this;
+
+ /* inlined block elements lose their width and height after first edit */
+ /* save them for later use as workaround */
+ var savedwidth = $(self).width();
+ var savedheight = $(self).height();
+
+ /* save so it can be later used by $.editable('destroy') */
+ $(this).data('event.editable', settings.event);
+
+ /* if element is empty add something clickable (if requested) */
+ if (!$.trim($(this).html())) {
+ $(this).html(settings.placeholder);
+ }
+
+ $(this).bind(settings.event, function(e) {
+
+ /* abort if disabled for this element */
+ if (true === $(this).data('disabled.editable')) {
+ return;
+ }
+
+ /* prevent throwing an exeption if edit field is clicked again */
+ if (self.editing) {
+ return;
+ }
+
+ /* abort if onedit hook returns false */
+ if (false === onedit.apply(this, [settings, self])) {
+ return;
+ }
+
+ /* prevent default action and bubbling */
+ e.preventDefault();
+ e.stopPropagation();
+
+ /* remove tooltip */
+ if (settings.tooltip) {
+ $(self).removeAttr('title');
+ }
+
+ /* figure out how wide and tall we are, saved width and height */
+ /* are workaround for http://dev.jquery.com/ticket/2190 */
+ if (0 == $(self).width()) {
+ //$(self).css('visibility', 'hidden');
+ settings.width = savedwidth;
+ settings.height = savedheight;
+ } else {
+ if (settings.width != 'none') {
+ settings.width =
+ settings.autowidth ? $(self).width() : settings.width;
+ }
+ if (settings.height != 'none') {
+ settings.height =
+ settings.autoheight ? $(self).height() : settings.height;
+ }
+ }
+ //$(this).css('visibility', '');
+
+ /* remove placeholder text, replace is here because of IE */
+ if ($(this).html().toLowerCase().replace(/(;|")/g, '') ==
+ settings.placeholder.toLowerCase().replace(/(;|")/g, '')) {
+ $(this).html('');
+ }
+
+ self.editing = true;
+ self.revert = $(self).html();
+ $(self).html('');
+
+ /* create the form object */
+ var form = $('<form />');
+
+ /* apply css or style or both */
+ if (settings.cssclass) {
+ if ('inherit' == settings.cssclass) {
+ form.attr('class', $(self).attr('class'));
+ } else {
+ form.attr('class', settings.cssclass);
+ }
+ }
+
+ if (settings.style) {
+ if ('inherit' == settings.style) {
+ form.attr('style', $(self).attr('style'));
+ /* IE needs the second line or display wont be inherited */
+ form.css('display', $(self).css('display'));
+ } else {
+ form.attr('style', settings.style);
+ }
+ }
+
+ /* add main input element to form and store it in input */
+ var input = element.apply(form, [settings, self]);
+
+ /* set input content via POST, GET, given data or existing value */
+ var input_content;
+
+ if (settings.loadurl) {
+ var t = setTimeout(function() {
+ input.disabled = true;
+ content.apply(form, [settings.loadtext, settings, self]);
+ }, 100);
+
+ var loaddata = {};
+ loaddata[settings.id] = self.id;
+ if ($.isFunction(settings.loaddata)) {
+ $.extend(loaddata, settings.loaddata.apply(self, [self.revert, settings]));
+ } else {
+ $.extend(loaddata, settings.loaddata);
+ }
+ $.ajax({
+ type : settings.loadtype,
+ url : settings.loadurl,
+ data : loaddata,
+ async : false,
+ success: function(result) {
+ window.clearTimeout(t);
+ input_content = result;
+ input.disabled = false;
+ }
+ });
+ } else if (settings.data) {
+ input_content = settings.data;
+ if ($.isFunction(settings.data)) {
+ input_content = settings.data.apply(self, [self.revert, settings]);
+ }
+ } else {
+ input_content = self.revert;
+ }
+ content.apply(form, [input_content, settings, self]);
+
+ input.attr('name', settings.name);
+
+ /* add buttons to the form */
+ buttons.apply(form, [settings, self]);
+
+ /* add created form to self */
+ $(self).append(form);
+
+ /* attach 3rd party plugin if requested */
+ plugin.apply(form, [settings, self]);
+
+ /* focus to first visible form element */
+ $(':input:visible:enabled:first', form).focus();
+
+ /* highlight input contents when requested */
+ if (settings.select) {
+ input.select();
+ }
+
+ /* discard changes if pressing esc */
+ input.keydown(function(e) {
+ if (e.keyCode == 27) {
+ e.preventDefault();
+ //self.reset();
+ reset.apply(form, [settings, self]);
+ }
+ });
+
+ /* discard, submit or nothing with changes when clicking outside */
+ /* do nothing is usable when navigating with tab */
+ var t;
+ if ('cancel' == settings.onblur) {
+ input.blur(function(e) {
+ /* prevent canceling if submit was clicked */
+ t = setTimeout(function() {
+ reset.apply(form, [settings, self]);
+ }, 500);
+ });
+ } else if ('submit' == settings.onblur) {
+ input.blur(function(e) {
+ /* prevent double submit if submit was clicked */
+ t = setTimeout(function() {
+ form.submit();
+ }, 200);
+ });
+ } else if ($.isFunction(settings.onblur)) {
+ input.blur(function(e) {
+ settings.onblur.apply(self, [input.val(), settings]);
+ });
+ } else {
+ input.blur(function(e) {
+ /* TODO: maybe something here */
+ });
+ }
+
+ form.submit(function(e) {
+
+ if (t) {
+ clearTimeout(t);
+ }
+
+ /* do no submit */
+ e.preventDefault();
+
+ /* call before submit hook. */
+ /* if it returns false abort submitting */
+ if (false !== onsubmit.apply(form, [settings, self])) {
+ /* custom inputs call before submit hook. */
+ /* if it returns false abort submitting */
+ if (false !== submit.apply(form, [settings, self])) {
+
+ /* check if given target is function */
+ if ($.isFunction(settings.target)) {
+ var str = settings.target.apply(self, [input.val(), settings]);
+ $(self).html(str);
+ self.editing = false;
+ callback.apply(self, [self.innerHTML, settings]);
+ /* TODO: this is not dry */
+ if (!$.trim($(self).html())) {
+ $(self).html(settings.placeholder);
+ }
+ } else {
+ /* add edited content and id of edited element to POST */
+ var submitdata = {};
+ submitdata[settings.name] = input.val();
+ submitdata[settings.id] = self.id;
+ /* add extra data to be POST:ed */
+ if ($.isFunction(settings.submitdata)) {
+ $.extend(submitdata, settings.submitdata.apply(self, [self.revert, settings]));
+ } else {
+ $.extend(submitdata, settings.submitdata);
+ }
+
+ /* quick and dirty PUT support */
+ if ('PUT' == settings.method) {
+ submitdata['_method'] = 'put';
+ }
+
+ /* show the saving indicator */
+ $(self).html(settings.indicator);
+
+ /* defaults for ajaxoptions */
+ var ajaxoptions = {
+ type : 'POST',
+ data : submitdata,
+ dataType: 'html',
+ url : settings.target,
+ success : function(result, status) {
+ if (ajaxoptions.dataType == 'html') {
+ $(self).html(result);
+ }
+ self.editing = false;
+ callback.apply(self, [result, settings]);
+ if (!$.trim($(self).html())) {
+ $(self).html(settings.placeholder);
+ }
+ },
+ error : function(xhr, status, error) {
+ onerror.apply(form, [settings, self, xhr]);
+ }
+ };
+
+ /* override with what is given in settings.ajaxoptions */
+ $.extend(ajaxoptions, settings.ajaxoptions);
+ $.ajax(ajaxoptions);
+
+ }
+ }
+ }
+
+ /* show tooltip again */
+ $(self).attr('title', settings.tooltip);
+
+ return false;
+ });
+ });
+
+ /* privileged methods */
+ this.reset = function(form) {
+ /* prevent calling reset twice when blurring */
+ if (this.editing) {
+ /* before reset hook, if it returns false abort reseting */
+ if (false !== onreset.apply(form, [settings, self])) {
+ $(self).html(self.revert);
+ self.editing = false;
+ if (!$.trim($(self).html())) {
+ $(self).html(settings.placeholder);
+ }
+ /* show tooltip again */
+ if (settings.tooltip) {
+ $(self).attr('title', settings.tooltip);
+ }
+ }
+ }
+ };
+ });
+
+ };
+
+
+ $.editable = {
+ types: {
+ defaults: {
+ element : function(settings, original) {
+ var input = $('<input type="hidden"></input>');
+ $(this).append(input);
+ return(input);
+ },
+ content : function(string, settings, original) {
+ $(':input:first', this).val(string);
+ },
+ reset : function(settings, original) {
+ original.reset(this);
+ },
+ buttons : function(settings, original) {
+ var form = this;
+ if (settings.submit) {
+ /* if given html string use that */
+ if (settings.submit.match(/>$/)) {
+ var submit = $(settings.submit).click(function() {
+ if (submit.attr("type") != "submit") {
+ form.submit();
+ }
+ });
+ /* otherwise use button with given string as text */
+ } else {
+ var submit = $('<button type="submit" />');
+ submit.html(settings.submit);
+ }
+ $(this).append(submit);
+ }
+ if (settings.cancel) {
+ /* if given html string use that */
+ if (settings.cancel.match(/>$/)) {
+ var cancel = $(settings.cancel);
+ /* otherwise use button with given string as text */
+ } else {
+ var cancel = $('<button type="cancel" />');
+ cancel.html(settings.cancel);
+ }
+ $(this).append(cancel);
+
+ $(cancel).click(function(event) {
+ //original.reset();
+ if ($.isFunction($.editable.types[settings.type].reset)) {
+ var reset = $.editable.types[settings.type].reset;
+ } else {
+ var reset = $.editable.types['defaults'].reset;
+ }
+ reset.apply(form, [settings, original]);
+ return false;
+ });
+ }
+ }
+ },
+ text: {
+ element : function(settings, original) {
+ var input = $('<input />');
+ if (settings.width != 'none') { input.width(settings.width); }
+ if (settings.height != 'none') { input.height(settings.height); }
+ /* https://bugzilla.mozilla.org/show_bug.cgi?id=236791 */
+ //input[0].setAttribute('autocomplete','off');
+ input.attr('autocomplete','off');
+ $(this).append(input);
+ return(input);
+ }
+ },
+ textarea: {
+ element : function(settings, original) {
+ var textarea = $('<textarea />');
+ if (settings.rows) {
+ textarea.attr('rows', settings.rows);
+ } else if (settings.height != "none") {
+ textarea.height(settings.height);
+ }
+ if (settings.cols) {
+ textarea.attr('cols', settings.cols);
+ } else if (settings.width != "none") {
+ textarea.width(settings.width);
+ }
+ $(this).append(textarea);
+ return(textarea);
+ }
+ },
+ select: {
+ element : function(settings, original) {
+ var select = $('<select />');
+ $(this).append(select);
+ return(select);
+ },
+ content : function(data, settings, original) {
+ /* If it is string assume it is json. */
+ if (String == data.constructor) {
+ eval ('var json = ' + data);
+ } else {
+ /* Otherwise assume it is a hash already. */
+ var json = data;
+ }
+ for (var key in json) {
+ if (!json.hasOwnProperty(key)) {
+ continue;
+ }
+ if ('selected' == key) {
+ continue;
+ }
+ var option = $('<option />').val(key).append(json[key]);
+ $('select', this).append(option);
+ }
+ /* Loop option again to set selected. IE needed this... */
+ $('select', this).children().each(function() {
+ if ($(this).val() == json['selected'] ||
+ $(this).text() == $.trim(original.revert)) {
+ $(this).attr('selected', 'selected');
+ }
+ });
+ }
+ }
+ },
+
+ /* Add new input type */
+ addInputType: function(name, input) {
+ $.editable.types[name] = input;
+ }
+ };
+
+ // publicly accessible defaults
+ $.fn.editable.defaults = {
+ name : 'value',
+ id : 'id',
+ type : 'text',
+ width : 'auto',
+ height : 'auto',
+ event : 'click.editable',
+ onblur : 'cancel',
+ loadtype : 'GET',
+ loadtext : 'Loading...',
+ placeholder: 'Click to edit',
+ loaddata : {},
+ submitdata : {},
+ ajaxoptions: {}
+ };
+
+})(jQuery);
Added: juddi/branches/juddi-3.2.x/juddi-gui/web/js/main.js
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/web/js/main.js?rev=1460942&view=auto
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/web/js/main.js (added)
+++ juddi/branches/juddi-3.2.x/juddi-gui/web/js/main.js Tue Mar 26 01:17:45 2013
@@ -0,0 +1,141 @@
+/*
+ * To change this template, choose Tools | Templates
+ * and open the template in the editor.
+ */
+
+var loggedin=false;
+
+var tagsToReplace = {
+ '&': '&',
+ '<': '<',
+ '>': '>'
+};
+
+function replaceTag(tag) {
+ return tagsToReplace[tag] || tag;
+}
+
+function safe_tags_replace(str) {
+ return str.replace(/[&<>]/g, replaceTag);
+}
+
+
+function Reedit()
+{
+ window.console && console.log('Reedit');
+ $('.edit').editable(function(value, settings) {
+
+ window.console && console.log(this);
+ window.console && console.log(value);
+ window.console && console.log(settings);
+ //replace tags with escaped characters to prevent XSS
+ return(safe_tags_replace(value));
+ }, {
+ type : 'text',
+ submit : 'OK'
+ });
+
+}
+
+Reedit();
+
+
+function Login()
+{
+
+ $("#loginbutton").addClass("disabled");
+ $("#loginbutton").text("Please wait");
+
+ var form = $("#uddiform");
+ var d = form.serializeArray();
+ var request= $.ajax({
+ url: 'ajax/loginpost.jsp',
+ type:"POST",
+ // dataType: "html",
+ cache: false,
+ // processData: false,f
+ data: d
+ });
+
+ request.done(function(msg) {
+ window.console && console.log('postback done ');
+ $("#loginbutton").text("Login");
+ RefreshLoginPage();
+ });
+
+ request.fail(function(jqXHR, textStatus) {
+ window.console && console.log('postback failed ');
+ RefreshLoginPage();
+ $("#loginbutton").text("Login");
+ });
+}
+
+function logout()
+{
+
+ $.get('logout.jsp', function(data) {
+ window.location = "index.jsp";
+ });
+}
+
+function RefreshLoginPage()
+{
+ $.get('login.jsp', function(data) {
+ $('#loginfield').html(data);
+ });
+}
+
+// Escapes special characters and returns a valid jQuery selector
+//source http://totaldev.com/content/escaping-characters-get-valid-jquery-id
+function jqSelector(str)
+{
+ return str.replace(/([;&,\.\+\*\~':"\!\^#$%@\[\]\(\)=>\|])/g, '\\$1');
+}
+
+function ShowServicesByBusinessKey(bizid)
+{
+ window.console && console.log('fetching service list for business ' + bizid);
+ var request= $.ajax({
+ url: 'ajax/servicelist.jsp?id=' + bizid,
+ type:"GET",
+ cache: false
+ });
+
+ request.done(function(msg) {
+ window.console && console.log(msg);
+ window.console && console.log('postback done to div ' + bizid);
+ $("#" + jqSelector(bizid)).html(msg);
+ //refresh();
+ });
+
+ request.fail(function(jqXHR, textStatus) {
+ window.console && console.log('postback failed ');
+ $("#" + jqSelector(bizid)).html("An error occured! " + textStatus + jqXHR);
+ //refresh();
+ });
+
+// $.get('ajax/servicelist.jsp?id=' + bizid, function(data) {
+// $("#" + bizid).html(data);
+// });
+}
+
+function ShowBusinssDetails(bizid)
+{
+ $.get('ajax/businessdetails.jsp?id=' + bizid, function(data) {
+ $('#servicelist').html(data);
+ });
+}
+
+function GetServiceDetails(svcid)
+{
+ $.get('ajax/servicedetails.jsp?id=' + svcid, function(data) {
+ $('#servicelist').html(data);
+ $('.editable').editable('ajax/saveservicedetails.jsp');
+ });
+}
+
+
+function hideAlert()
+{
+ $("#resultBar").hide();
+}
\ No newline at end of file
Added: juddi/branches/juddi-3.2.x/juddi-gui/web/js/serviceBrowse.js
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/web/js/serviceBrowse.js?rev=1460942&view=auto
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/web/js/serviceBrowse.js (added)
+++ juddi/branches/juddi-3.2.x/juddi-gui/web/js/serviceBrowse.js Tue Mar 26 01:17:45 2013
@@ -0,0 +1,90 @@
+
+var offset=0; //start at the begining
+var maxrecords=20; //record 20 at a time
+var totalrecords=0;
+
+function refreshServiceList()
+{
+ RenderServiceListBySearch('%', offset, maxrecords);
+}
+RenderServiceListBySearch('%', offset, maxrecords);
+//offset += maxrecords;
+function pagedown()
+{
+ offset = $("#offset").text();
+ //alert(offset);
+ var newoffset = offset - maxrecords;
+ if (newoffset < 0)
+ return;
+ //alert(newoffset);
+ if (newoffset != offset)
+ RenderServiceListBySearch('%', newoffset, maxrecords);
+}
+function pageup()
+{
+ offset = $("#offset").text();
+ //alert(offset);
+ var fetch = maxrecords;
+ if ((parseInt(offset) + parseInt(maxrecords)) > totalrecords)
+ //fetch = maxrecords - offset;
+ return;
+ else
+ fetch = (parseInt(offset) + parseInt(maxrecords));
+ //alert(fetch);
+ offset = fetch;
+ RenderServiceListBySearch('%', fetch, maxrecords);
+}
+
+function RenderServiceListBySearch(keyword, offset, maxrecords)
+{
+ var lang = $("#lang").text();
+ $("#serviceBrowserListing").html("<img src=\"img/bigrollergreen.gif\" title=\"Loading\"/>");
+ var request= $.ajax({
+ url: 'ajax/servicesearch.jsp?keyword=' + keyword + "&offset=" + offset + "&maxrecords=" + maxrecords + "&lang=" + lang,
+ type:"GET",
+ // dataType: "html",
+ cache: false
+ // processData: false,f
+ //data: d
+ });
+
+ request.done(function(msg) {
+ window.console && console.log('postback done ');
+ $("#serviceBrowserListings").html(msg);
+ //refresh();
+ });
+
+ request.fail(function(jqXHR, textStatus) {
+ window.console && console.log('postback failed ');
+ $("#serviceBrowserListings").html("An error occured! " + textStatus + jqXHR);
+ //refresh();
+ });
+/*
+ $.get('ajax/servicesearch.jsp?keyword=' + keyword + "&offset=" + offset + "&maxrecords=" + maxrecords, function(data) {
+ $("#serviceBrowserListings").html(data);
+ refresh();
+ });*/
+}
+
+function refresh()
+{
+ var displayrecords = $("#displayrecords").text();
+ if (displayrecords == totalrecords)
+ {
+ $("#pageup").addClass("disabled");
+ $("#pagedown").addClass("disabled");
+ }
+ else if (offset + maxrecords > totalrecords)
+ {
+ $("#pageup").addClass("disabled");
+ }
+ else if (offset ==0)
+ {
+ $("#pagedown").removeClass("disabled");
+ }
+ else
+ {
+ $("#pagedown").removeClass("disabled");
+ $("#pageup").removeClass("disabled");
+ }
+}
\ No newline at end of file
Added: juddi/branches/juddi-3.2.x/juddi-gui/web/js/serviceEditor.js
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/web/js/serviceEditor.js?rev=1460942&view=auto
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/web/js/serviceEditor.js (added)
+++ juddi/branches/juddi-3.2.x/juddi-gui/web/js/serviceEditor.js Tue Mar 26 01:17:45 2013
@@ -0,0 +1,53 @@
+/*
+ * To change this template, choose Tools | Templates
+ * and open the template in the editor.
+ */
+
+
+//init the editable fields
+Reedit();
+
+
+
+function AddBindingTemplate()
+{
+
+
+ currentbindingtemplates++;
+ var i = currentbindingtemplates;
+ $("<div id=\"bindingTemplate" + i + "\" style=\"border-width:1px; border-style:solid\" >"
+ +"<div style=\"float:left;height:100%\"><a href=\"javascript:Remove('bindingTemplate" + i
+ +"');\"><i class=\"icon-remove-sign\"></i></a></div>"
+ +"<div class=\"editrableSelectAccessPoint\"></div>"
+ +"<div style=\"float:left\">Value: </div>"
+ +"<div class=\"edit\" id=\"Name" + i + "Value\"></div>"
+ +"<div style=\"float:left\">Language: </div>"
+ +"<div class=\"edit\" id=\"Name" + i + "Lang\"></div>"
+ +"</div>").appendTo("#bindingTemplatesContainer");
+ Reedit();
+ reselect();
+
+}
+
+function reselect()
+{
+ $('.editableSelectAccessPoint').editable(null, {
+ data : " {'accessPoint':'accessPoint','HostingRedirector':'HostingRedirector', 'selected':'accessPoint'}",
+ type : 'select'
+ });
+}
+
+function AddTmodelInstance(div)
+{
+
+}
+
+
+function saveService()
+{
+
+}
+function deleteService()
+{
+
+}
\ No newline at end of file
Added: juddi/branches/juddi-3.2.x/juddi-gui/web/js/tmodeledit.js
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/web/js/tmodeledit.js?rev=1460942&view=auto
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/web/js/tmodeledit.js (added)
+++ juddi/branches/juddi-3.2.x/juddi-gui/web/js/tmodeledit.js Tue Mar 26 01:17:45 2013
@@ -0,0 +1,135 @@
+/*
+ * To change this template, choose Tools | Templates
+ * and open the template in the editor.
+ */
+
+
+function AddOverviewDocument()
+{
+ currentOverviewDocs++;
+ var i = currentOverviewDocs;
+ $("<div id=\"overviewDoc" + i + "\" style=\"border-width:1px; border-style:solid\" >"
+ +"<div style=\"float:left;height:100%\"><a href=\"javascript:Remove('overviewDoc" + i
+ +"');\"><i class=\"icon-remove-sign\"></i></a></div>"
+ +"<div style=\"float:left\">Value: </div>"
+ +"<div class=\"edit\" id=\"overviewDoc" + i + "Value\"></div>"
+ +"<div style=\"float:left\">Use Type: </div>"
+ +"<div class=\"edit\" id=\"overviewDoc" + i + "Type\"></div>"
+ //descriptions
+ +"<a href=\"javascript:AddDescriptionSpecific('overviewDoc" + i + "Description');\">"
+ +"<i class=\"icon-plus-sign\"></i></a> Add a description"
+ + ("<div id=\"overviewDoc" + i + "Description\" style=\"border-width:1px; border-style:dotted\"></div>")
+
+ +"</div>").prependTo("#overviewDoc");
+ Reedit();
+}
+
+
+function AddDescriptionOverviewSpecific(div)
+{
+ //javascript:Remove('bindingTemplate0Description0');
+ currentDescriptionSpecific++;
+ var i = currentDescriptionSpecific;
+ $("<div id=\""+ div + i + "\" style=\"border-width:1px; border-style:solid\" >"
+ +"<div style=\"float:left;height:100%\"><a href=\"javascript:Remove('" + div + i
+ +"');\"><i class=\"icon-remove-sign\"></i></a></div>"
+ +"<div style=\"float:left\">Value: </div>"
+ +"<div class=\"edit\" id=\"" + div + "Description" + i + "Value\"></div>"
+ +"<div style=\"float:left\">Language: </div>"
+ +"<div class=\"edit\" id=\"" + div + "Description" + i + "Lang\"></div>"
+ +"</div>").appendTo("#" + div);
+ Reedit();
+}
+
+
+function savetModel()
+{
+ var url='ajax/savetmodel.jsp';
+ var postbackdata = new Array();
+ $("div.edit").each(function()
+ {
+ //TODO filter out (click to edit) values
+ var id=$(this).attr("id");
+ var value=$(this).text();
+ postbackdata.push({
+ name: id,
+ value: value
+ });
+ });
+ postbackdata.push({
+ name:"nonce",
+ value: $("#nonce").val()
+ });
+ $("div.noedit").each(function()
+ {
+ var id=$(this).attr("id");
+ var value=$(this).text();
+ postbackdata.push({
+ name: id,
+ value: value
+ });
+ });
+
+
+ var request= $.ajax({
+ url: url,
+ type:"POST",
+ // dataType: "html",
+ cache: false,
+ // processData: false,f
+ data: postbackdata
+ });
+
+
+ request.done(function(msg) {
+ window.console && console.log('postback done ' + url);
+
+ $("#resultBar").html('<a class="close" data-dismiss="alert" href="javascript:hideAlert();">×' + '</a>' + msg);
+ $("#resultBar").show();
+
+ });
+
+ request.fail(function(jqXHR, textStatus) {
+ window.console && console.log('postback failed ' + url);
+ $("#resultBar").html('<a class="close" data-dismiss="alert" href="javascript:hideAlert();">×' + '</a>' +jqXHR.responseText );
+ //$(".alert").alert();
+ $("#resultBar").show();
+
+ });
+}
+
+function deletetModel()
+{
+ //businessKey
+ var bizid=$("#serviceKey").text();
+ var url='ajax/deletetmodel.jsp?id=' + bizid;
+ var postbackdata = new Array();
+ postbackdata.push({
+ name:"nonce",
+ value: $("#nonce").val()
+ });
+ var request= $.ajax({
+ url: url,
+ type:"POST",
+ // dataType: "html",
+ cache: false,
+ // processData: false,f
+ data: postbackdata
+ });
+
+ request.done(function(msg) {
+ window.console && console.log('postback done ' + url);
+
+ $("#resultBar").html('<a class="close" data-dismiss="alert" href="javascript:hideAlert();">×' + '</a>' + msg);
+ $("#resultBar").show();
+
+ });
+
+ request.fail(function(jqXHR, textStatus) {
+ window.console && console.log('postback failed ' + url);
+ $("#resultBar").html('<a class="close" data-dismiss="alert" href="javascript:hideAlert();">×' + '</a>' + jqXHR.responseText );
+ //$(".alert").alert();
+ $("#resultBar").show();
+
+ });
+}
\ No newline at end of file
Added: juddi/branches/juddi-3.2.x/juddi-gui/web/js/tmodelsearch.js
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/web/js/tmodelsearch.js?rev=1460942&view=auto
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/web/js/tmodelsearch.js (added)
+++ juddi/branches/juddi-3.2.x/juddi-gui/web/js/tmodelsearch.js Tue Mar 26 01:17:45 2013
@@ -0,0 +1,85 @@
+
+var offset=0; //start at the begining
+var maxrecords=20; //record 20 at a time
+var lang="en"; //langauge english
+var totalrecords=0;
+
+RenderTmodelListBySearch('%', offset, maxrecords);
+
+function pagedown()
+{
+ offset = $("#offset").text();
+ //alert(offset);
+ var newoffset = offset - maxrecords;
+ if (newoffset < 0)
+ return;
+ //alert(newoffset);
+ if (newoffset != offset)
+ RenderTmodelListBySearch('%', newoffset, maxrecords);
+}
+function pageup()
+{
+ offset = $("#offset").text();
+ //alert(offset);
+ var fetch = maxrecords;
+ if ((parseInt(offset) + parseInt(maxrecords)) > totalrecords)
+ //fetch = maxrecords - offset;
+ return;
+ else
+ fetch = (parseInt(offset) + parseInt(maxrecords));
+ //alert(fetch);
+ offset = fetch;
+ RenderTmodelListBySearch('%', fetch, maxrecords);
+}
+
+//offset, maxrecords, keyword
+function RenderTmodelListBySearch(keyword1, offset1, maxrecords1)
+{
+ var lang = $("#lang").text();
+ $("#tmodellist").html("<img src=\"img/bigrollergreen.gif\" title=\"Loading\"/>");
+ var request= $.ajax({
+ url: 'ajax/tmodelsearch.jsp?keyword=' + keyword1 + "&offset=" + offset1 + "&maxrecords=" + maxrecords1 + "&lang=" + lang,
+ type:"GET",
+ cache: false
+ });
+
+ request.done(function(msg) {
+ window.console && console.log('postback done ');
+ $("#tmodellist").html(msg);
+ //refresh();
+ });
+
+ request.fail(function(jqXHR, textStatus) {
+ window.console && console.log('postback failed ');
+ $("#tmodellist").html("An error occured! " + textStatus + jqXHR);
+ //refresh();
+ });
+/*
+ $.get('ajax/businesssearch.jsp?keyword=' + keyword1 + "&offset=" + offset1 + "&maxrecords=" + maxrecords1 + "&lang=" + lang, function(data) {
+ $("#businesslist").html(data);
+ refresh();
+ });*/
+}
+
+function refresh()
+{
+ var displayrecords = $("#displayrecords").text();
+ if (displayrecords == totalrecords)
+ {
+ $("#pageup").addClass("disabled");
+ $("#pagedown").addClass("disabled");
+ }
+ else if (offset + maxrecords > totalrecords)
+ {
+ $("#pageup").addClass("disabled");
+ }
+ else if (offset ==0)
+ {
+ $("#pagedown").removeClass("disabled");
+ }
+ else
+ {
+ $("#pagedown").removeClass("disabled");
+ $("#pageup").removeClass("disabled");
+ }
+}
\ No newline at end of file
Added: juddi/branches/juddi-3.2.x/juddi-gui/web/login.jsp
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/web/login.jsp?rev=1460942&view=auto
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/web/login.jsp (added)
+++ juddi/branches/juddi-3.2.x/juddi-gui/web/login.jsp Tue Mar 26 01:17:45 2013
@@ -0,0 +1,33 @@
+<%--
+ Document : login
+ Created on : Feb 24, 2013, 9:08:02 AM
+ Author : Alex O'Ree
+--%>
+
+<%@page import="org.apache.commons.lang.StringEscapeUtils"%>
+<%@page contentType="text/html" pageEncoding="UTF-8"%>
+<!DOCTYPE html>
+
+<div class="navbar-form pull-right">
+ <%
+ if (session.getAttribute("username") == null || session.getAttribute("password") == null) {
+ %>
+ <script type="text/javascript">
+ loggedin = false;
+ </script>
+ <input class="span2" type="text" placeholder="Username" name="username" id="username">
+ <input class="span2" type="password" placeholder="Password" name="password" id="password">
+ <button type="button" onclick="javascript:Login();" class="btn" id="loginbutton">Login</button>
+
+ <% } else {
+ %>
+ <script type="text/javascript">
+ loggedin = true;
+ </script>
+ <a class="btn" title="Click to logout" href="javascript:logout();"><i class="icon-user"></i>
+ <%
+ out.write("Welcome " + StringEscapeUtils.escapeHtml((String) session.getAttribute("username")) + "</a>");
+
+ }
+ %>
+</div>
Added: juddi/branches/juddi-3.2.x/juddi-gui/web/logout.jsp
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/web/logout.jsp?rev=1460942&view=auto
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/web/logout.jsp (added)
+++ juddi/branches/juddi-3.2.x/juddi-gui/web/logout.jsp Tue Mar 26 01:17:45 2013
@@ -0,0 +1,18 @@
+<%--
+ Document : logout page
+ Created on : Feb 25, 2013, 10:25:48 PM
+ Author : Alex O'Ree
+--%>
+
+<%@page import="org.apache.juddi.webconsole.UddiHub"%>
+<%@page contentType="text/html" pageEncoding="UTF-8"%>
+<%
+ UddiHub hub = UddiHub.getInstance(application, session);
+ UddiHub.reset(session);
+ hub.die();
+ session.removeAttribute("username");
+ session.removeAttribute("password");
+ // session.invalidate();
+ // response.sendRedirect("index.jsp");
+//do not invalidate the session, this will cause the form nonce to clear until the browser url changes
+%>
\ No newline at end of file
Added: juddi/branches/juddi-3.2.x/juddi-gui/web/publisherBrowse.jsp
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/web/publisherBrowse.jsp?rev=1460942&view=auto
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/web/publisherBrowse.jsp (added)
+++ juddi/branches/juddi-3.2.x/juddi-gui/web/publisherBrowse.jsp Tue Mar 26 01:17:45 2013
@@ -0,0 +1,69 @@
+<%--
+ Document : publisherBrowse
+ Created on : Feb 28, 2013, 6:44:04 AM
+ Author : Alex O'Ree
+--%>
+
+
+<%@page import="org.apache.juddi.webconsole.UddiHub"%>
+<%@page import="org.apache.juddi.v3.client.transport.Transport"%>
+
+<%@page import="org.apache.juddi.ClassUtil"%>
+<%@page import="org.apache.juddi.query.util.FindQualifiers"%>
+<%@page import="org.apache.juddi.v3.client.config.UDDIClientContainer"%>
+<%@page import="org.apache.juddi.v3.client.transport.Transport"%>
+<%@page import="org.apache.juddi.v3_service.JUDDIApiPortType"%>
+<%@page import="org.uddi.api_v3.AuthToken"%>
+<%@page import="org.uddi.api_v3.BindingTemplates"%>
+<%@page import="org.uddi.api_v3.BusinessDetail"%>
+<%@page import="org.uddi.api_v3.BusinessInfos"%>
+<%@page import="org.uddi.api_v3.BusinessList"%>
+<%@page import="org.uddi.api_v3.BusinessService"%>
+<%@page import="org.uddi.api_v3.CategoryBag"%>
+<%@page import="org.uddi.api_v3.Contacts"%>
+<%@page import="org.uddi.api_v3.Description"%>
+<%@page import="org.uddi.api_v3.FindBusiness"%>
+<%@page import="org.uddi.api_v3.GetAuthToken"%>
+<%@page import="org.uddi.api_v3.GetBusinessDetail"%>
+<%@page import="org.uddi.api_v3.GetServiceDetail"%>
+<%@page import="org.uddi.api_v3.KeyedReference"%>
+<%@page import="org.uddi.api_v3.Name"%>
+<%@page import="org.uddi.api_v3.ServiceDetail"%>
+<%@page import="org.uddi.api_v3.ServiceInfos"%>
+<%@page import="org.uddi.v3_service.UDDIInquiryPortType"%>
+<%@page import="org.uddi.v3_service.UDDISecurityPortType"%>
+
+<%@page contentType="text/html" pageEncoding="UTF-8"%>
+<%@include file="header-top.jsp" %>
+<div class="container">
+
+ <!-- Main hero unit for a primary marketing message or call to action -->
+ <div class="well" >
+ <h1>Publishers</h1>
+ </div>
+
+ <!-- Example row of columns -->
+ <div class="row">
+ <div class="span12" >
+ <div id="publisherlist">
+ <%
+ UddiHub x = UddiHub.getInstance(application, request.getSession());
+
+ out.write(x.GetPublisherListAsHtml());
+ %>
+ </div>
+ <script type="text/javascript">
+
+ $('.edit').editable(function(value, settings) {
+ console.log(this);
+ console.log(value);
+ console.log(settings);
+ return(value);
+ }, {
+ type : 'text',
+ submit : 'OK'
+ });
+ </script>
+ </div>
+ </div>
+ <%@include file="header-bottom.jsp" %>
Added: juddi/branches/juddi-3.2.x/juddi-gui/web/search.jsp
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/web/search.jsp?rev=1460942&view=auto
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/web/search.jsp (added)
+++ juddi/branches/juddi-3.2.x/juddi-gui/web/search.jsp Tue Mar 26 01:17:45 2013
@@ -0,0 +1,219 @@
+<%--
+ Document : search
+ Created on : Feb 24, 2013, 9:14:01 AM
+ Author : Alex O'Ree
+--%>
+
+<%@page import="org.apache.juddi.query.util.FindQualifiers"%>
+<%@page import="org.apache.juddi.webconsole.UddiHub"%>
+
+<%@page contentType="text/html" pageEncoding="UTF-8"%>
+<%@include file="header-top.jsp" %>
+<div class="container">
+
+ <!-- Main hero unit for a primary marketing message or call to action -->
+ <div class="well" >
+ <h1>Search</h1>
+ </div>
+
+ <!-- Example row of columns -->
+ <div class="row">
+ <div class="span12" >
+
+
+ <%
+ UddiHub x = UddiHub.getInstance(application, request.getSession());
+
+ %>
+ <div class="accordion" id="accordion2">
+ <div class="accordion-group">
+ <div class="accordion-heading">
+ <a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseOne">
+ <b>Search!</b>
+ </a>
+ </div>
+ <div id="collapseOne" class="accordion-body collapse in">
+ <div class="accordion-inner">
+ What are you looking for?<Br>
+ <div class="btn-group" id="searchfor" data-toggle="buttons-radio">
+ <button type="button" class="btn active" value="business">Business</button>
+ <!--<button type="button" class="btn " >Related Business</button>-->
+ <button type="button" class="btn " value="service">Service</button>
+ <button type="button" class="btn " value="bindingTemplate">Binding Template</button>
+ <button type="button" class="btn " value="tModel">tModel</button>
+ <% if (x.IsJuddiRegistry()) {
+ %>
+ <button type="button" class="btn " >Publisher</button>
+ <% }
+ %>
+ </div><br><Br>
+ Search Criteria<br>
+ <div class="btn-group" id="searchcriteria" data-toggle="buttons-radio">
+ <button type="button" class="btn active" active value="name">By Name</button>
+ <button type="button" class="btn " value="category">By Category</button>
+ <button type="button" class="btn " value="key">Unique Identifier</button>
+ <button type="button" class="btn " value="tmodel">tModel</button>
+ </div><br>
+ Find Qualifiers<br>
+
+ <div style=" float:left; padding: 2px">
+
+ <div ><input type="checkbox" name="<%=FindQualifiers.AND_ALL_KEYS%>" value="<%=FindQualifiers.AND_ALL_KEYS%>"> <%=FindQualifiers.AND_ALL_KEYS%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.APPROXIMATE_MATCH%>" value="<%=FindQualifiers.APPROXIMATE_MATCH%>"> <%=FindQualifiers.APPROXIMATE_MATCH%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.BINARY_SORT%>" value="<%=FindQualifiers.BINARY_SORT%>"> <%=FindQualifiers.BINARY_SORT%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.BINDING_SUBSET%>" value="<%=FindQualifiers.BINDING_SUBSET%>"> <%=FindQualifiers.BINDING_SUBSET%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.CASE_INSENSITIVE_MATCH%>" value="<%=FindQualifiers.CASE_INSENSITIVE_MATCH%>"> <%=FindQualifiers.CASE_INSENSITIVE_MATCH%></div>
+ </div>
+ <div style=" float:left; padding: 2px">
+ <div ><input type="checkbox" name="<%=FindQualifiers.CASE_INSENSITIVE_SORT%>" value="<%=FindQualifiers.CASE_INSENSITIVE_SORT%>"> <%=FindQualifiers.CASE_INSENSITIVE_SORT%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.CASE_SENSITIVE_MATCH%>" value="<%=FindQualifiers.CASE_SENSITIVE_MATCH%>"> <%=FindQualifiers.CASE_SENSITIVE_MATCH%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.CASE_SENSITIVE_SORT%>" value="<%=FindQualifiers.CASE_SENSITIVE_SORT%>"> <%=FindQualifiers.CASE_SENSITIVE_SORT%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.COMBINE_CATEGORY_BAGS%>" value="<%=FindQualifiers.COMBINE_CATEGORY_BAGS%>"> <%=FindQualifiers.COMBINE_CATEGORY_BAGS%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.DIACRITIC_INSENSITIVE_MATCH%>" value="<%=FindQualifiers.DIACRITIC_INSENSITIVE_MATCH%>"> <%=FindQualifiers.DIACRITIC_INSENSITIVE_MATCH%></div>
+ </div>
+ <div style=" float:left; padding: 2px">
+ <div ><input type="checkbox" name="<%=FindQualifiers.DIACRITIC_SENSITIVE_MATCH%>" value="<%=FindQualifiers.DIACRITIC_SENSITIVE_MATCH%>"> <%=FindQualifiers.DIACRITIC_SENSITIVE_MATCH%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.EXACT_MATCH%>" value="<%=FindQualifiers.EXACT_MATCH%>"> <%=FindQualifiers.EXACT_MATCH%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.OR_ALL_KEYS%>" value="<%=FindQualifiers.OR_ALL_KEYS%>"> <%=FindQualifiers.OR_ALL_KEYS%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.OR_LIKE_KEYS%>" value="<%=FindQualifiers.OR_LIKE_KEYS%>"> <%=FindQualifiers.OR_LIKE_KEYS%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.SERVICE_SUBSET%>" value="<%=FindQualifiers.SERVICE_SUBSET%>"> <%=FindQualifiers.SERVICE_SUBSET%></div>
+ </div>
+ <div style=" float:left; padding: 2px">
+ <div ><input type="checkbox" name="<%=FindQualifiers.SIGNATURE_PRESENT%>" value="<%=FindQualifiers.SIGNATURE_PRESENT%>"> <%=FindQualifiers.SIGNATURE_PRESENT%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.SORT_BY_DATE_ASC%>" value="<%=FindQualifiers.SORT_BY_DATE_ASC%>"> <%=FindQualifiers.SORT_BY_DATE_ASC%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.SORT_BY_DATE_DESC%>" value="<%=FindQualifiers.SORT_BY_DATE_DESC%>"> <%=FindQualifiers.SORT_BY_DATE_DESC%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.SORT_BY_NAME_ASC%>" value="<%=FindQualifiers.SORT_BY_NAME_ASC%>"> <%=FindQualifiers.SORT_BY_NAME_ASC%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.SORT_BY_NAME_DESC%>" value="<%=FindQualifiers.SORT_BY_NAME_DESC%>"> <%=FindQualifiers.SORT_BY_NAME_DESC%></div>
+ </div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.SUPPRESS_PROJECTED_SERVICES%>" value="<%=FindQualifiers.SUPPRESS_PROJECTED_SERVICES%>"> <%=FindQualifiers.SUPPRESS_PROJECTED_SERVICES%></div>
+ <div ><input type="checkbox" name="<%=FindQualifiers.UTS_10%>" value="<%=FindQualifiers.UTS_10%>"> <%=FindQualifiers.UTS_10%></div>
+
+ <Br>
+ <br>
+ <div>
+ <br><Br>
+ <input type="text" placeholder="Type somethingâ¦" id="searchcontent">
+ <input type="text" placeholder="Language" id="lang"><br>
+ *Tip: use '%' for any number of wild card characters and '_' for a single wild card character.
+ <br>
+ <a href="javascript:search();" class="btn btn-primary btn-large">Search</a>
+ </div>
+ </div>
+ </div>
+ </div>
+ <div class="accordion-group">
+ <div class="accordion-heading">
+ <a class="accordion-toggle" data-toggle="collapse" data-parent="#accordion2" href="#collapseTwo">
+ Results
+ </a>
+ </div>
+ <div id="collapseTwo" class="accordion-body collapse">
+ <div class="accordion-inner" id="resultdivs">
+ Try Searching first...
+ </div>
+ </div>
+ </div>
+ </div>
+
+ </div>
+ </div>
+ <script type="text/javascript">
+ var offset=0;
+ var maxrecords=20;
+ function search()
+ {
+ /*
+ $.each($('input:checkbox'), function(index,item){
+ var itemname = item.name;
+ if (item.checked)
+ {
+ fqs+=itemname+",";
+ }
+ });
+ */
+ //var fqs = $('input:checkbox').length ? $('input:checked').val() : '';
+ //alert (fqs);
+ var selection = $("#searchcriteria > button.btn.active").val();
+ //alert(selection);
+
+ //var findqualifier = $("#findqualifier").val();
+ //alert(findqualifier);
+ var searchfor = $("#searchfor > button.btn.active").val();
+ //alert(searchfor);
+ var searchcontent = $("#searchcontent").val();
+ //alert(searchcontent );
+ var url='ajax/search.jsp';
+
+ $("#collapseTwo").collapse("show");
+ $("#collapseOne").collapse("hide");
+
+ var postbackdata = new Array();
+
+ postbackdata.push({
+ name:"selection",
+ value: selection
+ });
+
+ postbackdata.push({
+ name:"searchcontent",
+ value: searchcontent
+ });
+
+ postbackdata.push({
+ name:"lang",
+ value: $("#lang").val()
+ });
+
+
+ $.each($('input:checkbox'), function(index,item){
+ var itemname = item.name;
+ if (item.checked)
+ {
+ postbackdata.push({
+ name:"findqualifier",
+ value: itemname
+ });
+ }
+ });
+
+
+ postbackdata.push({
+ name:"searchfor",
+ value: searchfor
+ });
+
+ postbackdata.push({
+ name:"nonce",
+ value: $("#nonce").val()
+ });
+
+ var request= $.ajax({
+ url: url,
+ type:"POST",
+ // dataType: "html",
+ cache: false,
+ // processData: false,f
+ data: postbackdata
+ });
+
+
+ request.done(function(msg) {
+ window.console && console.log('postback done ' + url);
+
+ $("#resultdivs").html(msg);
+
+
+ });
+
+ request.fail(function(jqXHR, textStatus) {
+ window.console && console.log('postback failed ' + url);
+ $("#resultdivs").html(jqXHR.responseText + textStatus);
+ //$(".alert").alert();
+
+
+ });
+
+ }
+
+ </script>
+ <%@include file="header-bottom.jsp" %>
\ No newline at end of file
Added: juddi/branches/juddi-3.2.x/juddi-gui/web/serviceBrowse.jsp
URL: http://svn.apache.org/viewvc/juddi/branches/juddi-3.2.x/juddi-gui/web/serviceBrowse.jsp?rev=1460942&view=auto
==============================================================================
--- juddi/branches/juddi-3.2.x/juddi-gui/web/serviceBrowse.jsp (added)
+++ juddi/branches/juddi-3.2.x/juddi-gui/web/serviceBrowse.jsp Tue Mar 26 01:17:45 2013
@@ -0,0 +1,52 @@
+<%--
+ Document : Service Browser
+ Created on : Feb 24, 2013, 9:14:01 AM
+ Author : Alex O'Ree
+--%>
+
+<%@page import="org.apache.juddi.webconsole.UddiHub"%>
+
+<%@page contentType="text/html" pageEncoding="UTF-8"%>
+<%@include file="header-top.jsp" %>
+<div class="container">
+
+ <!-- Main hero unit for a primary marketing message or call to action -->
+ <div class="well" >
+ <h1>Service Browser</h1>
+ </div>
+
+ <!-- Example row of columns -->
+ <div class="row">
+ <div class="span12" >
+ <div id="businesslist">
+ Total records: <span id="totalrecords"></span><br>
+ Records returned: <span id="displayrecords"></span><br>
+ Offset: <span id="offset">0</span><br>
+ Lang: <span id="lang" class="edit"></span><br>
+
+ <a href="javascript:pagedown();"><i class="icon-circle-arrow-left " id="pageup"></i></a>
+ <a href="javascript:refreshServiceList();"><i class="icon-refresh " id="refresh"></i></a>
+ <a href="javascript:pageup();"><i class="icon-circle-arrow-right " id="pagedown"></i></a>
+
+ <div id="serviceBrowserListings">
+ <img src="img/bigrollergreen.gif" title="Loading"/>
+ </div>
+ <script src="js/serviceBrowse.js"></script>
+ <script type="text/javascript">
+
+ $('.edit').editable(function(value, settings) {
+ console.log(this);
+ console.log(value);
+ console.log(settings);
+ RenderServiceListBySearch('%', offset, maxrecords);
+ return(value);
+ }, {
+ type : 'text',
+ submit : 'OK'
+ });
+ </script>
+ </div>
+
+ </div>
+ </div>
+ <%@include file="header-bottom.jsp" %>
\ No newline at end of file
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@juddi.apache.org
For additional commands, e-mail: commits-help@juddi.apache.org