├── .idea ├── .name ├── compiler.xml ├── copyright │ └── profiles_settings.xml ├── encodings.xml ├── libraries │ ├── Maven__ch_qos_logback_logback_access_1_1_3.xml │ ├── Maven__ch_qos_logback_logback_classic_1_1_7.xml │ ├── Maven__ch_qos_logback_logback_core_1_1_7.xml │ ├── Maven__com_fasterxml_classmate_1_3_3.xml │ ├── Maven__com_fasterxml_jackson_core_jackson_annotations_2_8_4.xml │ ├── Maven__com_fasterxml_jackson_core_jackson_core_2_8_4.xml │ ├── Maven__com_fasterxml_jackson_core_jackson_databind_2_8_4.xml │ ├── Maven__com_jayway_jsonpath_json_path_2_2_0.xml │ ├── Maven__com_voodoodyne_jackson_jsog_jackson_jsog_1_1.xml │ ├── Maven__commons_beanutils_commons_beanutils_1_9_2.xml │ ├── Maven__commons_codec_commons_codec_1_10.xml │ ├── Maven__commons_io_commons_io_2_4.xml │ ├── Maven__javax_validation_validation_api_1_1_0_Final.xml │ ├── Maven__junit_junit_4_12.xml │ ├── Maven__net_minidev_accessors_smart_1_1.xml │ ├── Maven__net_minidev_json_smart_2_2_1.xml │ ├── Maven__nz_net_ultraq_thymeleaf_thymeleaf_layout_dialect_1_4_0.xml │ ├── Maven__ognl_ognl_3_0_8.xml │ ├── Maven__org_apache_commons_commons_collections4_4_1.xml │ ├── Maven__org_apache_commons_commons_lang3_3_4.xml │ ├── Maven__org_apache_httpcomponents_httpclient_4_5_2.xml │ ├── Maven__org_apache_httpcomponents_httpcore_4_4_5.xml │ ├── Maven__org_apache_tomcat_embed_tomcat_embed_core_8_5_6.xml │ ├── Maven__org_apache_tomcat_embed_tomcat_embed_el_8_5_6.xml │ ├── Maven__org_apache_tomcat_embed_tomcat_embed_websocket_8_5_6.xml │ ├── Maven__org_assertj_assertj_core_2_5_0.xml │ ├── Maven__org_codehaus_groovy_groovy_2_4_7.xml │ ├── Maven__org_eclipse_jetty_jetty_http_9_2_14_v20151106.xml │ ├── Maven__org_eclipse_jetty_jetty_io_9_2_14_v20151106.xml │ ├── Maven__org_eclipse_jetty_jetty_security_9_2_14_v20151106.xml │ ├── Maven__org_eclipse_jetty_jetty_server_9_2_14_v20151106.xml │ ├── Maven__org_eclipse_jetty_jetty_servlet_9_2_14_v20151106.xml │ ├── Maven__org_eclipse_jetty_jetty_util_9_2_14_v20151106.xml │ ├── Maven__org_eclipse_jetty_jetty_webapp_9_2_14_v20151106.xml │ ├── Maven__org_eclipse_jetty_jetty_xml_9_2_14_v20151106.xml │ ├── Maven__org_hamcrest_hamcrest_core_1_3.xml │ ├── Maven__org_hamcrest_hamcrest_library_1_3.xml │ ├── Maven__org_hibernate_hibernate_validator_5_2_4_Final.xml │ ├── Maven__org_javassist_javassist_3_20_0_GA.xml │ ├── Maven__org_jboss_logging_jboss_logging_3_3_0_Final.xml │ ├── Maven__org_json_json_20140107.xml │ ├── Maven__org_mockito_mockito_core_1_10_19.xml │ ├── Maven__org_neo4j_neo4j_ogm_api_2_0_5.xml │ ├── Maven__org_neo4j_neo4j_ogm_compiler_2_0_5.xml │ ├── Maven__org_neo4j_neo4j_ogm_core_2_0_5.xml │ ├── Maven__org_neo4j_neo4j_ogm_http_driver_2_0_5.xml │ ├── Maven__org_objenesis_objenesis_2_1.xml │ ├── Maven__org_ow2_asm_asm_5_0_3.xml │ ├── Maven__org_skyscreamer_jsonassert_1_3_0.xml │ ├── Maven__org_slf4j_jcl_over_slf4j_1_7_21.xml │ ├── Maven__org_slf4j_jul_to_slf4j_1_7_21.xml │ ├── Maven__org_slf4j_log4j_over_slf4j_1_7_21.xml │ ├── Maven__org_slf4j_slf4j_api_1_7_21.xml │ ├── Maven__org_springframework_boot_spring_boot_1_4_2_RELEASE.xml │ ├── Maven__org_springframework_boot_spring_boot_actuator_1_4_2_RELEASE.xml │ ├── Maven__org_springframework_boot_spring_boot_autoconfigure_1_4_2_RELEASE.xml │ ├── Maven__org_springframework_boot_spring_boot_starter_1_4_2_RELEASE.xml │ ├── Maven__org_springframework_boot_spring_boot_starter_actuator_1_4_2_RELEASE.xml │ ├── Maven__org_springframework_boot_spring_boot_starter_logging_1_4_2_RELEASE.xml │ ├── Maven__org_springframework_boot_spring_boot_starter_test_1_4_2_RELEASE.xml │ ├── Maven__org_springframework_boot_spring_boot_starter_thymeleaf_1_4_2_RELEASE.xml │ ├── Maven__org_springframework_boot_spring_boot_starter_tomcat_1_4_2_RELEASE.xml │ ├── Maven__org_springframework_boot_spring_boot_starter_web_1_4_2_RELEASE.xml │ ├── Maven__org_springframework_boot_spring_boot_test_1_4_2_RELEASE.xml │ ├── Maven__org_springframework_boot_spring_boot_test_autoconfigure_1_4_2_RELEASE.xml │ ├── Maven__org_springframework_data_spring_data_commons_1_12_5_RELEASE.xml │ ├── Maven__org_springframework_data_spring_data_neo4j_4_1_5_RELEASE.xml │ ├── Maven__org_springframework_spring_aop_4_3_4_RELEASE.xml │ ├── Maven__org_springframework_spring_beans_4_3_4_RELEASE.xml │ ├── Maven__org_springframework_spring_context_4_3_4_RELEASE.xml │ ├── Maven__org_springframework_spring_core_4_3_4_RELEASE.xml │ ├── Maven__org_springframework_spring_expression_4_3_4_RELEASE.xml │ ├── Maven__org_springframework_spring_test_4_3_4_RELEASE.xml │ ├── Maven__org_springframework_spring_tx_4_3_4_RELEASE.xml │ ├── Maven__org_springframework_spring_web_4_3_4_RELEASE.xml │ ├── Maven__org_springframework_spring_webmvc_4_3_4_RELEASE.xml │ ├── Maven__org_thymeleaf_thymeleaf_2_1_5_RELEASE.xml │ ├── Maven__org_thymeleaf_thymeleaf_spring4_2_1_5_RELEASE.xml │ ├── Maven__org_unbescape_unbescape_1_1_0_RELEASE.xml │ └── Maven__org_yaml_snakeyaml_1_17.xml ├── misc.xml ├── modules.xml ├── uiDesigner.xml └── vcs.xml ├── data ├── data.iml ├── pom.xml └── src │ ├── main │ ├── java │ │ └── com │ │ │ └── test │ │ │ └── data │ │ │ ├── config │ │ │ └── Neo4jConfig.java │ │ │ ├── domain │ │ │ ├── Actor.java │ │ │ ├── Movie.java │ │ │ └── Role.java │ │ │ ├── repositories │ │ │ ├── ActorRepository.java │ │ │ └── MovieRepository.java │ │ │ └── service │ │ │ └── PagesService.java │ └── resources │ │ └── ogm.properties │ └── test │ └── java │ └── com │ └── test │ └── data │ └── test │ └── MovieTest.java ├── pom.xml ├── readme.md ├── spring-boot-ui.iml └── webui ├── pom.xml ├── src └── main │ ├── java │ └── com │ │ └── test │ │ └── webui │ │ ├── WebuiApp.java │ │ └── controller │ │ ├── ActorController.java │ │ └── MovieController.java │ └── resources │ ├── application.yml │ ├── static │ ├── images │ │ ├── arrow.png │ │ ├── global │ │ │ ├── selectDown.png │ │ │ ├── subMenuBk.png │ │ │ ├── togUpDownCircle.png │ │ │ ├── topLineBk.png │ │ │ └── wen.png │ │ ├── index │ │ │ ├── addIcon.png │ │ │ ├── arr1.png │ │ │ ├── arr2.png │ │ │ ├── arr3.png │ │ │ ├── arr4.png │ │ │ ├── bg.png │ │ │ ├── blueBtn-62X30.png │ │ │ ├── bryBk-256X118.png │ │ │ ├── btn-56X29.png │ │ │ ├── btn-93X38.png │ │ │ ├── btnBk.png │ │ │ ├── closeIcon-14X14.png │ │ │ ├── del.png │ │ │ ├── deleteIcon.png │ │ │ ├── line.png │ │ │ ├── list-bk.png │ │ │ ├── radiusBlueBot-782.png │ │ │ ├── radiusBlueMid-782.png │ │ │ ├── radiusBlueTop-782.png │ │ │ ├── radiusGrayBot-782.png │ │ │ ├── radiusGrayTop-782.png │ │ │ ├── selectDown.png │ │ │ ├── selectIcon-15X14.png │ │ │ ├── togMoveIcon.png │ │ │ └── verticalLine.png │ │ ├── logo.png │ │ └── movie │ │ │ ├── 西游记.jpg │ │ │ └── 西游记续集.jpg │ ├── index.html │ ├── scripts │ │ ├── My97DatePicker │ │ │ ├── WdatePicker.js │ │ │ ├── calendar.js │ │ │ ├── lang │ │ │ │ ├── en.js │ │ │ │ ├── zh-cn.js │ │ │ │ └── zh-tw.js │ │ │ └── skin │ │ │ │ ├── WdatePicker.css │ │ │ │ ├── datePicker.gif │ │ │ │ ├── default │ │ │ │ ├── datepicker.css │ │ │ │ └── img.gif │ │ │ │ └── whyGreen │ │ │ │ ├── bg.jpg │ │ │ │ ├── datepicker.css │ │ │ │ └── img.gif │ │ ├── actor │ │ │ ├── edit.js │ │ │ ├── list.js │ │ │ └── new.js │ │ ├── artDialog │ │ │ ├── artDialog.js │ │ │ ├── default.css │ │ │ ├── icons │ │ │ │ └── loading.gif │ │ │ └── jquery.artDialog.source.js │ │ ├── common.js │ │ ├── imageselect.js │ │ ├── jquery.min.js │ │ ├── jquery.smartselect-1.1.min.js │ │ ├── movie │ │ │ ├── edit.js │ │ │ ├── list.js │ │ │ └── new.js │ │ ├── pagination │ │ │ ├── jquery.pagination.js │ │ │ ├── pagination.css │ │ │ └── wait.gif │ │ ├── public │ │ │ ├── json2.js │ │ │ └── public.js │ │ └── validate │ │ │ ├── additional-methods.js │ │ │ ├── chinese.js │ │ │ ├── css │ │ │ ├── chili.css │ │ │ ├── cmxform.css │ │ │ ├── cmxformTemplate.css │ │ │ ├── core.css │ │ │ ├── reset.css │ │ │ └── screen.css │ │ │ ├── jquery.metadata.js │ │ │ ├── jquery.validate.min.js │ │ │ ├── tooltip.js │ │ │ ├── tooltip.slide.js │ │ │ └── validate.js │ └── styles │ │ ├── global.css │ │ ├── imageselect.css │ │ └── index.css │ └── templates │ ├── actor │ ├── edit.html │ ├── index.html │ ├── new.html │ └── show.html │ ├── fragments │ ├── footer.html │ ├── layout.html │ └── nav.html │ └── movie │ ├── edit.html │ ├── index.html │ ├── new.html │ └── show.html └── webui.iml /.idea/.name: -------------------------------------------------------------------------------- 1 | spring-boot-ui -------------------------------------------------------------------------------- /.idea/compiler.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 35 | -------------------------------------------------------------------------------- /.idea/copyright/profiles_settings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | -------------------------------------------------------------------------------- /.idea/encodings.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__ch_qos_logback_logback_access_1_1_3.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__ch_qos_logback_logback_classic_1_1_7.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__ch_qos_logback_logback_core_1_1_7.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__com_fasterxml_classmate_1_3_3.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__com_fasterxml_jackson_core_jackson_annotations_2_8_4.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__com_fasterxml_jackson_core_jackson_core_2_8_4.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__com_fasterxml_jackson_core_jackson_databind_2_8_4.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__com_jayway_jsonpath_json_path_2_2_0.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__com_voodoodyne_jackson_jsog_jackson_jsog_1_1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__commons_beanutils_commons_beanutils_1_9_2.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__commons_codec_commons_codec_1_10.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__commons_io_commons_io_2_4.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__javax_validation_validation_api_1_1_0_Final.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__junit_junit_4_12.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__net_minidev_accessors_smart_1_1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__net_minidev_json_smart_2_2_1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__nz_net_ultraq_thymeleaf_thymeleaf_layout_dialect_1_4_0.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__ognl_ognl_3_0_8.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_apache_commons_commons_collections4_4_1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_apache_commons_commons_lang3_3_4.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_apache_httpcomponents_httpclient_4_5_2.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_apache_httpcomponents_httpcore_4_4_5.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_apache_tomcat_embed_tomcat_embed_core_8_5_6.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_apache_tomcat_embed_tomcat_embed_el_8_5_6.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_apache_tomcat_embed_tomcat_embed_websocket_8_5_6.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_assertj_assertj_core_2_5_0.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_codehaus_groovy_groovy_2_4_7.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_eclipse_jetty_jetty_http_9_2_14_v20151106.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_eclipse_jetty_jetty_io_9_2_14_v20151106.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_eclipse_jetty_jetty_security_9_2_14_v20151106.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_eclipse_jetty_jetty_server_9_2_14_v20151106.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_eclipse_jetty_jetty_servlet_9_2_14_v20151106.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_eclipse_jetty_jetty_util_9_2_14_v20151106.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_eclipse_jetty_jetty_webapp_9_2_14_v20151106.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_eclipse_jetty_jetty_xml_9_2_14_v20151106.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_hamcrest_hamcrest_core_1_3.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_hamcrest_hamcrest_library_1_3.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_hibernate_hibernate_validator_5_2_4_Final.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_javassist_javassist_3_20_0_GA.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_jboss_logging_jboss_logging_3_3_0_Final.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_json_json_20140107.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_mockito_mockito_core_1_10_19.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_neo4j_neo4j_ogm_api_2_0_5.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_neo4j_neo4j_ogm_compiler_2_0_5.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_neo4j_neo4j_ogm_core_2_0_5.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_neo4j_neo4j_ogm_http_driver_2_0_5.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_objenesis_objenesis_2_1.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_ow2_asm_asm_5_0_3.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_skyscreamer_jsonassert_1_3_0.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_slf4j_jcl_over_slf4j_1_7_21.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_slf4j_jul_to_slf4j_1_7_21.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_slf4j_log4j_over_slf4j_1_7_21.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_slf4j_slf4j_api_1_7_21.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_boot_spring_boot_1_4_2_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_boot_spring_boot_actuator_1_4_2_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_boot_spring_boot_autoconfigure_1_4_2_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_1_4_2_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_actuator_1_4_2_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_logging_1_4_2_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_test_1_4_2_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_thymeleaf_1_4_2_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_tomcat_1_4_2_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_boot_spring_boot_starter_web_1_4_2_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_boot_spring_boot_test_1_4_2_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_boot_spring_boot_test_autoconfigure_1_4_2_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_data_spring_data_commons_1_12_5_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_data_spring_data_neo4j_4_1_5_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_spring_aop_4_3_4_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_spring_beans_4_3_4_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_spring_context_4_3_4_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_spring_core_4_3_4_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_spring_expression_4_3_4_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_spring_test_4_3_4_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_spring_tx_4_3_4_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_spring_web_4_3_4_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_springframework_spring_webmvc_4_3_4_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_thymeleaf_thymeleaf_2_1_5_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_thymeleaf_thymeleaf_spring4_2_1_5_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_unbescape_unbescape_1_1_0_RELEASE.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/libraries/Maven__org_yaml_snakeyaml_1_17.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /.idea/modules.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /.idea/vcs.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /data/data.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | -------------------------------------------------------------------------------- /data/pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | spring-boot-ui 7 | springboot.demo 8 | 1.0-SNAPSHOT 9 | 10 | 4.0.0 11 | 12 | data 13 | jar 14 | 15 | 16 | 17 | org.springframework.data 18 | spring-data-neo4j 19 | 20 | 21 | com.voodoodyne.jackson.jsog 22 | jackson-jsog 23 | 1.1 24 | compile 25 | 26 | 27 | -------------------------------------------------------------------------------- /data/src/main/java/com/test/data/config/Neo4jConfig.java: -------------------------------------------------------------------------------- 1 | package com.test.data.config; 2 | 3 | import org.neo4j.ogm.session.SessionFactory; 4 | import org.springframework.context.annotation.Configuration; 5 | import org.springframework.data.neo4j.config.Neo4jConfiguration; 6 | import org.springframework.data.neo4j.repository.config.EnableNeo4jRepositories; 7 | import org.springframework.transaction.annotation.EnableTransactionManagement; 8 | 9 | 10 | @Configuration 11 | @EnableTransactionManagement 12 | @EnableNeo4jRepositories(basePackages = { "com.test.data.repositories" }) 13 | public class Neo4jConfig extends Neo4jConfiguration { 14 | //SDN 升级到4.1.5,连接服务器的配置改在ogm.properties中设定,这样可以访问Neo4j 2.x 到 3.x 版本 15 | // @Override 16 | // public Neo4jServer neo4jServer() { 17 | // return new RemoteServer("http://192.168.1.211:7474","neo4j","12345678"); 18 | // } 19 | 20 | @Override 21 | public SessionFactory getSessionFactory() { 22 | return new SessionFactory("com.test.data.domain"); 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /data/src/main/java/com/test/data/domain/Actor.java: -------------------------------------------------------------------------------- 1 | package com.test.data.domain; 2 | 3 | 4 | import com.fasterxml.jackson.annotation.JsonIdentityInfo; 5 | import com.voodoodyne.jackson.jsog.JSOGGenerator; 6 | import org.neo4j.ogm.annotation.GraphId; 7 | import org.neo4j.ogm.annotation.NodeEntity; 8 | import org.neo4j.ogm.annotation.typeconversion.DateLong; 9 | import org.springframework.format.annotation.DateTimeFormat; 10 | 11 | import java.util.Date; 12 | 13 | @JsonIdentityInfo(generator=JSOGGenerator.class) 14 | @NodeEntity 15 | public class Actor { 16 | @GraphId 17 | Long id; 18 | private String name; 19 | private int sex; 20 | @DateLong 21 | @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") 22 | private Date born; 23 | 24 | public Actor() { } 25 | 26 | public Long getId() { 27 | return id; 28 | } 29 | 30 | public void setId(Long id) { 31 | this.id = id; 32 | } 33 | 34 | public String getName() { 35 | return name; 36 | } 37 | 38 | public void setName(String name) { 39 | this.name = name; 40 | } 41 | 42 | public int getSex() { 43 | return sex; 44 | } 45 | 46 | public void setSex(int sex) { 47 | this.sex = sex; 48 | } 49 | 50 | public Date getBorn() { 51 | return born; 52 | } 53 | 54 | public void setBorn(Date born) { 55 | this.born = born; 56 | } 57 | } 58 | -------------------------------------------------------------------------------- /data/src/main/java/com/test/data/domain/Movie.java: -------------------------------------------------------------------------------- 1 | package com.test.data.domain; 2 | 3 | import com.fasterxml.jackson.annotation.JsonIdentityInfo; 4 | import com.voodoodyne.jackson.jsog.JSOGGenerator; 5 | import org.neo4j.ogm.annotation.GraphId; 6 | import org.neo4j.ogm.annotation.NodeEntity; 7 | import org.neo4j.ogm.annotation.Relationship; 8 | import org.neo4j.ogm.annotation.typeconversion.DateLong; 9 | import org.springframework.format.annotation.DateTimeFormat; 10 | 11 | import java.util.ArrayList; 12 | import java.util.Date; 13 | import java.util.List; 14 | 15 | @JsonIdentityInfo(generator=JSOGGenerator.class) 16 | @NodeEntity 17 | public class Movie { 18 | @GraphId 19 | Long id; 20 | private String name; 21 | private String photo; 22 | @DateLong 23 | @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") 24 | private Date createDate; 25 | 26 | @Relationship(type="扮演", direction = Relationship.INCOMING) 27 | List roles = new ArrayList<>(); 28 | 29 | public Role addRole(Actor actor, String name){ 30 | Role role = new Role(actor,this,name); 31 | this.roles.add(role); 32 | return role; 33 | } 34 | 35 | public Movie() { } 36 | 37 | public Long getId() { 38 | return id; 39 | } 40 | 41 | public void setId(Long id) { 42 | this.id = id; 43 | } 44 | 45 | public List getRoles() { 46 | return roles; 47 | } 48 | 49 | public void setRoles(List roles) { 50 | this.roles = roles; 51 | } 52 | 53 | public String getName() { 54 | return name; 55 | } 56 | 57 | public void setName(String name) { 58 | this.name = name; 59 | } 60 | 61 | public String getPhoto() { 62 | return photo; 63 | } 64 | 65 | public void setPhoto(String photo) { 66 | this.photo = photo; 67 | } 68 | 69 | public Date getCreateDate() { 70 | return createDate; 71 | } 72 | 73 | public void setCreateDate(Date createDate) { 74 | this.createDate = createDate; 75 | } 76 | } 77 | -------------------------------------------------------------------------------- /data/src/main/java/com/test/data/domain/Role.java: -------------------------------------------------------------------------------- 1 | package com.test.data.domain; 2 | 3 | import com.fasterxml.jackson.annotation.JsonIdentityInfo; 4 | import com.voodoodyne.jackson.jsog.JSOGGenerator; 5 | import org.neo4j.ogm.annotation.EndNode; 6 | import org.neo4j.ogm.annotation.GraphId; 7 | import org.neo4j.ogm.annotation.RelationshipEntity; 8 | import org.neo4j.ogm.annotation.StartNode; 9 | 10 | @JsonIdentityInfo(generator=JSOGGenerator.class) 11 | @RelationshipEntity(type = "扮演") 12 | public class Role { 13 | @GraphId 14 | Long id; 15 | String name; 16 | @StartNode 17 | Actor actor; 18 | @EndNode 19 | Movie movie; 20 | 21 | public Role() { 22 | } 23 | 24 | public Role(Actor actor, Movie movie, String name) { 25 | this.actor = actor; 26 | this.movie = movie; 27 | this.name = name; 28 | } 29 | 30 | public Long getId() { 31 | return id; 32 | } 33 | 34 | public void setId(Long id) { 35 | this.id = id; 36 | } 37 | 38 | public String getName() { 39 | return name; 40 | } 41 | 42 | public void setName(String name) { 43 | this.name = name; 44 | } 45 | 46 | public Actor getActor() { 47 | return actor; 48 | } 49 | 50 | public Movie getMovie() { 51 | return movie; 52 | } 53 | 54 | } 55 | -------------------------------------------------------------------------------- /data/src/main/java/com/test/data/repositories/ActorRepository.java: -------------------------------------------------------------------------------- 1 | package com.test.data.repositories; 2 | 3 | import com.test.data.domain.Actor; 4 | import org.springframework.data.neo4j.repository.GraphRepository; 5 | import org.springframework.stereotype.Repository; 6 | 7 | @Repository 8 | public interface ActorRepository extends GraphRepository { 9 | } 10 | -------------------------------------------------------------------------------- /data/src/main/java/com/test/data/repositories/MovieRepository.java: -------------------------------------------------------------------------------- 1 | package com.test.data.repositories; 2 | 3 | import com.test.data.domain.Movie; 4 | import org.springframework.data.domain.Page; 5 | import org.springframework.data.domain.Pageable; 6 | import org.springframework.data.neo4j.annotation.Query; 7 | import org.springframework.data.neo4j.repository.GraphRepository; 8 | import org.springframework.data.repository.query.Param; 9 | import org.springframework.stereotype.Repository; 10 | 11 | @Repository 12 | public interface MovieRepository extends GraphRepository { 13 | Movie findByName(@Param("name") String name); 14 | 15 | @Query("MATCH (m:Movie) WHERE m.name =~ ('(?i).*'+{name}+'.*') RETURN m") 16 | Page findByName(@Param("name") String name, Pageable pageable);//not support yet 17 | } 18 | 19 | 20 | -------------------------------------------------------------------------------- /data/src/main/java/com/test/data/service/PagesService.java: -------------------------------------------------------------------------------- 1 | package com.test.data.service; 2 | 3 | import org.neo4j.ogm.cypher.Filters; 4 | import org.neo4j.ogm.cypher.query.Pagination; 5 | import org.neo4j.ogm.cypher.query.SortOrder; 6 | import org.neo4j.ogm.session.Session; 7 | import org.springframework.beans.factory.annotation.Autowired; 8 | import org.springframework.data.domain.Page; 9 | import org.springframework.data.domain.PageImpl; 10 | import org.springframework.data.domain.Pageable; 11 | import org.springframework.data.domain.Sort; 12 | import org.springframework.stereotype.Service; 13 | 14 | import java.util.ArrayList; 15 | import java.util.Collection; 16 | import java.util.Iterator; 17 | import java.util.List; 18 | 19 | @Service 20 | public class PagesService { 21 | @Autowired 22 | private Session session; 23 | 24 | 25 | public Page findAll(Class clazz, Pageable pageable, Filters filters){ 26 | Collection data = this.session.loadAll(clazz, filters, convert(pageable.getSort()), new Pagination(pageable.getPageNumber(), pageable.getPageSize()), 1); 27 | return updatePage(pageable, new ArrayList(data)); 28 | } 29 | 30 | private Page updatePage(Pageable pageable, List results) { 31 | int pageSize = pageable.getPageSize(); 32 | int pageOffset = pageable.getOffset(); 33 | int total = pageOffset + results.size() + (results.size() == pageSize?pageSize:0); 34 | return new PageImpl(results, pageable, (long)total); 35 | } 36 | 37 | private SortOrder convert(Sort sort) { 38 | SortOrder sortOrder = new SortOrder(); 39 | if(sort != null) { 40 | Iterator var3 = sort.iterator(); 41 | 42 | while(var3.hasNext()) { 43 | Sort.Order order = (Sort.Order)var3.next(); 44 | if(order.isAscending()) { 45 | sortOrder.add(new String[]{order.getProperty()}); 46 | } else { 47 | sortOrder.add(SortOrder.Direction.DESC, new String[]{order.getProperty()}); 48 | } 49 | } 50 | } 51 | return sortOrder; 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /data/src/main/resources/ogm.properties: -------------------------------------------------------------------------------- 1 | compiler=org.neo4j.ogm.compiler.MultiStatementCypherCompiler 2 | driver=org.neo4j.ogm.drivers.http.driver.HttpDriver 3 | URI=http://localhost:7474 4 | username = neo4j 5 | password = 12345678 6 | 7 | 8 | -------------------------------------------------------------------------------- /data/src/test/java/com/test/data/test/MovieTest.java: -------------------------------------------------------------------------------- 1 | package com.test.data.test; 2 | 3 | import com.test.data.config.Neo4jConfig; 4 | import com.test.data.domain.Actor; 5 | import com.test.data.domain.Movie; 6 | import com.test.data.domain.Role; 7 | import com.test.data.repositories.ActorRepository; 8 | import com.test.data.repositories.MovieRepository; 9 | import org.junit.Before; 10 | import org.junit.Test; 11 | import org.junit.runner.RunWith; 12 | import org.slf4j.Logger; 13 | import org.slf4j.LoggerFactory; 14 | import org.springframework.beans.factory.annotation.Autowired; 15 | import org.springframework.test.context.ContextConfiguration; 16 | import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; 17 | import org.springframework.util.Assert; 18 | 19 | import java.util.Date; 20 | 21 | 22 | @RunWith(SpringJUnit4ClassRunner.class) 23 | @ContextConfiguration(classes = {Neo4jConfig.class}) 24 | public class MovieTest { 25 | private static Logger logger = LoggerFactory.getLogger(MovieTest.class); 26 | 27 | @Autowired 28 | MovieRepository movieRepository; 29 | @Autowired 30 | ActorRepository actorRepository; 31 | 32 | @Before 33 | public void initData(){ 34 | movieRepository.deleteAll(); 35 | actorRepository.deleteAll(); 36 | 37 | Movie matrix1 = new Movie(); 38 | matrix1.setName("西游记"); 39 | matrix1.setPhoto("/images/movie/西游记.jpg"); 40 | matrix1.setCreateDate(new Date()); 41 | 42 | Actor swk = new Actor(); 43 | swk.setName("六小龄童"); 44 | 45 | Actor zbj = new Actor(); 46 | zbj.setName("马德华"); 47 | 48 | Actor ccr = new Actor(); 49 | ccr.setName("迟重瑞"); 50 | 51 | Actor yhl = new Actor(); 52 | yhl.setName("闫怀礼"); 53 | 54 | 55 | matrix1.addRole(swk, "孙悟空"); 56 | matrix1.addRole(zbj, "猪八戒"); 57 | matrix1.addRole(ccr, "唐僧"); 58 | matrix1.addRole(yhl, "沙僧"); 59 | 60 | movieRepository.save(matrix1); 61 | Assert.notNull(matrix1.getId()); 62 | 63 | } 64 | 65 | @Test 66 | public void get(){ 67 | Movie movie = movieRepository.findByName("西游记"); 68 | Assert.notNull(movie); 69 | logger.info("===movie=== movie:{}, {}",movie.getName(), movie.getCreateDate()); 70 | for(Role role : movie.getRoles()){ 71 | logger.info("====== actor:{}, role:{}", role.getActor().getName(), role.getName()); 72 | } 73 | } 74 | } 75 | -------------------------------------------------------------------------------- /pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 4.0.0 6 | 7 | springboot.demo 8 | spring-boot-ui 9 | pom 10 | 1.0-SNAPSHOT 11 | 12 | data 13 | webui 14 | 15 | 16 | 17 | org.springframework.boot 18 | spring-boot-starter-parent 19 | 1.4.2.RELEASE 20 | 21 | 22 | 23 | UTF-8 24 | 1.8 25 | 26 | 27 | 28 | 29 | org.springframework.boot 30 | spring-boot-starter 31 | 32 | 33 | org.springframework.boot 34 | spring-boot-starter-web 35 | 36 | 37 | org.springframework.boot 38 | spring-boot-starter-actuator 39 | 40 | 41 | org.springframework.boot 42 | spring-boot-starter-test 43 | test 44 | 45 | 46 | -------------------------------------------------------------------------------- /readme.md: -------------------------------------------------------------------------------- 1 | 1. config /data...Neo4jConfig set url username password 2 | 2. run: com.test.webui.WebuiApp 3 | (or mvn clean package -D skipTests 4 | java -jar webui-1.0-SNAPSHOT.jar) 5 | 3. http://localhost 6 | -------------------------------------------------------------------------------- /spring-boot-ui.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | -------------------------------------------------------------------------------- /webui/pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | spring-boot-ui 7 | springboot.demo 8 | 1.0-SNAPSHOT 9 | 10 | 4.0.0 11 | 12 | webui 13 | jar 14 | 15 | 16 | 17 | org.springframework.boot 18 | spring-boot-starter-thymeleaf 19 | 20 | 21 | springboot.demo 22 | data 23 | ${project.version} 24 | 25 | 26 | 27 | 28 | 29 | 30 | org.springframework.boot 31 | spring-boot-maven-plugin 32 | 33 | 34 | 35 | repackage 36 | 37 | 38 | 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /webui/src/main/java/com/test/webui/WebuiApp.java: -------------------------------------------------------------------------------- 1 | package com.test.webui; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.boot.autoconfigure.SpringBootApplication; 5 | import org.springframework.context.annotation.ComponentScan; 6 | 7 | @SpringBootApplication 8 | @ComponentScan(basePackages = "com.test") 9 | public class WebuiApp { 10 | public static void main(String[] args) { 11 | SpringApplication.run(WebuiApp.class, args); 12 | } 13 | } 14 | -------------------------------------------------------------------------------- /webui/src/main/java/com/test/webui/controller/ActorController.java: -------------------------------------------------------------------------------- 1 | package com.test.webui.controller; 2 | 3 | import com.test.data.domain.Actor; 4 | import com.test.data.repositories.ActorRepository; 5 | import org.slf4j.Logger; 6 | import org.slf4j.LoggerFactory; 7 | import org.springframework.beans.factory.annotation.Autowired; 8 | import org.springframework.data.domain.Page; 9 | import org.springframework.data.domain.PageRequest; 10 | import org.springframework.data.domain.Pageable; 11 | import org.springframework.data.domain.Sort; 12 | import org.springframework.ui.ModelMap; 13 | import org.springframework.web.bind.annotation.*; 14 | import org.springframework.web.servlet.ModelAndView; 15 | 16 | import javax.servlet.http.HttpServletRequest; 17 | 18 | 19 | @RestController 20 | @RequestMapping("/actor") 21 | public class ActorController { 22 | private static Logger logger = LoggerFactory.getLogger(ActorController.class); 23 | @Autowired 24 | private ActorRepository actorRepository; 25 | 26 | @RequestMapping("/index") 27 | public ModelAndView index(){ 28 | return new ModelAndView("actor/index"); 29 | } 30 | 31 | @RequestMapping(value="/{id}") 32 | public ModelAndView show(ModelMap model,@PathVariable Long id) { 33 | Actor actor = actorRepository.findOne(id); 34 | model.addAttribute("actor",actor); 35 | return new ModelAndView("actor/show"); 36 | } 37 | 38 | @RequestMapping("/new") 39 | public ModelAndView create(){ 40 | return new ModelAndView("actor/new"); 41 | } 42 | 43 | @RequestMapping(value="/save", method = RequestMethod.POST) 44 | public String save(Actor actor) throws Exception{ 45 | actorRepository.save(actor); 46 | logger.info("新增->ID={}", actor.getId()); 47 | return "1"; 48 | } 49 | 50 | @RequestMapping(value="/edit/{id}") 51 | public ModelAndView update(ModelMap model,@PathVariable Long id){ 52 | Actor actor = actorRepository.findOne(id); 53 | model.addAttribute("actor",actor); 54 | return new ModelAndView("actor/edit"); 55 | } 56 | 57 | @RequestMapping(method = RequestMethod.POST, value="/update") 58 | public String update(Actor actor) throws Exception{ 59 | actorRepository.save(actor); 60 | logger.info("修改->ID="+actor.getId()); 61 | return "1"; 62 | } 63 | 64 | @RequestMapping(value="/delete/{id}",method = RequestMethod.GET) 65 | public String delete(@PathVariable Long id) throws Exception{ 66 | Actor actor = actorRepository.findOne(id); 67 | actorRepository.delete(actor); 68 | logger.info("删除->ID="+id); 69 | return "1"; 70 | } 71 | 72 | @RequestMapping(value="/list") 73 | public Page list(HttpServletRequest request) throws Exception{ 74 | String name = request.getParameter("name"); 75 | String page = request.getParameter("page"); 76 | String size = request.getParameter("size"); 77 | Pageable pageable = new PageRequest(page==null? 0: Integer.parseInt(page), size==null? 10:Integer.parseInt(size), 78 | new Sort(Sort.Direction.DESC, "id")); 79 | 80 | return actorRepository.findAll(pageable); 81 | } 82 | 83 | } 84 | -------------------------------------------------------------------------------- /webui/src/main/java/com/test/webui/controller/MovieController.java: -------------------------------------------------------------------------------- 1 | package com.test.webui.controller; 2 | 3 | import com.test.data.domain.Actor; 4 | import com.test.data.domain.Movie; 5 | import com.test.data.repositories.ActorRepository; 6 | import com.test.data.repositories.MovieRepository; 7 | import com.test.data.service.PagesService; 8 | import org.neo4j.ogm.cypher.Filter; 9 | import org.neo4j.ogm.cypher.Filters; 10 | import org.slf4j.Logger; 11 | import org.slf4j.LoggerFactory; 12 | import org.springframework.beans.factory.annotation.Autowired; 13 | import org.springframework.data.domain.Page; 14 | import org.springframework.data.domain.PageRequest; 15 | import org.springframework.data.domain.Pageable; 16 | import org.springframework.data.domain.Sort; 17 | import org.springframework.ui.ModelMap; 18 | import org.springframework.util.StringUtils; 19 | import org.springframework.web.bind.annotation.*; 20 | import org.springframework.web.servlet.ModelAndView; 21 | 22 | import javax.servlet.http.HttpServletRequest; 23 | 24 | @RestController 25 | @RequestMapping("/movie") 26 | public class MovieController { 27 | private static Logger logger = LoggerFactory.getLogger(MovieController.class); 28 | @Autowired 29 | private MovieRepository movieRepository; 30 | @Autowired 31 | private ActorRepository actorRepository; 32 | @Autowired 33 | private PagesService pagesService; 34 | 35 | @RequestMapping("/index") 36 | public ModelAndView index(){ 37 | return new ModelAndView("movie/index"); 38 | } 39 | 40 | @RequestMapping(value="/{id}") 41 | public ModelAndView show(ModelMap model, @PathVariable Long id) { 42 | Movie movie = movieRepository.findOne(id); 43 | model.addAttribute("movie",movie); 44 | return new ModelAndView("movie/show"); 45 | } 46 | 47 | @RequestMapping("/new") 48 | public ModelAndView create(ModelMap model){ 49 | String[] files = {"/images/movie/西游记.jpg","/images/movie/西游记续集.jpg"}; 50 | model.addAttribute("files",files); 51 | return new ModelAndView("movie/new"); 52 | } 53 | 54 | @RequestMapping(value="/save", method = RequestMethod.POST) 55 | public String save(Movie movie) throws Exception{ 56 | movieRepository.save(movie); 57 | logger.info("新增->ID={}", movie.getId()); 58 | return "1"; 59 | } 60 | 61 | @RequestMapping(value="/edit/{id}") 62 | public ModelAndView update(ModelMap model, @PathVariable Long id){ 63 | Movie movie = movieRepository.findOne(id); 64 | String[] files = {"/images/movie/西游记.jpg","/images/movie/西游记续集.jpg"}; 65 | String[] rolelist = new String[]{"唐僧","孙悟空","猪八戒","沙僧"}; 66 | Iterable actors = actorRepository.findAll(); 67 | 68 | model.addAttribute("files", files); 69 | model.addAttribute("rolelist",rolelist); 70 | model.addAttribute("movie",movie); 71 | model.addAttribute("actors",actors); 72 | 73 | return new ModelAndView("movie/edit"); 74 | } 75 | 76 | @RequestMapping(method = RequestMethod.POST, value="/update") 77 | public String update(Movie movie, HttpServletRequest request) throws Exception{ 78 | String rolename = request.getParameter("rolename"); 79 | String actorid = request.getParameter("actorid"); 80 | 81 | Movie old = movieRepository.findOne(movie.getId()); 82 | old.setName(movie.getName()); 83 | old.setPhoto(movie.getPhoto()); 84 | old.setCreateDate(movie.getCreateDate()); 85 | 86 | if(!StringUtils.isEmpty(rolename) && !StringUtils.isEmpty(actorid)) { 87 | Actor actor = actorRepository.findOne(new Long(actorid)); 88 | old.addRole(actor, rolename); 89 | } 90 | movieRepository.save(old); 91 | logger.info("修改->ID="+old.getId()); 92 | return "1"; 93 | } 94 | 95 | @RequestMapping(value="/delete/{id}",method = RequestMethod.GET) 96 | public String delete(@PathVariable Long id) throws Exception{ 97 | Movie movie = movieRepository.findOne(id); 98 | movieRepository.delete(movie); 99 | logger.info("删除->ID="+id); 100 | return "1"; 101 | } 102 | 103 | @RequestMapping(value="/list") 104 | public Page list(HttpServletRequest request) throws Exception{ 105 | String name = request.getParameter("name"); 106 | String page = request.getParameter("page"); 107 | String size = request.getParameter("size"); 108 | Pageable pageable = new PageRequest(page==null? 0: Integer.parseInt(page), size==null? 10:Integer.parseInt(size), 109 | new Sort(Sort.Direction.DESC, "id")); 110 | 111 | Filters filters = new Filters(); 112 | if (!StringUtils.isEmpty(name)) { 113 | Filter filter = new Filter("name", name); 114 | filters.add(filter); 115 | } 116 | 117 | return pagesService.findAll(Movie.class, pageable, filters); 118 | } 119 | } 120 | -------------------------------------------------------------------------------- /webui/src/main/resources/application.yml: -------------------------------------------------------------------------------- 1 | server: 2 | port: 80 3 | tomcat: 4 | uri-encoding: UTF-8 5 | -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/arrow.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/global/selectDown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/global/selectDown.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/global/subMenuBk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/global/subMenuBk.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/global/togUpDownCircle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/global/togUpDownCircle.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/global/topLineBk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/global/topLineBk.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/global/wen.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/global/wen.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/addIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/addIcon.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/arr1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/arr1.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/arr2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/arr2.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/arr3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/arr3.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/arr4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/arr4.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/bg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/bg.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/blueBtn-62X30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/blueBtn-62X30.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/bryBk-256X118.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/bryBk-256X118.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/btn-56X29.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/btn-56X29.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/btn-93X38.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/btn-93X38.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/btnBk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/btnBk.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/closeIcon-14X14.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/closeIcon-14X14.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/del.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/del.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/deleteIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/deleteIcon.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/line.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/line.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/list-bk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/list-bk.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/radiusBlueBot-782.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/radiusBlueBot-782.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/radiusBlueMid-782.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/radiusBlueMid-782.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/radiusBlueTop-782.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/radiusBlueTop-782.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/radiusGrayBot-782.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/radiusGrayBot-782.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/radiusGrayTop-782.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/radiusGrayTop-782.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/selectDown.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/selectDown.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/selectIcon-15X14.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/selectIcon-15X14.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/togMoveIcon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/togMoveIcon.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/index/verticalLine.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/index/verticalLine.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/logo.png -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/movie/西游记.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/movie/西游记.jpg -------------------------------------------------------------------------------- /webui/src/main/resources/static/images/movie/西游记续集.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/images/movie/西游记续集.jpg -------------------------------------------------------------------------------- /webui/src/main/resources/static/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 欢迎 6 | 7 | 14 | 15 | ......请稍候! 16 | 17 | -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/My97DatePicker/lang/en.js: -------------------------------------------------------------------------------- 1 | var $lang={ 2 | errAlertMsg: "Invalid date or the date out of range,redo or not?", 3 | aWeekStr: ["wk", "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], 4 | aLongWeekStr:["wk","Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"], 5 | aMonStr: ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"], 6 | aLongMonStr: ["January","February","March","April","May","June","July","August","September","October","November","December"], 7 | clearStr: "Clear", 8 | todayStr: "Today", 9 | okStr: "OK", 10 | updateStr: "OK", 11 | timeStr: "Time", 12 | quickStr: "Quick Selection", 13 | err_1: 'MinDate Cannot be bigger than MaxDate!' 14 | } -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/My97DatePicker/lang/zh-cn.js: -------------------------------------------------------------------------------- 1 | var $lang={ 2 | errAlertMsg: "\u4E0D\u5408\u6CD5\u7684\u65E5\u671F\u683C\u5F0F\u6216\u8005\u65E5\u671F\u8D85\u51FA\u9650\u5B9A\u8303\u56F4,\u9700\u8981\u64A4\u9500\u5417?", 3 | aWeekStr: ["\u5468","\u65E5","\u4E00","\u4E8C","\u4E09","\u56DB","\u4E94","\u516D"], 4 | aLongWeekStr:["\u5468","\u661F\u671F\u65E5","\u661F\u671F\u4E00","\u661F\u671F\u4E8C","\u661F\u671F\u4E09","\u661F\u671F\u56DB","\u661F\u671F\u4E94","\u661F\u671F\u516D"], 5 | aMonStr: ["\u4E00\u6708","\u4E8C\u6708","\u4E09\u6708","\u56DB\u6708","\u4E94\u6708","\u516D\u6708","\u4E03\u6708","\u516B\u6708","\u4E5D\u6708","\u5341\u6708","\u5341\u4E00","\u5341\u4E8C"], 6 | aLongMonStr: ["\u4E00\u6708","\u4E8C\u6708","\u4E09\u6708","\u56DB\u6708","\u4E94\u6708","\u516D\u6708","\u4E03\u6708","\u516B\u6708","\u4E5D\u6708","\u5341\u6708","\u5341\u4E00\u6708","\u5341\u4E8C\u6708"], 7 | clearStr: "\u6E05\u7A7A", 8 | todayStr: "\u4ECA\u5929", 9 | okStr: "\u786E\u5B9A", 10 | updateStr: "\u786E\u5B9A", 11 | timeStr: "\u65F6\u95F4", 12 | quickStr: "\u5FEB\u901F\u9009\u62E9", 13 | err_1: '\u6700\u5C0F\u65E5\u671F\u4E0D\u80FD\u5927\u4E8E\u6700\u5927\u65E5\u671F!' 14 | } -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/My97DatePicker/lang/zh-tw.js: -------------------------------------------------------------------------------- 1 | var $lang={ 2 | errAlertMsg: "\u4E0D\u5408\u6CD5\u7684\u65E5\u671F\u683C\u5F0F\u6216\u8005\u65E5\u671F\u8D85\u51FA\u9650\u5B9A\u7BC4\u570D,\u9700\u8981\u64A4\u92B7\u55CE?", 3 | aWeekStr: ["\u5468","\u65E5","\u4E00","\u4E8C","\u4E09","\u56DB","\u4E94","\u516D"], 4 | aLongWeekStr:["\u5468","\u661F\u671F\u65E5","\u661F\u671F\u4E00","\u661F\u671F\u4E8C","\u661F\u671F\u4E09","\u661F\u671F\u56DB","\u661F\u671F\u4E94","\u661F\u671F\u516D"], 5 | aMonStr: ["\u4E00\u6708","\u4E8C\u6708","\u4E09\u6708","\u56DB\u6708","\u4E94\u6708","\u516D\u6708","\u4E03\u6708","\u516B\u6708","\u4E5D\u6708","\u5341\u6708","\u5341\u4E00","\u5341\u4E8C"], 6 | aLongMonStr: ["\u4E00\u6708","\u4E8C\u6708","\u4E09\u6708","\u56DB\u6708","\u4E94\u6708","\u516D\u6708","\u4E03\u6708","\u516B\u6708","\u4E5D\u6708","\u5341\u6708","\u5341\u4E00\u6708","\u5341\u4E8C\u6708"], 7 | clearStr: "\u6E05\u7A7A", 8 | todayStr: "\u4ECA\u5929", 9 | okStr: "\u78BA\u5B9A", 10 | updateStr: "\u78BA\u5B9A", 11 | timeStr: "\u6642\u9593", 12 | quickStr: "\u5FEB\u901F\u9078\u64C7", 13 | err_1: '\u6700\u5C0F\u65E5\u671F\u4E0D\u80FD\u5927\u65BC\u6700\u5927\u65E5\u671F!' 14 | } -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/My97DatePicker/skin/WdatePicker.css: -------------------------------------------------------------------------------- 1 | .Wdate{ 2 | /*border:#999 1px solid;*/ 3 | /*height:20px;*/ 4 | background:#fff url(datePicker.gif) no-repeat right; 5 | } 6 | .Wdate::-ms-clear{display:none;} 7 | 8 | .WdateFmtErr{ 9 | font-weight:bold; 10 | color:red; 11 | } -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/My97DatePicker/skin/datePicker.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/scripts/My97DatePicker/skin/datePicker.gif -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/My97DatePicker/skin/default/datepicker.css: -------------------------------------------------------------------------------- 1 | /* 2 | * My97 DatePicker 4.8 3 | */ 4 | 5 | .WdateDiv{ 6 | width:180px; 7 | background-color:#FFFFFF; 8 | border:#bbb 1px solid; 9 | padding:2px; 10 | } 11 | 12 | .WdateDiv2{ 13 | width:360px; 14 | } 15 | .WdateDiv *{font-size:9pt;} 16 | 17 | .WdateDiv .NavImg a{ 18 | display:block; 19 | cursor:pointer; 20 | height:16px; 21 | width:16px; 22 | } 23 | 24 | .WdateDiv .NavImgll a{ 25 | float:left; 26 | background:transparent url(img.gif) no-repeat scroll 0 0; 27 | } 28 | .WdateDiv .NavImgl a{ 29 | float:left; 30 | background:transparent url(img.gif) no-repeat scroll -16px 0; 31 | } 32 | .WdateDiv .NavImgr a{ 33 | float:right; 34 | background:transparent url(img.gif) no-repeat scroll -32px 0; 35 | } 36 | .WdateDiv .NavImgrr a{ 37 | float:right; 38 | background:transparent url(img.gif) no-repeat scroll -48px 0; 39 | } 40 | 41 | .WdateDiv #dpTitle{ 42 | height:24px; 43 | margin-bottom:2px; 44 | padding:1px; 45 | } 46 | 47 | .WdateDiv .yminput{ 48 | margin-top:2px; 49 | text-align:center; 50 | height:20px; 51 | border:0px; 52 | width:50px; 53 | cursor:pointer; 54 | } 55 | 56 | .WdateDiv .yminputfocus{ 57 | margin-top:2px; 58 | text-align:center; 59 | font-weight:bold; 60 | height:20px; 61 | color:blue; 62 | border:#ccc 1px solid; 63 | width:50px; 64 | } 65 | 66 | .WdateDiv .menuSel{ 67 | z-index:1; 68 | position:absolute; 69 | background-color:#FFFFFF; 70 | border:#ccc 1px solid; 71 | display:none; 72 | } 73 | 74 | .WdateDiv .menu{ 75 | cursor:pointer; 76 | background-color:#fff; 77 | } 78 | 79 | .WdateDiv .menuOn{ 80 | cursor:pointer; 81 | background-color:#BEEBEE; 82 | } 83 | 84 | .WdateDiv .invalidMenu{ 85 | color:#aaa; 86 | } 87 | 88 | .WdateDiv .YMenu{ 89 | margin-top:20px; 90 | 91 | } 92 | 93 | .WdateDiv .MMenu{ 94 | margin-top:20px; 95 | *width:62px; 96 | } 97 | 98 | .WdateDiv .hhMenu{ 99 | margin-top:-90px; 100 | margin-left:26px; 101 | } 102 | 103 | .WdateDiv .mmMenu{ 104 | margin-top:-46px; 105 | margin-left:26px; 106 | } 107 | 108 | .WdateDiv .ssMenu{ 109 | margin-top:-24px; 110 | margin-left:26px; 111 | } 112 | 113 | .WdateDiv .Wweek { 114 | text-align:center; 115 | background:#DAF3F5; 116 | border-right:#BDEBEE 1px solid; 117 | } 118 | 119 | .WdateDiv .MTitle{ 120 | background-color:#BDEBEE; 121 | } 122 | .WdateDiv .WdayTable2{ 123 | border-collapse:collapse; 124 | border:#c5d9e8 1px solid; 125 | } 126 | .WdateDiv .WdayTable2 table{ 127 | border:0; 128 | } 129 | 130 | .WdateDiv .WdayTable{ 131 | line-height:20px; 132 | border:#c5d9e8 1px solid; 133 | } 134 | .WdateDiv .WdayTable td{ 135 | text-align:center; 136 | } 137 | 138 | .WdateDiv .Wday{ 139 | cursor:pointer; 140 | } 141 | 142 | .WdateDiv .WdayOn{ 143 | cursor:pointer; 144 | background-color:#C0EBEF; 145 | } 146 | 147 | .WdateDiv .Wwday{ 148 | cursor:pointer; 149 | color:#FF2F2F; 150 | } 151 | 152 | .WdateDiv .WwdayOn{ 153 | cursor:pointer; 154 | color:#000; 155 | background-color:#C0EBEF; 156 | } 157 | .WdateDiv .Wtoday{ 158 | cursor:pointer; 159 | color:blue; 160 | } 161 | .WdateDiv .Wselday{ 162 | background-color:#A9E4E9; 163 | } 164 | .WdateDiv .WspecialDay{ 165 | background-color:#66F4DF; 166 | } 167 | 168 | .WdateDiv .WotherDay{ 169 | cursor:pointer; 170 | color:#6A6AFF; 171 | } 172 | 173 | .WdateDiv .WotherDayOn{ 174 | cursor:pointer; 175 | background-color:#C0EBEF; 176 | } 177 | 178 | .WdateDiv .WinvalidDay{ 179 | color:#aaa; 180 | } 181 | 182 | .WdateDiv #dpTime{ 183 | float:left; 184 | margin-top:3px; 185 | margin-right:30px; 186 | } 187 | 188 | .WdateDiv #dpTime #dpTimeStr{ 189 | margin-left:1px; 190 | } 191 | 192 | .WdateDiv #dpTime input{ 193 | width:18px; 194 | height:20px; 195 | text-align:center; 196 | border:#ccc 1px solid; 197 | } 198 | 199 | .WdateDiv #dpTime .tB{ 200 | border-right:0px; 201 | } 202 | 203 | .WdateDiv #dpTime .tE{ 204 | border-left:0; 205 | border-right:0; 206 | } 207 | 208 | .WdateDiv #dpTime .tm{ 209 | width:7px; 210 | border-left:0; 211 | border-right:0; 212 | } 213 | 214 | .WdateDiv #dpTime #dpTimeUp{ 215 | height:10px; 216 | width:13px; 217 | border:0px; 218 | background:url(img.gif) no-repeat -32px -16px; 219 | } 220 | 221 | .WdateDiv #dpTime #dpTimeDown{ 222 | height:10px; 223 | width:13px; 224 | border:0px; 225 | background:url(img.gif) no-repeat -48px -16px; 226 | } 227 | 228 | .WdateDiv #dpQS { 229 | float:left; 230 | margin-right:3px; 231 | margin-top:3px; 232 | background:url(img.gif) no-repeat 0px -16px; 233 | width:20px; 234 | height:20px; 235 | cursor:pointer; 236 | } 237 | .WdateDiv #dpControl { 238 | text-align:right; 239 | } 240 | .WdateDiv .dpButton{ 241 | height:20px; 242 | width:45px; 243 | border:#ccc 1px solid; 244 | margin-top:2px; 245 | margin-right:1px; 246 | } -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/My97DatePicker/skin/default/img.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/scripts/My97DatePicker/skin/default/img.gif -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/My97DatePicker/skin/whyGreen/bg.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/scripts/My97DatePicker/skin/whyGreen/bg.jpg -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/My97DatePicker/skin/whyGreen/datepicker.css: -------------------------------------------------------------------------------- 1 | /* 2 | * My97 DatePicker 4.8 Skin:whyGreen 3 | */ 4 | .WdateDiv{ 5 | width:180px; 6 | background-color:#fff; 7 | border:#C5E1E4 1px solid; 8 | padding:2px; 9 | } 10 | 11 | .WdateDiv2{ 12 | width:360px; 13 | } 14 | .WdateDiv *{font-size:9pt;} 15 | 16 | .WdateDiv .NavImg a{ 17 | cursor:pointer; 18 | display:block; 19 | width:16px; 20 | height:16px; 21 | margin-top:1px; 22 | } 23 | 24 | .WdateDiv .NavImgll a{ 25 | float:left; 26 | background:url(img.gif) no-repeat; 27 | } 28 | .WdateDiv .NavImgl a{ 29 | float:left; 30 | background:url(img.gif) no-repeat -16px 0px; 31 | } 32 | .WdateDiv .NavImgr a{ 33 | float:right; 34 | background:url(img.gif) no-repeat -32px 0px; 35 | } 36 | .WdateDiv .NavImgrr a{ 37 | float:right; 38 | background:url(img.gif) no-repeat -48px 0px; 39 | } 40 | 41 | .WdateDiv #dpTitle{ 42 | height:24px; 43 | padding:1px; 44 | border:#c5d9e8 1px solid; 45 | background:url(bg.jpg); 46 | margin-bottom:2px; 47 | } 48 | 49 | .WdateDiv .yminput{ 50 | margin-top:2px; 51 | text-align:center; 52 | border:0px; 53 | height:20px; 54 | width:50px; 55 | color:#034c50; 56 | background-color:transparent; 57 | cursor:pointer; 58 | } 59 | 60 | .WdateDiv .yminputfocus{ 61 | margin-top:2px; 62 | text-align:center; 63 | border:#939393 1px solid; 64 | font-weight:bold; 65 | color:#034c50; 66 | height:20px; 67 | width:50px; 68 | } 69 | 70 | .WdateDiv .menuSel{ 71 | z-index:1; 72 | position:absolute; 73 | background-color:#FFFFFF; 74 | border:#A3C6C8 1px solid; 75 | display:none; 76 | } 77 | 78 | .WdateDiv .menu{ 79 | cursor:pointer; 80 | background-color:#fff; 81 | color:#11777C; 82 | } 83 | 84 | .WdateDiv .menuOn{ 85 | cursor:pointer; 86 | background-color:#BEEBEE; 87 | } 88 | 89 | .WdateDiv .invalidMenu{ 90 | color:#aaa; 91 | } 92 | 93 | .WdateDiv .YMenu{ 94 | margin-top:20px; 95 | } 96 | 97 | .WdateDiv .MMenu{ 98 | margin-top:20px; 99 | *width:62px; 100 | } 101 | 102 | .WdateDiv .hhMenu{ 103 | margin-top:-90px; 104 | margin-left:26px; 105 | } 106 | 107 | .WdateDiv .mmMenu{ 108 | margin-top:-46px; 109 | margin-left:26px; 110 | } 111 | 112 | .WdateDiv .ssMenu{ 113 | margin-top:-24px; 114 | margin-left:26px; 115 | } 116 | 117 | .WdateDiv .Wweek { 118 | text-align:center; 119 | background:#DAF3F5; 120 | border-right:#BDEBEE 1px solid; 121 | } 122 | 123 | .WdateDiv .MTitle{ 124 | color:#13777e; 125 | background-color:#bdebee; 126 | } 127 | .WdateDiv .WdayTable2{ 128 | border-collapse:collapse; 129 | border:#BEE9F0 1px solid; 130 | } 131 | .WdateDiv .WdayTable2 table{ 132 | border:0; 133 | } 134 | 135 | .WdateDiv .WdayTable{ 136 | line-height:20px; 137 | color:#13777e; 138 | background-color:#edfbfb; 139 | border:#BEE9F0 1px solid; 140 | } 141 | .WdateDiv .WdayTable td{ 142 | text-align:center; 143 | } 144 | 145 | .WdateDiv .Wday{ 146 | cursor:pointer; 147 | } 148 | 149 | .WdateDiv .WdayOn{ 150 | cursor:pointer; 151 | background-color:#74d2d9 ; 152 | } 153 | 154 | .WdateDiv .Wwday{ 155 | cursor:pointer; 156 | color:#ab1e1e; 157 | } 158 | 159 | .WdateDiv .WwdayOn{ 160 | cursor:pointer; 161 | background-color:#74d2d9; 162 | } 163 | .WdateDiv .Wtoday{ 164 | cursor:pointer; 165 | color:blue; 166 | } 167 | .WdateDiv .Wselday{ 168 | background-color:#A7E2E7; 169 | } 170 | .WdateDiv .WspecialDay{ 171 | background-color:#66F4DF; 172 | } 173 | 174 | .WdateDiv .WotherDay{ 175 | cursor:pointer; 176 | color:#0099CC; 177 | } 178 | 179 | .WdateDiv .WotherDayOn{ 180 | cursor:pointer; 181 | background-color:#C0EBEF; 182 | } 183 | 184 | .WdateDiv .WinvalidDay{ 185 | color:#aaa; 186 | } 187 | 188 | .WdateDiv #dpTime{ 189 | float:left; 190 | margin-top:3px; 191 | margin-right:30px; 192 | } 193 | 194 | .WdateDiv #dpTime #dpTimeStr{ 195 | margin-left:1px; 196 | color:#497F7F; 197 | } 198 | 199 | .WdateDiv #dpTime input{ 200 | height:20px; 201 | width:18px; 202 | text-align:center; 203 | color:#333; 204 | border:#61CAD0 1px solid; 205 | } 206 | 207 | .WdateDiv #dpTime .tB{ 208 | border-right:0px; 209 | } 210 | 211 | .WdateDiv #dpTime .tE{ 212 | border-left:0; 213 | border-right:0; 214 | } 215 | 216 | .WdateDiv #dpTime .tm{ 217 | width:7px; 218 | border-left:0; 219 | border-right:0; 220 | } 221 | 222 | .WdateDiv #dpTime #dpTimeUp{ 223 | height:10px; 224 | width:13px; 225 | border:0px; 226 | background:url(img.gif) no-repeat -32px -16px; 227 | } 228 | 229 | .WdateDiv #dpTime #dpTimeDown{ 230 | height:10px; 231 | width:13px; 232 | border:0px; 233 | background:url(img.gif) no-repeat -48px -16px; 234 | } 235 | 236 | .WdateDiv #dpQS { 237 | float:left; 238 | margin-right:3px; 239 | margin-top:3px; 240 | background:url(img.gif) no-repeat 0px -16px; 241 | width:20px; 242 | height:20px; 243 | cursor:pointer; 244 | } 245 | .WdateDiv #dpControl { 246 | text-align:right; 247 | margin-top:3px; 248 | } 249 | .WdateDiv .dpButton{ 250 | height:20px; 251 | width:45px; 252 | margin-top:2px; 253 | border:#38B1B9 1px solid; 254 | background-color:#CFEBEE; 255 | color:#08575B; 256 | } -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/My97DatePicker/skin/whyGreen/img.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/scripts/My97DatePicker/skin/whyGreen/img.gif -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/actor/edit.js: -------------------------------------------------------------------------------- 1 | $(function(){ 2 | $('#saveForm').validate({ 3 | rules: { 4 | name :{required:true} 5 | },submitHandler:function(){ 6 | return false; 7 | },errorPlacement:function(error,ele){ 8 | ele.attr('data',error.html()); 9 | },success:function(label){ 10 | 11 | },ignore: '' 12 | }); 13 | $('.saveBtn').click(function(){ 14 | if($('#saveForm').valid()){ 15 | $.ajax({ 16 | type: "POST", 17 | url: "./update", 18 | data: $("#saveForm").serialize(), 19 | headers: {"Content-type": "application/x-www-form-urlencoded;charset=UTF-8"}, 20 | success: function (data) { 21 | if (data == 1) { 22 | alert("编辑成功"); 23 | pageaction(); 24 | closeDialog(); 25 | } else { 26 | alert(data); 27 | } 28 | } 29 | }); 30 | }else{ 31 | alert('数据验证失败,请检查!'); 32 | } 33 | }); 34 | 35 | }); 36 | -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/actor/list.js: -------------------------------------------------------------------------------- 1 | $(function () { 2 | $('#searchBtn').click(function(){ 3 | pageaction(); 4 | }); 5 | $('#addBtn').click(function(){ 6 | create(); 7 | }); 8 | //初始化分页 9 | pageaction(); 10 | var pg = $('.pagination'); 11 | $('#pageSelect').live("change",function(){ 12 | pg.trigger('setPage', [$(this).val()-1]); 13 | }); 14 | 15 | }); 16 | 17 | //分页的参数设置 18 | var getOpt = function(){ 19 | var opt = { 20 | items_per_page: 10, //每页记录数 21 | num_display_entries: 3, //中间显示的页数个数 默认为10 22 | current_page:0, //当前页 23 | num_edge_entries:1, //头尾显示的页数个数 默认为0 24 | link_to:"javascript:void(0)", 25 | prev_text:"上页", 26 | next_text:"下页", 27 | load_first_page:true, 28 | show_total_info:true , 29 | show_first_last:true, 30 | first_text:"首页", 31 | last_text:"尾页", 32 | hasSelect:false, 33 | callback: pageselectCallback //回调函数 34 | } 35 | return opt; 36 | } 37 | //分页开始 38 | var currentPageData = null ; 39 | var pageaction = function(){ 40 | $.get('./list?t='+new Date().getTime(),{ 41 | name:$("#name").val() 42 | },function(data){ 43 | currentPageData = data.content; 44 | $(".pagination").pagination(data.totalElements, getOpt()); 45 | }); 46 | } 47 | 48 | var pageselectCallback = function(page_index, jq, size){ 49 | if(currentPageData!=null){ 50 | fillData(currentPageData); 51 | currentPageData = null; 52 | }else 53 | $.get('./list?t='+new Date().getTime(),{ 54 | size:size,page:page_index,name:$("#name").val() 55 | },function(data){ 56 | fillData(data.content); 57 | }); 58 | } 59 | //填充分页数据 60 | function fillData(data){ 61 | var $list = $('#tbodyContent').empty(); 62 | $.each(data,function(k,v){ 63 | var html = "" ; 64 | html += ' ' + 65 | ''+ (v.id==null?'':v.id) +'' + 66 | ''+ (v.name==null?'':v.name) +'' + 67 | ''+ (v.born==null?'': getSmpFormatDateByLong(v.born,true)) +'' ; 68 | html += '查看修改删除' ; 69 | html +='' ; 70 | 71 | $list.append($(html)); 72 | }); 73 | } 74 | //分页结束 75 | var artdialog ; 76 | function detail(id){ 77 | $.get("./"+id,{ts:new Date().getTime()},function(data){ 78 | art.dialog({ 79 | lock:true, 80 | opacity:0.3, 81 | title: "查看信息", 82 | width:'750px', 83 | height: 'auto', 84 | left: '50%', 85 | top: '50%', 86 | content:data, 87 | esc: true, 88 | init: function(){ 89 | artdialog = this; 90 | }, 91 | close: function(){ 92 | artdialog = null; 93 | } 94 | }); 95 | }); 96 | } 97 | function edit(id){ 98 | $.get("./edit/"+id,{ts:new Date().getTime()},function(data){ 99 | art.dialog({ 100 | lock:true, 101 | opacity:0.3, 102 | title: "修改", 103 | width:'750px', 104 | height: 'auto', 105 | left: '50%', 106 | top: '50%', 107 | content:data, 108 | esc: true, 109 | init: function(){ 110 | artdialog = this; 111 | }, 112 | close: function(){ 113 | artdialog = null; 114 | } 115 | }); 116 | }); 117 | } 118 | function del(id){ 119 | if(!confirm("您确定删除此记录吗?")){ 120 | return false; 121 | } 122 | $.get("./delete/"+id,{ts:new Date().getTime()},function(data){ 123 | if(data==1){ 124 | alert("删除成功"); 125 | pageaction(); 126 | }else{ 127 | alert(data); 128 | } 129 | }); 130 | } 131 | function create(){ 132 | $.get("./new",{ts:new Date().getTime()},function(data){ 133 | art.dialog({ 134 | lock:true, 135 | opacity:0.3, 136 | title: "新增", 137 | width:'750px', 138 | height: 'auto', 139 | left: '50%', 140 | top: '50%', 141 | content:data, 142 | esc: true, 143 | init: function(){ 144 | artdialog = this; 145 | }, 146 | close: function(){ 147 | artdialog = null; 148 | } 149 | }); 150 | }); 151 | } 152 | 153 | function closeDialog() { 154 | artdialog.close(); 155 | } 156 | -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/actor/new.js: -------------------------------------------------------------------------------- 1 | $(function(){ 2 | $('#saveForm').validate({ 3 | rules: { 4 | name :{required:true}, 5 | createDate :{required:true} 6 | },messages:{ 7 | name :{required:"必填"}, 8 | createDate :{required:"必填"} 9 | } 10 | }); 11 | $('.saveBtn').click(function(){ 12 | if($('#saveForm').valid()){ 13 | $.ajax({ 14 | type: "POST", 15 | url: "./save", 16 | data: $("#saveForm").serialize(), 17 | headers: {"Content-type": "application/x-www-form-urlencoded;charset=UTF-8"}, 18 | success: function (data) { 19 | if (data == 1) { 20 | alert("保存成功"); 21 | pageaction(); 22 | closeDialog(); 23 | } else { 24 | alert(data); 25 | } 26 | }, 27 | error:function(data){ 28 | var e; 29 | $.each(data,function(v){ 30 | e += v + " "; 31 | }); 32 | alert(e); 33 | } 34 | }); 35 | }else{ 36 | alert('数据验证失败,请检查!'); 37 | } 38 | }); 39 | }); 40 | -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/artDialog/default.css: -------------------------------------------------------------------------------- 1 | @charset "utf-8"; 2 | /* 3 | * artDialog skin 4 | * http://code.google.com/p/artdialog/ 5 | * (c) 2009-2011 TangBin, http://www.planeArt.cn 6 | * 7 | * This is licensed under the GNU LGPL, version 2.1 or later. 8 | * For details, see: http://creativecommons.org/licenses/LGPL/2.1/ 9 | */ 10 | 11 | /* common start */ 12 | body { _margin:0; _height:100%; /*IE6 BUG*/ } 13 | .aui_outer { text-align:left; } 14 | table.aui_border, table.aui_dialog { border:0; margin:0; border-collapse:collapse; width:auto; } 15 | .aui_nw, .aui_n, .aui_ne, .aui_w, .aui_c, .aui_e, .aui_sw, .aui_s, .aui_se, .aui_header, .aui_tdIcon, .aui_main, .aui_footer { padding:0; } 16 | .aui_header, .aui_buttons button { font: 12px/1.11 'Microsoft Yahei', Tahoma, Arial, Helvetica, STHeiti; _font-family:Tahoma,Arial,Helvetica,STHeiti; -o-font-family: Tahoma, Arial; } 17 | .aui_title { overflow:hidden; text-overflow: ellipsis; } 18 | .aui_state_noTitle .aui_title { display:none; } 19 | .aui_close { display:block; position:absolute; text-decoration:none; outline:none; _cursor:pointer; } 20 | .aui_close:hover { text-decoration:none; } 21 | .aui_main { text-align:center; min-width:9em; min-width:0\9/*IE8 BUG*/; } 22 | .aui_content { display:inline-block; *zoom:1; *display:inline; text-align:left; border:none 0; } 23 | .aui_content.aui_state_full { display:block; width:100%; margin:0; padding:0!important; height:100%; } 24 | .aui_loading { width:96px; height:32px; text-align:left; text-indent:-999em; overflow:hidden; background:url(icons/loading.gif) no-repeat center center; } 25 | .aui_icon { vertical-align: middle; } 26 | .aui_icon div { width:48px; height:48px; margin:10px 0 10px 10px; background-position: center center; background-repeat:no-repeat; } 27 | .aui_buttons { padding:8px; text-align:right; white-space:nowrap; } 28 | .aui_buttons button { margin-left:15px; padding: 6px 8px; cursor: pointer; display: inline-block; text-align: center; line-height: 1; *padding:4px 10px; *height:2em; letter-spacing:2px; font-family: Tahoma, Arial/9!important; width:auto; overflow:visible; *width:1; color: #333; border: solid 1px #999; border-radius: 5px; background: #DDD; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#FFFFFF', endColorstr='#DDDDDD'); background: linear-gradient(top, #FFF, #DDD); background: -moz-linear-gradient(top, #FFF, #DDD); background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#FFF), to(#DDD)); text-shadow: 0px 1px 1px rgba(255, 255, 255, 1); box-shadow: 0 1px 0 rgba(255, 255, 255, .7), 0 -1px 0 rgba(0, 0, 0, .09); -moz-transition:-moz-box-shadow linear .2s; -webkit-transition: -webkit-box-shadow linear .2s; transition: box-shadow linear .2s; } 29 | .aui_buttons button::-moz-focus-inner{ border:0; padding:0; margin:0; } 30 | .aui_buttons button:focus { outline:none 0; border-color:#426DC9; box-shadow:0 0 8px rgba(66, 109, 201, .9); } 31 | .aui_buttons button:hover { color:#000; border-color:#666; } 32 | .aui_buttons button:active { border-color:#666; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#DDDDDD', endColorstr='#FFFFFF'); background: linear-gradient(top, #DDD, #FFF); background: -moz-linear-gradient(top, #DDD, #FFF); background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#DDD), to(#FFF)); box-shadow:inset 0 1px 5px rgba(66, 109, 201, .9), inset 0 1px 1em rgba(0, 0, 0, .3); } 33 | .aui_buttons button[disabled] { cursor:default; color:#666; background:#DDD; border: solid 1px #999; filter:alpha(opacity=50); opacity:.5; box-shadow:none; } 34 | button.aui_state_highlight { color: #FFF; border: solid 1px #1c6a9e; background: #2288cc; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#33bbee', endColorstr='#2288cc'); background: linear-gradient(top, #33bbee, #2288cc); background: -moz-linear-gradient(top, #33bbee, #2288cc); background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#33bbee), to(#2288cc)); text-shadow: -1px -1px 1px #1c6a9e; } 35 | button.aui_state_highlight:hover { color:#FFF; border-color:#0F3A56; } 36 | button.aui_state_highlight:active { border-color:#1c6a9e; filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#33bbee', endColorstr='#2288cc'); background: linear-gradient(top, #33bbee, #2288cc); background: -moz-linear-gradient(top, #33bbee, #2288cc); background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#33bbee), to(#2288cc)); } 37 | /* common end */ 38 | 39 | .aui_inner { background:#FFF; } 40 | .aui_outer, .aui_inner { border:1px solid rgba(0, 0, 0, .7); border:1px solid #333\9; } 41 | .aui_border { box-shadow: inset 0 0 1px rgba(255, 255, 255, .9); } 42 | .aui_nw, .aui_ne, .aui_sw, .aui_se { width:8px; height:8px; } 43 | .aui_nw, .aui_n, .aui_ne, .aui_w, .aui_e, .aui_sw, .aui_s, .aui_se { background:rgba(0, 0, 0, .4); background:#000\9!important; filter:alpha(opacity=40); } 44 | .aui_state_lock .aui_nw, .aui_state_lock .aui_n, .aui_state_lock .aui_ne, .aui_state_lock .aui_w, .aui_state_lock .aui_e, .aui_state_lock .aui_sw, .aui_state_lock .aui_s, .aui_state_lock .aui_se { background:rgba(0, 0, 0, .5); background:#000\9!important; filter:alpha(opacity=50); } 45 | .aui_state_focus .aui_dialog { box-shadow: 0 0 3px rgba(0, 0, 0, 0.4); } 46 | .aui_state_focus .aui_outer { box-shadow: 0 2px 3px rgba(0, 0, 0, 0.1); } 47 | .aui_state_lock .aui_border { box-shadow:0 3px 26px rgba(0, 0, 0, .9); } 48 | .aui_state_drag .aui_outer, .aui_outer:active { box-shadow:none; } 49 | .aui_titleBar { position:relative; height:100%; } 50 | .aui_title { height:28px; line-height:27px; padding:0 28px 0 10px; text-shadow:0 1px 0 rgba(255, 255, 255, .7); background-color:#edf5f8; font-weight:bold; color:#95a7ae; font-family: Tahoma, Arial/9!important; background-color:#bdc6cd; background: linear-gradient(top, #edf5f8, #bdc6cd); background: -moz-linear-gradient(top, #edf5f8, #bdc6cd); background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#edf5f8), to(#bdc6cd)); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#edf5f8', endColorstr='#bdc6cd'); border-top:1px solid #edf5f8; border-bottom:1px solid #b6bec5; } 51 | .aui_state_focus .aui_title { color:#4c5a5f; } 52 | .aui_state_drag .aui_title { background: linear-gradient(top, #bdc6cd, #edf5f8); background: -moz-linear-gradient(top, #bdc6cd, #edf5f8); background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#bdc6cd), to(#edf5f8)); filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#bdc6cd', endColorstr='#edf5f8'); box-shadow:none; } 53 | .aui_state_drag .aui_titleBar { box-shadow:none; } 54 | .aui_close { padding:0; top:4px; right:4px; width:21px; height:21px; line-height:21px; font-size:18px; color:#68767b; text-align:center; font-family: Helvetica, STHeiti; _font-family: '\u9ed1\u4f53', 'Book Antiqua', Palatino; text-shadow:0 1px 0 rgba(255, 255, 255, .9); } 55 | .aui_close:hover { color:#C72015; } 56 | .aui_close:active { box-shadow: none; } 57 | .aui_content { color:#666;float:left; } 58 | .aui_state_focus .aui_content { color:#000; } 59 | .aui_buttons { background-color:#F6F6F6; border-top:solid 1px #DADEE5; } 60 | .aui_state_noTitle .aui_nw, .aui_state_noTitle .aui_ne, .aui_state_noTitle .aui_sw, .aui_state_noTitle .aui_se { width:3px; height:3px; } 61 | .aui_state_noTitle .aui_inner { border:1px solid #666; background:#FFF; } 62 | .aui_state_noTitle .aui_outer { border:none 0; box-shadow:none; } 63 | .aui_state_noTitle .aui_nw, .aui_state_noTitle .aui_n, .aui_state_noTitle .aui_ne, .aui_state_noTitle .aui_w, .aui_state_noTitle .aui_e, .aui_state_noTitle .aui_sw, .aui_state_noTitle .aui_s, .aui_state_noTitle .aui_se { background:rgba(0, 0, 0, .05); background:#000\9!important; filter:alpha(opacity=5)!important; } 64 | .aui_state_noTitle .aui_titleBar { bottom:0; _bottom:0; _margin-top:0; } 65 | .aui_state_noTitle .aui_close { top:0; right:0; width:18px; height:18px; line-height:18px; text-align:center; text-indent:0; font-family: Helvetica, STHeiti; _font-family: '\u9ed1\u4f53', 'Book Antiqua', Palatino; font-size:18px; text-decoration:none; color:#214FA3; background:none; filter:!important; } 66 | .aui_state_noTitle .aui_close:hover, .aui_state_noTitle .aui_close:active { text-decoration:none; color:#900; } 67 | .aui_state_noTitle .aui_dialog { box-shadow: none; } -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/artDialog/icons/loading.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/chenfromsz/spring-boot-ui/2adff5373224d260ba7ec7ec13fb613086092fa7/webui/src/main/resources/static/scripts/artDialog/icons/loading.gif -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/common.js: -------------------------------------------------------------------------------- 1 | function getScrollTop() { 2 | try { 3 | var scrollTop = document.body.scrollTop || document.documentElement.scrollTop; 4 | } catch (e) { 5 | 6 | } 7 | return scrollTop; 8 | } 9 | function showWindowPop(state) { 10 | if (state === undefined) { 11 | state = true; 12 | } 13 | if (state) { 14 | var contentHeight = $(window).height() , top = getScrollTop() + (contentHeight - $('#windowTipBox').height()) / 2; 15 | $('#windowShadow').height($(document).height()).show(); 16 | $('#windowTipBox').css('top', (top < 0 ? 36 : top) + 'px').show(); 17 | } else { 18 | $('#windowTipBox').hide(); 19 | $('#windowShadow').hide(); 20 | } 21 | } 22 | $(function () { 23 | $('.columnLeftMenu h6').live('click', function () { 24 | var $this = $(this); 25 | $this.toggleClass('isOpen'); 26 | if (!$this.hasClass('isOpen')) { 27 | $this.next('ul').slideDown('300'); 28 | } else { 29 | $this.next('ul').slideUp('300'); 30 | } 31 | }); 32 | $('.selectMode').live("change", (function () { 33 | var $this = $(this) , val = $(this).find('option:selected').text(); 34 | $this.siblings('input').val(val); 35 | })); 36 | }); 37 | 38 | function isEmpty(obj){ 39 | if (obj == undefined||obj ==null||obj =='') { 40 | return true; 41 | } 42 | return false; 43 | } 44 | -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/imageselect.js: -------------------------------------------------------------------------------- 1 | (function($){var methods={init:function(options){if(!/select/i.test(this.tagName)){return false;} 2 | var element=$(this);var selectName=element.attr('name');var id='jq_imageselect_'+ selectName;if($('#'+id).length>0){return;} 3 | var iWidth=options.width>options.dropdownWidth?options.width:options.dropdownWidth;var imageSelect=$(document.createElement('div')).attr('id',id).addClass('jqis');imageSelect.css('width',iWidth+'px').css('height',options.height+'px');var header=$(document.createElement('div')).addClass('jqis_header');header.css('width',options.width+'px').css('height',options.height+'px');header.css('text-align','center').css('background-color',options.backgroundColor);header.css('border','1px solid '+ options.borderColor);var dropdown=$(document.createElement('div')).addClass('jqis_dropdown');dropdown.css('width',options.dropdownWidth+'px');dropdown.css('z-index',options.z).css('background-color',options.backgroundColor).css('border','1px solid '+ options.borderColor);;dropdown.hide();var selectedImage=$('option:selected',element).text();header.attr('lock',options.lock);if(options.lock=='height'){header.append('');}else{header.append('');} 4 | var $options=$('option',element);$options.each(function(i,el){dropdown.append('');});imageSelect.append(header);imageSelect.append(dropdown);element.after(imageSelect);element.hide();header.attr('linkedselect',selectName);header.children().attr('linkedselect',selectName);header.click(function(){$('select[name='+ $(this).attr('linkedselect')+']').ImageSelect('open');});var w=0;$('.jqis_dropdown img').mouseover(function(){$(this).css('opacity',1);}).mouseout(function(){$(this).css('opacity',0.7);}).css('opacity',0.7).each(function(i,el){w=w+$(el).width();});dropdown.css('max-height',options.dropdownHeight+'px');element.ImageSelect('update',{src:selectedImage});},update:function(options){var element=$(this);var selectName=element.attr('name');var id='jq_imageselect_'+ selectName;if($('#'+id+' .jqis_header').length==1){var ffix=false;if($('#'+id+' .jqis_header img').attr('src')!=options.src){ffix=true;} 5 | $('#'+id+' .jqis_header img').attr('src',options.src).css('opacity',0.1);if(ffix){setTimeout(function(){element.ImageSelect('update',options);},1);return;} 6 | if($('#'+id+' .jqis_header').attr('lock')=='height'){$('#'+id+' .jqis_header img').unbind('load');$('#'+id+' .jqis_header img').one('load',function(){$(this).parent().stop();$(this).parent().parent().stop();$(this).parent().animate({width:$(this).width()+ 60});$(this).parent().parent().animate({width:$(this).width()+ 60});$('.jqis_dropdown',$(this).parent().parent()).animate({width:$(this).width()+ 50});}).each(function(){if(this.complete)$(this).load();});}else{$('#'+id+' .jqis_header img').unbind('load');$('#'+id+' .jqis_header img').one('load',function(){$(this).parent().parent().stop();$(this).parent().stop();$(this).parent().parent().css('height',($(this).height()+2)+'px');$(this).parent().animate({height:$(this).height()+2});}).each(function(){if(this.complete)$(this).load();});} 7 | $('#'+id+' .jqis_header img').animate({opacity:1});}},open:function(){var element=$(this);var selectName=element.attr('name');var id='jq_imageselect_'+ selectName;var w=0;if($('#'+id).length==1){if($('#'+id+' .jqis_dropdown').is(':visible')){$('#'+id+' .jqis_dropdown').stop();$('#'+id+' .jqis_dropdown').slideUp().fadeOut();}else{$('#'+id+' .jqis_dropdown').stop();var mh=$('#'+id+' .jqis_dropdown').css('max-height').replace(/px/,'');mh=parseInt(mh);window.imageHeightTotal=0;$('#'+id+' .jqis_dropdown').show();$('#'+id+' .jqis_dropdown img').each(function(i,el){window.imageHeightTotal=window.imageHeightTotal+ $(el).height();});var ih=window.imageHeightTotal;mh=(ih0)?ih:mh;$('#'+id+' .jqis_dropdown').height(mh);}}},close:function(){var element=$(this);var selectName=element.attr('name');var id='jq_imageselect_'+ selectName;if($('#'+id).length==1){$('#'+id+' .jqis_dropdown').slideUp().hide();}},remove:function(){if(!/select/i.test(this.tagName)){return false;} 8 | var element=$(this);var selectName=element.attr('name');var id='jq_imageselect_'+ selectName;if($('#'+id).length>0){$('#'+id).remove();$('select[name='+ selectName+']').show();return;}}};$.fn.ImageSelect=function(method,options){if(method==undefined){method='init';} 9 | var settings={width:200,height:75,dropdownHeight:250,dropdownWidth:200,z:99999,backgroundColor:'#ffffff',border:true,borderColor:'#cccccc',lock:'height'};if(options){$.extend(settings,options);} 10 | if(typeof method==='object'){$.extend(settings,method);} 11 | settings.dropdownWidth=settings.width- 10;return this.each(function(){if(methods[method]){return methods[method].apply(this,Array(settings));}else if(typeof method==='object'||!method){return methods.init.apply(this,Array(settings));}else{$.error('Method '+ method+' does not exist on jQuery.ImageSelect');}});};})(jQuery); -------------------------------------------------------------------------------- /webui/src/main/resources/static/scripts/jquery.smartselect-1.1.min.js: -------------------------------------------------------------------------------- 1 | /* 2 | Copyright (c) 2013 SPC 3 | Date:2013-06-05 4 | example: 5 | var $select = $("#...").smartFilterSelect({width:140,height:20,divHeight:300,defaultLabel:"全部"}); 6 | 如果该下拉列表需要处理change事件,则需要在$("#...").change(function(){...});中首先执行如下一行代码: 7 | $select.resetSmartFilterSelectHandleFlag(); 8 | 9 | 如果数据是异步加载的,则需要在被异步加载的地方调用 T.resetSmartFilterSelect();函数. 10 | */ 11 | (function(a) { 12 | a.fn.smartFilterSelect = function(c) { 13 | var c = a.extend({ 14 | width: 140, 15 | height: 20, 16 | divHeight: 300, 17 | defaultLabel: "" 18 | }, c); 19 | var l = function j(x) { 20 | var v = ["0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z"]; 21 | var u = ""; 22 | for (var t = 0; t < x; t++) { 23 | var w = Math.ceil(Math.random() * 35); 24 | u += v[w] 25 | } 26 | return u 27 | }; 28 | var f = new Array(); 29 | var h; 30 | var o; 31 | var n = "smartFilterSelectText_id_" + l(10); 32 | var q = "smartFilterSelectDiv_id_" + l(10); 33 | var r; 34 | var e = false; 35 | var b = function s(u) { 36 | var t = f.length; 37 | if (t != 0) { 38 | u.show(); 39 | a("#" + q).show() 40 | } else { 41 | u.each(function() { 42 | a(this).children("option:gt(0)").each(function() { 43 | f.push([a(this).text(), a(this).val()]) 44 | }) 45 | }); 46 | u.show(); 47 | a("#" + q).show() 48 | } 49 | }; 50 | var k = function m(v) { 51 | v.empty(); 52 | var u = f.length; 53 | if (u != 0) { 54 | v.append(a("