roo00 6 жил өмнө
parent
commit
a7922f1b75
100 өөрчлөгдсөн 1095 нэмэгдсэн , 3644 устгасан
  1. 0 191
      o2server/x_attendance_assemble_control/src/main/webapp/jest/ajaxfileupload.js
  2. 0 26
      o2server/x_attendance_assemble_control/src/main/webapp/jest/common.js
  3. 0 105
      o2server/x_attendance_assemble_control/src/main/webapp/jest/data.js
  4. 0 77
      o2server/x_attendance_assemble_control/src/main/webapp/jest/debug.js
  5. 34 13
      o2server/x_attendance_assemble_control/src/main/webapp/jest/describe.js
  6. 0 44
      o2server/x_attendance_assemble_control/src/main/webapp/jest/do_statistic.html
  7. 0 17
      o2server/x_attendance_assemble_control/src/main/webapp/jest/do_statistic.js
  8. 0 58
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceAdmin.html
  9. 0 56
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceAdmin.js
  10. 0 77
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceAppeal.html
  11. 0 82
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceAppeal.js
  12. 0 90
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceDetail.html
  13. 0 124
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceDetail.js
  14. 0 58
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceDetailFileImport.html
  15. 0 61
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceDetailFileImport.js
  16. 0 70
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceImportFileInfo.html
  17. 0 71
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceImportFileInfo.js
  18. 0 58
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceScheduleSetting.html
  19. 0 56
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceScheduleSetting.js
  20. 0 58
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceSelfHoliday.html
  21. 0 56
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceSelfHoliday.js
  22. 0 58
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceSetting.html
  23. 0 56
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceSetting.js
  24. 0 58
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceWorkDayConfig.html
  25. 0 56
      o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceWorkDayConfig.js
  26. 66 4
      o2server/x_attendance_assemble_control/src/main/webapp/jest/index.html
  27. 0 1
      o2server/x_attendance_assemble_control/src/main/webapp/jest/jquery.js
  28. 0 105
      o2server/x_attendance_assemble_control/src/main/webapp/jest/logger.js
  29. 0 94
      o2server/x_attendance_assemble_control/src/main/webapp/jest/showStatistic.html
  30. 0 62
      o2server/x_attendance_assemble_control/src/main/webapp/jest/showStatistic.js
  31. 0 48
      o2server/x_attendance_assemble_control/src/main/webapp/jest/test.html
  32. 0 71
      o2server/x_attendance_assemble_control/src/main/webapp/jest/test.js
  33. 0 45
      o2server/x_attendance_assemble_control/src/main/webapp/jest/uuid.html
  34. 33 1
      o2server/x_base_core_project/src/main/java/com/x/base/core/container/EntityManagerContainer.java
  35. 33 0
      o2server/x_base_core_project/src/main/java/com/x/base/core/container/factory/PersistenceXmlHelper.java
  36. 1 2
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/Applications.java
  37. 6 1
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/annotation/Describe.java
  38. 12 5
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/config/CenterServer.java
  39. 13 1
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/config/Config.java
  40. 11 0
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/exception/ExceptionUnknowValue.java
  41. 2 0
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/jaxrs/AbstractJaxrsAction.java
  42. 36 2
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/jaxrs/ResponseFactory.java
  43. 26 0
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/jaxrs/WoSeeOther.java
  44. 26 0
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/jaxrs/WoTemporaryRedirect.java
  45. 10 0
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/message/MessageConnector.java
  46. 6 2
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/message/WsMessage.java
  47. 3 0
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/organization/OrganizationDefinition.java
  48. 12 0
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/tools/StringTools.java
  49. 3 3
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/x_processplatform_assemble_designer.java
  50. 3 3
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/x_processplatform_assemble_surface.java
  51. 2 1
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/x_processplatform_service_processing.java
  52. 0 32
      o2server/x_base_core_project/src/main/java/com/x/base/core/project/x_query_service_processing.java
  53. 0 8
      o2server/x_base_core_project/src/test/java/com/x/base/core/project/test/CryptoClass.java
  54. 0 82
      o2server/x_bbs_assemble_control/src/main/webapp/jest/bbs_foruminfo.html
  55. 0 86
      o2server/x_bbs_assemble_control/src/main/webapp/jest/bbs_permissioninfo.html
  56. 0 86
      o2server/x_bbs_assemble_control/src/main/webapp/jest/bbs_roleinfo.html
  57. 0 82
      o2server/x_bbs_assemble_control/src/main/webapp/jest/bbs_subjectinfo.html
  58. 0 26
      o2server/x_bbs_assemble_control/src/main/webapp/jest/common.js
  59. 0 76
      o2server/x_bbs_assemble_control/src/main/webapp/jest/common_rest.html
  60. 0 77
      o2server/x_bbs_assemble_control/src/main/webapp/jest/debug.js
  61. 34 13
      o2server/x_bbs_assemble_control/src/main/webapp/jest/describe.js
  62. 66 4
      o2server/x_bbs_assemble_control/src/main/webapp/jest/index.html
  63. 0 191
      o2server/x_bbs_assemble_control/src/main/webapp/jest/jest_ajaxfileupload.js
  64. 0 119
      o2server/x_bbs_assemble_control/src/main/webapp/jest/jest_common.js
  65. 0 1
      o2server/x_bbs_assemble_control/src/main/webapp/jest/jest_jquery.js
  66. 0 1
      o2server/x_bbs_assemble_control/src/main/webapp/jest/jquery.js
  67. 0 13
      o2server/x_bbs_assemble_control/src/main/webapp/jest/json/centerworkinfo/save.json
  68. 0 105
      o2server/x_bbs_assemble_control/src/main/webapp/jest/logger.js
  69. 7 1
      o2server/x_calendar_assemble_control/src/main/java/com/x/calendar/assemble/control/factory/MessageFactory.java
  70. 1 1
      o2server/x_calendar_assemble_control/src/main/java/com/x/calendar/assemble/control/jaxrs/event/ActionDestroyAfterEventId.java
  71. 1 1
      o2server/x_calendar_assemble_control/src/main/java/com/x/calendar/assemble/control/jaxrs/event/ActionDestroySingleEventWithId.java
  72. 1 1
      o2server/x_calendar_assemble_control/src/main/java/com/x/calendar/assemble/control/jaxrs/event/ActionDestroyWithMaster.java
  73. 5 7
      o2server/x_calendar_assemble_control/src/main/java/com/x/calendar/assemble/control/service/Calendar_EventService.java
  74. 0 26
      o2server/x_calendar_assemble_control/src/main/webapp/jest/common.js
  75. 0 76
      o2server/x_calendar_assemble_control/src/main/webapp/jest/common_rest.html
  76. 0 77
      o2server/x_calendar_assemble_control/src/main/webapp/jest/debug.js
  77. 34 13
      o2server/x_calendar_assemble_control/src/main/webapp/jest/describe.js
  78. 66 4
      o2server/x_calendar_assemble_control/src/main/webapp/jest/index.html
  79. 0 119
      o2server/x_calendar_assemble_control/src/main/webapp/jest/jest_common.js
  80. 0 1
      o2server/x_calendar_assemble_control/src/main/webapp/jest/jest_jquery.js
  81. 0 1
      o2server/x_calendar_assemble_control/src/main/webapp/jest/jquery.js
  82. 0 105
      o2server/x_calendar_assemble_control/src/main/webapp/jest/logger.js
  83. 15 10
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/factory/AppInfoFactory.java
  84. 25 23
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/factory/CategoryInfoFactory.java
  85. 2 2
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/factory/DocumentFactory.java
  86. 2 2
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionGetPublishableAppInfo.java
  87. 3 1
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListAllAppType.java
  88. 2 2
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanManage_WithAppType.java
  89. 4 4
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanPublish.java
  90. 87 0
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanPublish_WithAppType.java
  91. 4 4
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanViewAllDocType.java
  92. 83 0
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanViewAllDocType_WithAppType.java
  93. 5 5
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanViewArticle.java
  94. 88 0
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanViewArticle_WithAppType.java
  95. 5 5
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanViewData.java
  96. 84 0
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanViewData_WithAppType.java
  97. 96 12
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/AppInfoAction.java
  98. 30 11
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/BaseAction.java
  99. 1 1
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/document/ActionPersistSaveDocument.java
  100. 6 0
      o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/service/AppInfoService.java

+ 0 - 191
o2server/x_attendance_assemble_control/src/main/webapp/jest/ajaxfileupload.js

@@ -1,191 +0,0 @@
-
-jQuery.extend({
-	
-
-    createUploadIframe: function(id, uri)
-	{
-			//create frame
-            var frameId = 'jUploadFrame' + id;
-            var iframeHtml = '<iframe id="' + frameId + '" name="' + frameId + '" style="position:absolute; top:-9999px; left:-9999px"';
-			if(window.ActiveXObject)
-			{
-                if(typeof uri== 'boolean'){
-					iframeHtml += ' src="' + 'javascript:false' + '"';
-
-                }
-                else if(typeof uri== 'string'){
-					iframeHtml += ' src="' + uri + '"';
-
-                }	
-			}
-			iframeHtml += ' />';
-			jQuery(iframeHtml).appendTo(document.body);
-
-            return jQuery('#' + frameId).get(0);			
-    },
-    createUploadForm: function(id, fileElementId)
-	{
-		//create form	
-		var formId = 'jUploadForm' + id;
-		var fileId = 'jUploadFile' + id;
-		var form = jQuery('<form  action="" method="POST" name="' + formId + '" id="' + formId + '" enctype="multipart/form-data"></form>');	
-		var oldElement = jQuery('#' + fileElementId);
-		var newElement = jQuery(oldElement).clone();
-		jQuery(oldElement).attr('id', fileId);
-		jQuery(oldElement).before(newElement);
-		jQuery(oldElement).appendTo(form);
-		//set attributes
-		jQuery(form).css('position', 'absolute');
-		jQuery(form).css('top', '-1200px');
-		jQuery(form).css('left', '-1200px');
-		jQuery(form).appendTo('body');		
-		return form;
-    },
-
-    ajaxFileUpload: function(s) {
-        // TODO introduce global settings, allowing the client to modify them for all requests, not only timeout		
-        s = jQuery.extend({}, jQuery.ajaxSettings, s);
-        var id = new Date().getTime()        
-		var form = jQuery.createUploadForm(id, s.fileElementId);
-		var io = jQuery.createUploadIframe(id, s.secureuri);
-		var frameId = 'jUploadFrame' + id;
-		var formId = 'jUploadForm' + id;		
-        // Watch for a new set of requests
-        if ( s.global && ! jQuery.active++ )
-		{
-			jQuery.event.trigger( "ajaxStart" );
-		}            
-        var requestDone = false;
-        // Create the request object
-        var xml = {}   
-        if ( s.global )
-            jQuery.event.trigger("ajaxSend", [xml, s]);
-        // Wait for a response to come back
-        var uploadCallback = function(isTimeout)
-		{			
-			var io = document.getElementById(frameId);
-            try 
-			{				
-				if(io.contentWindow)
-				{
-					 xml.responseText = io.contentWindow.document.body?io.contentWindow.document.body.innerHTML:null;
-                	 xml.responseXML = io.contentWindow.document.XMLDocument?io.contentWindow.document.XMLDocument:io.contentWindow.document;
-					 
-				}else if(io.contentDocument)
-				{
-					 xml.responseText = io.contentDocument.document.body?io.contentDocument.document.body.innerHTML:null;
-                	xml.responseXML = io.contentDocument.document.XMLDocument?io.contentDocument.document.XMLDocument:io.contentDocument.document;
-				}						
-            }catch(e)
-			{
-				jQuery.handleError(s, xml, null, e);
-			}
-            if ( xml || isTimeout == "timeout") 
-			{				
-                requestDone = true;
-                var status;
-                try {
-                    status = isTimeout != "timeout" ? "success" : "error";
-                    // Make sure that the request was successful or notmodified
-                    if ( status != "error" )
-					{
-                        // process the data (runs the xml through httpData regardless of callback)
-                        var data = jQuery.uploadHttpData( xml, s.dataType );    
-                        // If a local callback was specified, fire it and pass it the data
-                        if ( s.success )
-                            s.success( data, status );
-    
-                        // Fire the global callback
-                        if( s.global )
-                            jQuery.event.trigger( "ajaxSuccess", [xml, s] );
-                    } else
-                        jQuery.handleError(s, xml, status);
-                } catch(e) 
-				{
-                    status = "error";
-                    jQuery.handleError(s, xml, status, e);
-                }
-
-                // The request was completed
-                if( s.global )
-                    jQuery.event.trigger( "ajaxComplete", [xml, s] );
-
-                // Handle the global AJAX counter
-                if ( s.global && ! --jQuery.active )
-                    jQuery.event.trigger( "ajaxStop" );
-
-                // Process result
-                if ( s.complete )
-                    s.complete(xml, status);
-
-                jQuery(io).unbind()
-
-                setTimeout(function()
-									{	try 
-										{
-											jQuery(io).remove();
-											jQuery(form).remove();	
-											
-										} catch(e) 
-										{
-											jQuery.handleError(s, xml, null, e);
-										}									
-
-									}, 100)
-
-                xml = null
-
-            }
-        }
-        // Timeout checker
-        if ( s.timeout > 0 ) 
-		{
-            setTimeout(function(){
-                // Check to see if the request is still happening
-                if( !requestDone ) uploadCallback( "timeout" );
-            }, s.timeout);
-        }
-        try 
-		{
-
-			var form = jQuery('#' + formId);
-			jQuery(form).attr('action', s.url);
-			jQuery(form).attr('method', 'POST');
-			jQuery(form).attr('target', frameId);
-            if(form.encoding)
-			{
-				jQuery(form).attr('encoding', 'multipart/form-data');      			
-            }
-            else
-			{	
-				jQuery(form).attr('enctype', 'multipart/form-data');			
-            }			
-            jQuery(form).submit();
-
-        } catch(e) 
-		{			
-            jQuery.handleError(s, xml, null, e);
-        }
-		
-		jQuery('#' + frameId).load(uploadCallback	);
-        return {abort: function () {}};	
-
-    },
-
-    uploadHttpData: function( r, type ) {
-        var data = !type;
-        data = type == "xml" || data ? r.responseXML : r.responseText;
-        // If the type is "script", eval it in global context
-        if ( type == "script" )
-            jQuery.globalEval( data );
-        // Get the JavaScript object, if JSON is used.
-        if ( type == "json" )
-            eval( "data = " + data );
-        // evaluate scripts within html
-        if ( type == "html" )
-            jQuery("<div>").html(data).evalScripts();
-
-        return data;
-    }
-})
-

+ 0 - 26
o2server/x_attendance_assemble_control/src/main/webapp/jest/common.js

@@ -1,26 +0,0 @@
-function failure(data) {
-    console.log(data);
-    alert(data.message);
-}
-
-function splitValue(str) {
-    if (str) {
-	if (str.length > 0) {
-	    return str.split(',');
-	}
-    }
-    return [];
-}
-
-function joinValue(o, split) {
-    var s = ',';
-    if (split) {
-	s = '' + split;
-    }
-    if (o) {
-	if (toString.apply(o) === '[object Array]') {
-	    return o.join(s);
-	}
-    }
-    return o;
-}

+ 0 - 105
o2server/x_attendance_assemble_control/src/main/webapp/jest/data.js

@@ -1,105 +0,0 @@
-function data_query() {
-    str = '<table border="1" width="100%">';
-    str += '<tr><td>id:</td><td><input type="text" id="id" style="width:95%"/></td></tr>';
-    str += '<tr><td>type:</td><td>';
-    str += '<select id="type">';
-    str += '<option value="appInfo">appInfo</option>';
-    str += '<option value="catagoryInfo">catagoryInfo</option>';
-    str += '<option value="fileInfo">fileInfo</option>';
-    str += '<option value="appCatagoryPermission">appCatagoryPermission</option>';
-    str += '<option value="appCatagoryAdmin">appCatagoryAdmin</option>';
-    str += '<option value="log">log</option>';
-    str += '</select>';
-    str += '</td></tr>';
-    str += '<tr><td colspan="2"><button id="get">get</button>&nbsp;<button id="put">put</button>&nbsp;<button id="post">post</button>&nbsp;<button id="uuid">UUID</button></td></tr>';
-    str += '<tr><td colspan="2"><textarea id="data" style="width:95%;height:500px"/></td></tr>';
-    str += '</table>';
-    $('#content').html(str);
-    $('#result').html('');
-    $('#get', '#content').click(function() {
-    	data_get($('#id').val(), $('#type').val());
-    });
-    $('#put', '#content').click(function() {
-    	data_put($('#id').val(), $('#type').val());
-    });
-    $('#post', '#content').click(function() {
-    	data_post($('#id').val(), $('#type').val());
-    });
-    $('#uuid', '#content').click(function() {
-    	get_uuid();
-    });
-}
-
-function get_uuid( ) {
-	$('#data', '#content').val('');
-	$.ajax({
-		type : 'get',
-		dataType : 'json',
-		url : '../jaxrs/uuid/random',
-		xhrFields : {
-			'withCredentials' : true
-		},
-		crossDomain : true
-	}).done(function(data) {
-		if (data.type == 'success') {
-			$('#content').html(JSON.stringify(json.data));
-		} else {
-			failure(data);
-		}
-	});
-}
-
-function data_get(id, type) {
-    $('#data', '#content').val('');
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	contentType : 'application/json; charset=utf-8',
-	url : '../jaxrs/' + type + '/' + id,
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-		$('#result').html(JSON.stringify(data, null, 4));
-		if (json.type == 'success') {
-		    $('#data', '#content').val(JSON.stringify(json.data, null, 4));
-		} else {
-		    failure(data);
-		}
-    }).fail(function(data) {
-    	failure(data);
-    });
-}
-
-function data_put( id, type ) {
-    $.ajax({
-		type : 'put',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/' + type + '/' + id,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON($('#data', '#content').val())),
-		crossDomain : true
-    }).done(function(data) {
-    	$('#result').html(JSON.stringify(data.data, null, 4));
-    });
-}
-
-function data_post( id, type ) {
-    $.ajax({
-		type : 'post',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/' + type ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON($('#data', '#content').val())),
-		crossDomain : true
-    }).done(function(data) {
-    	$('#result').html(JSON.stringify(data.data, null, 4));
-    });
-}

+ 0 - 77
o2server/x_attendance_assemble_control/src/main/webapp/jest/debug.js

@@ -1,77 +0,0 @@
-debug_parameter = {};
-
-function debug_init() {
-    $('#result').html('');
-    $('#content').html('');
-    var str = '<table border="1" width="100%">';
-    str += '<tr><td colspan="2"><a href="#" id="get">get</a>&nbsp<a href="#" id="on">on</a>&nbsp;<a href="#" id="off">off</a></td></tr>';
-    str += '<tr><td>debug:</td><td id="status">&nbsp;</td></tr>';
-    str += '</table>';
-    $('#content').html(str);
-    $('#get').click(function() {
-	debug_get();
-    });
-    $('#on').click(function() {
-	debug_on();
-    });
-    $('#off').click(function() {
-	debug_off();
-    });
-}
-
-function debug_get() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/debug',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-	if (json.type == 'success') {
-	    $('#status').html(json.data.value + '');
-	}
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function debug_on() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/debug/true',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-	if (json.type == 'success') {
-	    $('#status').html(json.data.value + '');
-	}
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function debug_off() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/debug/false',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-	if (json.type == 'success') {
-	    $('#status').html(json.data.value + '');
-	}
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}

+ 34 - 13
o2server/x_attendance_assemble_control/src/main/webapp/jest/describe.js

@@ -200,20 +200,20 @@ Describe.prototype = {
 											switch (p.name) {
 											switch (p.name) {
 											case 'flag':
 											case 'flag':
 											case 'id':
 											case 'id':
-												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid" value="(0)"/></td><td>' + p.name
+												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; " value="(0)"/></td><td>' + p.name
 														+ ':' + p.description + '</td></tr>';
 														+ ':' + p.description + '</td></tr>';
 												break;
 												break;
 											case 'count':
 											case 'count':
-												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid" value="20"/></td><td>' + p.name + ':'
+												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; " value="20"/></td><td>' + p.name + ':'
 														+ p.description + '</td></tr>';
 														+ p.description + '</td></tr>';
 												break;
 												break;
 											default:
 											default:
-												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + p.name + ':'
+												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>' + p.name + ':'
 														+ p.description + '</td></tr>';
 														+ p.description + '</td></tr>';
 												break
 												break
 											}
 											}
 										} else {
 										} else {
-											txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + p.name + ':'
+											txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>' + p.name + ':'
 													+ p.description + '</td></tr>';
 													+ p.description + '</td></tr>';
 										}
 										}
 									});
 									});
@@ -225,10 +225,10 @@ Describe.prototype = {
 									txt += '<table >';
 									txt += '<table >';
 									$.each(m.formParameters, function(pi, p) {
 									$.each(m.formParameters, function(pi, p) {
 										if (p.type == "File") {
 										if (p.type == "File") {
-											txt += '<tr><td><input type="file" name="' + p.name + '" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>'
+											txt += '<tr><td><input type="file" name="' + p.name + '" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>'
 													+ p.name + ':' + p.description + '</td></tr>';
 													+ p.name + ':' + p.description + '</td></tr>';
 										} else {
 										} else {
-											txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + p.name + ':'
+											txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>' + p.name + ':'
 													+ p.description + '</td></tr>';
 													+ p.description + '</td></tr>';
 										}
 										}
 									});
 									});
@@ -239,7 +239,7 @@ Describe.prototype = {
 									txt += '<fieldset id="queryParameters"><legend>Query Parameter</legend>';
 									txt += '<fieldset id="queryParameters"><legend>Query Parameter</legend>';
 									txt += '<table >';
 									txt += '<table >';
 									$.each(m.queryParameters, function(pi, p) {
 									$.each(m.queryParameters, function(pi, p) {
-										txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + p.name + ':' + p.description
+										txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>' + p.name + ':' + p.description
 												+ '</td></tr>';
 												+ '</td></tr>';
 									});
 									});
 									txt += '</table>';
 									txt += '</table>';
@@ -250,10 +250,10 @@ Describe.prototype = {
 									txt += '<table>';
 									txt += '<table>';
 									$.each(m.ins, function(ii, i) {
 									$.each(m.ins, function(ii, i) {
 										if (i.isCollection) {
 										if (i.isCollection) {
-											txt += '<tr><td><textarea id="' + i.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + i.name + ':' + i.description
+											txt += '<tr><td><textarea id="' + i.name + '" style="width:600px; padding:1px; "/></td><td>' + i.name + ':' + i.description
 											'</td></tr>';
 											'</td></tr>';
 										} else {
 										} else {
-											txt += '<tr><td><input type="text" id="' + i.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + i.name + ':'
+											txt += '<tr><td><input type="text" id="' + i.name + '" style="width:600px; padding:1px; "/></td><td>' + i.name + ':'
 													+ i.description
 													+ i.description
 											'</td></tr>';
 											'</td></tr>';
 										}
 										}
@@ -264,7 +264,7 @@ Describe.prototype = {
 								if (m.useJsonElementParameter) {
 								if (m.useJsonElementParameter) {
 									txt += '<fieldset><legend>JsonElement</legend>';
 									txt += '<fieldset><legend>JsonElement</legend>';
 									txt += '<table><tr><td>';
 									txt += '<table><tr><td>';
-									txt += '<textarea id="jsonElement" style="height:300px; width:600px; padding:1px; border:1px #000000 solid"/>';
+									txt += '<textarea id="jsonElement" style="height:300px; width:600px; padding:1px; "/>';
 									txt += '</td><td>json</td></tr>';
 									txt += '</td><td>json</td></tr>';
 									txt += '</table>';
 									txt += '</table>';
 									txt += '</fieldset>';
 									txt += '</fieldset>';
@@ -272,7 +272,7 @@ Describe.prototype = {
 								if (m.useStringParameter) {
 								if (m.useStringParameter) {
 									txt += '<fieldset><legend>String</legend>';
 									txt += '<fieldset><legend>String</legend>';
 									txt += '<table><tr><td>';
 									txt += '<table><tr><td>';
-									txt += '<textarea id="string" style="height:300px; width:600px; padding:1px; border:1px #000000 solid"/>';
+									txt += '<textarea id="string" style="height:300px; width:600px; padding:1px; "/>';
 									txt += '</td><td>string</td></tr>';
 									txt += '</td><td>string</td></tr>';
 									txt += '</table>';
 									txt += '</table>';
 									txt += '</fieldset>';
 									txt += '</fieldset>';
@@ -308,6 +308,7 @@ Describe.prototype = {
 									if (m.contentType.indexOf('application/json') > -1) {
 									if (m.contentType.indexOf('application/json') > -1) {
 										switch (m.type) {
 										switch (m.type) {
 										case 'POST':
 										case 'POST':
+										debugger;
 											var data = {};
 											var data = {};
 											if (m.ins && m.ins.length > 0) {
 											if (m.ins && m.ins.length > 0) {
 												$.each(m.ins, function(ii, i) {
 												$.each(m.ins, function(ii, i) {
@@ -320,11 +321,21 @@ Describe.prototype = {
 																data[i.name] = $('#' + i.name, '#ins').val();
 																data[i.name] = $('#' + i.name, '#ins').val();
 															}
 															}
 														} else {
 														} else {
-															data[i.name] = $.parseJSON($('#' + i.name, '#ins').val());
+															if (i.isCollection) {
+																data[i.name] = Describe.splitValue($('#' + i.name, '#ins').val());
+															} else {
+																if( $('#' + i.name, '#ins').val() == null || typeof($('#' + i.name, '#ins').val()) == "undefind" || $('#' + i.name, '#ins').val() == "" ){
+																	$('#' + i.name, '#ins').val("{}");
+																}
+																data[i.name] = $.parseJSON($('#' + i.name, '#ins').val());
+															}
 														}
 														}
 													}
 													}
 												});
 												});
 											} else if (m.useJsonElementParameter) {
 											} else if (m.useJsonElementParameter) {
+												if( $('#jsonElement').val() == null || typeof($('#jsonElement').val()) == "undefind" || $('#jsonElement').val() == "" ){
+													$('#jsonElement').val("{}");
+												}
 												data = $.parseJSON($('#jsonElement').val());
 												data = $.parseJSON($('#jsonElement').val());
 											} else if (m.useStringParameter) {
 											} else if (m.useStringParameter) {
 												data = $('#string').val();
 												data = $('#string').val();
@@ -344,11 +355,21 @@ Describe.prototype = {
 																data[i.name] = $('#' + i.name, '#ins').val();
 																data[i.name] = $('#' + i.name, '#ins').val();
 															}
 															}
 														} else {
 														} else {
-															data[i.name] = $.parseJSON($('#' + i.name, '#ins').val());
+															if (i.isCollection) {
+																data[i.name] = Describe.splitValue($('#' + i.name, '#ins').val());
+															} else {
+																if( $('#' + i.name, '#ins').val() == null || typeof($('#' + i.name, '#ins').val()) == "undefind" || $('#' + i.name, '#ins').val() == "" ){
+																	$('#' + i.name, '#ins').val("{}");
+																}
+																data[i.name] = $.parseJSON($('#' + i.name, '#ins').val());
+															}
 														}
 														}
 													}
 													}
 												});
 												});
 											} else if (m.useJsonElementParameter) {
 											} else if (m.useJsonElementParameter) {
+												if( $('#jsonElement').val() == null || typeof($('#jsonElement').val()) == "undefind" || $('#jsonElement').val() == "" ){
+													$('#jsonElement').val("{}");
+												}
 												data = $.parseJSON($('#jsonElement').val());
 												data = $.parseJSON($('#jsonElement').val());
 											} else if (m.useStringParameter) {
 											} else if (m.useStringParameter) {
 												data = $('#string').val();
 												data = $('#string').val();

+ 0 - 44
o2server/x_attendance_assemble_control/src/main/webapp/jest/do_statistic.html

@@ -1,44 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script src="./do_statistic.js"></script>
-<script>
-    $(document).ready(function() {
-    	$('#dostatistic').click(function() {
-    		do_statistic();
-        });
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			Do_Statistic
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="dostatistic">do_statistic</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px"></textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-</body>
-</html>

+ 0 - 17
o2server/x_attendance_assemble_control/src/main/webapp/jest/do_statistic.js

@@ -1,17 +0,0 @@
-function do_statistic() {
-	var query_url = '../jaxrs/statistic/do';
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}

+ 0 - 58
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceAdmin.html

@@ -1,58 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script src="./entity_AttendanceAdmin.js"></script>
-<script>
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		data_get_attendanceadmin($('#id').val());
-        });
-        $('#post').click(function() {
-        	data_post_attendanceadmin();
-        });
-        $('#delete').click(function() {
-        	data_delete_attendanceadmin( $('#id').val() );
-        });
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>id:</td>
-				<td><input type="text" id="id" style="width:95%"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			AttendanceAdmin
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="get">GET</button>
-					<button id="post">POST</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px"></textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 0 - 56
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceAdmin.js

@@ -1,56 +0,0 @@
-function data_get_attendanceadmin( id ) {
-	var query_url = '../jaxrs/attendanceadmin/' + id;
-	//如果未输入ID,那么就查询所有的应用信息
-	if( id == null || id == undefined || id == "" ){
-		query_url = '../jaxrs/attendanceadmin/list/all';
-	}
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function data_post_attendanceadmin( id ) {
-    $.ajax({
-		type : 'post',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendanceadmin' ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON($('#content').val())),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function data_delete_attendanceadmin( id ) {
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendanceadmin/' + id ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}

+ 0 - 77
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceAppeal.html

@@ -1,77 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script src="./entity_AttendanceAppeal.js"></script>
-<script>
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		data_get_attendanceappeal();
-        });
-    	$('#put').click(function() {
-    		data_put_attendanceappeal();
-        });
-        $('#delete').click(function() {
-        	data_delete_attendanceappeal( $('#id').val() );
-        });        
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>id:<input type="text" id="id" style="width:95%"/></td>
-			</tr>
-			<tr>
-				<td width="50px">last_id:<input type="text" id="last_id" style="width:95%" value="(0)"/></td>
-				<td width="50px">count:<input type="text" id="count" style="width:95%" value="10"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			AttendanceAppeal
-	    		</td>
-			</tr>
-			<tr>
-	    		<td width="50px">GET:/jaxrs/attendanceappealInfo/
-	    			<select id="service_url">
-	    				<option value="{id}">{id}</option>
-	    			</select>
-	    		</td>
-			</tr>
-			<tr>
-	    		<td width="50px">PUT:/jaxrs/attendanceappealInfo/
-	    			<select id="put_url">
-	    				<option value="appeal/{id}">appeal/{id}</option>
-	    				<option value="process/{id}">process/{id}</option>
-	    				<option value="process2/{id}">process2/{id}</option>
-	    				<option value="filter/list/{id}/next/{count}">filter/list/{id}/next/{count}</option>
-	    				<option value="filter/list/{id}/prev/{count}">filter/list/{id}/prev/{count}</option>
-	    			</select>
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="get">GET</button>
-					<button id="put">PUT</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px"></textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-</body>
-</html>

+ 0 - 82
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceAppeal.js

@@ -1,82 +0,0 @@
-var service_base_path = '../jaxrs/attendanceappealInfo';
-function data_get_attendanceappeal( ) {
-	var service_url = $("#service_url").val();
-	var query_url =  service_base_path + "/" + service_url;
-	
-	//获取用户所填写的参数
-	var id = $("#id").val();
-	
-	//根据参数组织URL
-	query_url = query_url.replace( "{id}",id );
-
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function data_put_attendanceappeal( ) {
-	var service_url = $("#put_url").val();
-	var query_url =  service_base_path + "/" + service_url;
-	
-	//获取用户所填写的参数
-	var id = $("#id").val();
-	var last_id = $("#last_id").val();
-	var count = $("#count").val();
-	
-	//根据参数组织URL	
-	if( "filter/list/{id}/next/{count}" == service_url ){
-		query_url = query_url.replace( "{id}",last_id );
-		query_url = query_url.replace( "{count}",count );
-	}else if( "filter/list/{id}/prev/{count}" == service_url ){
-		query_url = query_url.replace( "{id}",last_id );
-		query_url = query_url.replace( "{count}",count );
-	}else{
-		query_url = query_url.replace( "{id}",id );
-		query_url = query_url.replace( "{count}",count );
-	}
-	
-	alert("PUT:"+query_url);
-	$.ajax({
-		type : 'put',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON($('#content').val())),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function data_delete_attendanceappeal( id ) {
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendancedetail/' + id ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}

+ 0 - 90
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceDetail.html

@@ -1,90 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script src="./entity_AttendanceDetail.js"></script>
-<script>
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		data_get_attendancedetail();
-        });
-    	$('#put').click(function() {
-    		data_put_attendancedetail();
-        });
-        $('#delete').click(function() {
-        	data_delete_attendancedetail( $('#id').val() );
-        });
-        $('#analyse').click(function() {
-        	data_Analyse( $('#anlyseStartDate').val(), $('#anlyseEndDate').val() );
-        });
-        
-        
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>id:<input type="text" id="id" style="width:95%"/></td>
-				<td>file_id:<input type="text" id="file_id" style="width:95%"/></td>
-			</tr>
-			<tr>
-				<td width="50px">last_id:<input type="text" id="last_id" style="width:95%" value="(0)"/></td>
-				<td width="50px">count:<input type="text" id="count" style="width:95%" value="10"/></td>
-			</tr>
-			<tr>
-				<td>anlyseStartDate:<input type="text" id="anlyseStartDate" style="width:95%" value="(0)"/></td>
-				<td>anlyseEndDate:<input type="text" id="anlyseEndDate" style="width:95%" value="(0)"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			AttendanceDetail
-	    		</td>
-			</tr>
-			<tr>
-	    		<td width="50px">GET:/jaxrs/attendancedetail/
-	    			<select id="service_url">
-	    				<option value="list/{file_id}">list/{file_id}</option>
-	    				<option value="{id}">{id}</option>
-	    			</select>
-	    		</td>
-			</tr>
-			<tr>
-	    		<td width="50px">PUT:/jaxrs/attendancedetail/
-	    			<select id="put_url">
-	    				<option value="filter/list">filter/list</option>
-	    				<option value="filter/list/user">filter/list/user</option>
-	    				<option value="filter/list/department">filter/list/department</option>
-	    				<option value="filter/list/company">filter/list/company</option>
-	    				<option value="filter/list/{id}/next/{count}">filter/list/{id}/next/{count}</option>
-	    				<option value="filter/list/{id}/prev/{count}">filter/list/{id}/prev/{count}</option>
-	    			</select>
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="get">GET</button>
-					<button id="put">PUT</button>
-					<button id="delete">DELETE</button>
-					<button id="analyse">Analyse</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px"></textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-</body>
-</html>

+ 0 - 124
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceDetail.js

@@ -1,124 +0,0 @@
-var service_base_path = '../jaxrs/attendancedetail';
-function data_get_attendancedetail( ) {
-	var service_url = $("#service_url").val();
-	var query_url =  service_base_path + "/" + service_url;
-	
-	//获取用户所填写的参数
-	var id = $("#id").val();
-	var file_id = $("#file_id").val();
-	var last_id = $("#last_id").val();
-	var count = $("#count").val();
-	
-	//根据参数组织URL
-	if( "{id}" == service_url ){
-		query_url = query_url.replace( "{id}",id );
-		if( id == null || id == "" || id == undefined){
-			alert("请填写ID");return false;
-		}
-	}else if( "list/{file_id}" == service_url ){
-		if( file_id == null || file_id == "" || file_id == undefined){
-			alert("请填写file_id");return false;
-		}
-		query_url = query_url.replace( "{file_id}",file_id );
-	}
-
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function data_put_attendancedetail( ) {
-	var service_url = $("#put_url").val();
-	var query_url =  service_base_path + "/" + service_url;
-	
-	//获取用户所填写的参数
-	var last_id = $("#last_id").val();
-	var count = $("#count").val();
-	
-	//根据参数组织URL
-	if( "filter/list/{id}/next/{count}" == service_url ){
-		query_url = query_url.replace( "{id}",last_id );
-		query_url = query_url.replace( "{count}",count );
-		if( last_id == null || last_id == "" || last_id == undefined){
-			alert("请填写last_id");return false;
-		}
-		if( count == null || count == "" || count == undefined){
-			alert("请填写count");return false;
-		}
-	}else if( "filter/list/{id}/prev/{count}" == service_url ){
-		query_url = query_url.replace( "{id}",last_id );
-		query_url = query_url.replace( "{count}",count );
-		if( last_id == null || last_id == "" || last_id == undefined){
-			alert("请填写last_id");return false;
-		}
-		if( count == null || count == "" || count == undefined){
-			alert("请填写count");return false;
-		}
-	}
-	alert("PUT:"+query_url);
-	alert(JSON.stringify($.parseJSON($('#content').val())));
-	$.ajax({
-		type : 'put',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON($('#content').val())),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function data_Analyse( anlyseStartDate, anlyseEndDate ) {
-	var query_url = '../jaxrs/attendancedetail/analyse/{startDate}/{endDate}';
-	//如果未输入ID,那么就查询所有的应用信息
-	query_url = query_url.replace( "{startDate}",anlyseStartDate );
-	query_url = query_url.replace( "{endDate}",anlyseEndDate );
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function data_delete_attendancedetail( id ) {
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendancedetail/' + id ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}

+ 0 - 58
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceDetailFileImport.html

@@ -1,58 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script src="./entity_AttendanceDetailFileImport.js"></script>
-<script>
-    $(document).ready(function() {
-    	$('#checkData').click(function() {
-    		checkData( $('#file_id').val() );
-        });
-        $('#importData').click(function() {
-        	importData( $('#file_id').val() );
-        });
-        $('#testImport').click(function() {
-        	testImport();
-        });
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>file_id:</td>
-				<td><input type="text" id="file_id" style="width:95%"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			AttendanceDetailFileImport
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="checkData">CheckDataFile</button>
-					<button id="importData">ImportDataFile</button>
-					<button id="testImport">testImportData</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px"></textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 0 - 61
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceDetailFileImport.js

@@ -1,61 +0,0 @@
-function checkData( file_id ) {
-	if( file_id == null || file_id == undefined || file_id == "" ){
-		alert("请输入file_id");
-		return false;
-	}
-	var query_url = '../jaxrs/fileimport/check/' + file_id;	
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function importData( file_id ) {
-	if( file_id == null || file_id == undefined || file_id == "" ){
-		alert("请输入file_id");
-		return false;
-	}
-	var query_url = '../jaxrs/fileimport/import/' + file_id;	
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function testImport( ) {
-	var query_url = '../jaxrs/fileimport/import/test';	
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}

+ 0 - 70
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceImportFileInfo.html

@@ -1,70 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script src="./ajaxfileupload.js"></script>
-<script src="./entity_AttendanceImportFileInfo.js"></script>
-<script>
-    $(document).ready(function() {
-    	 $('#upload').click(function() {
-         	upload_attendanceimportfileinfo();
-         });
-    	 
-    	 $('#download').click(function() {
-         	download_attendanceimportfileinfo($('#id').val());
-         });    	
-    	
-    	 $('#get').click(function() {
-    		data_get_attendanceimportfileinfo($('#id').val());
-         });
-       
-         $('#delete').click(function() {
-        	data_delete_attendanceimportfileinfo( $('#id').val() );
-         });
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>id:</td>
-				<td><input type="text" id="id" style="width:95%"/></td>
-			</tr>
-			<tr>
-				<td>file:</td>
-				<td><input type="file" id="file" style="width:95%"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			AttendanceSetting
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="upload">Upload</button>
-					<button id="download">Download</button>
-					<button id="get">GET</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px"></textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 0 - 71
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceImportFileInfo.js

@@ -1,71 +0,0 @@
-function upload_attendanceimportfileinfo() {
-	//开始上传具体的文件
-	$.ajaxFileUpload({				
-		//处理文件上传操作的服务器端地址(可以传参数,已亲测可用)
-	    url: '../servlet/upload/',
- 		data:{},
-		secureuri:false,            //是否启用安全提交,默认为false 
-		fileElementId:'file',         //文件选择框的id属性
-		dataType:'text',            //服务器返回的格式,可以是json或xml等
-		success:function( data, status){        //服务器响应成功时的处理函数
-			$('#result').html("数据导入成功!");
-		},
-		error:function(data, status, e){ //服务器响应失败时的处理函数
-			console.log(e);
-			console.log(data);
-			$('#result').html('上传失败,请重试!!');
-		}
-	});
-}
-
-function download_attendanceimportfileinfo( id ) {
-	
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-	
-    window.open( '../servlet/download/'+id+'/stream' );
-}
-
-function data_get_attendanceimportfileinfo( id ) {
-	var query_url = '../jaxrs/attendanceimportfileinfo/' + id;
-	//如果未输入ID,那么就查询所有的应用信息
-	if( id == null || id == undefined || id == "" ){
-		query_url = '../jaxrs/attendanceimportfileinfo/list/all';
-	}
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-
-function data_delete_attendanceimportfileinfo( id ) {
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendanceimportfileinfo/' + id ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}

+ 0 - 58
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceScheduleSetting.html

@@ -1,58 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script src="./entity_AttendanceScheduleSetting.js"></script>
-<script>
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		data_get_attendanceschedulesetting($('#id').val());
-        });
-        $('#post').click(function() {
-        	data_post_attendanceschedulesetting();
-        });
-        $('#delete').click(function() {
-        	data_delete_attendanceschedulesetting( $('#id').val() );
-        });
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>id:</td>
-				<td><input type="text" id="id" style="width:95%"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			AttendanceScheduleSetting
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="get">GET</button>
-					<button id="post">POST</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px"></textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 0 - 56
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceScheduleSetting.js

@@ -1,56 +0,0 @@
-function data_get_attendanceschedulesetting( id ) {
-	var query_url = '../jaxrs/attendanceschedulesetting/' + id;
-	//如果未输入ID,那么就查询所有的应用信息
-	if( id == null || id == undefined || id == "" ){
-		query_url = '../jaxrs/attendanceschedulesetting/list/all';
-	}
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function data_post_attendanceschedulesetting( id ) {
-    $.ajax({
-		type : 'post',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendanceschedulesetting' ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON($('#content').val())),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function data_delete_attendanceschedulesetting( id ) {
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendanceschedulesetting/' + id ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}

+ 0 - 58
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceSelfHoliday.html

@@ -1,58 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script src="./entity_AttendanceSelfHoliday.js"></script>
-<script>
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		data_get_attendanceselfholiday($('#id').val());
-        });
-        $('#post').click(function() {
-        	data_post_attendanceselfholiday();
-        });
-        $('#delete').click(function() {
-        	data_delete_attendanceselfholiday( $('#id').val() );
-        });
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>id:</td>
-				<td><input type="text" id="id" style="width:95%"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			AttendanceAdmin
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="get">GET</button>
-					<button id="post">POST</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px"></textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 0 - 56
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceSelfHoliday.js

@@ -1,56 +0,0 @@
-function data_get_attendanceselfholiday( id ) {
-	var query_url = '../jaxrs/attendanceselfholiday/' + id;
-	//如果未输入ID,那么就查询所有的应用信息
-	if( id == null || id == undefined || id == "" ){
-		query_url = '../jaxrs/attendanceselfholiday/list/all';
-	}
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function data_post_attendanceselfholiday( id ) {
-    $.ajax({
-		type : 'post',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendanceselfholiday' ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON($('#content').val())),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function data_delete_attendanceselfholiday( id ) {
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendanceselfholiday/' + id ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}

+ 0 - 58
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceSetting.html

@@ -1,58 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script src="./entity_AttendanceSetting.js"></script>
-<script>
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		data_get_attendancesetting($('#id').val());
-        });
-        $('#post').click(function() {
-        	data_post_attendancesetting();
-        });
-        $('#delete').click(function() {
-        	data_delete_attendancesetting( $('#id').val() );
-        });
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>id:</td>
-				<td><input type="text" id="id" style="width:95%"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			AttendanceSetting
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="get">GET</button>
-					<button id="post">POST</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px"></textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 0 - 56
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceSetting.js

@@ -1,56 +0,0 @@
-function data_get_attendancesetting( id ) {
-	var query_url = '../jaxrs/attendancesetting/' + id;
-	//如果未输入ID,那么就查询所有的应用信息
-	if( id == null || id == undefined || id == "" ){
-		query_url = '../jaxrs/attendancesetting/list/all';
-	}
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function data_post_attendancesetting( id ) {
-    $.ajax({
-		type : 'post',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendancesetting' ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON($('#content').val())),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function data_delete_attendancesetting( id ) {
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendancesetting/' + id ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}

+ 0 - 58
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceWorkDayConfig.html

@@ -1,58 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script src="./entity_AttendanceWorkDayConfig.js"></script>
-<script>
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		data_get_attendanceworkdayconfig($('#id').val());
-        });
-        $('#post').click(function() {
-        	data_post_attendanceworkdayconfig();
-        });
-        $('#delete').click(function() {
-        	data_delete_attendanceworkdayconfig( $('#id').val() );
-        });
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>id:</td>
-				<td><input type="text" id="id" style="width:95%"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			AttendanceWorkDayConfig
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="get">GET</button>
-					<button id="post">POST</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px"></textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 0 - 56
o2server/x_attendance_assemble_control/src/main/webapp/jest/entity_AttendanceWorkDayConfig.js

@@ -1,56 +0,0 @@
-function data_get_attendanceworkdayconfig( id ) {
-	var query_url = '../jaxrs/attendanceworkdayconfig/' + id;
-	//如果未输入ID,那么就查询所有的应用信息
-	if( id == null || id == undefined || id == "" ){
-		query_url = '../jaxrs/attendanceworkdayconfig/list/all';
-	}
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function data_post_attendanceworkdayconfig( id ) {
-    $.ajax({
-		type : 'post',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendanceworkdayconfig' ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON($('#content').val())),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function data_delete_attendanceworkdayconfig( id ) {
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : '../jaxrs/attendanceworkdayconfig/' + id ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}

+ 66 - 4
o2server/x_attendance_assemble_control/src/main/webapp/jest/index.html

@@ -5,6 +5,68 @@
 <meta http-equiv="pragma" content="no-cache" />
 <meta http-equiv="pragma" content="no-cache" />
 <script src="./jquery.min.js"></script>
 <script src="./jquery.min.js"></script>
 <script src="./clipboard.min.js"></script>
 <script src="./clipboard.min.js"></script>
+<style type="text/css">
+	<!--
+	body {
+		font-family: Arial, Helvetica, sans-serif;
+		font-size:12px;
+		color:#666666;
+		background:#fff;
+		text-align:left;
+	}
+	a {
+		color:#1E7ACE;
+		text-decoration:none; 
+	}
+	a:hover {
+		color:#000;
+		text-decoration:underline;
+	}
+	h3 {
+		font-size:14px;
+		font-weight:bold;
+	}
+	
+	pre,p {
+		color:#1E7ACE;
+		margin:4px;
+	}
+	input, select,textarea {
+		padding:1px;
+		margin:2px;
+		font-size:11px;
+	}
+	
+	fieldset {
+		padding:10px;
+		margin-top:10px;
+		border:1px solid #A4CDF2;
+		background:#fff;
+	}
+	
+	fieldset legend {
+		color:#1E7ACE;
+		font-weight:bold;
+		padding:3px 20px 3px 20px;
+		border:1px solid #A4CDF2; 
+		background:#fff;
+	}
+	
+	input {
+		border:1px solid #A4CDF2;
+	}
+	
+	button {
+		border:1px solid #A4CDF2;
+		background-color : #FFFFFF;
+		height:25px;
+		margin-top:10px;
+		font-weight:bold;
+		color:#1E7ACE;
+	}
+	-->
+</style>
+	
 <script>
 <script>
     $.getScript('./describe.js?rd=' + Math.random()).then(function() {
     $.getScript('./describe.js?rd=' + Math.random()).then(function() {
 		var describe = new Describe();
 		var describe = new Describe();
@@ -14,7 +76,7 @@
     });
     });
 	
 	
 	$(document).ready(function(){
 	$(document).ready(function(){
-        var clipboard = new Clipboard("#btn");
+        var clipboard = new Clipboard("#btn_copy");
 	});	
 	});	
 </script>
 </script>
 </head>
 </head>
@@ -24,19 +86,19 @@
 		<tr>
 		<tr>
 			<td style="width: 350px;" valign="top">
 			<td style="width: 350px;" valign="top">
 				<fieldset>
 				<fieldset>
-					<legend>Menu</legend>
+					<legend>API Menu</legend>
 					<div id="menu" style="height: 850px; overflow: auto">&nbsp;</div>
 					<div id="menu" style="height: 850px; overflow: auto">&nbsp;</div>
 				</fieldset>
 				</fieldset>
 			</td>
 			</td>
 			<td valign="top">
 			<td valign="top">
 				<fieldset>
 				<fieldset>
-					<legend>Content</legend>
+					<legend>API Content</legend>
 					<div id="content"
 					<div id="content"
 						style="white-space: pre; font-size: 12px; word-break: break-all; word-wrap: break-word">&nbsp;</div>
 						style="white-space: pre; font-size: 12px; word-break: break-all; word-wrap: break-word">&nbsp;</div>
 				</fieldset>
 				</fieldset>
 				<fieldset>
 				<fieldset>
 					<legend>
 					<legend>
-						Result&nbsp;<a href="javascript:" data-clipboard-target="#result">copy</a>&nbsp;
+						Result&nbsp;<a id="btn_copy" href="javascript:" data-clipboard-target="#result">copy</a>&nbsp;
 					</legend>
 					</legend>
 					<div id="result"
 					<div id="result"
 						style="white-space: pre; font-size: 12px; word-break: break-all; word-wrap: break-word; width: 1400px">&nbsp;</div>
 						style="white-space: pre; font-size: 12px; word-break: break-all; word-wrap: break-word; width: 1400px">&nbsp;</div>

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 0 - 1
o2server/x_attendance_assemble_control/src/main/webapp/jest/jquery.js


+ 0 - 105
o2server/x_attendance_assemble_control/src/main/webapp/jest/logger.js

@@ -1,105 +0,0 @@
-logger_parameter = {};
-
-function logger_init() {
-    $('#result').html('');
-    $('#content').html('');
-    var str = '<table border="1" width="100%">';
-    str += '<tr><td colspan="2"><a href="#" id="get">get</a>&nbsp<a href="#" id="trace">trace</a>&nbsp;<a href="#" id="debug">debug</a>&nbsp;<a href="#" id="info">info</a>&nbsp;<a href="#" id="warn">warn</a></td></tr>';
-    str += '<tr><td>debug:</td><td id="level">&nbsp;</td></tr>';
-    str += '</table>';
-    $('#content').html(str);
-    $('#get').click(function() {
-	logger_get();
-    });
-    $('#trace').click(function() {
-	logger_trace();
-    });
-    $('#debug').click(function() {
-	logger_debug();
-    });
-    $('#info').click(function() {
-	logger_info();
-    });
-    $('#warn').click(function() {
-	logger_warn();
-    });
-}
-
-function logger_get() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-	if (json.type == 'success') {
-	    $('#level').html(json.data.value);
-	}
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function logger_trace() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger/trace',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function logger_debug() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger/debug',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function logger_info() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger/info',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function logger_warn() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger/warn',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}

+ 0 - 94
o2server/x_attendance_assemble_control/src/main/webapp/jest/showStatistic.html

@@ -1,94 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script src="./showStatistic.js"></script>
-<script>
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		var _name = $("#name").val();
-    		var _year = $("#year").val();
-    		var _month = $("#month").val();
-    		var _date = $("#date").val();
-    		getStatistic( _name, _year, _month, _date );
-        });
-    	$('#put').click(function() {
-    		var _id = $("#last_id").val();
-    		var _count = $("#count").val();
-    		getFilterListForStatistic( _id, _count );
-        });
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>name:<input type="text" id="name" value="蔡艳红"/></td>
-				<td>date:<input type="text" id="date" value=""/></td>
-			</tr>
-	    	<tr>
-				<td>year:<input type="text" id="year" value="2016"/></td>
-				<td>month:<input type="text" id="month" value="03"/></td>
-			</tr>
-			<tr>
-				<td>last_id:<input type="text" id="last_id" value="(0)"/></td>
-				<td>count:<input type="text" id="count" value="10"/></td>
-			</tr>
-	    	<tr>
-				<td>type:SHOW_Statistic</td>
-			</tr>
-	    	<tr>
-	    		<td>
-					<select id="queryUrl">
-						<option value="person/{name}/{year}/{month}">person/{name}/{year}/{month}</option>
-						<option value="persons/department/{name}/{year}/{month}">persons/department/{name}/{year}/{month}</option>
-						<option value="department/{name}/{year}/{month}">department/{name}/{year}/{month}</option>
-						<option value="department/sum/{name}/{year}/{month}">department/sum/{name}/{year}/{month}</option>
-						<option value="department/{name}/{date}">department/{name}/{date}</option>
-						<option value="department/day/{name}/{year}/{month}">department/day/{name}/{year}/{month}</option>
-						<option value="department/day/{name}/{date}">department/day/{name}/{date}</option>
-						<option value="company/{name}/{year}/{month}">company/{name}/{year}/{month}</option>
-						<option value="company/day/{name}/{year}/{month}">company/day/{name}/{year}/{month}</option>
-					</select>
-				</td>
-				<td>
-					<button id="get">GET</button>
-				</td>
-			</tr>
-			<tr>
-	    		<td>
-					<select id="putUrl">
-						<option value="filter/personMonth/list/{id}/next/{count}">filter/personMonth/list/{id}/next/{count}</option>
-						<option value="filter/personMonth/list/{id}/prev/{count}">filter/personMonth/list/{id}/prev/{count}</option>
-						<option value="filter/departmentMonth/list/{id}/next/{count}">filter/departmentMonth/list/{id}/next/{count}</option>
-						<option value="filter/departmentMonth/list/{id}/prev/{count}">filter/departmentMonth/list/{id}/prev/{count}</option>
-						<option value="filter/companyMonth/list/{id}/next/{count}">filter/companyMonth/list/{id}/next/{count}</option>
-						<option value="filter/companyMonth/list/{id}/prev/{count}">filter/companyMonth/list/{id}/prev/{count}</option>
-						<option value="filter/departmentDay/list/{id}/next/{count}">filter/departmentDay/list/{id}/next/{count}</option>
-						<option value="filter/departmentDay/list/{id}/prev/{count}">filter/departmentDay/list/{id}/prev/{count}</option>
-						<option value="filter/companyDay/list/{id}/next/{count}">filter/companyDay/list/{id}/next/{count}</option>
-						<option value="filter/companyDay/list/{id}/prev/{count}">filter/companyDay/list/{id}/prev/{count}</option>
-					</select>
-				</td>
-				<td>
-					<button id="put">PUT</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px"></textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-</body>
-</html>

+ 0 - 62
o2server/x_attendance_assemble_control/src/main/webapp/jest/showStatistic.js

@@ -1,62 +0,0 @@
-var service_base_path = '../jaxrs/statisticshow/';
-function getStatistic( name, year, month, date ) {
-	var query_url = service_base_path + $("#queryUrl").val();
-	if( name != null && name != undefined && name != "(0)"){
-		query_url = query_url.replace( "{name}", encodeURIComponent(name) );
-	}
-	if( date != null && date != undefined && date != "(0)"){
-		query_url = query_url.replace( "{date}", encodeURIComponent(date) );
-	}
-	if( year != null && year != undefined && year != "(0)"){
-		query_url = query_url.replace( "{year}", year );
-	}
-	if( month != null && month != undefined && month != "(0)"){
-		query_url = query_url.replace( "{month}", month );
-	}
-	alert(query_url);
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function getFilterListForStatistic( last_id, _count ){
-	var service_url = $("#putUrl").val();
-	var query_url =  service_base_path + "/" + service_url;
-	
-	if( last_id == null || last_id == undefined ){
-		last_id="(0)";
-	}
-	if( _count == null || _count == undefined ){
-		_count=20;
-	}
-	
-	//根据参数组织URL
-	query_url = query_url.replace( "{id}",last_id );
-	query_url = query_url.replace( "{count}",_count );
-	
-	alert( "PUT:"+query_url );
-	$.ajax({
-		type : 'put',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : query_url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON($('#content').val())),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}

+ 0 - 48
o2server/x_attendance_assemble_control/src/main/webapp/jest/test.html

@@ -1,48 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script src="./test.js"></script>
-<script>
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		doget();
-        });
-    	$('#put').click(function() {
-    		doput();
-        });
-        $('#post').click(function() {
-        	dopost();
-        });
-        $('#delete').click(function() {
-        	dodelete();
-        });
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>URL:</td>
-				<td>/jaxrs/<input type="text" id="url" style="width:95%"/></td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="get">GET</button>
-					<button id="post">POST</button>
-					<button id="put">PUT</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr><td colspan="2"><textarea id="content" style="width:97%;height:300px">{}</textarea></td></tr>
-			<tr><td colspan="2"><textarea id="result" style="width:97%;height:400px"></textarea></td></tr>
-	    </table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 0 - 71
o2server/x_attendance_assemble_control/src/main/webapp/jest/test.js

@@ -1,71 +0,0 @@
-function doget() {
-	var url = '../jaxrs/'+$("#url").val();
-	alert(url);
-    $.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function dopost() {
-	var url = '../jaxrs/'+$("#url").val();
-	alert(url);
-    $.ajax({
-		type : 'post',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON($('#content').val())),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function doput() {
-	var url = '../jaxrs/'+$("#url").val();
-	alert(url);
-	$.ajax({
-		type : 'put',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON($('#content').val())),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function dodelete() {
-	var url = '../jaxrs/'+$("#url").val();
-	alert(url);
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}

+ 0 - 45
o2server/x_attendance_assemble_control/src/main/webapp/jest/uuid.html

@@ -1,45 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<title>main_entiity</title>
-<script>
-    $(document).ready(function() {
-		$('#get_uuid').click(function() {
-			$('#data', '#result').val('');
-			$.ajax({
-				type : 'get',
-				dataType : 'json',
-				url : '../jaxrs/uuid/random',
-				xhrFields : {
-					'withCredentials' : true
-				},
-				crossDomain : true
-			}).done(function(json) {
-				$('#result').html(JSON.stringify( json, null, 4));
-			});
-	    });
-    });
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" width="100%">
-	    	<tr>
-				<td colspan="2">
-					<button id="get_uuid">GET UUID</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:600px"/>
-				</td>
-			</tr>
-    	</table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 33 - 1
o2server/x_base_core_project/src/main/java/com/x/base/core/container/EntityManagerContainer.java

@@ -51,7 +51,7 @@ public class EntityManagerContainer extends EntityManagerContainerBasic {
 	}
 	}
 
 
 	public void persist(JpaObject o) throws Exception {
 	public void persist(JpaObject o) throws Exception {
-		//o.onPersist();
+		// o.onPersist();
 		this.get(o.getClass()).persist(o);
 		this.get(o.getClass()).persist(o);
 	}
 	}
 
 
@@ -523,6 +523,20 @@ public class EntityManagerContainer extends EntityManagerContainerBasic {
 		return em.createQuery(cq).getSingleResult();
 		return em.createQuery(cq).getSingleResult();
 	}
 	}
 
 
+	public <T extends JpaObject> Long countEqualAndEqualAndEqual(Class<T> cls, String oneEuqalAttribute,
+			Object oneEqualValue, String twoEqualAttribute, Object twoEqualValue, String threeEqualAttribute,
+			Object threeEqualValue) throws Exception {
+		EntityManager em = this.get(cls);
+		CriteriaBuilder cb = em.getCriteriaBuilder();
+		CriteriaQuery<Long> cq = cb.createQuery(Long.class);
+		Root<T> root = cq.from(cls);
+		cq.select(cb.count(root))
+				.where(cb.and(cb.equal(root.get(oneEuqalAttribute), oneEqualValue),
+						cb.equal(root.get(twoEqualAttribute), twoEqualValue),
+						cb.equal(root.get(threeEqualAttribute), threeEqualValue)));
+		return em.createQuery(cq).getSingleResult();
+	}
+
 	public <T extends JpaObject> Long countEqualAndEqualAndNotEqual(Class<T> cls, String euqalAttribute,
 	public <T extends JpaObject> Long countEqualAndEqualAndNotEqual(Class<T> cls, String euqalAttribute,
 			Object equalValue, String otherEqualAttribute, Object otherEqualValue, String notEqualAttribute,
 			Object equalValue, String otherEqualAttribute, Object otherEqualValue, String notEqualAttribute,
 			Object notEqualValue) throws Exception {
 			Object notEqualValue) throws Exception {
@@ -1345,6 +1359,24 @@ public class EntityManagerContainer extends EntityManagerContainerBasic {
 		return list;
 		return list;
 	}
 	}
 
 
+	public <T extends JpaObject> List<T> listEqualAndEqualAndSequenceAfter(Class<T> clz, String oneEqualAttribute,
+			Object oneEqualValue, String twoEqualAttribute, Object twoEqualValue, Integer count, String sequence)
+			throws Exception {
+		EntityManager em = this.get(clz);
+		CriteriaBuilder cb = em.getCriteriaBuilder();
+		CriteriaQuery<T> cq = cb.createQuery(clz);
+		Root<T> root = cq.from(clz);
+		Predicate p = cb.equal(root.get(oneEqualAttribute), oneEqualValue);
+		p = cb.and(p, cb.equal(root.get(twoEqualAttribute), twoEqualValue));
+		if (StringUtils.isNotEmpty(sequence)) {
+			p = cb.and(p, cb.greaterThan(root.get(JpaObject_.sequence), sequence));
+		}
+		cq.select(root).where(p).orderBy(cb.asc(root.get(JpaObject_.sequence)));
+		List<T> os = em.createQuery(cq).setMaxResults((count != null && count > 0) ? count : 100).getResultList();
+		List<T> list = new ArrayList<>(os);
+		return list;
+	}
+
 	/* 仅在单一数据库可用 */
 	/* 仅在单一数据库可用 */
 	public <T extends JpaObject, W extends GsonPropertyObject> List<W> fetchEqualDescPaging(Class<T> clz,
 	public <T extends JpaObject, W extends GsonPropertyObject> List<W> fetchEqualDescPaging(Class<T> clz,
 			WrapCopier<T, W> copier, String equalAttribute, Object equalValue, Integer page, Integer count,
 			WrapCopier<T, W> copier, String equalAttribute, Object equalValue, Integer page, Integer count,

+ 33 - 0
o2server/x_base_core_project/src/main/java/com/x/base/core/container/factory/PersistenceXmlHelper.java

@@ -24,6 +24,39 @@ import com.x.base.core.project.tools.ListTools;
 
 
 public class PersistenceXmlHelper {
 public class PersistenceXmlHelper {
 
 
+	public static List<String> directWrite(String path, List<String> classNames) throws Exception {
+		try {
+			Document document = DocumentHelper.createDocument();
+			Element persistence = document.addElement("persistence", "http://java.sun.com/xml/ns/persistence");
+			persistence.addAttribute(QName.get("schemaLocation", "xsi", "http://www.w3.org/2001/XMLSchema-instance"),
+					"http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd");
+			persistence.addAttribute("version", "2.0");
+			for (String className : classNames) {
+				Element unit = persistence.addElement("persistence-unit");
+				unit.addAttribute("name", className);
+				unit.addAttribute("transaction-type", "RESOURCE_LOCAL");
+				Element provider = unit.addElement("provider");
+				provider.addText(PersistenceProviderImpl.class.getName());
+				Element mapped_element = unit.addElement("class");
+				mapped_element.addText(className);
+				Element sliceJpaObject_element = unit.addElement("class");
+				sliceJpaObject_element.addText("com.x.base.core.entity.SliceJpaObject");
+				Element jpaObject_element = unit.addElement("class");
+				jpaObject_element.addText("com.x.base.core.entity.JpaObject");
+			}
+			OutputFormat format = OutputFormat.createPrettyPrint();
+			format.setEncoding("UTF-8");
+			File file = new File(path);
+			FileUtils.touch(file);
+			XMLWriter writer = new XMLWriter(new FileWriter(file), format);
+			writer.write(document);
+			writer.close();
+			return classNames;
+		} catch (Exception e) {
+			throw new Exception("registContainerEntity error.className:" + ListTools.toStringJoin(classNames), e);
+		}
+	}
+
 	public static List<String> write(String path, List<String> entities) throws Exception {
 	public static List<String> write(String path, List<String> entities) throws Exception {
 		List<String> names = new ArrayList<>();
 		List<String> names = new ArrayList<>();
 		String name = "";
 		String name = "";

+ 1 - 2
o2server/x_base_core_project/src/main/java/com/x/base/core/project/Applications.java

@@ -134,8 +134,7 @@ public class Applications extends ConcurrentHashMap<String, CopyOnWriteArrayList
 
 
 	public ActionResponse postQuery(Boolean xdebugger, Application application, String uri, Object body)
 	public ActionResponse postQuery(Boolean xdebugger, Application application, String uri, Object body)
 			throws Exception {
 			throws Exception {
-		return CipherConnectionAction.post(xdebugger, application.getUrlRoot() + CipherConnectionAction.trim(uri),
-				body);
+		return CipherConnectionAction.post(xdebugger, application.getUrlRoot() + CipherConnectionAction.trim(uri), 	body);
 	}
 	}
 
 
 	public ActionResponse postQuery(String applicationName, String uri, Object body) throws Exception {
 	public ActionResponse postQuery(String applicationName, String uri, Object body) throws Exception {

+ 6 - 1
o2server/x_base_core_project/src/main/java/com/x/base/core/project/annotation/Describe.java

@@ -337,7 +337,12 @@ public class Describe {
 						jaxrsField.setIsBaseType(true);
 						jaxrsField.setIsBaseType(true);
 					}
 					}
 				} else {
 				} else {
-					jaxrsField.setIsCollection(false);
+					//O2LEE,String[]未被判断为collection导致组织的JSON格式不符合wrapIn要求
+					if( StringUtils.equalsAnyIgnoreCase( "String[]", jaxrsField.getType() )) {
+						jaxrsField.setIsCollection(true);
+					}else {
+						jaxrsField.setIsCollection(false);
+					}
 					if (StringUtils.startsWithAny(jaxrsField.getType(), "String", "Boolean", "Date", "Integer",
 					if (StringUtils.startsWithAny(jaxrsField.getType(), "String", "Boolean", "Date", "Integer",
 							"Double", "Long", "Float")) {
 							"Double", "Long", "Float")) {
 						jaxrsField.setIsBaseType(true);
 						jaxrsField.setIsBaseType(true);

+ 12 - 5
o2server/x_base_core_project/src/main/java/com/x/base/core/project/config/CenterServer.java

@@ -8,7 +8,6 @@ import org.apache.commons.lang3.BooleanUtils;
 import org.apache.commons.lang3.StringUtils;
 import org.apache.commons.lang3.StringUtils;
 
 
 import com.x.base.core.project.annotation.FieldDescribe;
 import com.x.base.core.project.annotation.FieldDescribe;
-import com.x.base.core.project.gson.GsonPropertyObject;
 import com.x.base.core.project.gson.XGsonBuilder;
 import com.x.base.core.project.gson.XGsonBuilder;
 import com.x.base.core.project.tools.DefaultCharset;
 import com.x.base.core.project.tools.DefaultCharset;
 
 
@@ -16,6 +15,7 @@ public class CenterServer extends ConfigObject {
 
 
 	private static final Integer default_port = 20030;
 	private static final Integer default_port = 20030;
 	private static final Integer default_scanInterval = 0;
 	private static final Integer default_scanInterval = 0;
+	private static final Boolean default_configApiEnable = true;
 
 
 	public static CenterServer defaultInstance() {
 	public static CenterServer defaultInstance() {
 		return new CenterServer();
 		return new CenterServer();
@@ -30,6 +30,7 @@ public class CenterServer extends ConfigObject {
 		this.proxyHost = "";
 		this.proxyHost = "";
 		this.proxyPort = default_port;
 		this.proxyPort = default_port;
 		this.scanInterval = default_scanInterval;
 		this.scanInterval = default_scanInterval;
+		this.configApiEnable = default_configApiEnable;
 	}
 	}
 
 
 	@FieldDescribe("是否启用")
 	@FieldDescribe("是否启用")
@@ -50,6 +51,12 @@ public class CenterServer extends ConfigObject {
 	private Integer scanInterval;
 	private Integer scanInterval;
 	@FieldDescribe("其他参数")
 	@FieldDescribe("其他参数")
 	private LinkedHashMap<String, Object> config;
 	private LinkedHashMap<String, Object> config;
+	@FieldDescribe("允许通过Api修改config")
+	private Boolean configApiEnable;
+
+	public Boolean getConfigApiEnable() {
+		return configApiEnable == null ? default_configApiEnable : this.configApiEnable;
+	}
 
 
 	public String getHttpProtocol() {
 	public String getHttpProtocol() {
 		return StringUtils.equals("https", this.httpProtocol) ? "https" : "http";
 		return StringUtils.equals("https", this.httpProtocol) ? "https" : "http";
@@ -123,10 +130,6 @@ public class CenterServer extends ConfigObject {
 		this.config = config;
 		this.config = config;
 	}
 	}
 
 
-	// public void setHost(String host) {
-	// this.host = host;
-	// }
-
 	public void setHttpProtocol(String httpProtocol) {
 	public void setHttpProtocol(String httpProtocol) {
 		this.httpProtocol = httpProtocol;
 		this.httpProtocol = httpProtocol;
 	}
 	}
@@ -136,4 +139,8 @@ public class CenterServer extends ConfigObject {
 		FileUtils.write(file, XGsonBuilder.toJson(this), DefaultCharset.charset);
 		FileUtils.write(file, XGsonBuilder.toJson(this), DefaultCharset.charset);
 	}
 	}
 
 
+	public void setConfigApiEnable(Boolean configApiEnable) {
+		this.configApiEnable = configApiEnable;
+	}
+
 }
 }

+ 13 - 1
o2server/x_base_core_project/src/main/java/com/x/base/core/project/config/Config.java

@@ -2,6 +2,7 @@ package com.x.base.core.project.config;
 
 
 import java.io.File;
 import java.io.File;
 import java.io.FileFilter;
 import java.io.FileFilter;
+import java.util.concurrent.ConcurrentHashMap;
 
 
 import javax.naming.InitialContext;
 import javax.naming.InitialContext;
 import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.MediaType;
@@ -101,7 +102,9 @@ public class Config {
 
 
 	public static final String RESOUCE_AUDITLOGPRINTSTREAM = "auditLogPrintStream";
 	public static final String RESOUCE_AUDITLOGPRINTSTREAM = "auditLogPrintStream";
 
 
-	public static final String RESOUCE_CONFIG = "config";
+	// public static final String RESOUCE_CONFIG = "config";
+
+	public static final String RESOUCE_NODE = "node";
 
 
 	private static final String DEFAULT_PUBLIC_KEY = "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCWcVZIS57VeOUzi8c01WKvwJK9uRe6hrGTUYmF6J/pI6/UvCbdBWCoErbzsBZOElOH8Sqal3vsNMVLjPYClfoDyYDaUlakP3ldfnXJzAFJVVubF53KadG+fwnh9ZMvxdh7VXVqRL3IQBDwGgzX4rmSK+qkUJjc3OkrNJPB7LLD8QIDAQAB";
 	private static final String DEFAULT_PUBLIC_KEY = "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCWcVZIS57VeOUzi8c01WKvwJK9uRe6hrGTUYmF6J/pI6/UvCbdBWCoErbzsBZOElOH8Sqal3vsNMVLjPYClfoDyYDaUlakP3ldfnXJzAFJVVubF53KadG+fwnh9ZMvxdh7VXVqRL3IQBDwGgzX4rmSK+qkUJjc3OkrNJPB7LLD8QIDAQAB";
 	private static final String DEFAULT_PRIVATE_KEY = "MIICdQIBADANBgkqhkiG9w0BAQEFAASCAl8wggJbAgEAAoGBAJZxVkhLntV45TOLxzTVYq/Akr25F7qGsZNRiYXon+kjr9S8Jt0FYKgStvOwFk4SU4fxKpqXe+w0xUuM9gKV+gPJgNpSVqQ/eV1+dcnMAUlVW5sXncpp0b5/CeH1ky/F2HtVdWpEvchAEPAaDNfiuZIr6qRQmNzc6Ss0k8HsssPxAgMBAAECgYAWtRy05NUgm5Lc6Og0jVDL/mEnydxPBy2ectwzHh2k7wIHNi8XhUxFki2TMqzrM9Dv3/LySpMl4AE3mhs34LNPy6F+MwyF5X7j+2Y6MflJyeb9HNyT++viysQneoOEiOk3ghxF2/GPjpiEF79wSp+1YKTxRAyq7ypV3t35fGOOEQJBANLDPWl8b5c3lrcz/dTamMjHbVamEyX43yzQOphzkhYsz4pruATzTxU+z8/zPdEqHcWWV39CP3xu3EYNcAhxJW8CQQC2u7PF5Xb1xYRCsmIPssFxil64vvdUadSxl7GLAgjQ9ULyYWB24KObCEzLnPcT8Pf2Q0YQOixxa/78FuzmgbyfAkA7ZFFV/H7lugB6t+f7p24OhkRFep9CwBMD6dnZRBgSr6X8d8ZvfrD2Z7DgBMeSva+OEoOtlNmXExZ3lynO9zN5AkAVczEmIMp3DSl6XtAuAZC9kD2QODJ2QToLYsAfjiyUwsWKCC43piTuVOoW2KUUPSwOR1VZIEsJQWEcHGDQqhgHAkAeZ7a6dVRZFdBwKA0ADjYCufAW2cIYiVDQBJpgB+kiLQflusNOCBK0FT3lg8BdUSy2D253Ih6l3lbaM/4M7DFQ";
 	private static final String DEFAULT_PRIVATE_KEY = "MIICdQIBADANBgkqhkiG9w0BAQEFAASCAl8wggJbAgEAAoGBAJZxVkhLntV45TOLxzTVYq/Akr25F7qGsZNRiYXon+kjr9S8Jt0FYKgStvOwFk4SU4fxKpqXe+w0xUuM9gKV+gPJgNpSVqQ/eV1+dcnMAUlVW5sXncpp0b5/CeH1ky/F2HtVdWpEvchAEPAaDNfiuZIr6qRQmNzc6Ss0k8HsssPxAgMBAAECgYAWtRy05NUgm5Lc6Og0jVDL/mEnydxPBy2ectwzHh2k7wIHNi8XhUxFki2TMqzrM9Dv3/LySpMl4AE3mhs34LNPy6F+MwyF5X7j+2Y6MflJyeb9HNyT++viysQneoOEiOk3ghxF2/GPjpiEF79wSp+1YKTxRAyq7ypV3t35fGOOEQJBANLDPWl8b5c3lrcz/dTamMjHbVamEyX43yzQOphzkhYsz4pruATzTxU+z8/zPdEqHcWWV39CP3xu3EYNcAhxJW8CQQC2u7PF5Xb1xYRCsmIPssFxil64vvdUadSxl7GLAgjQ9ULyYWB24KObCEzLnPcT8Pf2Q0YQOixxa/78FuzmgbyfAkA7ZFFV/H7lugB6t+f7p24OhkRFep9CwBMD6dnZRBgSr6X8d8ZvfrD2Z7DgBMeSva+OEoOtlNmXExZ3lynO9zN5AkAVczEmIMp3DSl6XtAuAZC9kD2QODJ2QToLYsAfjiyUwsWKCC43piTuVOoW2KUUPSwOR1VZIEsJQWEcHGDQqhgHAkAeZ7a6dVRZFdBwKA0ADjYCufAW2cIYiVDQBJpgB+kiLQflusNOCBK0FT3lg8BdUSy2D253Ih6l3lbaM/4M7DFQ";
@@ -1031,4 +1034,13 @@ public class Config {
 		return initialContext().lookup(RESOUCE_JDBC_PREFIX + name);
 		return initialContext().lookup(RESOUCE_JDBC_PREFIX + name);
 	}
 	}
 
 
+	@SuppressWarnings("unchecked")
+	public static ConcurrentHashMap<String, Object> resource_node() throws Exception {
+		return (ConcurrentHashMap<String, Object>) initialContext().lookup(RESOUCE_NODE);
+	}
+
+	public static void registWebServer() {
+
+	}
+
 }
 }

+ 11 - 0
o2server/x_base_core_project/src/main/java/com/x/base/core/project/exception/ExceptionUnknowValue.java

@@ -0,0 +1,11 @@
+package com.x.base.core.project.exception;
+
+public class ExceptionUnknowValue extends PromptException {
+
+	private static final long serialVersionUID = -7354813827434276962L;
+
+	public ExceptionUnknowValue(Object value) {
+		super("未知的值:{}.", value);
+	}
+
+}

+ 2 - 0
o2server/x_base_core_project/src/main/java/com/x/base/core/project/jaxrs/AbstractJaxrsAction.java

@@ -75,6 +75,8 @@ abstract class AbstractJaxrsAction {
 				DefaultCharset.charset);
 				DefaultCharset.charset);
 		fileName = FilenameUtils.getName(fileName);
 		fileName = FilenameUtils.getName(fileName);
 		return fileName;
 		return fileName;
+		
 	}
 	}
 
 
+	
 }
 }

+ 36 - 2
o2server/x_base_core_project/src/main/java/com/x/base/core/project/jaxrs/ResponseFactory.java

@@ -1,7 +1,9 @@
 package com.x.base.core.project.jaxrs;
 package com.x.base.core.project.jaxrs;
 
 
+import java.net.URI;
+import java.util.Objects;
+
 import javax.ws.rs.core.CacheControl;
 import javax.ws.rs.core.CacheControl;
-import javax.ws.rs.core.MediaType;
 import javax.ws.rs.core.Response;
 import javax.ws.rs.core.Response;
 
 
 import com.x.base.core.project.exception.CallbackPromptException;
 import com.x.base.core.project.exception.CallbackPromptException;
@@ -37,6 +39,22 @@ public class ResponseFactory {
 						.build();
 						.build();
 			} else if ((null != result.getData()) && (result.getData() instanceof WoCallback)) {
 			} else if ((null != result.getData()) && (result.getData() instanceof WoCallback)) {
 				return Response.ok(callback((WoCallback) result.getData())).cacheControl(defaultCacheControl).build();
 				return Response.ok(callback((WoCallback) result.getData())).cacheControl(defaultCacheControl).build();
+			} else if ((null != result.getData()) && (result.getData() instanceof WoSeeOther)) {
+				WoSeeOther wo = (WoSeeOther) result.getData();
+				try {
+					return Response.seeOther(new URI(wo.getUrl())).build();
+				} catch (Exception e) {
+					return Response.serverError().entity(Objects.toString(wo.getUrl(), ""))
+							.cacheControl(defaultCacheControl).build();
+				}
+			} else if ((null != result.getData()) && (result.getData() instanceof WoTemporaryRedirect)) {
+				WoTemporaryRedirect wo = (WoTemporaryRedirect) result.getData();
+				try {
+					return Response.temporaryRedirect(new URI(wo.getUrl())).build();
+				} catch (Exception e) {
+					return Response.serverError().entity(Objects.toString(wo.getUrl(), ""))
+							.cacheControl(defaultCacheControl).build();
+				}
 			} else {
 			} else {
 				return Response.ok(result.toJson()).cacheControl(defaultCacheControl).build();
 				return Response.ok(result.toJson()).cacheControl(defaultCacheControl).build();
 			}
 			}
@@ -63,8 +81,24 @@ public class ResponseFactory {
 						.build();
 						.build();
 			} else if ((null != result.getData()) && (result.getData() instanceof WoCallback)) {
 			} else if ((null != result.getData()) && (result.getData() instanceof WoCallback)) {
 				return Response.ok(callback((WoCallback) result.getData())).cacheControl(maxAgeCacheControl).build();
 				return Response.ok(callback((WoCallback) result.getData())).cacheControl(maxAgeCacheControl).build();
+			} else if ((null != result.getData()) && (result.getData() instanceof WoSeeOther)) {
+				WoSeeOther wo = (WoSeeOther) result.getData();
+				try {
+					return Response.seeOther(new URI(wo.getUrl())).build();
+				} catch (Exception e) {
+					return Response.serverError().entity(Objects.toString(wo.getUrl(), ""))
+							.cacheControl(defaultCacheControl).build();
+				}
+			} else if ((null != result.getData()) && (result.getData() instanceof WoTemporaryRedirect)) {
+				WoTemporaryRedirect wo = (WoTemporaryRedirect) result.getData();
+				try {
+					return Response.temporaryRedirect(new URI(wo.getUrl())).build();
+				} catch (Exception e) {
+					return Response.serverError().entity(Objects.toString(wo.getUrl(), ""))
+							.cacheControl(defaultCacheControl).build();
+				}
 			} else {
 			} else {
-				return Response.ok(result.toJson()).cacheControl(maxAgeCacheControl).build();
+				return Response.ok(result.toJson()).cacheControl(defaultCacheControl).build();
 			}
 			}
 		}
 		}
 	}
 	}

+ 26 - 0
o2server/x_base_core_project/src/main/java/com/x/base/core/project/jaxrs/WoSeeOther.java

@@ -0,0 +1,26 @@
+package com.x.base.core.project.jaxrs;
+
+import com.x.base.core.project.annotation.FieldDescribe;
+import com.x.base.core.project.gson.GsonPropertyObject;
+
+public class WoSeeOther extends GsonPropertyObject {
+
+	public WoSeeOther() {
+	}
+
+	public WoSeeOther(String url) throws Exception {
+		this.url = url;
+	}
+
+	@FieldDescribe("地址")
+	private String url;
+
+	public String getUrl() {
+		return url;
+	}
+
+	public void setUrl(String url) {
+		this.url = url;
+	}
+
+}

+ 26 - 0
o2server/x_base_core_project/src/main/java/com/x/base/core/project/jaxrs/WoTemporaryRedirect.java

@@ -0,0 +1,26 @@
+package com.x.base.core.project.jaxrs;
+
+import com.x.base.core.project.annotation.FieldDescribe;
+import com.x.base.core.project.gson.GsonPropertyObject;
+
+public class WoTemporaryRedirect extends GsonPropertyObject {
+
+	public WoTemporaryRedirect() {
+	}
+
+	public WoTemporaryRedirect(String url) throws Exception {
+		this.url = url;
+	}
+
+	@FieldDescribe("地址")
+	private String url;
+
+	public String getUrl() {
+		return url;
+	}
+
+	public void setUrl(String url) {
+		this.url = url;
+	}
+
+}

+ 10 - 0
o2server/x_base_core_project/src/main/java/com/x/base/core/project/message/MessageConnector.java

@@ -95,6 +95,16 @@ public class MessageConnector {
 	public static final String TYPE_CALENDAR_ALARM = "calendar_alarm";
 	public static final String TYPE_CALENDAR_ALARM = "calendar_alarm";
 
 
 	public static final String TYPE_CUSTOM_CREATE = "custom_create";
 	public static final String TYPE_CUSTOM_CREATE = "custom_create";
+	
+	public static final String TYPE_TEAMWORK_TASKCREATE = "teamwork_taskCreate";
+	
+	public static final String TYPE_TEAMWORK_TASKUPDATE = "teamwork_taskUpdate";
+	
+	public static final String TYPE_TEAMWORK_TASKDELETE = "teamwork_taskDelelte";
+	
+	public static final String TYPE_TEAMWORK_TASKOVERTIME = "teamwork_taskOvertime";
+	
+	public static final String TYPE_TEAMWORK_CHAT = "teamwork_taskChat";
 
 
 	public static final String CONSUME_WS = "ws";
 	public static final String CONSUME_WS = "ws";
 
 

+ 6 - 2
o2server/x_base_core_project/src/main/java/com/x/base/core/project/message/WsMessage.java

@@ -1,19 +1,23 @@
 package com.x.base.core.project.message;
 package com.x.base.core.project.message;
 
 
 import com.google.gson.JsonElement;
 import com.google.gson.JsonElement;
+import com.x.base.core.project.annotation.FieldDescribe;
 
 
 public class WsMessage extends Message {
 public class WsMessage extends Message {
 
 
 	public WsMessage() {
 	public WsMessage() {
-
 	}
 	}
-
+	
+	@FieldDescribe("Ws消息类别.")
 	private String type;
 	private String type;
 
 
+	@FieldDescribe("Ws消息接收人.")
 	private String person;
 	private String person;
 
 
+	@FieldDescribe("Ws消息标题.")
 	private String title;
 	private String title;
 
 
+	@FieldDescribe("Ws消息内容.")
 	private JsonElement body;
 	private JsonElement body;
 
 
 	public String getPerson() {
 	public String getPerson() {

+ 3 - 0
o2server/x_base_core_project/src/main/java/com/x/base/core/project/organization/OrganizationDefinition.java

@@ -64,6 +64,9 @@ public class OrganizationDefinition {
 	public final static String MessageManager = "MessageManager";
 	public final static String MessageManager = "MessageManager";
 	public final static String MessageManager_discription = "消息管理员(系统角色),可以对系统中产生的消息进行管理。";
 	public final static String MessageManager_discription = "消息管理员(系统角色),可以对系统中产生的消息进行管理。";
 
 
+	public final static String HotPictureManager = "HotPictureManager";
+	public final static String HotPictureManager_discription = "热点图片控制权限(系统角色),可以对系统中产生的系统图片进行管理。";
+
 	public final static String SearchPrivilege = "SearchPrivilege";
 	public final static String SearchPrivilege = "SearchPrivilege";
 	public final static String SearchPrivilege_discription = "搜索管理员(系统角色),可以跨权限对系统内容进行搜索。";
 	public final static String SearchPrivilege_discription = "搜索管理员(系统角色),可以跨权限对系统内容进行搜索。";
 
 

+ 12 - 0
o2server/x_base_core_project/src/main/java/com/x/base/core/project/tools/StringTools.java

@@ -45,6 +45,10 @@ public class StringTools {
 	public static final Pattern UUID_REGEX = Pattern
 	public static final Pattern UUID_REGEX = Pattern
 			.compile("^[a-zA-Z_0-9]{8}-[a-zA-Z_0-9]{4}-[a-zA-Z_0-9]{4}-[a-zA-Z_0-9]{4}-[a-zA-Z_0-9]{12}$");
 			.compile("^[a-zA-Z_0-9]{8}-[a-zA-Z_0-9]{4}-[a-zA-Z_0-9]{4}-[a-zA-Z_0-9]{4}-[a-zA-Z_0-9]{12}$");
 
 
+	public static final String[] SQL_LIKE = new String[] { "_", "%" };
+
+	public static final String[] SQL_LIKE_SHIFT = new String[] { "\\\\_", "\\\\%" };
+
 	private static final Random random = new Random();
 	private static final Random random = new Random();
 
 
 	public static int utf8Length(String str) {
 	public static int utf8Length(String str) {
@@ -373,4 +377,12 @@ public class StringTools {
 			return ListUtils.subtract(in, ex);
 			return ListUtils.subtract(in, ex);
 		}
 		}
 	}
 	}
+
+	public static String escapeSqlLikeKey(String str) {
+		if (StringUtils.isEmpty(str)) {
+			return str;
+		} else {
+			return StringUtils.trim(StringUtils.replaceEach(str, SQL_LIKE, SQL_LIKE_SHIFT));
+		}
+	}
 }
 }

+ 3 - 3
o2server/x_base_core_project/src/main/java/com/x/base/core/project/x_processplatform_assemble_designer.java

@@ -25,9 +25,9 @@ import com.x.base.core.project.annotation.ModuleType;
 		"com.x.processplatform.core.entity.element.End", "com.x.processplatform.core.entity.element.ApplicationDict",
 		"com.x.processplatform.core.entity.element.End", "com.x.processplatform.core.entity.element.ApplicationDict",
 		"com.x.processplatform.core.entity.element.ApplicationDictItem",
 		"com.x.processplatform.core.entity.element.ApplicationDictItem",
 		"com.x.processplatform.core.entity.element.QueryView", "com.x.processplatform.core.entity.element.QueryStat",
 		"com.x.processplatform.core.entity.element.QueryView", "com.x.processplatform.core.entity.element.QueryStat",
-		"com.x.processplatform.core.entity.element.Projection", "com.x.query.core.entity.Item",
-		"com.x.query.dynamic.entity.*" }, storeJars = { "x_organization_core_entity", "x_organization_core_express",
-				"x_processplatform_core_entity", "x_query_core_entity" }, dynamicJars = {
+		"com.x.processplatform.core.entity.element.Projection", "com.x.processplatform.core.entity.element.Mapping",
+		"com.x.query.core.entity.Item", "com.x.query.dynamic.entity.*" }, storeJars = { "x_organization_core_entity",
+				"x_organization_core_express", "x_processplatform_core_entity", "x_query_core_entity" }, dynamicJars = {
 						"x_query_dynamic_entity" }, storageTypes = { StorageType.processPlatform })
 						"x_query_dynamic_entity" }, storageTypes = { StorageType.processPlatform })
 public class x_processplatform_assemble_designer extends Deployable {
 public class x_processplatform_assemble_designer extends Deployable {
 
 

+ 3 - 3
o2server/x_base_core_project/src/main/java/com/x/base/core/project/x_processplatform_assemble_surface.java

@@ -26,9 +26,9 @@ import com.x.base.core.project.annotation.ModuleType;
 		"com.x.processplatform.core.entity.element.Script", "com.x.processplatform.core.entity.element.Service",
 		"com.x.processplatform.core.entity.element.Script", "com.x.processplatform.core.entity.element.Service",
 		"com.x.processplatform.core.entity.element.Split", "com.x.processplatform.core.entity.element.QueryView",
 		"com.x.processplatform.core.entity.element.Split", "com.x.processplatform.core.entity.element.QueryView",
 		"com.x.processplatform.core.entity.element.QueryStat", "com.x.processplatform.core.entity.element.Projection",
 		"com.x.processplatform.core.entity.element.QueryStat", "com.x.processplatform.core.entity.element.Projection",
-		"com.x.query.core.entity.Item" }, storageTypes = { StorageType.processPlatform }, storeJars = {
-				"x_organization_core_entity", "x_organization_core_express", "x_processplatform_core_entity",
-				"x_query_core_entity" })
+		"com.x.processplatform.core.entity.element.Mapping", "com.x.query.core.entity.Item" }, storageTypes = {
+				StorageType.processPlatform }, storeJars = { "x_organization_core_entity",
+						"x_organization_core_express", "x_processplatform_core_entity", "x_query_core_entity" })
 public class x_processplatform_assemble_surface extends Deployable {
 public class x_processplatform_assemble_surface extends Deployable {
 
 
 //	public x_processplatform_assemble_surface() {
 //	public x_processplatform_assemble_surface() {

+ 2 - 1
o2server/x_base_core_project/src/main/java/com/x/base/core/project/x_processplatform_service_processing.java

@@ -26,7 +26,8 @@ import com.x.base.core.project.annotation.ModuleType;
 		"com.x.processplatform.core.entity.element.Delay", "com.x.processplatform.core.entity.element.File",
 		"com.x.processplatform.core.entity.element.Delay", "com.x.processplatform.core.entity.element.File",
 		"com.x.processplatform.core.entity.element.Form", "com.x.processplatform.core.entity.element.FormField",
 		"com.x.processplatform.core.entity.element.Form", "com.x.processplatform.core.entity.element.FormField",
 		"com.x.processplatform.core.entity.element.Embed", "com.x.processplatform.core.entity.element.Projection",
 		"com.x.processplatform.core.entity.element.Embed", "com.x.processplatform.core.entity.element.Projection",
-		"com.x.processplatform.core.entity.log.ProcessingError", "com.x.query.core.entity.Item",
+		"com.x.processplatform.core.entity.element.Mapping", "com.x.processplatform.core.entity.log.ProcessingError",
+		"com.x.query.core.entity.Item",
 		"com.x.query.dynamic.entity.*" }, storageTypes = { StorageType.processPlatform }, storeJars = {
 		"com.x.query.dynamic.entity.*" }, storageTypes = { StorageType.processPlatform }, storeJars = {
 				"x_organization_core_entity", "x_organization_core_express", "x_processplatform_core_entity",
 				"x_organization_core_entity", "x_organization_core_express", "x_processplatform_core_entity",
 				"x_query_core_entity" }, dynamicJars = { "x_query_dynamic_entity" })
 				"x_query_core_entity" }, dynamicJars = { "x_query_dynamic_entity" })

+ 0 - 32
o2server/x_base_core_project/src/main/java/com/x/base/core/project/x_query_service_processing.java

@@ -22,36 +22,4 @@ import com.x.base.core.project.annotation.ModuleType;
 						"x_organization_core_express", "x_processplatform_core_entity", "x_cms_core_entity" })
 						"x_organization_core_express", "x_processplatform_core_entity", "x_cms_core_entity" })
 public class x_query_service_processing extends Deployable {
 public class x_query_service_processing extends Deployable {
 
 
-//	public x_query_service_processing() {
-//		super();
-//		dependency.containerEntities.add("com.x.query.core.entity.Item");
-//		dependency.containerEntities.add("com.x.query.core.entity.Query");
-//		dependency.containerEntities.add("com.x.query.core.entity.View");
-//		dependency.containerEntities.add("com.x.query.core.entity.Stat");
-//		dependency.containerEntities.add("com.x.query.core.entity.Reveal");
-//		dependency.containerEntities.add("com.x.query.core.entity.segment.Word");
-//		dependency.containerEntities.add("com.x.query.core.entity.segment.Entry");
-//		dependency.containerEntities.add("com.x.query.core.entity.neural.Entry");
-//		dependency.containerEntities.add("com.x.query.core.entity.neural.InText");
-//		dependency.containerEntities.add("com.x.query.core.entity.neural.OutText");
-//		dependency.containerEntities.add("com.x.query.core.entity.neural.InValue");
-//		dependency.containerEntities.add("com.x.query.core.entity.neural.OutValue");
-//		dependency.containerEntities.add("com.x.query.core.entity.neural.Model");
-//		dependency.containerEntities.add("com.x.query.core.entity.schema.*");
-//		dependency.containerEntities.add("com.x.processplatform.core.entity.content.Review");
-//		dependency.containerEntities.add("com.x.processplatform.core.entity.content.Work");
-//		dependency.containerEntities.add("com.x.processplatform.core.entity.content.WorkCompleted");
-//		dependency.containerEntities.add("com.x.processplatform.core.entity.content.Attachment");
-//		dependency.containerEntities.add("com.x.cms.core.entity.Document");
-//		dependency.containerEntities.add("com.x.cms.core.entity.FileInfo");
-//		dependency.containerEntities.add("com.x.cms.core.entity.AppInfo");
-//		dependency.containerEntities.add("com.x.cms.core.entity.CategoryInfo");
-//		dependency.storageTypes.add(StorageType.processPlatform.toString());
-//		dependency.storageTypes.add(StorageType.cms.toString());
-//		dependency.storeJars.add(x_query_core_entity.class.getSimpleName());
-//		dependency.storeJars.add(x_organization_core_entity.class.getSimpleName());
-//		dependency.storeJars.add(x_organization_core_express.class.getSimpleName());
-//		dependency.storeJars.add(x_processplatform_core_entity.class.getSimpleName());
-//		dependency.storeJars.add(x_cms_core_entity.class.getSimpleName());
-//	}
 }
 }

+ 0 - 8
o2server/x_base_core_project/src/test/java/com/x/base/core/project/test/CryptoClass.java

@@ -139,14 +139,6 @@ public class CryptoClass {
 		String value = rsaEncrypt(Base64.encodeBase64String(ss), TEST_PUBLIC_KEY);
 		String value = rsaEncrypt(Base64.encodeBase64String(ss), TEST_PUBLIC_KEY);
 		byte[] ds = Base64.decodeBase64(rsaDecrypt(value, TEST_PRIVATE_KEY));
 		byte[] ds = Base64.decodeBase64(rsaDecrypt(value, TEST_PRIVATE_KEY));
 		FileUtils.writeByteArrayToFile(new File("e:/2.war"), ds);
 		FileUtils.writeByteArrayToFile(new File("e:/2.war"), ds);
-		System.out.println(ds.length + "<>" + ss.length);
-		for (int i = 0; i < ss.length; i++) {
-			if (ss[i] != ds[i]) {
-				System.out.println("!!!!!!!!@##");
-				System.out.println(i);
-				System.out.println("!!!!!!!!@##");
-			}
-		}
 	}
 	}
 
 
 }
 }

+ 0 - 82
o2server/x_bbs_assemble_control/src/main/webapp/jest/bbs_foruminfo.html

@@ -1,82 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<script lang="text/javascript">   
-	//根据ID获取论坛信息对象
-	function query_by_id( id, serviceName ) {
-		if( id == null || id == undefined || id == "" ){
-			alert("请输入ID");
-			return false;
-		}
-		var query_url = '../jaxrs/'+serviceName+'/' + id;
-		send_get_request( query_url );
-	}
-	//保存论坛信息对象
-	function saveEntity(serviceName) {
-		var url = '../jaxrs/' + serviceName;
-		send_post_request( url );
-	}
-	//根据ID删除论坛信息对象
-	function deleteEntity( id, serviceName ) {
-		if( id == null || id == undefined || id == "" ){
-			alert("请输入ID");
-			return false;
-		}
-		var url = '../jaxrs/' + serviceName ;
-		send_delete_request( url, id );
-	}
-	
-	/////////////////////////////////////////////////////////////////////////////////////////////////
-	var serviceName = "forum";
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		query_by_id($('#id').val(), serviceName);
-        });
-        $('#post').click(function() {
-        	saveEntity(serviceName);
-        });
-        $('#delete').click(function() {
-        	deleteEntity( $('#id').val(), serviceName );
-        });
-    });    
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>ID:</td>
-				<td><input type="text" id="id" style="width:95%"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			论坛信息(BBSFORUMINFO)
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="get">GET</button>
-					<button id="post">POST</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px">{}</textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 0 - 86
o2server/x_bbs_assemble_control/src/main/webapp/jest/bbs_permissioninfo.html

@@ -1,86 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<script lang="text/javascript">   
-	//根据ID获取论坛信息对象
-	function query_by_id( id, serviceName ) {
-		if( id == null || id == undefined || id == "" ){
-			alert("请输入ID");
-			return false;
-		}
-		var query_url = '../jaxrs/'+serviceName+'/' + id;
-		send_get_request( query_url );
-	}
-	//保存论坛信息对象
-	function saveEntity(serviceName) {
-		var url = '../jaxrs/' + serviceName;
-		send_post_request( url );
-	}
-	//根据ID删除论坛信息对象
-	function deleteEntity( id, serviceName ) {
-		if( id == null || id == undefined || id == "" ){
-			alert("请输入ID");
-			return false;
-		}
-		var url = '../jaxrs/' + serviceName ;
-		send_delete_request( url, id );
-	}
-	
-	/////////////////////////////////////////////////////////////////////////////////////////////////
-	var serviceName = "permission";
-    $(document).ready(function() {
-    	$('#all').click(function() {
-    		send_get_request( '../jaxrs/' + serviceName + "/all" );
-        });
-    	$('#get').click(function() {
-    		query_by_id($('#id').val(), serviceName);
-        });
-        $('#post').click(function() {
-        	saveEntity(serviceName);
-        });
-        $('#delete').click(function() {
-        	deleteEntity( $('#id').val(), serviceName );
-        });
-    });    
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>ID:</td>
-				<td><input type="text" id="id" style="width:95%"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			权限信息(BBSPERMISSIONINFO)
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="all">ALL</button>
-					<button id="get">GET</button>
-					<button id="post">POST</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px">{}</textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 0 - 86
o2server/x_bbs_assemble_control/src/main/webapp/jest/bbs_roleinfo.html

@@ -1,86 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<script lang="text/javascript">   
-	//根据ID获取论坛信息对象
-	function query_by_id( id, serviceName ) {
-		if( id == null || id == undefined || id == "" ){
-			alert("请输入ID");
-			return false;
-		}
-		var query_url = '../jaxrs/'+serviceName+'/' + id;
-		send_get_request( query_url );
-	}
-	//保存论坛信息对象
-	function saveEntity(serviceName) {
-		var url = '../jaxrs/' + serviceName;
-		send_post_request( url );
-	}
-	//根据ID删除论坛信息对象
-	function deleteEntity( id, serviceName ) {
-		if( id == null || id == undefined || id == "" ){
-			alert("请输入ID");
-			return false;
-		}
-		var url = '../jaxrs/' + serviceName ;
-		send_delete_request( url, id );
-	}
-	
-	/////////////////////////////////////////////////////////////////////////////////////////////////
-	var serviceName = "role";
-    $(document).ready(function() {
-    	$('#all').click(function() {
-    		send_get_request( '../jaxrs/' + serviceName + "/all" );
-        });
-    	$('#get').click(function() {
-    		query_by_id($('#id').val(), serviceName);
-        });
-        $('#post').click(function() {
-        	saveEntity(serviceName);
-        });
-        $('#delete').click(function() {
-        	deleteEntity( $('#id').val(), serviceName );
-        });
-    });    
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>ID:</td>
-				<td><input type="text" id="id" style="width:95%"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			角色信息(BBSROLEINFO)
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="all">ALL</button>
-					<button id="get">GET</button>
-					<button id="post">POST</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px">{}</textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 0 - 82
o2server/x_bbs_assemble_control/src/main/webapp/jest/bbs_subjectinfo.html

@@ -1,82 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<script lang="text/javascript">   
-	//根据ID获取论坛信息对象
-	function query_by_id( id, serviceName ) {
-		if( id == null || id == undefined || id == "" ){
-			alert("请输入ID");
-			return false;
-		}
-		var query_url = '../jaxrs/'+serviceName+'/' + id;
-		send_get_request( query_url );
-	}
-	//保存论坛信息对象
-	function saveEntity(serviceName) {
-		var url = '../jaxrs/' + serviceName;
-		send_post_request( url );
-	}
-	//根据ID删除论坛信息对象
-	function deleteEntity( id, serviceName ) {
-		if( id == null || id == undefined || id == "" ){
-			alert("请输入ID");
-			return false;
-		}
-		var url = '../jaxrs/' + serviceName ;
-		send_delete_request( url, id );
-	}
-	
-	/////////////////////////////////////////////////////////////////////////////////////////////////
-	var serviceName = "subject";
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		query_by_id($('#id').val(), serviceName);
-        });
-        $('#post').click(function() {
-        	saveEntity(serviceName);
-        });
-        $('#delete').click(function() {
-        	deleteEntity( $('#id').val(), serviceName );
-        });
-    });    
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>ID:</td>
-				<td><input type="text" id="id" style="width:95%"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			主题信息(BBSSUBJECTINFO)
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="get">GET</button>
-					<button id="post">POST</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px">{}</textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-		
-		
-</body>
-</html>

+ 0 - 26
o2server/x_bbs_assemble_control/src/main/webapp/jest/common.js

@@ -1,26 +0,0 @@
-function failure(data) {
-    console.log(data);
-    alert(data.message);
-}
-
-function splitValue(str) {
-    if (str) {
-	if (str.length > 0) {
-	    return str.split(',');
-	}
-    }
-    return [];
-}
-
-function joinValue(o, split) {
-    var s = ',';
-    if (split) {
-	s = '' + split;
-    }
-    if (o) {
-	if (toString.apply(o) === '[object Array]') {
-	    return o.join(s);
-	}
-    }
-    return o;
-}

+ 0 - 76
o2server/x_bbs_assemble_control/src/main/webapp/jest/common_rest.html

@@ -1,76 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<script lang="text/javascript">   
-	//GET
-	function m_get( url ) {
-		send_get_request( url );
-	}
-	//POST
-	function m_post() {
-		send_post_request( url );
-	}
-	//PUT
-	function m_post() {
-		send_put_request( url );
-	}
-	//DELETE
-	function m_delete() {
-		send_delete_request_as_url( url );
-	}
-	
-	/////////////////////////////////////////////////////////////////////////////////////////////////
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		common_get( $("#url").val() );
-        });
-        $('#post').click(function() {
-        	common_post( $("#url").val() );
-        });
-        $('#put').click(function() {
-        	common_put( $("#url").val() );
-        });
-        $('#delete').click(function() {
-        	common_delete( $("#url").val() );
-        });
-    });    
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>URL:</td>
-				<td><input type="text" id="url" style="width:95%" placeholder="../jaxrs/forum/"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			通用REST服务调用
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="get">GET</button>
-					<button id="post">POST</button>
-					<button id="put">PUT</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px">{}</textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-</body>
-</html>

+ 0 - 77
o2server/x_bbs_assemble_control/src/main/webapp/jest/debug.js

@@ -1,77 +0,0 @@
-debug_parameter = {};
-
-function debug_init() {
-    $('#result').html('');
-    $('#content').html('');
-    var str = '<table border="1" width="100%">';
-    str += '<tr><td colspan="2"><a href="#" id="get">get</a>&nbsp<a href="#" id="on">on</a>&nbsp;<a href="#" id="off">off</a></td></tr>';
-    str += '<tr><td>debug:</td><td id="status">&nbsp;</td></tr>';
-    str += '</table>';
-    $('#content').html(str);
-    $('#get').click(function() {
-	debug_get();
-    });
-    $('#on').click(function() {
-	debug_on();
-    });
-    $('#off').click(function() {
-	debug_off();
-    });
-}
-
-function debug_get() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/debug',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-	if (json.type == 'success') {
-	    $('#status').html(json.data.value + '');
-	}
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function debug_on() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/debug/true',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-	if (json.type == 'success') {
-	    $('#status').html(json.data.value + '');
-	}
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function debug_off() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/debug/false',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-	if (json.type == 'success') {
-	    $('#status').html(json.data.value + '');
-	}
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}

+ 34 - 13
o2server/x_bbs_assemble_control/src/main/webapp/jest/describe.js

@@ -200,20 +200,20 @@ Describe.prototype = {
 											switch (p.name) {
 											switch (p.name) {
 											case 'flag':
 											case 'flag':
 											case 'id':
 											case 'id':
-												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid" value="(0)"/></td><td>' + p.name
+												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; " value="(0)"/></td><td>' + p.name
 														+ ':' + p.description + '</td></tr>';
 														+ ':' + p.description + '</td></tr>';
 												break;
 												break;
 											case 'count':
 											case 'count':
-												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid" value="20"/></td><td>' + p.name + ':'
+												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; " value="20"/></td><td>' + p.name + ':'
 														+ p.description + '</td></tr>';
 														+ p.description + '</td></tr>';
 												break;
 												break;
 											default:
 											default:
-												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + p.name + ':'
+												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>' + p.name + ':'
 														+ p.description + '</td></tr>';
 														+ p.description + '</td></tr>';
 												break
 												break
 											}
 											}
 										} else {
 										} else {
-											txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + p.name + ':'
+											txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>' + p.name + ':'
 													+ p.description + '</td></tr>';
 													+ p.description + '</td></tr>';
 										}
 										}
 									});
 									});
@@ -225,10 +225,10 @@ Describe.prototype = {
 									txt += '<table >';
 									txt += '<table >';
 									$.each(m.formParameters, function(pi, p) {
 									$.each(m.formParameters, function(pi, p) {
 										if (p.type == "File") {
 										if (p.type == "File") {
-											txt += '<tr><td><input type="file" name="' + p.name + '" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>'
+											txt += '<tr><td><input type="file" name="' + p.name + '" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>'
 													+ p.name + ':' + p.description + '</td></tr>';
 													+ p.name + ':' + p.description + '</td></tr>';
 										} else {
 										} else {
-											txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + p.name + ':'
+											txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>' + p.name + ':'
 													+ p.description + '</td></tr>';
 													+ p.description + '</td></tr>';
 										}
 										}
 									});
 									});
@@ -239,7 +239,7 @@ Describe.prototype = {
 									txt += '<fieldset id="queryParameters"><legend>Query Parameter</legend>';
 									txt += '<fieldset id="queryParameters"><legend>Query Parameter</legend>';
 									txt += '<table >';
 									txt += '<table >';
 									$.each(m.queryParameters, function(pi, p) {
 									$.each(m.queryParameters, function(pi, p) {
-										txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + p.name + ':' + p.description
+										txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>' + p.name + ':' + p.description
 												+ '</td></tr>';
 												+ '</td></tr>';
 									});
 									});
 									txt += '</table>';
 									txt += '</table>';
@@ -250,10 +250,10 @@ Describe.prototype = {
 									txt += '<table>';
 									txt += '<table>';
 									$.each(m.ins, function(ii, i) {
 									$.each(m.ins, function(ii, i) {
 										if (i.isCollection) {
 										if (i.isCollection) {
-											txt += '<tr><td><textarea id="' + i.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + i.name + ':' + i.description
+											txt += '<tr><td><textarea id="' + i.name + '" style="width:600px; padding:1px; "/></td><td>' + i.name + ':' + i.description
 											'</td></tr>';
 											'</td></tr>';
 										} else {
 										} else {
-											txt += '<tr><td><input type="text" id="' + i.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + i.name + ':'
+											txt += '<tr><td><input type="text" id="' + i.name + '" style="width:600px; padding:1px; "/></td><td>' + i.name + ':'
 													+ i.description
 													+ i.description
 											'</td></tr>';
 											'</td></tr>';
 										}
 										}
@@ -264,7 +264,7 @@ Describe.prototype = {
 								if (m.useJsonElementParameter) {
 								if (m.useJsonElementParameter) {
 									txt += '<fieldset><legend>JsonElement</legend>';
 									txt += '<fieldset><legend>JsonElement</legend>';
 									txt += '<table><tr><td>';
 									txt += '<table><tr><td>';
-									txt += '<textarea id="jsonElement" style="height:300px; width:600px; padding:1px; border:1px #000000 solid"/>';
+									txt += '<textarea id="jsonElement" style="height:300px; width:600px; padding:1px; "/>';
 									txt += '</td><td>json</td></tr>';
 									txt += '</td><td>json</td></tr>';
 									txt += '</table>';
 									txt += '</table>';
 									txt += '</fieldset>';
 									txt += '</fieldset>';
@@ -272,7 +272,7 @@ Describe.prototype = {
 								if (m.useStringParameter) {
 								if (m.useStringParameter) {
 									txt += '<fieldset><legend>String</legend>';
 									txt += '<fieldset><legend>String</legend>';
 									txt += '<table><tr><td>';
 									txt += '<table><tr><td>';
-									txt += '<textarea id="string" style="height:300px; width:600px; padding:1px; border:1px #000000 solid"/>';
+									txt += '<textarea id="string" style="height:300px; width:600px; padding:1px; "/>';
 									txt += '</td><td>string</td></tr>';
 									txt += '</td><td>string</td></tr>';
 									txt += '</table>';
 									txt += '</table>';
 									txt += '</fieldset>';
 									txt += '</fieldset>';
@@ -308,6 +308,7 @@ Describe.prototype = {
 									if (m.contentType.indexOf('application/json') > -1) {
 									if (m.contentType.indexOf('application/json') > -1) {
 										switch (m.type) {
 										switch (m.type) {
 										case 'POST':
 										case 'POST':
+										debugger;
 											var data = {};
 											var data = {};
 											if (m.ins && m.ins.length > 0) {
 											if (m.ins && m.ins.length > 0) {
 												$.each(m.ins, function(ii, i) {
 												$.each(m.ins, function(ii, i) {
@@ -320,11 +321,21 @@ Describe.prototype = {
 																data[i.name] = $('#' + i.name, '#ins').val();
 																data[i.name] = $('#' + i.name, '#ins').val();
 															}
 															}
 														} else {
 														} else {
-															data[i.name] = $.parseJSON($('#' + i.name, '#ins').val());
+															if (i.isCollection) {
+																data[i.name] = Describe.splitValue($('#' + i.name, '#ins').val());
+															} else {
+																if( $('#' + i.name, '#ins').val() == null || typeof($('#' + i.name, '#ins').val()) == "undefind" || $('#' + i.name, '#ins').val() == "" ){
+																	$('#' + i.name, '#ins').val("{}");
+																}
+																data[i.name] = $.parseJSON($('#' + i.name, '#ins').val());
+															}
 														}
 														}
 													}
 													}
 												});
 												});
 											} else if (m.useJsonElementParameter) {
 											} else if (m.useJsonElementParameter) {
+												if( $('#jsonElement').val() == null || typeof($('#jsonElement').val()) == "undefind" || $('#jsonElement').val() == "" ){
+													$('#jsonElement').val("{}");
+												}
 												data = $.parseJSON($('#jsonElement').val());
 												data = $.parseJSON($('#jsonElement').val());
 											} else if (m.useStringParameter) {
 											} else if (m.useStringParameter) {
 												data = $('#string').val();
 												data = $('#string').val();
@@ -344,11 +355,21 @@ Describe.prototype = {
 																data[i.name] = $('#' + i.name, '#ins').val();
 																data[i.name] = $('#' + i.name, '#ins').val();
 															}
 															}
 														} else {
 														} else {
-															data[i.name] = $.parseJSON($('#' + i.name, '#ins').val());
+															if (i.isCollection) {
+																data[i.name] = Describe.splitValue($('#' + i.name, '#ins').val());
+															} else {
+																if( $('#' + i.name, '#ins').val() == null || typeof($('#' + i.name, '#ins').val()) == "undefind" || $('#' + i.name, '#ins').val() == "" ){
+																	$('#' + i.name, '#ins').val("{}");
+																}
+																data[i.name] = $.parseJSON($('#' + i.name, '#ins').val());
+															}
 														}
 														}
 													}
 													}
 												});
 												});
 											} else if (m.useJsonElementParameter) {
 											} else if (m.useJsonElementParameter) {
+												if( $('#jsonElement').val() == null || typeof($('#jsonElement').val()) == "undefind" || $('#jsonElement').val() == "" ){
+													$('#jsonElement').val("{}");
+												}
 												data = $.parseJSON($('#jsonElement').val());
 												data = $.parseJSON($('#jsonElement').val());
 											} else if (m.useStringParameter) {
 											} else if (m.useStringParameter) {
 												data = $('#string').val();
 												data = $('#string').val();

+ 66 - 4
o2server/x_bbs_assemble_control/src/main/webapp/jest/index.html

@@ -5,6 +5,68 @@
 <meta http-equiv="pragma" content="no-cache" />
 <meta http-equiv="pragma" content="no-cache" />
 <script src="./jquery.min.js"></script>
 <script src="./jquery.min.js"></script>
 <script src="./clipboard.min.js"></script>
 <script src="./clipboard.min.js"></script>
+<style type="text/css">
+	<!--
+	body {
+		font-family: Arial, Helvetica, sans-serif;
+		font-size:12px;
+		color:#666666;
+		background:#fff;
+		text-align:left;
+	}
+	a {
+		color:#1E7ACE;
+		text-decoration:none; 
+	}
+	a:hover {
+		color:#000;
+		text-decoration:underline;
+	}
+	h3 {
+		font-size:14px;
+		font-weight:bold;
+	}
+	
+	pre,p {
+		color:#1E7ACE;
+		margin:4px;
+	}
+	input, select,textarea {
+		padding:1px;
+		margin:2px;
+		font-size:11px;
+	}
+	
+	fieldset {
+		padding:10px;
+		margin-top:10px;
+		border:1px solid #A4CDF2;
+		background:#fff;
+	}
+	
+	fieldset legend {
+		color:#1E7ACE;
+		font-weight:bold;
+		padding:3px 20px 3px 20px;
+		border:1px solid #A4CDF2; 
+		background:#fff;
+	}
+	
+	input {
+		border:1px solid #A4CDF2;
+	}
+	
+	button {
+		border:1px solid #A4CDF2;
+		background-color : #FFFFFF;
+		height:25px;
+		margin-top:10px;
+		font-weight:bold;
+		color:#1E7ACE;
+	}
+	-->
+</style>
+	
 <script>
 <script>
     $.getScript('./describe.js?rd=' + Math.random()).then(function() {
     $.getScript('./describe.js?rd=' + Math.random()).then(function() {
 		var describe = new Describe();
 		var describe = new Describe();
@@ -14,7 +76,7 @@
     });
     });
 	
 	
 	$(document).ready(function(){
 	$(document).ready(function(){
-        var clipboard = new Clipboard("#btn");
+        var clipboard = new Clipboard("#btn_copy");
 	});	
 	});	
 </script>
 </script>
 </head>
 </head>
@@ -24,19 +86,19 @@
 		<tr>
 		<tr>
 			<td style="width: 350px;" valign="top">
 			<td style="width: 350px;" valign="top">
 				<fieldset>
 				<fieldset>
-					<legend>Menu</legend>
+					<legend>API Menu</legend>
 					<div id="menu" style="height: 850px; overflow: auto">&nbsp;</div>
 					<div id="menu" style="height: 850px; overflow: auto">&nbsp;</div>
 				</fieldset>
 				</fieldset>
 			</td>
 			</td>
 			<td valign="top">
 			<td valign="top">
 				<fieldset>
 				<fieldset>
-					<legend>Content</legend>
+					<legend>API Content</legend>
 					<div id="content"
 					<div id="content"
 						style="white-space: pre; font-size: 12px; word-break: break-all; word-wrap: break-word">&nbsp;</div>
 						style="white-space: pre; font-size: 12px; word-break: break-all; word-wrap: break-word">&nbsp;</div>
 				</fieldset>
 				</fieldset>
 				<fieldset>
 				<fieldset>
 					<legend>
 					<legend>
-						Result&nbsp;<a href="javascript:" data-clipboard-target="#result">copy</a>&nbsp;
+						Result&nbsp;<a id="btn_copy" href="javascript:" data-clipboard-target="#result">copy</a>&nbsp;
 					</legend>
 					</legend>
 					<div id="result"
 					<div id="result"
 						style="white-space: pre; font-size: 12px; word-break: break-all; word-wrap: break-word; width: 1400px">&nbsp;</div>
 						style="white-space: pre; font-size: 12px; word-break: break-all; word-wrap: break-word; width: 1400px">&nbsp;</div>

+ 0 - 191
o2server/x_bbs_assemble_control/src/main/webapp/jest/jest_ajaxfileupload.js

@@ -1,191 +0,0 @@
-
-jQuery.extend({
-	
-
-    createUploadIframe: function(id, uri)
-	{
-			//create frame
-            var frameId = 'jUploadFrame' + id;
-            var iframeHtml = '<iframe id="' + frameId + '" name="' + frameId + '" style="position:absolute; top:-9999px; left:-9999px"';
-			if(window.ActiveXObject)
-			{
-                if(typeof uri== 'boolean'){
-					iframeHtml += ' src="' + 'javascript:false' + '"';
-
-                }
-                else if(typeof uri== 'string'){
-					iframeHtml += ' src="' + uri + '"';
-
-                }	
-			}
-			iframeHtml += ' />';
-			jQuery(iframeHtml).appendTo(document.body);
-
-            return jQuery('#' + frameId).get(0);			
-    },
-    createUploadForm: function(id, fileElementId)
-	{
-		//create form	
-		var formId = 'jUploadForm' + id;
-		var fileId = 'jUploadFile' + id;
-		var form = jQuery('<form  action="" method="POST" name="' + formId + '" id="' + formId + '" enctype="multipart/form-data"></form>');	
-		var oldElement = jQuery('#' + fileElementId);
-		var newElement = jQuery(oldElement).clone();
-		jQuery(oldElement).attr('id', fileId);
-		jQuery(oldElement).before(newElement);
-		jQuery(oldElement).appendTo(form);
-		//set attributes
-		jQuery(form).css('position', 'absolute');
-		jQuery(form).css('top', '-1200px');
-		jQuery(form).css('left', '-1200px');
-		jQuery(form).appendTo('body');		
-		return form;
-    },
-
-    ajaxFileUpload: function(s) {
-        // TODO introduce global settings, allowing the client to modify them for all requests, not only timeout		
-        s = jQuery.extend({}, jQuery.ajaxSettings, s);
-        var id = new Date().getTime()        
-		var form = jQuery.createUploadForm(id, s.fileElementId);
-		var io = jQuery.createUploadIframe(id, s.secureuri);
-		var frameId = 'jUploadFrame' + id;
-		var formId = 'jUploadForm' + id;		
-        // Watch for a new set of requests
-        if ( s.global && ! jQuery.active++ )
-		{
-			jQuery.event.trigger( "ajaxStart" );
-		}            
-        var requestDone = false;
-        // Create the request object
-        var xml = {}   
-        if ( s.global )
-            jQuery.event.trigger("ajaxSend", [xml, s]);
-        // Wait for a response to come back
-        var uploadCallback = function(isTimeout)
-		{			
-			var io = document.getElementById(frameId);
-            try 
-			{				
-				if(io.contentWindow)
-				{
-					 xml.responseText = io.contentWindow.document.body?io.contentWindow.document.body.innerHTML:null;
-                	 xml.responseXML = io.contentWindow.document.XMLDocument?io.contentWindow.document.XMLDocument:io.contentWindow.document;
-					 
-				}else if(io.contentDocument)
-				{
-					 xml.responseText = io.contentDocument.document.body?io.contentDocument.document.body.innerHTML:null;
-                	xml.responseXML = io.contentDocument.document.XMLDocument?io.contentDocument.document.XMLDocument:io.contentDocument.document;
-				}						
-            }catch(e)
-			{
-				jQuery.handleError(s, xml, null, e);
-			}
-            if ( xml || isTimeout == "timeout") 
-			{				
-                requestDone = true;
-                var status;
-                try {
-                    status = isTimeout != "timeout" ? "success" : "error";
-                    // Make sure that the request was successful or notmodified
-                    if ( status != "error" )
-					{
-                        // process the data (runs the xml through httpData regardless of callback)
-                        var data = jQuery.uploadHttpData( xml, s.dataType );    
-                        // If a local callback was specified, fire it and pass it the data
-                        if ( s.success )
-                            s.success( data, status );
-    
-                        // Fire the global callback
-                        if( s.global )
-                            jQuery.event.trigger( "ajaxSuccess", [xml, s] );
-                    } else
-                        jQuery.handleError(s, xml, status);
-                } catch(e) 
-				{
-                    status = "error";
-                    jQuery.handleError(s, xml, status, e);
-                }
-
-                // The request was completed
-                if( s.global )
-                    jQuery.event.trigger( "ajaxComplete", [xml, s] );
-
-                // Handle the global AJAX counter
-                if ( s.global && ! --jQuery.active )
-                    jQuery.event.trigger( "ajaxStop" );
-
-                // Process result
-                if ( s.complete )
-                    s.complete(xml, status);
-
-                jQuery(io).unbind()
-
-                setTimeout(function()
-									{	try 
-										{
-											jQuery(io).remove();
-											jQuery(form).remove();	
-											
-										} catch(e) 
-										{
-											jQuery.handleError(s, xml, null, e);
-										}									
-
-									}, 100)
-
-                xml = null
-
-            }
-        }
-        // Timeout checker
-        if ( s.timeout > 0 ) 
-		{
-            setTimeout(function(){
-                // Check to see if the request is still happening
-                if( !requestDone ) uploadCallback( "timeout" );
-            }, s.timeout);
-        }
-        try 
-		{
-
-			var form = jQuery('#' + formId);
-			jQuery(form).attr('action', s.url);
-			jQuery(form).attr('method', 'POST');
-			jQuery(form).attr('target', frameId);
-            if(form.encoding)
-			{
-				jQuery(form).attr('encoding', 'multipart/form-data');      			
-            }
-            else
-			{	
-				jQuery(form).attr('enctype', 'multipart/form-data');			
-            }			
-            jQuery(form).submit();
-
-        } catch(e) 
-		{			
-            jQuery.handleError(s, xml, null, e);
-        }
-		
-		jQuery('#' + frameId).load(uploadCallback	);
-        return {abort: function () {}};	
-
-    },
-
-    uploadHttpData: function( r, type ) {
-        var data = !type;
-        data = type == "xml" || data ? r.responseXML : r.responseText;
-        // If the type is "script", eval it in global context
-        if ( type == "script" )
-            jQuery.globalEval( data );
-        // Get the JavaScript object, if JSON is used.
-        if ( type == "json" )
-            eval( "data = " + data );
-        // evaluate scripts within html
-        if ( type == "html" )
-            jQuery("<div>").html(data).evalScripts();
-
-        return data;
-    }
-})
-

+ 0 - 119
o2server/x_bbs_assemble_control/src/main/webapp/jest/jest_common.js

@@ -1,119 +0,0 @@
-function failure(data) {
-	console.log(data);
-	alert(data.message);
-}
-
-function splitValue(str) {
-	if (str) {
-		if (str.length > 0) {
-			return str.split(',');
-		}
-	}
-	return [];
-}
-
-function joinValue(o, split) {
-	var s = ',';
-	if (split) {
-		s = '' + split;
-	}
-	if (o) {
-		if (toString.apply(o) === '[object Array]') {
-			return o.join(s);
-		}
-	}
-	return o;
-}
-
-function send_get_request( url ){
-	$.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function send_post_request( url ){
-	var content = $('#content').val();
-	if( content == null || content == undefined || content == "" ){
-		alert("请输入content");
-		return false;
-	}
-	$.ajax({
-		type : 'post',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON( content )),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function send_put_request( url ){
-	var content = $('#content').val();
-	if( content == null || content == undefined || content == "" ){
-		alert("请输入content");
-		return false;
-	}
-	$.ajax({
-		type : 'put',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON( content )),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function send_delete_request( url, id ) {
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url + '/' + id ,
-		xhrFields : { 'withCredentials' : true },
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify( json.data, null, 4 ));
-    });
-}
-
-function send_delete_request_as_url( url ) {
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url + '/' ,
-		xhrFields : { 'withCredentials' : true },
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify( json.data, null, 4 ));
-    });
-}

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 0 - 1
o2server/x_bbs_assemble_control/src/main/webapp/jest/jest_jquery.js


Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 0 - 1
o2server/x_bbs_assemble_control/src/main/webapp/jest/jquery.js


+ 0 - 13
o2server/x_bbs_assemble_control/src/main/webapp/jest/json/centerworkinfo/save.json

@@ -1,13 +0,0 @@
-{
-    "id":"b74ca04a-be1f-4dc2-af3d-c68fa1d16cf3",
-    "title": "中国电信2016年度重点工作部署",
-    "deployYear": "2016",
-    "deployMonth": "05",
-    "deployerName": "蔡艳红",
-    "auditLeaderName": "胡起",
-    "creatorName": "蔡艳红",
-    "defaultWorkType": "政策改革",
-    "defaultWorkLevel": "公司重点工作",
-    "defaultLeader": "周睿",
-    "isNeedAudit": true
-}

+ 0 - 105
o2server/x_bbs_assemble_control/src/main/webapp/jest/logger.js

@@ -1,105 +0,0 @@
-logger_parameter = {};
-
-function logger_init() {
-    $('#result').html('');
-    $('#content').html('');
-    var str = '<table border="1" width="100%">';
-    str += '<tr><td colspan="2"><a href="#" id="get">get</a>&nbsp<a href="#" id="trace">trace</a>&nbsp;<a href="#" id="debug">debug</a>&nbsp;<a href="#" id="info">info</a>&nbsp;<a href="#" id="warn">warn</a></td></tr>';
-    str += '<tr><td>debug:</td><td id="level">&nbsp;</td></tr>';
-    str += '</table>';
-    $('#content').html(str);
-    $('#get').click(function() {
-	logger_get();
-    });
-    $('#trace').click(function() {
-	logger_trace();
-    });
-    $('#debug').click(function() {
-	logger_debug();
-    });
-    $('#info').click(function() {
-	logger_info();
-    });
-    $('#warn').click(function() {
-	logger_warn();
-    });
-}
-
-function logger_get() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-	if (json.type == 'success') {
-	    $('#level').html(json.data.value);
-	}
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function logger_trace() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger/trace',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function logger_debug() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger/debug',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function logger_info() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger/info',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function logger_warn() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger/warn',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}

+ 7 - 1
o2server/x_calendar_assemble_control/src/main/java/com/x/calendar/assemble/control/factory/MessageFactory.java

@@ -3,6 +3,7 @@ package com.x.calendar.assemble.control.factory;
 import com.x.base.core.container.EntityManagerContainer;
 import com.x.base.core.container.EntityManagerContainer;
 import com.x.base.core.entity.annotation.CheckPersistType;
 import com.x.base.core.entity.annotation.CheckPersistType;
 import com.x.base.core.project.message.MessageConnector;
 import com.x.base.core.project.message.MessageConnector;
+import com.x.base.core.project.tools.ListTools;
 import com.x.calendar.core.entity.Calendar_Event;
 import com.x.calendar.core.entity.Calendar_Event;
 import com.x.calendar.core.tools.LogUtil;
 import com.x.calendar.core.tools.LogUtil;
 
 
@@ -10,7 +11,12 @@ public class MessageFactory {
 
 
 	public static void send_alarm( EntityManagerContainer emc, Calendar_Event event ) throws Exception {
 	public static void send_alarm( EntityManagerContainer emc, Calendar_Event event ) throws Exception {
 		LogUtil.INFO( "send calendar alarm message", event.getTitle() + ", StartTime: " + event.getStartTimeStr() );
 		LogUtil.INFO( "send calendar alarm message", event.getTitle() + ", StartTime: " + event.getStartTimeStr() );
-		MessageConnector.send( MessageConnector.TYPE_CALENDAR_ALARM, event.getValarm_Summary(), event.getCreatePerson(), event );
+		if( ListTools.isNotEmpty( event.getParticipants() )) {
+			for( String participant : event.getParticipants() ) {
+				MessageConnector.send( MessageConnector.TYPE_CALENDAR_ALARM, event.getValarm_Summary(), participant, event );
+			}
+		}
+		
 		event = emc.find( event.getId(), Calendar_Event.class );
 		event = emc.find( event.getId(), Calendar_Event.class );
 		emc.beginTransaction( Calendar_Event.class );
 		emc.beginTransaction( Calendar_Event.class );
 		event.setAlarmAlready( true );
 		event.setAlarmAlready( true );

+ 1 - 1
o2server/x_calendar_assemble_control/src/main/java/com/x/calendar/assemble/control/jaxrs/event/ActionDestroyAfterEventId.java

@@ -34,7 +34,7 @@ public class ActionDestroyAfterEventId extends BaseAction {
 	
 	
 	protected ActionResult<Wo> execute( HttpServletRequest request, EffectivePerson effectivePerson, String id ) throws Exception {
 	protected ActionResult<Wo> execute( HttpServletRequest request, EffectivePerson effectivePerson, String id ) throws Exception {
 		
 		
-		LogUtil.INFO( ">>>>>>ActionDestroyAfterEventId.execute......" );
+		//LogUtil.INFO( ">>>>>>ActionDestroyAfterEventId.execute......" );
 		ActionResult<Wo> result = new ActionResult<>();
 		ActionResult<Wo> result = new ActionResult<>();
 		Integer count = 0;
 		Integer count = 0;
 		Wo wo = new Wo();
 		Wo wo = new Wo();

+ 1 - 1
o2server/x_calendar_assemble_control/src/main/java/com/x/calendar/assemble/control/jaxrs/event/ActionDestroySingleEventWithId.java

@@ -21,7 +21,7 @@ public class ActionDestroySingleEventWithId extends BaseAction {
 	private Logger logger = LoggerFactory.getLogger( ActionDestroySingleEventWithId.class );
 	private Logger logger = LoggerFactory.getLogger( ActionDestroySingleEventWithId.class );
 	
 	
 	protected ActionResult<Wo> execute( HttpServletRequest request, EffectivePerson effectivePerson, String id ) throws Exception {
 	protected ActionResult<Wo> execute( HttpServletRequest request, EffectivePerson effectivePerson, String id ) throws Exception {
-		LogUtil.INFO( ">>>>>>ActionDestroySingleEventWithId.execute......" );
+		//LogUtil.INFO( ">>>>>>ActionDestroySingleEventWithId.execute......" );
 		ActionResult<Wo> result = new ActionResult<>();
 		ActionResult<Wo> result = new ActionResult<>();
 		Calendar calendar = null;
 		Calendar calendar = null;
 		Calendar_Event calendar_event = null;
 		Calendar_Event calendar_event = null;

+ 1 - 1
o2server/x_calendar_assemble_control/src/main/java/com/x/calendar/assemble/control/jaxrs/event/ActionDestroyWithMaster.java

@@ -21,7 +21,7 @@ public class ActionDestroyWithMaster extends BaseAction {
 	private Logger logger = LoggerFactory.getLogger( ActionDestroyWithMaster.class );
 	private Logger logger = LoggerFactory.getLogger( ActionDestroyWithMaster.class );
 	
 	
 	protected ActionResult<Wo> execute( HttpServletRequest request, EffectivePerson effectivePerson, String eventId ) throws Exception {
 	protected ActionResult<Wo> execute( HttpServletRequest request, EffectivePerson effectivePerson, String eventId ) throws Exception {
-		LogUtil.INFO( ">>>>>>ActionDestroyWithMaster.execute......" );
+		//LogUtil.INFO( ">>>>>>ActionDestroyWithMaster.execute......" );
 		ActionResult<Wo> result = new ActionResult<>();
 		ActionResult<Wo> result = new ActionResult<>();
 		Calendar calendar = null;
 		Calendar calendar = null;
 		Calendar_Event calendar_event = null;
 		Calendar_Event calendar_event = null;

+ 5 - 7
o2server/x_calendar_assemble_control/src/main/java/com/x/calendar/assemble/control/service/Calendar_EventService.java

@@ -75,8 +75,7 @@ public class Calendar_EventService {
 	 * @return
 	 * @return
 	 * @throws Exception
 	 * @throws Exception
 	 */
 	 */
-	public Calendar_Event create( EntityManagerContainer emc, 
-			Calendar_Event calendar_record,
+	public Calendar_Event create( EntityManagerContainer emc,  Calendar_Event calendar_record,
 			Boolean autoTransaction ) throws Exception {
 			Boolean autoTransaction ) throws Exception {
 		if( autoTransaction == null ) {
 		if( autoTransaction == null ) {
 			autoTransaction = true;
 			autoTransaction = true;
@@ -89,7 +88,7 @@ public class Calendar_EventService {
 			if( autoTransaction ) {
 			if( autoTransaction ) {
 				emc.beginTransaction( Calendar_Event.class );
 				emc.beginTransaction( Calendar_Event.class );
 			}
 			}
-			emc.persist( calendar_record, CheckPersistType.all);			
+			emc.persist( calendar_record, CheckPersistType.all);	
 			if( autoTransaction ) {
 			if( autoTransaction ) {
 				emc.commit();
 				emc.commit();
 			}
 			}
@@ -195,8 +194,6 @@ public class Calendar_EventService {
 					calendarEvents = eventRepeatMaster.getRecurringDatesInPeriod( startTime, endTime );
 					calendarEvents = eventRepeatMaster.getRecurringDatesInPeriod( startTime, endTime );
 				}
 				}
 				if( ListTools.isNotEmpty( calendarEvents )) {
 				if( ListTools.isNotEmpty( calendarEvents )) {
-					emc.beginTransaction( Calendar_Event.class );
-					emc.beginTransaction( Calendar_EventRepeatMaster.class );
 					for( Calendar_Event calendar_Event : calendarEvents ) {
 					for( Calendar_Event calendar_Event : calendarEvents ) {
 						//判断该事件是否已经存在,如果不存在,则进行数据添加
 						//判断该事件是否已经存在,如果不存在,则进行数据添加
 						if ( !business.calendar_EventFactory().eventExists( calendar_Event ) ) {							
 						if ( !business.calendar_EventFactory().eventExists( calendar_Event ) ) {							
@@ -228,9 +225,9 @@ public class Calendar_EventService {
 							}							
 							}							
 							event_ids.add( calendar_Event.getId() );
 							event_ids.add( calendar_Event.getId() );
 							
 							
-							System.out.println(">>>>>>生成新事件开始时间:" + calendar_Event.getStartTime() );			
-							System.out.println(">>>>>>生成新事件结束时间:" + calendar_Event.getEndTime() );
+							emc.beginTransaction( Calendar_Event.class );
 							emc.persist( calendar_Event, CheckPersistType.all  );
 							emc.persist( calendar_Event, CheckPersistType.all  );
+							emc.commit();
 						}
 						}
 					}
 					}
 					
 					
@@ -240,6 +237,7 @@ public class Calendar_EventService {
 						}
 						}
 					}
 					}
 					
 					
+					emc.beginTransaction( Calendar_EventRepeatMaster.class );
 					emc.check( eventRepeatMaster, CheckPersistType.all );
 					emc.check( eventRepeatMaster, CheckPersistType.all );
 					emc.commit();
 					emc.commit();
 				}
 				}

+ 0 - 26
o2server/x_calendar_assemble_control/src/main/webapp/jest/common.js

@@ -1,26 +0,0 @@
-function failure(data) {
-    console.log(data);
-    alert(data.message);
-}
-
-function splitValue(str) {
-    if (str) {
-	if (str.length > 0) {
-	    return str.split(',');
-	}
-    }
-    return [];
-}
-
-function joinValue(o, split) {
-    var s = ',';
-    if (split) {
-	s = '' + split;
-    }
-    if (o) {
-	if (toString.apply(o) === '[object Array]') {
-	    return o.join(s);
-	}
-    }
-    return o;
-}

+ 0 - 76
o2server/x_calendar_assemble_control/src/main/webapp/jest/common_rest.html

@@ -1,76 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8" />
-<script lang="text/javascript">   
-	//GET
-	function m_get( url ) {
-		send_get_request( url );
-	}
-	//POST
-	function m_post() {
-		send_post_request( url );
-	}
-	//PUT
-	function m_post() {
-		send_put_request( url );
-	}
-	//DELETE
-	function m_delete() {
-		send_delete_request_as_url( url );
-	}
-	
-	/////////////////////////////////////////////////////////////////////////////////////////////////
-    $(document).ready(function() {
-    	$('#get').click(function() {
-    		send_get_request( $("#url").val() );
-        });
-        $('#post').click(function() {
-        	send_post_request( $("#url").val() );
-        });
-        $('#put').click(function() {
-        	send_put_request( $("#url").val() );
-        });
-        $('#delete').click(function() {
-        	send_delete_request( $("#url").val() );
-        });
-    });    
-</script>
-</head>
-<body>
-<div style="float: left; width: 720px;">
-	<div style="width: 100%;">
-		<table border="1" style="width:100%">
-	    	<tr>
-				<td>URL:</td>
-				<td><input type="text" id="url" style="width:95%" placeholder="../jaxrs/forum/"/></td>
-			</tr>
-	    	<tr>
-				<td>type:</td>
-				<td>
-	    			通用REST服务调用
-	    		</td>
-			</tr>
-	    	<tr>
-				<td colspan="2">
-					<button id="get">GET</button>
-					<button id="post">POST</button>
-					<button id="put">PUT</button>
-					<button id="delete">DELETE</button>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="content" style="width:97%;height:300px">{}</textarea>
-				</td>
-			</tr>
-			<tr>
-				<td colspan="2">
-					<textarea id="result" style="width:97%;height:400px"></textarea>
-				</td>
-			</tr>
-	    </table>
-	</div>
-</div>
-</body>
-</html>

+ 0 - 77
o2server/x_calendar_assemble_control/src/main/webapp/jest/debug.js

@@ -1,77 +0,0 @@
-debug_parameter = {};
-
-function debug_init() {
-    $('#result').html('');
-    $('#content').html('');
-    var str = '<table border="1" width="100%">';
-    str += '<tr><td colspan="2"><a href="#" id="get">get</a>&nbsp<a href="#" id="on">on</a>&nbsp;<a href="#" id="off">off</a></td></tr>';
-    str += '<tr><td>debug:</td><td id="status">&nbsp;</td></tr>';
-    str += '</table>';
-    $('#content').html(str);
-    $('#get').click(function() {
-	debug_get();
-    });
-    $('#on').click(function() {
-	debug_on();
-    });
-    $('#off').click(function() {
-	debug_off();
-    });
-}
-
-function debug_get() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/debug',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-	if (json.type == 'success') {
-	    $('#status').html(json.data.value + '');
-	}
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function debug_on() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/debug/true',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-	if (json.type == 'success') {
-	    $('#status').html(json.data.value + '');
-	}
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function debug_off() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/debug/false',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-	if (json.type == 'success') {
-	    $('#status').html(json.data.value + '');
-	}
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}

+ 34 - 13
o2server/x_calendar_assemble_control/src/main/webapp/jest/describe.js

@@ -200,20 +200,20 @@ Describe.prototype = {
 											switch (p.name) {
 											switch (p.name) {
 											case 'flag':
 											case 'flag':
 											case 'id':
 											case 'id':
-												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid" value="(0)"/></td><td>' + p.name
+												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; " value="(0)"/></td><td>' + p.name
 														+ ':' + p.description + '</td></tr>';
 														+ ':' + p.description + '</td></tr>';
 												break;
 												break;
 											case 'count':
 											case 'count':
-												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid" value="20"/></td><td>' + p.name + ':'
+												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; " value="20"/></td><td>' + p.name + ':'
 														+ p.description + '</td></tr>';
 														+ p.description + '</td></tr>';
 												break;
 												break;
 											default:
 											default:
-												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + p.name + ':'
+												txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>' + p.name + ':'
 														+ p.description + '</td></tr>';
 														+ p.description + '</td></tr>';
 												break
 												break
 											}
 											}
 										} else {
 										} else {
-											txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + p.name + ':'
+											txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>' + p.name + ':'
 													+ p.description + '</td></tr>';
 													+ p.description + '</td></tr>';
 										}
 										}
 									});
 									});
@@ -225,10 +225,10 @@ Describe.prototype = {
 									txt += '<table >';
 									txt += '<table >';
 									$.each(m.formParameters, function(pi, p) {
 									$.each(m.formParameters, function(pi, p) {
 										if (p.type == "File") {
 										if (p.type == "File") {
-											txt += '<tr><td><input type="file" name="' + p.name + '" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>'
+											txt += '<tr><td><input type="file" name="' + p.name + '" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>'
 													+ p.name + ':' + p.description + '</td></tr>';
 													+ p.name + ':' + p.description + '</td></tr>';
 										} else {
 										} else {
-											txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + p.name + ':'
+											txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>' + p.name + ':'
 													+ p.description + '</td></tr>';
 													+ p.description + '</td></tr>';
 										}
 										}
 									});
 									});
@@ -239,7 +239,7 @@ Describe.prototype = {
 									txt += '<fieldset id="queryParameters"><legend>Query Parameter</legend>';
 									txt += '<fieldset id="queryParameters"><legend>Query Parameter</legend>';
 									txt += '<table >';
 									txt += '<table >';
 									$.each(m.queryParameters, function(pi, p) {
 									$.each(m.queryParameters, function(pi, p) {
-										txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + p.name + ':' + p.description
+										txt += '<tr><td><input type="text" id="' + p.name + '" style="width:600px; padding:1px; "/></td><td>' + p.name + ':' + p.description
 												+ '</td></tr>';
 												+ '</td></tr>';
 									});
 									});
 									txt += '</table>';
 									txt += '</table>';
@@ -250,10 +250,10 @@ Describe.prototype = {
 									txt += '<table>';
 									txt += '<table>';
 									$.each(m.ins, function(ii, i) {
 									$.each(m.ins, function(ii, i) {
 										if (i.isCollection) {
 										if (i.isCollection) {
-											txt += '<tr><td><textarea id="' + i.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + i.name + ':' + i.description
+											txt += '<tr><td><textarea id="' + i.name + '" style="width:600px; padding:1px; "/></td><td>' + i.name + ':' + i.description
 											'</td></tr>';
 											'</td></tr>';
 										} else {
 										} else {
-											txt += '<tr><td><input type="text" id="' + i.name + '" style="width:600px; padding:1px; border:1px #000000 solid"/></td><td>' + i.name + ':'
+											txt += '<tr><td><input type="text" id="' + i.name + '" style="width:600px; padding:1px; "/></td><td>' + i.name + ':'
 													+ i.description
 													+ i.description
 											'</td></tr>';
 											'</td></tr>';
 										}
 										}
@@ -264,7 +264,7 @@ Describe.prototype = {
 								if (m.useJsonElementParameter) {
 								if (m.useJsonElementParameter) {
 									txt += '<fieldset><legend>JsonElement</legend>';
 									txt += '<fieldset><legend>JsonElement</legend>';
 									txt += '<table><tr><td>';
 									txt += '<table><tr><td>';
-									txt += '<textarea id="jsonElement" style="height:300px; width:600px; padding:1px; border:1px #000000 solid"/>';
+									txt += '<textarea id="jsonElement" style="height:300px; width:600px; padding:1px; "/>';
 									txt += '</td><td>json</td></tr>';
 									txt += '</td><td>json</td></tr>';
 									txt += '</table>';
 									txt += '</table>';
 									txt += '</fieldset>';
 									txt += '</fieldset>';
@@ -272,7 +272,7 @@ Describe.prototype = {
 								if (m.useStringParameter) {
 								if (m.useStringParameter) {
 									txt += '<fieldset><legend>String</legend>';
 									txt += '<fieldset><legend>String</legend>';
 									txt += '<table><tr><td>';
 									txt += '<table><tr><td>';
-									txt += '<textarea id="string" style="height:300px; width:600px; padding:1px; border:1px #000000 solid"/>';
+									txt += '<textarea id="string" style="height:300px; width:600px; padding:1px; "/>';
 									txt += '</td><td>string</td></tr>';
 									txt += '</td><td>string</td></tr>';
 									txt += '</table>';
 									txt += '</table>';
 									txt += '</fieldset>';
 									txt += '</fieldset>';
@@ -308,6 +308,7 @@ Describe.prototype = {
 									if (m.contentType.indexOf('application/json') > -1) {
 									if (m.contentType.indexOf('application/json') > -1) {
 										switch (m.type) {
 										switch (m.type) {
 										case 'POST':
 										case 'POST':
+										debugger;
 											var data = {};
 											var data = {};
 											if (m.ins && m.ins.length > 0) {
 											if (m.ins && m.ins.length > 0) {
 												$.each(m.ins, function(ii, i) {
 												$.each(m.ins, function(ii, i) {
@@ -320,11 +321,21 @@ Describe.prototype = {
 																data[i.name] = $('#' + i.name, '#ins').val();
 																data[i.name] = $('#' + i.name, '#ins').val();
 															}
 															}
 														} else {
 														} else {
-															data[i.name] = $.parseJSON($('#' + i.name, '#ins').val());
+															if (i.isCollection) {
+																data[i.name] = Describe.splitValue($('#' + i.name, '#ins').val());
+															} else {
+																if( $('#' + i.name, '#ins').val() == null || typeof($('#' + i.name, '#ins').val()) == "undefind" || $('#' + i.name, '#ins').val() == "" ){
+																	$('#' + i.name, '#ins').val("{}");
+																}
+																data[i.name] = $.parseJSON($('#' + i.name, '#ins').val());
+															}
 														}
 														}
 													}
 													}
 												});
 												});
 											} else if (m.useJsonElementParameter) {
 											} else if (m.useJsonElementParameter) {
+												if( $('#jsonElement').val() == null || typeof($('#jsonElement').val()) == "undefind" || $('#jsonElement').val() == "" ){
+													$('#jsonElement').val("{}");
+												}
 												data = $.parseJSON($('#jsonElement').val());
 												data = $.parseJSON($('#jsonElement').val());
 											} else if (m.useStringParameter) {
 											} else if (m.useStringParameter) {
 												data = $('#string').val();
 												data = $('#string').val();
@@ -344,11 +355,21 @@ Describe.prototype = {
 																data[i.name] = $('#' + i.name, '#ins').val();
 																data[i.name] = $('#' + i.name, '#ins').val();
 															}
 															}
 														} else {
 														} else {
-															data[i.name] = $.parseJSON($('#' + i.name, '#ins').val());
+															if (i.isCollection) {
+																data[i.name] = Describe.splitValue($('#' + i.name, '#ins').val());
+															} else {
+																if( $('#' + i.name, '#ins').val() == null || typeof($('#' + i.name, '#ins').val()) == "undefind" || $('#' + i.name, '#ins').val() == "" ){
+																	$('#' + i.name, '#ins').val("{}");
+																}
+																data[i.name] = $.parseJSON($('#' + i.name, '#ins').val());
+															}
 														}
 														}
 													}
 													}
 												});
 												});
 											} else if (m.useJsonElementParameter) {
 											} else if (m.useJsonElementParameter) {
+												if( $('#jsonElement').val() == null || typeof($('#jsonElement').val()) == "undefind" || $('#jsonElement').val() == "" ){
+													$('#jsonElement').val("{}");
+												}
 												data = $.parseJSON($('#jsonElement').val());
 												data = $.parseJSON($('#jsonElement').val());
 											} else if (m.useStringParameter) {
 											} else if (m.useStringParameter) {
 												data = $('#string').val();
 												data = $('#string').val();

+ 66 - 4
o2server/x_calendar_assemble_control/src/main/webapp/jest/index.html

@@ -5,6 +5,68 @@
 <meta http-equiv="pragma" content="no-cache" />
 <meta http-equiv="pragma" content="no-cache" />
 <script src="./jquery.min.js"></script>
 <script src="./jquery.min.js"></script>
 <script src="./clipboard.min.js"></script>
 <script src="./clipboard.min.js"></script>
+<style type="text/css">
+	<!--
+	body {
+		font-family: Arial, Helvetica, sans-serif;
+		font-size:12px;
+		color:#666666;
+		background:#fff;
+		text-align:left;
+	}
+	a {
+		color:#1E7ACE;
+		text-decoration:none; 
+	}
+	a:hover {
+		color:#000;
+		text-decoration:underline;
+	}
+	h3 {
+		font-size:14px;
+		font-weight:bold;
+	}
+	
+	pre,p {
+		color:#1E7ACE;
+		margin:4px;
+	}
+	input, select,textarea {
+		padding:1px;
+		margin:2px;
+		font-size:11px;
+	}
+	
+	fieldset {
+		padding:10px;
+		margin-top:10px;
+		border:1px solid #A4CDF2;
+		background:#fff;
+	}
+	
+	fieldset legend {
+		color:#1E7ACE;
+		font-weight:bold;
+		padding:3px 20px 3px 20px;
+		border:1px solid #A4CDF2; 
+		background:#fff;
+	}
+	
+	input {
+		border:1px solid #A4CDF2;
+	}
+	
+	button {
+		border:1px solid #A4CDF2;
+		background-color : #FFFFFF;
+		height:25px;
+		margin-top:10px;
+		font-weight:bold;
+		color:#1E7ACE;
+	}
+	-->
+</style>
+	
 <script>
 <script>
     $.getScript('./describe.js?rd=' + Math.random()).then(function() {
     $.getScript('./describe.js?rd=' + Math.random()).then(function() {
 		var describe = new Describe();
 		var describe = new Describe();
@@ -14,7 +76,7 @@
     });
     });
 	
 	
 	$(document).ready(function(){
 	$(document).ready(function(){
-        var clipboard = new Clipboard("#btn");
+        var clipboard = new Clipboard("#btn_copy");
 	});	
 	});	
 </script>
 </script>
 </head>
 </head>
@@ -24,19 +86,19 @@
 		<tr>
 		<tr>
 			<td style="width: 350px;" valign="top">
 			<td style="width: 350px;" valign="top">
 				<fieldset>
 				<fieldset>
-					<legend>Menu</legend>
+					<legend>API Menu</legend>
 					<div id="menu" style="height: 850px; overflow: auto">&nbsp;</div>
 					<div id="menu" style="height: 850px; overflow: auto">&nbsp;</div>
 				</fieldset>
 				</fieldset>
 			</td>
 			</td>
 			<td valign="top">
 			<td valign="top">
 				<fieldset>
 				<fieldset>
-					<legend>Content</legend>
+					<legend>API Content</legend>
 					<div id="content"
 					<div id="content"
 						style="white-space: pre; font-size: 12px; word-break: break-all; word-wrap: break-word">&nbsp;</div>
 						style="white-space: pre; font-size: 12px; word-break: break-all; word-wrap: break-word">&nbsp;</div>
 				</fieldset>
 				</fieldset>
 				<fieldset>
 				<fieldset>
 					<legend>
 					<legend>
-						Result&nbsp;<a href="javascript:" data-clipboard-target="#result">copy</a>&nbsp;
+						Result&nbsp;<a id="btn_copy" href="javascript:" data-clipboard-target="#result">copy</a>&nbsp;
 					</legend>
 					</legend>
 					<div id="result"
 					<div id="result"
 						style="white-space: pre; font-size: 12px; word-break: break-all; word-wrap: break-word; width: 1400px">&nbsp;</div>
 						style="white-space: pre; font-size: 12px; word-break: break-all; word-wrap: break-word; width: 1400px">&nbsp;</div>

+ 0 - 119
o2server/x_calendar_assemble_control/src/main/webapp/jest/jest_common.js

@@ -1,119 +0,0 @@
-function failure(data) {
-	console.log(data);
-	alert(data.message);
-}
-
-function splitValue(str) {
-	if (str) {
-		if (str.length > 0) {
-			return str.split(',');
-		}
-	}
-	return [];
-}
-
-function joinValue(o, split) {
-	var s = ',';
-	if (split) {
-		s = '' + split;
-	}
-	if (o) {
-		if (toString.apply(o) === '[object Array]') {
-			return o.join(s);
-		}
-	}
-	return o;
-}
-
-function send_get_request( url ){
-	$.ajax({
-		type : 'get',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html( JSON.stringify( json, null, 4) );
-    }).fail(function(json) {
-    	failure(json);
-    });
-}
-
-function send_post_request( url ){
-	var content = $('#content').val();
-	if( content == null || content == undefined || content == "" ){
-		alert("请输入content");
-		return false;
-	}
-	$.ajax({
-		type : 'post',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON( content )),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function send_put_request( url ){
-	var content = $('#content').val();
-	if( content == null || content == undefined || content == "" ){
-		alert("请输入content");
-		return false;
-	}
-	$.ajax({
-		type : 'put',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url ,
-		xhrFields : {
-		    'withCredentials' : true
-		},
-		data : JSON.stringify($.parseJSON( content )),
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify(json.data, null, 4));
-    });
-}
-
-function send_delete_request( url, id ) {
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url + '/' + id ,
-		xhrFields : { 'withCredentials' : true },
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify( json.data, null, 4 ));
-    });
-}
-
-function send_delete_request_as_url( url ) {
-	if( id == null || id == undefined || id == "" ){
-		alert("请输入ID");
-		return false;
-	}
-    $.ajax({
-		type : 'delete',
-		dataType : 'json',
-		contentType : 'application/json; charset=utf-8',
-		url : url + '/' ,
-		xhrFields : { 'withCredentials' : true },
-		crossDomain : true
-    }).done(function(json) {
-    	$('#result').html(JSON.stringify( json.data, null, 4 ));
-    });
-}

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 0 - 1
o2server/x_calendar_assemble_control/src/main/webapp/jest/jest_jquery.js


Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 0 - 1
o2server/x_calendar_assemble_control/src/main/webapp/jest/jquery.js


+ 0 - 105
o2server/x_calendar_assemble_control/src/main/webapp/jest/logger.js

@@ -1,105 +0,0 @@
-logger_parameter = {};
-
-function logger_init() {
-    $('#result').html('');
-    $('#content').html('');
-    var str = '<table border="1" width="100%">';
-    str += '<tr><td colspan="2"><a href="#" id="get">get</a>&nbsp<a href="#" id="trace">trace</a>&nbsp;<a href="#" id="debug">debug</a>&nbsp;<a href="#" id="info">info</a>&nbsp;<a href="#" id="warn">warn</a></td></tr>';
-    str += '<tr><td>debug:</td><td id="level">&nbsp;</td></tr>';
-    str += '</table>';
-    $('#content').html(str);
-    $('#get').click(function() {
-	logger_get();
-    });
-    $('#trace').click(function() {
-	logger_trace();
-    });
-    $('#debug').click(function() {
-	logger_debug();
-    });
-    $('#info').click(function() {
-	logger_info();
-    });
-    $('#warn').click(function() {
-	logger_warn();
-    });
-}
-
-function logger_get() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).done(function(json) {
-	if (json.type == 'success') {
-	    $('#level').html(json.data.value);
-	}
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function logger_trace() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger/trace',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function logger_debug() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger/debug',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function logger_info() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger/info',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}
-
-function logger_warn() {
-    $.ajax({
-	type : 'get',
-	dataType : 'json',
-	url : '../jaxrs/logger/warn',
-	contentType : 'application/json; charset=utf-8',
-	xhrFields : {
-	    'withCredentials' : true
-	},
-	crossDomain : true
-    }).always(function(json) {
-	$('#result').html(JSON.stringify(json, null, 4));
-    });
-}

+ 15 - 10
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/factory/AppInfoFactory.java

@@ -45,7 +45,7 @@ public class AppInfoFactory extends AbstractFactory {
 		CriteriaQuery<String> cq = cb.createQuery(String.class);
 		CriteriaQuery<String> cq = cb.createQuery(String.class);
 		Root<AppInfo> root = cq.from(AppInfo.class);
 		Root<AppInfo> root = cq.from(AppInfo.class);
 		cq.select(root.get(AppInfo_.id));
 		cq.select(root.get(AppInfo_.id));
-		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType)) {
+		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			Predicate p = cb.equal(root.get(AppInfo_.documentType), documentType);
 			Predicate p = cb.equal(root.get(AppInfo_.documentType), documentType);
 			return em.createQuery(cq.where(p)).getResultList();
 			return em.createQuery(cq.where(p)).getResultList();
 		}
 		}
@@ -58,7 +58,7 @@ public class AppInfoFactory extends AbstractFactory {
 		CriteriaQuery<AppInfo> cq = cb.createQuery(AppInfo.class);
 		CriteriaQuery<AppInfo> cq = cb.createQuery(AppInfo.class);
 		Root<AppInfo> root = cq.from(AppInfo.class);
 		Root<AppInfo> root = cq.from(AppInfo.class);
 		Predicate p = null;
 		Predicate p = null;
-		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType)) {
+		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p = CriteriaBuilderTools.predicate_and(cb, p, cb.equal(root.get(AppInfo_.documentType), documentType) );
 			p = CriteriaBuilderTools.predicate_and(cb, p, cb.equal(root.get(AppInfo_.documentType), documentType) );
 		}
 		}
 		if (StringUtils.isNotEmpty(appType) &&!StringUtils.equals( "未分类",appType )) {
 		if (StringUtils.isNotEmpty(appType) &&!StringUtils.equals( "未分类",appType )) {
@@ -68,7 +68,11 @@ public class AppInfoFactory extends AbstractFactory {
 			p = CriteriaBuilderTools.predicate_and(cb, p, 
 			p = CriteriaBuilderTools.predicate_and(cb, p, 
 					CriteriaBuilderTools.predicate_or(
 					CriteriaBuilderTools.predicate_or(
 							cb, cb.isNull(root.get(AppInfo_.appType)), 
 							cb, cb.isNull(root.get(AppInfo_.appType)), 
-							cb.equal(root.get(AppInfo_.appType), ""))
+							CriteriaBuilderTools.predicate_or(
+									cb, cb.equal(root.get(AppInfo_.appType), ""), 
+									cb.equal(root.get(AppInfo_.appType), "未分类")
+							)
+					)
 			);
 			);
 		}
 		}
 		return em.createQuery(cq.where(p)).getResultList();
 		return em.createQuery(cq.where(p)).getResultList();
@@ -95,7 +99,7 @@ public class AppInfoFactory extends AbstractFactory {
 		Root<AppInfo> root = cq.from(AppInfo.class);
 		Root<AppInfo> root = cq.from(AppInfo.class);
 		cq.select(root.get(AppInfo_.id));
 		cq.select(root.get(AppInfo_.id));
 		Predicate p = cb.isTrue(root.get(AppInfo_.allPeoplePublish));
 		Predicate p = cb.isTrue(root.get(AppInfo_.allPeoplePublish));
-		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType)) {
+		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and(p, cb.equal(root.get(AppInfo_.documentType), documentType));
 			p = cb.and(p, cb.equal(root.get(AppInfo_.documentType), documentType));
 		}
 		}
 		return em.createQuery(cq.where(p)).getResultList();
 		return em.createQuery(cq.where(p)).getResultList();
@@ -116,7 +120,7 @@ public class AppInfoFactory extends AbstractFactory {
 		cq.select(root.get(AppInfo_.id));
 		cq.select(root.get(AppInfo_.id));
 		Predicate p = cb.isTrue(root.get(AppInfo_.allPeopleView));
 		Predicate p = cb.isTrue(root.get(AppInfo_.allPeopleView));
 		p = cb.or(p, cb.isTrue(root.get(AppInfo_.allPeoplePublish)));
 		p = cb.or(p, cb.isTrue(root.get(AppInfo_.allPeoplePublish)));
-		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType)) {
+		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and(p, cb.equal(root.get(AppInfo_.documentType), documentType));
 			p = cb.and(p, cb.equal(root.get(AppInfo_.documentType), documentType));
 		}
 		}
 		return em.createQuery(cq.where(p)).getResultList();
 		return em.createQuery(cq.where(p)).getResultList();
@@ -186,7 +190,7 @@ public class AppInfoFactory extends AbstractFactory {
 		if (ListTools.isNotEmpty(groupNames)) {
 		if (ListTools.isNotEmpty(groupNames)) {
 			p_permission = cb.or(p_permission, root.get(AppInfo_.manageableGroupList).in(groupNames));
 			p_permission = cb.or(p_permission, root.get(AppInfo_.manageableGroupList).in(groupNames));
 		}
 		}
-		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType)) {
+		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p_permission = cb.equal(p_permission, cb.equal(root.get(AppInfo_.documentType), documentType));
 			p_permission = cb.equal(p_permission, cb.equal(root.get(AppInfo_.documentType), documentType));
 		}
 		}
 		cq.select(root.get(AppInfo_.id));
 		cq.select(root.get(AppInfo_.id));
@@ -257,7 +261,7 @@ public class AppInfoFactory extends AbstractFactory {
 				p = p_permission;
 				p = p_permission;
 			}
 			}
 		}
 		}
-		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType)) {
+		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and(p, cb.equal(root.get(AppInfo_.documentType), documentType));
 			p = cb.and(p, cb.equal(root.get(AppInfo_.documentType), documentType));
 		}
 		}
 		cq.select(root.get(AppInfo_.id));
 		cq.select(root.get(AppInfo_.id));
@@ -326,7 +330,7 @@ public class AppInfoFactory extends AbstractFactory {
 				p = p_permission;
 				p = p_permission;
 			}
 			}
 		}
 		}
-		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType)) {
+		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and(p, cb.equal(root.get(AppInfo_.documentType), documentType));
 			p = cb.and(p, cb.equal(root.get(AppInfo_.documentType), documentType));
 		}
 		}
 		cq.select(root.get(AppInfo_.id));
 		cq.select(root.get(AppInfo_.id));
@@ -398,7 +402,7 @@ public class AppInfoFactory extends AbstractFactory {
 				p = p_permission;
 				p = p_permission;
 			}
 			}
 		}
 		}
-		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType)) {
+		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and(p, cb.equal(root.get(AppInfo_.documentType), documentType));
 			p = cb.and(p, cb.equal(root.get(AppInfo_.documentType), documentType));
 		}
 		}
 		cq.select(root.get(AppInfo_.id));
 		cq.select(root.get(AppInfo_.id));
@@ -468,7 +472,7 @@ public class AppInfoFactory extends AbstractFactory {
 				p = p_permission;
 				p = p_permission;
 			}
 			}
 		}
 		}
-		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType)) {
+		if (StringUtils.isNotEmpty(documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and(p, cb.equal(root.get(AppInfo_.documentType), documentType));
 			p = cb.and(p, cb.equal(root.get(AppInfo_.documentType), documentType));
 		}
 		}
 		cq.select(root.get(AppInfo_.id));
 		cq.select(root.get(AppInfo_.id));
@@ -510,6 +514,7 @@ public class AppInfoFactory extends AbstractFactory {
 		Root<AppInfo> root = cq.from(AppInfo.class);
 		Root<AppInfo> root = cq.from(AppInfo.class);
 		Predicate p = cb.isNull( root.get(AppInfo_.appType) );
 		Predicate p = cb.isNull( root.get(AppInfo_.appType) );
 		p = cb.or( p, cb.equal( root.get(AppInfo_.appType), ""));
 		p = cb.or( p, cb.equal( root.get(AppInfo_.appType), ""));
+		p = cb.or( p, cb.equal( root.get(AppInfo_.appType), "未分类"));
 		cq.select(cb.count(root));
 		cq.select(cb.count(root));
 		return em.createQuery(cq.where(p)).getSingleResult();
 		return em.createQuery(cq.where(p)).getSingleResult();
 	}
 	}

+ 25 - 23
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/factory/CategoryInfoFactory.java

@@ -4,6 +4,7 @@ import java.util.ArrayList;
 import java.util.List;
 import java.util.List;
 
 
 import javax.persistence.EntityManager;
 import javax.persistence.EntityManager;
+import javax.persistence.TypedQuery;
 import javax.persistence.criteria.CriteriaBuilder;
 import javax.persistence.criteria.CriteriaBuilder;
 import javax.persistence.criteria.CriteriaQuery;
 import javax.persistence.criteria.CriteriaQuery;
 import javax.persistence.criteria.Predicate;
 import javax.persistence.criteria.Predicate;
@@ -79,33 +80,37 @@ public class CategoryInfoFactory extends AbstractFactory {
 		CriteriaBuilder cb = em.getCriteriaBuilder();
 		CriteriaBuilder cb = em.getCriteriaBuilder();
 		CriteriaQuery<String> cq = cb.createQuery( String.class );
 		CriteriaQuery<String> cq = cb.createQuery( String.class );
 		Root<CategoryInfo> root = cq.from( CategoryInfo.class );
 		Root<CategoryInfo> root = cq.from( CategoryInfo.class );
-		cq.select(root.get( CategoryInfo_.id));
+		cq.select(root.get( CategoryInfo_.id));		
+		TypedQuery<String> query = null;
 		if( manager ) {
 		if( manager ) {
 			if( ListTools.isEmpty( appIds )) {
 			if( ListTools.isEmpty( appIds )) {
-				if( StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType )) {
-					Predicate p = cb.equal( root.get( CategoryInfo_.documentType ), documentType );
-					return em.createQuery( cq.where( p ) ).setMaxResults(maxCount).getResultList();
+				if( StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType)&& !"all".equalsIgnoreCase(documentType)) {
+					Predicate p = cb.equal( root.get( CategoryInfo_.documentType ), documentType );					
+					query = em.createQuery( cq.where( p ) ).setMaxResults(maxCount);
 				}else {
 				}else {
-					return em.createQuery( cq ).setMaxResults(maxCount).getResultList();
+					query =  em.createQuery( cq ).setMaxResults(maxCount);
 				}
 				}
 			}else {
 			}else {
 				Predicate p = root.get( CategoryInfo_.appId ).in(appIds);
 				Predicate p = root.get( CategoryInfo_.appId ).in(appIds);
-				if( StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType ) ) {
+				if( StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType)&& !"all".equalsIgnoreCase(documentType) ) {
 					p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType ), documentType ));
 					p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType ), documentType ));
 				}
 				}
-				return em.createQuery( cq.where(p) ).setMaxResults(maxCount).getResultList();
+				query = em.createQuery( cq.where(p) ).setMaxResults(maxCount);
 			}
 			}
 		}else {
 		}else {
 			if( ListTools.isEmpty( appIds )) {
 			if( ListTools.isEmpty( appIds )) {
 				return new ArrayList<>();
 				return new ArrayList<>();
 			}else {
 			}else {
 				Predicate p = root.get( CategoryInfo_.appId ).in(appIds);
 				Predicate p = root.get( CategoryInfo_.appId ).in(appIds);
-				if( StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType )) {
+				if( StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType)&& !"all".equalsIgnoreCase(documentType)) {
 					p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType ), documentType ));
 					p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType ), documentType ));
 				}
 				}
-				return em.createQuery( cq.where(p) ).setMaxResults(maxCount).getResultList();
+				query = em.createQuery( cq.where(p) ).setMaxResults(maxCount);
 			}
 			}
 		}
 		}
+		
+		//System.out.println(">>>>>>>>>>>listByAppIds SQL:" +query.toString() );
+		return query.getResultList();
 	}
 	}
 	
 	
 	public List<CategoryInfo> listCategoryByAppId( String appId, String documentType, Integer maxCount ) throws Exception {
 	public List<CategoryInfo> listCategoryByAppId( String appId, String documentType, Integer maxCount ) throws Exception {
@@ -114,7 +119,7 @@ public class CategoryInfoFactory extends AbstractFactory {
 		CriteriaQuery<CategoryInfo> cq = cb.createQuery( CategoryInfo.class );
 		CriteriaQuery<CategoryInfo> cq = cb.createQuery( CategoryInfo.class );
 		Root<CategoryInfo> root = cq.from( CategoryInfo.class );
 		Root<CategoryInfo> root = cq.from( CategoryInfo.class );
 		Predicate p = cb.equal(root.get( CategoryInfo_.appId ), appId );
 		Predicate p = cb.equal(root.get( CategoryInfo_.appId ), appId );
-		if( StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType )) {
+		if( StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType)&& !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType ), documentType ));
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType ), documentType ));
 		}
 		}
 		return em.createQuery( cq.where(p) ).setMaxResults(maxCount).getResultList();
 		return em.createQuery( cq.where(p) ).setMaxResults(maxCount).getResultList();
@@ -127,7 +132,7 @@ public class CategoryInfoFactory extends AbstractFactory {
 		CriteriaQuery<Long> cq = cb.createQuery(Long.class);
 		CriteriaQuery<Long> cq = cb.createQuery(Long.class);
 		Root<CategoryInfo> root = cq.from(CategoryInfo.class);
 		Root<CategoryInfo> root = cq.from(CategoryInfo.class);
 		Predicate p = cb.equal( root.get(CategoryInfo_.appId), appId );
 		Predicate p = cb.equal( root.get(CategoryInfo_.appId), appId );
-		if( StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType )) {
+		if( StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType)&& !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType ), documentType ));
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType ), documentType ));
 		}
 		}
 		cq.select(cb.count(root));
 		cq.select(cb.count(root));
@@ -156,15 +161,13 @@ public class CategoryInfoFactory extends AbstractFactory {
 		Root<CategoryInfo> root = cq.from( CategoryInfo.class);
 		Root<CategoryInfo> root = cq.from( CategoryInfo.class);
 		Predicate p = cb.like(root.get( CategoryInfo_.categoryName ), "%" + str + "%", '\\');
 		Predicate p = cb.like(root.get( CategoryInfo_.categoryName ), "%" + str + "%", '\\');
 		p = cb.or(p, cb.like(root.get( CategoryInfo_.categoryAlias ), str + "%", '\\'));
 		p = cb.or(p, cb.like(root.get( CategoryInfo_.categoryAlias ), str + "%", '\\'));
-		if( StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType )) {
+		if( StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType)&& !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType ), documentType ));
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType ), documentType ));
 		}
 		}
 		cq.select(root.get( CategoryInfo_.id));
 		cq.select(root.get( CategoryInfo_.id));
 		return em.createQuery(cq.where(p)).setMaxResults(200).getResultList();
 		return em.createQuery(cq.where(p)).setMaxResults(200).getResultList();
 	}
 	}
 	
 	
-	
-
 	public List<String> listMyCategoryWithAppId( List<String> myCategoryIds, String documentType, String appId ) throws Exception {
 	public List<String> listMyCategoryWithAppId( List<String> myCategoryIds, String documentType, String appId ) throws Exception {
 		EntityManager em = this.entityManagerContainer().get( CategoryInfo.class );
 		EntityManager em = this.entityManagerContainer().get( CategoryInfo.class );
 		CriteriaBuilder cb = em.getCriteriaBuilder();
 		CriteriaBuilder cb = em.getCriteriaBuilder();
@@ -175,7 +178,7 @@ public class CategoryInfoFactory extends AbstractFactory {
 		if( myCategoryIds != null && !myCategoryIds.isEmpty() ){
 		if( myCategoryIds != null && !myCategoryIds.isEmpty() ){
 			p = cb.and( p, root.get( CategoryInfo_.id ).in( myCategoryIds ) );
 			p = cb.and( p, root.get( CategoryInfo_.id ).in( myCategoryIds ) );
 		}
 		}
-		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType)) {
+		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType), documentType));
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType), documentType));
 		}
 		}
 		return em.createQuery(cq.where( p )).getResultList();
 		return em.createQuery(cq.where( p )).getResultList();
@@ -239,7 +242,7 @@ public class CategoryInfoFactory extends AbstractFactory {
 			}else {
 			}else {
 				p_filter = cb.and( p_filter, root.get( CategoryInfo_.id ).in( inCategoryIds ));
 				p_filter = cb.and( p_filter, root.get( CategoryInfo_.id ).in( inCategoryIds ));
 			}
 			}
-		}		
+		}
 		//排除指定的ID列表
 		//排除指定的ID列表
 		if( ListTools.isNotEmpty( excludCategoryIds )) {
 		if( ListTools.isNotEmpty( excludCategoryIds )) {
 			if( p_filter == null ) {
 			if( p_filter == null ) {
@@ -247,8 +250,7 @@ public class CategoryInfoFactory extends AbstractFactory {
 			}else {
 			}else {
 				p_filter = cb.and( p_filter, cb.not( root.get( CategoryInfo_.id ).in( excludCategoryIds )));
 				p_filter = cb.and( p_filter, cb.not( root.get( CategoryInfo_.id ).in( excludCategoryIds )));
 			}
 			}
-		}
-		
+		}		
 		Predicate p_permission = null;
 		Predicate p_permission = null;
 		if( StringUtils.isNotEmpty( personName )) {
 		if( StringUtils.isNotEmpty( personName )) {
 			//可以管理的栏目,肯定可以发布信息
 			//可以管理的栏目,肯定可以发布信息
@@ -283,7 +285,7 @@ public class CategoryInfoFactory extends AbstractFactory {
 				p = p_permission;
 				p = p_permission;
 			}
 			}
 		}
 		}
-		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType)) {
+		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType)&& !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType), documentType));
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType), documentType));
 		}
 		}
 		cq.select(root.get( CategoryInfo_.id ));
 		cq.select(root.get( CategoryInfo_.id ));
@@ -371,7 +373,7 @@ public class CategoryInfoFactory extends AbstractFactory {
 				p = p_permission;
 				p = p_permission;
 			}
 			}
 		}
 		}
-		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType)) {
+		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType), documentType));
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType), documentType));
 		}
 		}
 		cq.select(root.get( CategoryInfo_.id ));
 		cq.select(root.get( CategoryInfo_.id ));
@@ -403,7 +405,7 @@ public class CategoryInfoFactory extends AbstractFactory {
 		if( ListTools.isNotEmpty( excludCategoryIds )) {
 		if( ListTools.isNotEmpty( excludCategoryIds )) {
 			p = cb.and( p, cb.not( root.get( CategoryInfo_.id ).in( excludCategoryIds )));
 			p = cb.and( p, cb.not( root.get( CategoryInfo_.id ).in( excludCategoryIds )));
 		}
 		}
-		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType)) {
+		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType), documentType));
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType), documentType));
 		}
 		}
 		return em.createQuery(cq.where( p )).setMaxResults(maxCount).getResultList();
 		return em.createQuery(cq.where( p )).setMaxResults(maxCount).getResultList();
@@ -439,7 +441,7 @@ public class CategoryInfoFactory extends AbstractFactory {
 			p = cb.and( p, cb.not( root.get( CategoryInfo_.id ).in( excludCategoryIds )));
 			p = cb.and( p, cb.not( root.get( CategoryInfo_.id ).in( excludCategoryIds )));
 		}
 		}
 		p = cb.and( p, p_all );
 		p = cb.and( p, p_all );
-		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType)) {
+		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType), documentType));
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType), documentType));
 		}
 		}
 		return em.createQuery(cq.where( p )).setMaxResults(maxCount).getResultList();
 		return em.createQuery(cq.where( p )).setMaxResults(maxCount).getResultList();
@@ -472,7 +474,7 @@ public class CategoryInfoFactory extends AbstractFactory {
 			p = cb.or( p,  root.get( CategoryInfo_.manageableGroupList).in(groupNames));
 			p = cb.or( p,  root.get( CategoryInfo_.manageableGroupList).in(groupNames));
 		}
 		}
 		cq.select(root.get( CategoryInfo_.id ));
 		cq.select(root.get( CategoryInfo_.id ));
-		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType)) {
+		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType) && !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType), documentType));
 			p = cb.and( p, cb.equal( root.get( CategoryInfo_.documentType), documentType));
 		}
 		}
 		return em.createQuery( cq.where( p ) ).setMaxResults(maxCount).getResultList();
 		return em.createQuery( cq.where( p ) ).setMaxResults(maxCount).getResultList();

+ 2 - 2
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/factory/DocumentFactory.java

@@ -64,7 +64,7 @@ public class DocumentFactory extends AbstractFactory {
 		Root<Document> root = cq.from( Document.class );
 		Root<Document> root = cq.from( Document.class );
 		Predicate p = cb.equal(root.get( Document_.appId ), appId );
 		Predicate p = cb.equal(root.get( Document_.appId ), appId );
 		cq.select( root.get( Document_.id) ).where(p);
 		cq.select( root.get( Document_.id) ).where(p);
-		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType)) {
+		if( StringUtils.isNotEmpty( documentType) && !"全部".equals(documentType)&& !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and( p, cb.equal( root.get( Document_.documentType), documentType));
 			p = cb.and( p, cb.equal( root.get( Document_.documentType), documentType));
 		}
 		}
 		return em.createQuery( cq ).setMaxResults(maxCount).getResultList();
 		return em.createQuery( cq ).setMaxResults(maxCount).getResultList();
@@ -332,7 +332,7 @@ public class DocumentFactory extends AbstractFactory {
 		if(ListTools.isNotEmpty( categoryIdList )) {
 		if(ListTools.isNotEmpty( categoryIdList )) {
 			p = cb.and( p, root.get( Document_.categoryId ).in( categoryIdList ));
 			p = cb.and( p, root.get( Document_.categoryId ).in( categoryIdList ));
 		}
 		}
-		if(StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType)) {
+		if(StringUtils.isNotEmpty( documentType ) && !"全部".equals(documentType)&& !"all".equalsIgnoreCase(documentType)) {
 			p = cb.and( p, cb.equal( root.get( Document_.documentType ), documentType));
 			p = cb.and( p, cb.equal( root.get( Document_.documentType ), documentType));
 		}
 		}
 		return em.createQuery(cq.where(p)).getResultList();
 		return em.createQuery(cq.where(p)).getResultList();

+ 2 - 2
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionGetPublishableAppInfo.java

@@ -46,7 +46,7 @@ public class ActionGetPublishableAppInfo extends BaseAction {
 			if (check) {
 			if (check) {
 				if ( isXAdmin ) { // 如果用户管理系统管理,则获取所有的栏目和分类信息
 				if ( isXAdmin ) { // 如果用户管理系统管理,则获取所有的栏目和分类信息
 					try {
 					try {
-						wos = listPublishAbleAppInfoByPermission( personName, isAnonymous, null, "全部", isXAdmin, 1000 );
+						wos = listPublishAbleAppInfoByPermission( personName, isAnonymous, null, "all", "全部", isXAdmin, 1000 );
 					} catch (Exception e) {
 					} catch (Exception e) {
 						check = false;
 						check = false;
 						Exception exception = new ExceptionAppInfoProcess(e,
 						Exception exception = new ExceptionAppInfoProcess(e,
@@ -56,7 +56,7 @@ public class ActionGetPublishableAppInfo extends BaseAction {
 					}
 					}
 				} else {
 				} else {
 					try {
 					try {
-						wos_out = listPublishAbleAppInfoByPermission( personName, isAnonymous, null, "全部", isXAdmin, 1000 );
+						wos_out = listPublishAbleAppInfoByPermission( personName, isAnonymous, null,  "all", "全部", isXAdmin, 1000 );
 						for( Wo wo : wos_out ) {
 						for( Wo wo : wos_out ) {
 							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
 							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
 								wos.add( wo );
 								wos.add( wo );

+ 3 - 1
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListAllAppType.java

@@ -44,7 +44,9 @@ public class ActionListAllAppType extends BaseAction {
 			if( check ){
 			if( check ){
 				if( appTypes != null && !appTypes.isEmpty() ){
 				if( appTypes != null && !appTypes.isEmpty() ){
 					for( String type : appTypes ) {
 					for( String type : appTypes ) {
-						wos.add( new Wo( type, appInfoServiceAdv.countAppInfoWithAppType( type )));
+						if( !"未分类".equals( type )) {
+							wos.add( new Wo( type, appInfoServiceAdv.countAppInfoWithAppType( type )));
+						}
 					}
 					}
 				}
 				}
 				
 				

+ 2 - 2
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanManageWithAppType.java → o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanManage_WithAppType.java

@@ -17,9 +17,9 @@ import com.x.cms.core.entity.CategoryInfo;
 
 
 import net.sf.ehcache.Element;
 import net.sf.ehcache.Element;
 
 
-public class ActionListWhatICanManageWithAppType extends BaseAction {
+public class ActionListWhatICanManage_WithAppType extends BaseAction {
 
 
-	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanManageWithAppType.class);
+	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanManage_WithAppType.class);
 
 
 	@SuppressWarnings("unchecked")
 	@SuppressWarnings("unchecked")
 	protected ActionResult<List<Wo>> execute( HttpServletRequest request, EffectivePerson effectivePerson, String appType ) throws Exception {
 	protected ActionResult<List<Wo>> execute( HttpServletRequest request, EffectivePerson effectivePerson, String appType ) throws Exception {

+ 4 - 4
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanPublish.java

@@ -20,7 +20,7 @@ public class ActionListWhatICanPublish extends BaseAction {
 	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanPublish.class);
 	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanPublish.class);
 
 
 	@SuppressWarnings("unchecked")
 	@SuppressWarnings("unchecked")
-	protected ActionResult<List<Wo>> execute(HttpServletRequest request, EffectivePerson effectivePerson ) throws Exception {
+	protected ActionResult<List<Wo>> execute( HttpServletRequest request, EffectivePerson effectivePerson ) throws Exception {
 		ActionResult<List<Wo>> result = new ActionResult<>();
 		ActionResult<List<Wo>> result = new ActionResult<>();
 		List<Wo> wos = new ArrayList<>();
 		List<Wo> wos = new ArrayList<>();
 		List<Wo> wos_out = new ArrayList<>();
 		List<Wo> wos_out = new ArrayList<>();
@@ -38,7 +38,7 @@ public class ActionListWhatICanPublish extends BaseAction {
 			logger.error(e, effectivePerson, request, null);
 			logger.error(e, effectivePerson, request, null);
 		}
 		}
 		
 		
-		String cacheKey = ApplicationCache.concreteCacheKey(personName, "publish", isXAdmin);
+		String cacheKey = ApplicationCache.concreteCacheKey( personName,  "all", "publish", isXAdmin);
 		Element element = cache.get(cacheKey);
 		Element element = cache.get(cacheKey);
 
 
 		if ((null != element) && (null != element.getObjectValue())) {
 		if ((null != element) && (null != element.getObjectValue())) {
@@ -48,7 +48,7 @@ public class ActionListWhatICanPublish extends BaseAction {
 			if (check) {
 			if (check) {
 				if ( isXAdmin ) { // 如果用户管理系统管理,则获取所有的栏目和分类信息
 				if ( isXAdmin ) { // 如果用户管理系统管理,则获取所有的栏目和分类信息
 					try {
 					try {
-						wos = listPublishAbleAppInfoByPermission( personName, isAnonymous, null, "全部", isXAdmin, 1000 );
+						wos = listPublishAbleAppInfoByPermission( personName, isAnonymous, null,  "all", "全部", isXAdmin, 1000 );
 					} catch (Exception e) {
 					} catch (Exception e) {
 						check = false;
 						check = false;
 						Exception exception = new ExceptionAppInfoProcess(e,
 						Exception exception = new ExceptionAppInfoProcess(e,
@@ -58,7 +58,7 @@ public class ActionListWhatICanPublish extends BaseAction {
 					}
 					}
 				} else {
 				} else {
 					try {
 					try {
-						wos_out = listPublishAbleAppInfoByPermission( personName, isAnonymous, null, "全部", isXAdmin, 1000 );
+						wos_out = listPublishAbleAppInfoByPermission( personName, isAnonymous, null,  "all", "全部", isXAdmin, 1000 );
 						for( Wo wo : wos_out ) {
 						for( Wo wo : wos_out ) {
 							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
 							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
 								wos.add( wo );
 								wos.add( wo );

+ 87 - 0
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanPublish_WithAppType.java

@@ -0,0 +1,87 @@
+package com.x.cms.assemble.control.jaxrs.appinfo;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.servlet.http.HttpServletRequest;
+
+import com.x.base.core.project.cache.ApplicationCache;
+import com.x.base.core.project.http.ActionResult;
+import com.x.base.core.project.http.EffectivePerson;
+import com.x.base.core.project.logger.Logger;
+import com.x.base.core.project.logger.LoggerFactory;
+import com.x.base.core.project.tools.ListTools;
+import com.x.base.core.project.tools.SortTools;
+
+import net.sf.ehcache.Element;
+
+public class ActionListWhatICanPublish_WithAppType extends BaseAction {
+
+	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanPublish_WithAppType.class);
+
+	@SuppressWarnings("unchecked")
+	protected ActionResult<List<Wo>> execute(HttpServletRequest request, EffectivePerson effectivePerson, String appType ) throws Exception {
+		ActionResult<List<Wo>> result = new ActionResult<>();
+		List<Wo> wos = new ArrayList<>();
+		List<Wo> wos_out = new ArrayList<>();
+		Boolean isXAdmin = false;
+		Boolean check = true;
+		Boolean isAnonymous = effectivePerson.isAnonymous();
+		String personName = effectivePerson.getDistinguishedName();
+
+		try {
+			isXAdmin = userManagerService.isManager(request, effectivePerson );
+		} catch (Exception e) {
+			check = false;
+			Exception exception = new ExceptionAppInfoProcess(e, "系统在检查用户是否是平台管理员时发生异常。Name:" + personName);
+			result.error(exception);
+			logger.error(e, effectivePerson, request, null);
+		}
+		
+		String cacheKey = ApplicationCache.concreteCacheKey( personName, appType, "publish", isXAdmin);
+		Element element = cache.get(cacheKey);
+
+		if ((null != element) && (null != element.getObjectValue())) {
+			wos = (List<Wo>) element.getObjectValue();
+			result.setData( wos );
+		} else {
+			if (check) {
+				if ( isXAdmin ) { // 如果用户管理系统管理,则获取所有的栏目和分类信息
+					try {
+						wos = listPublishAbleAppInfoByPermission( personName, isAnonymous, null, appType, "全部", isXAdmin, 1000 );
+					} catch (Exception e) {
+						check = false;
+						Exception exception = new ExceptionAppInfoProcess(e,
+								"系统在根据用户权限查询所有可见的分类信息时发生异常。Name:" + personName);
+						result.error(exception);
+						logger.error(e, effectivePerson, request, null);
+					}
+				} else {
+					try {
+						wos_out = listPublishAbleAppInfoByPermission( personName, isAnonymous, null, appType, "全部", isXAdmin, 1000 );
+						for( Wo wo : wos_out ) {
+							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
+								wos.add( wo );
+							}
+						}
+					} catch (Exception e) {
+						check = false;
+						Exception exception = new ExceptionAppInfoProcess(e,
+								"系统在根据用户权限查询所有可见的分类信息时发生异常。Name:" + personName);
+						result.error(exception);
+						logger.error(e, effectivePerson, request, null);
+					}
+				}
+			}
+			if (check) {
+				if(ListTools.isNotEmpty( wos)) {
+					SortTools.asc( wos, "appInfoSeq");
+				}
+				cache.put(new Element( cacheKey, wos ));
+				result.setData( wos );
+			}
+		}
+		return result;
+	}
+
+}

+ 4 - 4
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanView_AllType.java → o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanViewAllDocType.java

@@ -15,9 +15,9 @@ import com.x.base.core.project.tools.SortTools;
 
 
 import net.sf.ehcache.Element;
 import net.sf.ehcache.Element;
 
 
-public class ActionListWhatICanView_AllType extends BaseAction {
+public class ActionListWhatICanViewAllDocType extends BaseAction {
 
 
-	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanView_AllType.class);
+	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanViewAllDocType.class);
 
 
 	@SuppressWarnings("unchecked")
 	@SuppressWarnings("unchecked")
 	protected ActionResult<List<Wo>> execute(HttpServletRequest request, EffectivePerson effectivePerson)
 	protected ActionResult<List<Wo>> execute(HttpServletRequest request, EffectivePerson effectivePerson)
@@ -49,7 +49,7 @@ public class ActionListWhatICanView_AllType extends BaseAction {
 			if (check) {
 			if (check) {
 				if (isXAdmin) {
 				if (isXAdmin) {
 					try {
 					try {
-						wos = listViewAbleAppInfoByPermission( personName, isAnonymous, null, "全部", isXAdmin, 1000 );
+						wos = listViewAbleAppInfoByPermission( personName, isAnonymous, null,  "all", "全部", isXAdmin, 1000 );
 					} catch (Exception e) {
 					} catch (Exception e) {
 						check = false;
 						check = false;
 						Exception exception = new ExceptionAppInfoProcess(e, "系统查询所有可见的分类信息时发生异常[管理员]。Name:" + personName);
 						Exception exception = new ExceptionAppInfoProcess(e, "系统查询所有可见的分类信息时发生异常[管理员]。Name:" + personName);
@@ -58,7 +58,7 @@ public class ActionListWhatICanView_AllType extends BaseAction {
 					}
 					}
 				} else {
 				} else {
 					try {
 					try {
-						wos_out = listViewAbleAppInfoByPermission( personName, isAnonymous, null, "全部", isXAdmin, 1000 );
+						wos_out = listViewAbleAppInfoByPermission( personName, isAnonymous, null,  "all", "全部", isXAdmin, 1000 );
 						for( Wo wo : wos_out ) {
 						for( Wo wo : wos_out ) {
 							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
 							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
 								wos.add( wo );
 								wos.add( wo );

+ 83 - 0
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanViewAllDocType_WithAppType.java

@@ -0,0 +1,83 @@
+package com.x.cms.assemble.control.jaxrs.appinfo;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.servlet.http.HttpServletRequest;
+
+import com.x.base.core.project.cache.ApplicationCache;
+import com.x.base.core.project.http.ActionResult;
+import com.x.base.core.project.http.EffectivePerson;
+import com.x.base.core.project.logger.Logger;
+import com.x.base.core.project.logger.LoggerFactory;
+import com.x.base.core.project.tools.ListTools;
+import com.x.base.core.project.tools.SortTools;
+
+import net.sf.ehcache.Element;
+
+public class ActionListWhatICanViewAllDocType_WithAppType extends BaseAction {
+
+	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanViewAllDocType_WithAppType.class);
+
+	@SuppressWarnings("unchecked")
+	protected ActionResult<List<Wo>> execute(HttpServletRequest request, EffectivePerson effectivePerson, String appType )
+			throws Exception {
+		ActionResult<List<Wo>> result = new ActionResult<>();
+		List<Wo> wos = new ArrayList<>();
+		List<Wo> wos_out = new ArrayList<>();
+		Boolean isXAdmin = false;
+		Boolean check = true;
+		Boolean isAnonymous = effectivePerson.isAnonymous();
+		String personName = effectivePerson.getDistinguishedName();
+		
+		try {
+			isXAdmin = userManagerService.isManager(request, effectivePerson );
+		} catch (Exception e) {
+			check = false;
+			Exception exception = new ExceptionAppInfoProcess(e, "系统在检查用户是否是平台管理员时发生异常。Name:" + personName);
+			result.error(exception);
+			logger.error(e, effectivePerson, request, null);
+		}
+		
+		String cacheKey = ApplicationCache.concreteCacheKey(personName, appType, "AllType", isXAdmin);
+		Element element = cache.get(cacheKey);
+
+		if ((null != element) && (null != element.getObjectValue())) {
+			wos = (List<Wo>) element.getObjectValue();
+			result.setData(wos);
+		} else {
+			if (check) {
+				if (isXAdmin) {
+					try {
+						wos = listViewAbleAppInfoByPermission( personName, isAnonymous, null, appType, "全部", isXAdmin, 1000 );
+					} catch (Exception e) {
+						check = false;
+						Exception exception = new ExceptionAppInfoProcess(e, "系统查询所有可见的分类信息时发生异常[管理员]。Name:" + personName);
+						result.error(exception);
+						logger.error(e, effectivePerson, request, null);
+					}
+				} else {
+					try {
+						wos_out = listViewAbleAppInfoByPermission( personName, isAnonymous, null, appType, "全部", isXAdmin, 1000 );
+						for( Wo wo : wos_out ) {
+							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
+								wos.add( wo );
+							}
+						}
+					} catch (Exception e) {
+						check = false;
+						Exception exception = new ExceptionAppInfoProcess(e, "系统在根据用户权限查询所有可见的分类信息时发生异常。Name:" + personName);
+						result.error(exception);
+						logger.error(e, effectivePerson, request, null);
+					}
+				}
+			}
+		}
+		if(ListTools.isNotEmpty( wos)) {
+			SortTools.asc( wos, "appInfoSeq");
+		}
+		cache.put(new Element( cacheKey, wos ));
+		result.setData(wos);
+		return result;
+	}
+}

+ 5 - 5
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanView_Article.java → o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanViewArticle.java

@@ -15,9 +15,9 @@ import com.x.base.core.project.tools.SortTools;
 
 
 import net.sf.ehcache.Element;
 import net.sf.ehcache.Element;
 
 
-public class ActionListWhatICanView_Article extends BaseAction {
+public class ActionListWhatICanViewArticle extends BaseAction {
 
 
-	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanView_Article.class);
+	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanViewArticle.class);
 
 
 	@SuppressWarnings("unchecked")
 	@SuppressWarnings("unchecked")
 	protected ActionResult<List<Wo>> execute(HttpServletRequest request, EffectivePerson effectivePerson)
 	protected ActionResult<List<Wo>> execute(HttpServletRequest request, EffectivePerson effectivePerson)
@@ -43,7 +43,7 @@ public class ActionListWhatICanView_Article extends BaseAction {
 			logger.error(e, effectivePerson, request, null);
 			logger.error(e, effectivePerson, request, null);
 		}
 		}
 		
 		
-		String cacheKey = ApplicationCache.concreteCacheKey(personName, "Article", isXAdmin);
+		String cacheKey = ApplicationCache.concreteCacheKey(personName,  "all", "Article", isXAdmin);
 		Element element = cache.get(cacheKey);
 		Element element = cache.get(cacheKey);
 
 
 		if ((null != element) && (null != element.getObjectValue())) {
 		if ((null != element) && (null != element.getObjectValue())) {
@@ -53,7 +53,7 @@ public class ActionListWhatICanView_Article extends BaseAction {
 			if (check) {
 			if (check) {
 				if (isXAdmin) {
 				if (isXAdmin) {
 					try {
 					try {
-						wos = listViewAbleAppInfoByPermission( personName, isAnonymous, null, "信息", isXAdmin, 1000 );
+						wos = listViewAbleAppInfoByPermission( personName, isAnonymous, null,  "all", "信息", isXAdmin, 1000 );
 					} catch (Exception e) {
 					} catch (Exception e) {
 						check = false;
 						check = false;
 						Exception exception = new ExceptionAppInfoProcess(e, "系统查询所有可见的分类信息时发生异常[管理员]。Name:" + personName);
 						Exception exception = new ExceptionAppInfoProcess(e, "系统查询所有可见的分类信息时发生异常[管理员]。Name:" + personName);
@@ -62,7 +62,7 @@ public class ActionListWhatICanView_Article extends BaseAction {
 					}
 					}
 				} else {
 				} else {
 					try {
 					try {
-						wos_out = listViewAbleAppInfoByPermission( personName, isAnonymous, null, "信息", isXAdmin, 1000 );
+						wos_out = listViewAbleAppInfoByPermission( personName, isAnonymous, null,  "all", "信息", isXAdmin, 1000 );
 						for( Wo wo : wos_out ) {
 						for( Wo wo : wos_out ) {
 							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
 							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
 								wos.add( wo );
 								wos.add( wo );

+ 88 - 0
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanViewArticle_WithAppType.java

@@ -0,0 +1,88 @@
+package com.x.cms.assemble.control.jaxrs.appinfo;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.servlet.http.HttpServletRequest;
+
+import com.x.base.core.project.cache.ApplicationCache;
+import com.x.base.core.project.http.ActionResult;
+import com.x.base.core.project.http.EffectivePerson;
+import com.x.base.core.project.logger.Logger;
+import com.x.base.core.project.logger.LoggerFactory;
+import com.x.base.core.project.tools.ListTools;
+import com.x.base.core.project.tools.SortTools;
+
+import net.sf.ehcache.Element;
+
+public class ActionListWhatICanViewArticle_WithAppType extends BaseAction {
+
+	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanViewArticle_WithAppType.class);
+
+	@SuppressWarnings("unchecked")
+	protected ActionResult<List<Wo>> execute(HttpServletRequest request, EffectivePerson effectivePerson, String appType )
+			throws Exception {
+		ActionResult<List<Wo>> result = new ActionResult<>();
+		List<Wo> wos = new ArrayList<>();
+		List<Wo> wos_out = new ArrayList<>();
+		Boolean isXAdmin = false;
+		Boolean check = true;
+		Boolean isAnonymous = effectivePerson.isAnonymous();
+		String personName = effectivePerson.getDistinguishedName();
+		
+		if( "xadmin".equalsIgnoreCase( effectivePerson.getName() ) ) {
+			personName = "xadmin";
+		}
+		
+		try {
+			isXAdmin = userManagerService.isManager(request, effectivePerson );
+		} catch (Exception e) {
+			check = false;
+			Exception exception = new ExceptionAppInfoProcess(e, "系统在检查用户是否是平台管理员时发生异常。Name:" + personName);
+			result.error(exception);
+			logger.error(e, effectivePerson, request, null);
+		}
+		
+		String cacheKey = ApplicationCache.concreteCacheKey(personName, "Article", appType, isXAdmin);
+		Element element = cache.get(cacheKey);
+
+		if ((null != element) && (null != element.getObjectValue())) {
+			wos = (List<Wo>) element.getObjectValue();
+			result.setData(wos);
+		} else {
+			if (check) {
+				if (isXAdmin) {
+					try {
+						wos = listViewAbleAppInfoByPermission( personName, isAnonymous, null, appType, "信息", isXAdmin, 1000 );
+					} catch (Exception e) {
+						check = false;
+						Exception exception = new ExceptionAppInfoProcess(e, "系统查询所有可见的分类信息时发生异常[管理员]。Name:" + personName);
+						result.error(exception);
+						logger.error(e, effectivePerson, request, null);
+					}
+				} else {
+					try {
+						wos_out = listViewAbleAppInfoByPermission( personName, isAnonymous, null, appType, "信息", isXAdmin, 1000 );
+						for( Wo wo : wos_out ) {
+							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
+								wos.add( wo );
+							}
+						}
+					} catch (Exception e) {
+						check = false;
+						Exception exception = new ExceptionAppInfoProcess(e,
+								"系统在根据用户权限查询所有可见的分类信息时发生异常。Name:" + personName);
+						result.error(exception);
+						logger.error(e, effectivePerson, request, null);
+					}
+				}
+			}
+		}
+		if(ListTools.isNotEmpty( wos)) {
+			SortTools.asc( wos, "appInfoSeq");
+		}
+		cache.put(new Element( cacheKey, wos ));
+		result.setData(wos);
+		return result;
+	}
+}

+ 5 - 5
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanView_Data.java → o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanViewData.java

@@ -15,9 +15,9 @@ import com.x.base.core.project.tools.SortTools;
 
 
 import net.sf.ehcache.Element;
 import net.sf.ehcache.Element;
 
 
-public class ActionListWhatICanView_Data extends BaseAction {
+public class ActionListWhatICanViewData extends BaseAction {
 
 
-	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanView_Data.class);
+	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanViewData.class);
 
 
 	@SuppressWarnings("unchecked")
 	@SuppressWarnings("unchecked")
 	protected ActionResult<List<Wo>> execute(HttpServletRequest request, EffectivePerson effectivePerson)
 	protected ActionResult<List<Wo>> execute(HttpServletRequest request, EffectivePerson effectivePerson)
@@ -39,7 +39,7 @@ public class ActionListWhatICanView_Data extends BaseAction {
 			logger.error(e, effectivePerson, request, null);
 			logger.error(e, effectivePerson, request, null);
 		}
 		}
 		
 		
-		String cacheKey = ApplicationCache.concreteCacheKey(personName, "Data", isXAdmin);
+		String cacheKey = ApplicationCache.concreteCacheKey(personName,  "all", "Data", isXAdmin);
 		Element element = cache.get(cacheKey);
 		Element element = cache.get(cacheKey);
 
 
 		if ((null != element) && (null != element.getObjectValue())) {
 		if ((null != element) && (null != element.getObjectValue())) {
@@ -49,7 +49,7 @@ public class ActionListWhatICanView_Data extends BaseAction {
 			if (check) {
 			if (check) {
 				if (isXAdmin) {
 				if (isXAdmin) {
 					try {
 					try {
-						wos = listViewAbleAppInfoByPermission( personName, isAnonymous, null, "数据", isXAdmin, 1000 );
+						wos = listViewAbleAppInfoByPermission( personName, isAnonymous, null,  "all", "数据", isXAdmin, 1000 );
 					} catch (Exception e) {
 					} catch (Exception e) {
 						check = false;
 						check = false;
 						Exception exception = new ExceptionAppInfoProcess(e, "系统查询所有可见的分类信息时发生异常[管理员]。Name:" + personName);
 						Exception exception = new ExceptionAppInfoProcess(e, "系统查询所有可见的分类信息时发生异常[管理员]。Name:" + personName);
@@ -58,7 +58,7 @@ public class ActionListWhatICanView_Data extends BaseAction {
 					}
 					}
 				} else {
 				} else {
 					try {
 					try {
-						wos_out = listViewAbleAppInfoByPermission( personName, isAnonymous, null, "数据", isXAdmin, 1000 );
+						wos_out = listViewAbleAppInfoByPermission( personName, isAnonymous, null,  "all", "数据", isXAdmin, 1000 );
 						for( Wo wo : wos_out ) {
 						for( Wo wo : wos_out ) {
 							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
 							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
 								wos.add( wo );
 								wos.add( wo );

+ 84 - 0
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/ActionListWhatICanViewData_WithAppType.java

@@ -0,0 +1,84 @@
+package com.x.cms.assemble.control.jaxrs.appinfo;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.servlet.http.HttpServletRequest;
+
+import com.x.base.core.project.cache.ApplicationCache;
+import com.x.base.core.project.http.ActionResult;
+import com.x.base.core.project.http.EffectivePerson;
+import com.x.base.core.project.logger.Logger;
+import com.x.base.core.project.logger.LoggerFactory;
+import com.x.base.core.project.tools.ListTools;
+import com.x.base.core.project.tools.SortTools;
+
+import net.sf.ehcache.Element;
+
+public class ActionListWhatICanViewData_WithAppType extends BaseAction {
+
+	private static  Logger logger = LoggerFactory.getLogger(ActionListWhatICanViewData_WithAppType.class);
+
+	@SuppressWarnings("unchecked")
+	protected ActionResult<List<Wo>> execute(HttpServletRequest request, EffectivePerson effectivePerson, String appType )
+			throws Exception {
+		ActionResult<List<Wo>> result = new ActionResult<>();
+		List<Wo> wos = new ArrayList<>();
+		List<Wo> wos_out = new ArrayList<>();
+		Boolean isXAdmin = false;
+		Boolean check = true;
+		Boolean isAnonymous = effectivePerson.isAnonymous();
+		String personName = effectivePerson.getDistinguishedName();
+		
+		try {
+			isXAdmin = userManagerService.isManager(request, effectivePerson );
+		} catch (Exception e) {
+			check = false;
+			Exception exception = new ExceptionAppInfoProcess(e, "系统在检查用户是否是平台管理员时发生异常。Name:" + personName);
+			result.error(exception);
+			logger.error(e, effectivePerson, request, null);
+		}
+		
+		String cacheKey = ApplicationCache.concreteCacheKey(personName, "Data", appType, isXAdmin);
+		Element element = cache.get(cacheKey);
+
+		if ((null != element) && (null != element.getObjectValue())) {
+			wos = (List<Wo>) element.getObjectValue();
+			result.setData(wos);
+		} else {
+			if (check) {
+				if (isXAdmin) {
+					try {
+						wos = listViewAbleAppInfoByPermission( personName, isAnonymous, null, appType, "数据", isXAdmin, 1000 );
+					} catch (Exception e) {
+						check = false;
+						Exception exception = new ExceptionAppInfoProcess(e, "系统查询所有可见的分类信息时发生异常[管理员]。Name:" + personName);
+						result.error(exception);
+						logger.error(e, effectivePerson, request, null);
+					}
+				} else {
+					try {
+						wos_out = listViewAbleAppInfoByPermission( personName, isAnonymous, null, appType, "数据", isXAdmin, 1000 );
+						for( Wo wo : wos_out ) {
+							if( ListTools.isNotEmpty( wo.getWrapOutCategoryList() )) {
+								wos.add( wo );
+							}
+						}
+					} catch (Exception e) {
+						check = false;
+						Exception exception = new ExceptionAppInfoProcess(e,
+								"系统在根据用户权限查询所有可见的分类信息时发生异常。Name:" + personName);
+						result.error(exception);
+						logger.error(e, effectivePerson, request, null);
+					}
+				}
+			}
+		}
+		if(ListTools.isNotEmpty( wos)) {
+			SortTools.asc( wos, "appInfoSeq");
+		}
+		cache.put(new Element( cacheKey, wos ));
+		result.setData(wos);
+		return result;
+	}
+}

+ 96 - 12
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/AppInfoAction.java

@@ -138,16 +138,37 @@ public class AppInfoAction extends StandardJaxrsAction {
 		return ResponseFactory.getDefaultActionResultResponse(result);
 		return ResponseFactory.getDefaultActionResultResponse(result);
 	}
 	}
 
 
-	@JaxrsMethodDescribe(value = "获取用户有权限查看的所有信息栏目信息列表.", action = ActionListWhatICanView_Article.class)
+	@JaxrsMethodDescribe(value = "获取用户有权限查看的所有信息栏目信息列表.", action = ActionListWhatICanViewArticle.class)
+	@GET
+	@Path("list/user/view/article/type/{appType}")
+	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
+	@Consumes(MediaType.APPLICATION_JSON)
+	public Response listWhatICanViewArticle_WithAppType(@Context HttpServletRequest request,
+			@JaxrsParameterDescribe("栏目类别") @PathParam("appType") String appType ) {
+		EffectivePerson effectivePerson = this.effectivePerson(request);
+		ActionResult<List<ActionListWhatICanViewArticle.Wo>> result = new ActionResult<>();
+		try {
+			result = new ActionListWhatICanViewArticle_WithAppType().execute(request, effectivePerson, appType );
+		} catch (Exception e) {
+			result = new ActionResult<>();
+			Exception exception = new ExceptionAppInfoProcess(e,
+					"根据权限查询用户可以访问的信息栏目列表,person:" + effectivePerson.getDistinguishedName());
+			result.error(exception);
+			logger.error(e, effectivePerson, request, null);
+		}
+		return ResponseFactory.getDefaultActionResultResponse(result);
+	}
+	
+	@JaxrsMethodDescribe(value = "获取用户有权限查看的所有信息栏目信息列表.", action = ActionListWhatICanViewArticle.class)
 	@GET
 	@GET
 	@Path("list/user/view")
 	@Path("list/user/view")
 	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
 	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
 	@Consumes(MediaType.APPLICATION_JSON)
 	@Consumes(MediaType.APPLICATION_JSON)
 	public Response listWhatICanView_Article(@Context HttpServletRequest request) {
 	public Response listWhatICanView_Article(@Context HttpServletRequest request) {
 		EffectivePerson effectivePerson = this.effectivePerson(request);
 		EffectivePerson effectivePerson = this.effectivePerson(request);
-		ActionResult<List<ActionListWhatICanView_Article.Wo>> result = new ActionResult<>();
+		ActionResult<List<ActionListWhatICanViewArticle.Wo>> result = new ActionResult<>();
 		try {
 		try {
-			result = new ActionListWhatICanView_Article().execute(request, effectivePerson);
+			result = new ActionListWhatICanViewArticle().execute(request, effectivePerson);
 		} catch (Exception e) {
 		} catch (Exception e) {
 			result = new ActionResult<>();
 			result = new ActionResult<>();
 			Exception exception = new ExceptionAppInfoProcess(e,
 			Exception exception = new ExceptionAppInfoProcess(e,
@@ -158,16 +179,58 @@ public class AppInfoAction extends StandardJaxrsAction {
 		return ResponseFactory.getDefaultActionResultResponse(result);
 		return ResponseFactory.getDefaultActionResultResponse(result);
 	}
 	}
 	
 	
-	@JaxrsMethodDescribe(value = "获取用户有权限查看的所有信息栏目信息列表.", action = ActionListWhatICanView_Data.class)
+	@JaxrsMethodDescribe(value = "获取用户有权限查看的所有信息栏目信息列表.", action = ActionListWhatICanViewData.class)
 	@GET
 	@GET
 	@Path("list/user/view/data")
 	@Path("list/user/view/data")
 	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
 	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
 	@Consumes(MediaType.APPLICATION_JSON)
 	@Consumes(MediaType.APPLICATION_JSON)
 	public Response listWhatICanView_Data(@Context HttpServletRequest request) {
 	public Response listWhatICanView_Data(@Context HttpServletRequest request) {
 		EffectivePerson effectivePerson = this.effectivePerson(request);
 		EffectivePerson effectivePerson = this.effectivePerson(request);
-		ActionResult<List<ActionListWhatICanView_Data.Wo>> result = new ActionResult<>();
+		ActionResult<List<ActionListWhatICanViewData.Wo>> result = new ActionResult<>();
+		try {
+			result = new ActionListWhatICanViewData().execute(request, effectivePerson);
+		} catch (Exception e) {
+			result = new ActionResult<>();
+			Exception exception = new ExceptionAppInfoProcess(e,
+					"根据权限查询用户可以访问的数据栏目列表,person:" + effectivePerson.getDistinguishedName());
+			result.error(exception);
+			logger.error(e, effectivePerson, request, null);
+		}
+		return ResponseFactory.getDefaultActionResultResponse(result);
+	}
+	
+	@JaxrsMethodDescribe(value = "获取用户有权限查看的所有信息栏目信息列表.", action = ActionListWhatICanViewData.class)
+	@GET
+	@Path("list/user/view/data/type/{appType}")
+	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
+	@Consumes(MediaType.APPLICATION_JSON)
+	public Response listWhatICanViewData_WithAppType(@Context HttpServletRequest request,
+			@JaxrsParameterDescribe("栏目类别") @PathParam("appType") String appType ) {
+		EffectivePerson effectivePerson = this.effectivePerson(request);
+		ActionResult<List<ActionListWhatICanViewData.Wo>> result = new ActionResult<>();
+		try {
+			result = new ActionListWhatICanViewData_WithAppType().execute(request, effectivePerson, appType );
+		} catch (Exception e) {
+			result = new ActionResult<>();
+			Exception exception = new ExceptionAppInfoProcess(e,
+					"根据权限查询用户可以访问的数据栏目列表,person:" + effectivePerson.getDistinguishedName());
+			result.error(exception);
+			logger.error(e, effectivePerson, request, null);
+		}
+		return ResponseFactory.getDefaultActionResultResponse(result);
+	}
+	
+	@JaxrsMethodDescribe(value = "获取用户有权限查看的所有栏目信息列表.", action = ActionListWhatICanViewAllDocType.class)
+	@GET
+	@Path("list/user/view/all/type/{appType}")
+	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
+	@Consumes(MediaType.APPLICATION_JSON)
+	public Response listWhatICanViewAllType_WithAppType(@Context HttpServletRequest request,
+			@JaxrsParameterDescribe("栏目类别") @PathParam("appType") String appType ) {
+		EffectivePerson effectivePerson = this.effectivePerson(request);
+		ActionResult<List<ActionListWhatICanViewAllDocType.Wo>> result = new ActionResult<>();
 		try {
 		try {
-			result = new ActionListWhatICanView_Data().execute(request, effectivePerson);
+			result = new ActionListWhatICanViewAllDocType_WithAppType().execute( request, effectivePerson, appType );
 		} catch (Exception e) {
 		} catch (Exception e) {
 			result = new ActionResult<>();
 			result = new ActionResult<>();
 			Exception exception = new ExceptionAppInfoProcess(e,
 			Exception exception = new ExceptionAppInfoProcess(e,
@@ -178,16 +241,16 @@ public class AppInfoAction extends StandardJaxrsAction {
 		return ResponseFactory.getDefaultActionResultResponse(result);
 		return ResponseFactory.getDefaultActionResultResponse(result);
 	}
 	}
 	
 	
-	@JaxrsMethodDescribe(value = "获取用户有权限查看的所有栏目信息列表.", action = ActionListWhatICanView_AllType.class)
+	@JaxrsMethodDescribe(value = "获取用户有权限查看的所有栏目信息列表.", action = ActionListWhatICanViewAllDocType.class)
 	@GET
 	@GET
 	@Path("list/user/view/all")
 	@Path("list/user/view/all")
 	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
 	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
 	@Consumes(MediaType.APPLICATION_JSON)
 	@Consumes(MediaType.APPLICATION_JSON)
 	public Response listWhatICanView_AllType(@Context HttpServletRequest request) {
 	public Response listWhatICanView_AllType(@Context HttpServletRequest request) {
 		EffectivePerson effectivePerson = this.effectivePerson(request);
 		EffectivePerson effectivePerson = this.effectivePerson(request);
-		ActionResult<List<ActionListWhatICanView_AllType.Wo>> result = new ActionResult<>();
+		ActionResult<List<ActionListWhatICanViewAllDocType.Wo>> result = new ActionResult<>();
 		try {
 		try {
-			result = new ActionListWhatICanView_AllType().execute(request, effectivePerson);
+			result = new ActionListWhatICanViewAllDocType().execute(request, effectivePerson);
 		} catch (Exception e) {
 		} catch (Exception e) {
 			result = new ActionResult<>();
 			result = new ActionResult<>();
 			Exception exception = new ExceptionAppInfoProcess(e,
 			Exception exception = new ExceptionAppInfoProcess(e,
@@ -218,6 +281,27 @@ public class AppInfoAction extends StandardJaxrsAction {
 		return ResponseFactory.getDefaultActionResultResponse(result);
 		return ResponseFactory.getDefaultActionResultResponse(result);
 	}
 	}
 	
 	
+	@JaxrsMethodDescribe(value = "获取用户有权限发布的所有信息栏目信息列表.", action = ActionListWhatICanPublish.class)
+	@GET
+	@Path("list/user/publish/type/{appType}")
+	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
+	@Consumes(MediaType.APPLICATION_JSON)
+	public Response listWhatICanPublish_WithAppType(@Context HttpServletRequest request,
+			@JaxrsParameterDescribe("栏目类别") @PathParam("appType") String appType ) {
+		EffectivePerson effectivePerson = this.effectivePerson(request);
+		ActionResult<List<BaseAction.Wo>> result = new ActionResult<>();
+		try {
+			result = new ActionListWhatICanPublish_WithAppType().execute(request, effectivePerson, appType );
+		} catch (Exception e) {
+			result = new ActionResult<>();
+			Exception exception = new ExceptionAppInfoProcess(e,
+					"系统在根据用户权限查询所有可见的栏目信息时发生异常。Name:" + effectivePerson.getDistinguishedName());
+			result.error(exception);
+			logger.error(e, effectivePerson, request, null);
+		}
+		return ResponseFactory.getDefaultActionResultResponse(result);
+	}
+	
 	@JaxrsMethodDescribe(value = "获取用户有权限发布的所有信息栏目信息列表.", action = ActionGetPublishableAppInfo.class)
 	@JaxrsMethodDescribe(value = "获取用户有权限发布的所有信息栏目信息列表.", action = ActionGetPublishableAppInfo.class)
 	@GET
 	@GET
 	@Path("get/user/publish/{appId}")
 	@Path("get/user/publish/{appId}")
@@ -279,17 +363,17 @@ public class AppInfoAction extends StandardJaxrsAction {
 		return ResponseFactory.getDefaultActionResultResponse(result);
 		return ResponseFactory.getDefaultActionResultResponse(result);
 	}
 	}
 	
 	
-	@JaxrsMethodDescribe(value = "根据栏目类别名称获取用户有权限管理的所有信息栏目信息列表.", action = ActionListWhatICanManageWithAppType.class)
+	@JaxrsMethodDescribe(value = "根据栏目类别名称获取用户有权限管理的所有信息栏目信息列表.", action = ActionListWhatICanManage_WithAppType.class)
 	@GET
 	@GET
 	@Path("list/manage/type/{appType}")
 	@Path("list/manage/type/{appType}")
 	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
 	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8)
 	@Consumes(MediaType.APPLICATION_JSON)
 	@Consumes(MediaType.APPLICATION_JSON)
-	public Response listWhatICanManageWithAppType(@Context HttpServletRequest request,
+	public Response listWhatICanManage_WithAppType(@Context HttpServletRequest request,
 			@JaxrsParameterDescribe("栏目类别") @PathParam("appType") String appType ) {
 			@JaxrsParameterDescribe("栏目类别") @PathParam("appType") String appType ) {
 		EffectivePerson effectivePerson = this.effectivePerson(request);
 		EffectivePerson effectivePerson = this.effectivePerson(request);
 		ActionResult<List<BaseAction.Wo>> result = new ActionResult<>();
 		ActionResult<List<BaseAction.Wo>> result = new ActionResult<>();
 		try {
 		try {
-			result = new ActionListWhatICanManageWithAppType().execute(request, effectivePerson, appType);
+			result = new ActionListWhatICanManage_WithAppType().execute(request, effectivePerson, appType);
 		} catch (Exception e) {
 		} catch (Exception e) {
 			result = new ActionResult<>();
 			result = new ActionResult<>();
 			Exception exception = new ExceptionAppInfoProcess(e,
 			Exception exception = new ExceptionAppInfoProcess(e,

+ 30 - 11
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/appinfo/BaseAction.java

@@ -7,6 +7,8 @@ import java.util.List;
 import java.util.Map;
 import java.util.Map;
 import java.util.Set;
 import java.util.Set;
 
 
+import org.apache.commons.lang3.StringUtils;
+
 import com.x.base.core.entity.JpaObject;
 import com.x.base.core.entity.JpaObject;
 import com.x.base.core.project.bean.WrapCopier;
 import com.x.base.core.project.bean.WrapCopier;
 import com.x.base.core.project.bean.WrapCopierFactory;
 import com.x.base.core.project.bean.WrapCopierFactory;
@@ -44,18 +46,22 @@ public class BaseAction extends StandardJaxrsAction {
 	protected PermissionOperateService permissionOperateService = new PermissionOperateService();
 	protected PermissionOperateService permissionOperateService = new PermissionOperateService();
 	
 	
 	/**
 	/**
-	 * 	  * 当前登录者访问栏目分类列表查询<br/>
+	 * 当前登录者访问栏目分类列表查询<br/>
 	  * 1、根据人员的访问权限获取可以访问的栏目信息ID列表<br/>
 	  * 1、根据人员的访问权限获取可以访问的栏目信息ID列表<br/>
 	  * 2、根据人员的访问权限获取可以访问的分类信息ID列表<br/>
 	  * 2、根据人员的访问权限获取可以访问的分类信息ID列表<br/>
 	  * 3、将栏目信息和分类信息查询出来组织在一起,如果只有分类,那么也要把栏目信息加上
 	  * 3、将栏目信息和分类信息查询出来组织在一起,如果只有分类,那么也要把栏目信息加上
 	  * 4、如果栏目信息下没有分类,则删除栏目信息的输出
 	  * 4、如果栏目信息下没有分类,则删除栏目信息的输出
 	 * @param personName
 	 * @param personName
+	 * @param isAnonymous
 	 * @param inAppInfoIds
 	 * @param inAppInfoIds
+	 * @param appType
+	 * @param documentType
 	 * @param manager
 	 * @param manager
+	 * @param maxCount
 	 * @return
 	 * @return
 	 * @throws Exception
 	 * @throws Exception
 	 */
 	 */
-	protected List<Wo> listViewAbleAppInfoByPermission( String personName, Boolean isAnonymous, List<String> inAppInfoIds,  String documentType, 
+	protected List<Wo> listViewAbleAppInfoByPermission( String personName, Boolean isAnonymous, List<String> inAppInfoIds,  String appType, String documentType, 
 			Boolean manager, Integer maxCount ) throws Exception {
 			Boolean manager, Integer maxCount ) throws Exception {
 		List<String> unitNames = null;
 		List<String> unitNames = null;
 		List<String> groupNames = null;
 		List<String> groupNames = null;
@@ -78,31 +84,34 @@ public class BaseAction extends StandardJaxrsAction {
 					null, null, documentType, maxCount, manager );
 					null, null, documentType, maxCount, manager );
 			
 			
 		}
 		}
-		return composeCategoriesIntoAppInfo( viewableAppInfoIds, viewableCategoryIds );
+		return composeCategoriesIntoAppInfo( viewableAppInfoIds, viewableCategoryIds, appType );
 	}
 	}
 	
 	
 	/**
 	/**
-	 * 	  * 当前登录者文档发布栏目分类列表查询<br/>
+	 * 当前登录者文档发布栏目分类列表查询<br/>
 	  * 1、根据人员的发布权限获取可以发布文档的栏目信息ID列表<br/>
 	  * 1、根据人员的发布权限获取可以发布文档的栏目信息ID列表<br/>
 	  * 2、根据人员的发布权限获取可以发布文档的分类信息ID列表<br/>
 	  * 2、根据人员的发布权限获取可以发布文档的分类信息ID列表<br/>
 	  * 3、将栏目信息和分类信息查询出来组织在一起,如果只有分类,那么也要把栏目信息加上
 	  * 3、将栏目信息和分类信息查询出来组织在一起,如果只有分类,那么也要把栏目信息加上
 	  * 4、如果栏目信息下没有分类,则删除栏目信息的输出
 	  * 4、如果栏目信息下没有分类,则删除栏目信息的输出
 	 * @param personName
 	 * @param personName
+	 * @param isAnonymous
 	 * @param inAppInfoIds
 	 * @param inAppInfoIds
+	 * @param documentType
+	 * @param appType
 	 * @param manager
 	 * @param manager
+	 * @param maxCount
 	 * @return
 	 * @return
 	 * @throws Exception
 	 * @throws Exception
 	 */
 	 */
-	protected List<Wo> listPublishAbleAppInfoByPermission( String personName, Boolean isAnonymous, List<String> inAppInfoIds,  String documentType, Boolean manager, Integer maxCount ) throws Exception {
+	protected List<Wo> listPublishAbleAppInfoByPermission( String personName, Boolean isAnonymous, List<String> inAppInfoIds,  String documentType, String appType, Boolean manager, Integer maxCount ) throws Exception {
 		List<String> unitNames = null;
 		List<String> unitNames = null;
 		List<String> groupNames = null;
 		List<String> groupNames = null;
 		List<String> publishableAppInfoIds = null;
 		List<String> publishableAppInfoIds = null;
 		List<String> publishableCategoryIds = new ArrayList<>();
 		List<String> publishableCategoryIds = new ArrayList<>();
-		
 		if( manager ) {
 		if( manager ) {
 			if( ListTools.isNotEmpty( inAppInfoIds )) {
 			if( ListTools.isNotEmpty( inAppInfoIds )) {
 				publishableAppInfoIds = inAppInfoIds; //可发布栏目就限制为inAppInfoIds
 				publishableAppInfoIds = inAppInfoIds; //可发布栏目就限制为inAppInfoIds
-			}else {
+			}else {				
 				publishableAppInfoIds = appInfoServiceAdv.listAllIds(documentType); //所有栏目均可发布
 				publishableAppInfoIds = appInfoServiceAdv.listAllIds(documentType); //所有栏目均可发布
 			}
 			}
 			publishableCategoryIds = categoryInfoServiceAdv.listCategoryIdsWithAppIds( publishableAppInfoIds, documentType, manager, maxCount );
 			publishableCategoryIds = categoryInfoServiceAdv.listCategoryIdsWithAppIds( publishableAppInfoIds, documentType, manager, maxCount );
@@ -115,7 +124,12 @@ public class BaseAction extends StandardJaxrsAction {
 			publishableCategoryIds = permissionQueryService.listPublishableCategoryIdByPerson(
 			publishableCategoryIds = permissionQueryService.listPublishableCategoryIdByPerson(
 					personName, isAnonymous, unitNames, groupNames, inAppInfoIds, null, null, documentType, maxCount, manager );		
 					personName, isAnonymous, unitNames, groupNames, inAppInfoIds, null, null, documentType, maxCount, manager );		
 		}
 		}
-		return composeCategoriesIntoAppInfo( publishableAppInfoIds, publishableCategoryIds );
+//		if( ListTools.isNotEmpty(publishableCategoryIds  )) {
+//			System.out.println(">>>>>>>>>publishableCategoryIds.size=" + publishableCategoryIds.size() );
+//		}else {
+//			System.out.println(">>>>>>>>>publishableCategoryIds is empty!"  );
+//		}		
+		return composeCategoriesIntoAppInfo( publishableAppInfoIds, publishableCategoryIds, appType );
 	}
 	}
 	
 	
 	/**
 	/**
@@ -125,7 +139,7 @@ public class BaseAction extends StandardJaxrsAction {
 	 * @return
 	 * @return
 	 * @throws Exception 
 	 * @throws Exception 
 	 */
 	 */
-	private List<Wo> composeCategoriesIntoAppInfo(List<String> appInfoIds, List<String> categoryInfoIds ) throws Exception {
+	private List<Wo> composeCategoriesIntoAppInfo(List<String> appInfoIds, List<String> categoryInfoIds, String appType ) throws Exception {
 		List<Wo> wraps = null;
 		List<Wo> wraps = null;
 		List<WoCategory> wrapCategories = null;
 		List<WoCategory> wrapCategories = null;
 		Map<String, Wo> app_map = new HashMap<>();
 		Map<String, Wo> app_map = new HashMap<>();
@@ -170,7 +184,7 @@ public class BaseAction extends StandardJaxrsAction {
 			if( wo_app.getWrapOutCategoryList() == null ) {
 			if( wo_app.getWrapOutCategoryList() == null ) {
 				wo_app.setWrapOutCategoryList( new ArrayList<>() );
 				wo_app.setWrapOutCategoryList( new ArrayList<>() );
 			}
 			}
-			wo_app.getWrapOutCategoryList().add( woCategory );				
+			wo_app.getWrapOutCategoryList().add( woCategory );
 			app_map.put( wo_app.getId(), wo_app );
 			app_map.put( wo_app.getId(), wo_app );
 			
 			
 		}
 		}
@@ -185,7 +199,12 @@ public class BaseAction extends StandardJaxrsAction {
 		while( app_iterator.hasNext() ) {
 		while( app_iterator.hasNext() ) {
 			app_key = app_iterator.next().toString();
 			app_key = app_iterator.next().toString();
 			wo_app = app_map.get( app_key );
 			wo_app = app_map.get( app_key );
-			wraps.add( wo_app );
+			if( StringUtils.isEmpty( wo_app.getAppType() )) {
+				wo_app.setAppType("未分类");
+			}
+			if( "全部".equalsIgnoreCase( appType )||  "all".equalsIgnoreCase( appType ) || (StringUtils.isNotEmpty(  wo_app.getAppType() ) && wo_app.getAppType().equalsIgnoreCase( appType ))) {
+				wraps.add( wo_app );
+			}
 		}
 		}
 		return wraps;
 		return wraps;
 	}
 	}

+ 1 - 1
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/jaxrs/document/ActionPersistSaveDocument.java

@@ -380,7 +380,7 @@ public class ActionPersistSaveDocument extends BaseAction {
 		@FieldDescribe( "不修改权限(跳过权限设置,保留原来的设置),非必填" )
 		@FieldDescribe( "不修改权限(跳过权限设置,保留原来的设置),非必填" )
 		private Boolean skipPermission  = false;	
 		private Boolean skipPermission  = false;	
 
 
-		public static WrapCopier<Wi, Document> copier = WrapCopierFactory.wi( Wi.class, Document.class, null, JpaObject.FieldsUnmodify);
+		public static WrapCopier<Wi, Document> copier = WrapCopierFactory.wi( Wi.class, Document.class, null, JpaObject.FieldsUnmodifyExcludeId);
 		
 		
 		public String getId() {
 		public String getId() {
 			return id;
 			return id;

+ 6 - 0
o2server/x_cms_assemble_control/src/main/java/com/x/cms/assemble/control/service/AppInfoService.java

@@ -145,6 +145,9 @@ public class AppInfoService {
 			if( StringUtils.isEmpty( appInfo.getAppAlias() )) {
 			if( StringUtils.isEmpty( appInfo.getAppAlias() )) {
 				appInfo.setAppAlias( appInfo.getAppName() );
 				appInfo.setAppAlias( appInfo.getAppName() );
 			}
 			}
+			if( StringUtils.isEmpty( appInfo.getAppType() )) {
+				appInfo.setAppType( "未分类" );
+			}
 			emc.persist( appInfo, CheckPersistType.all);
 			emc.persist( appInfo, CheckPersistType.all);
 			emc.commit();
 			emc.commit();
 		}else{
 		}else{
@@ -154,6 +157,9 @@ public class AppInfoService {
 				appInfo.setAppAlias( appInfo.getAppName() );
 				appInfo.setAppAlias( appInfo.getAppName() );
 			}
 			}
 			emc.beginTransaction( AppInfo.class );
 			emc.beginTransaction( AppInfo.class );
+			if( StringUtils.isEmpty( appInfo.getAppType() )) {
+				appInfo.setAppType( "未分类" );
+			}
 			emc.check( appInfo, CheckPersistType.all );	
 			emc.check( appInfo, CheckPersistType.all );	
 			emc.commit();
 			emc.commit();
 		}		
 		}		

Энэ ялгаанд хэт олон файл өөрчлөгдсөн тул зарим файлыг харуулаагүй болно