Commit 007e7d09e7b65e68d07747a2fbfb71e51140f5b6
0 parents
第一版
Showing
319 changed files
with
9513 additions
and
0 deletions
.idea/.gitignore
0 → 100644
1 | +++ a/.idea/.gitignore | ||
1 | +*.class | ||
2 | + | ||
3 | +# Mobile Tools for Java (J2ME) | ||
4 | +.mtj.tmp/ | ||
5 | + | ||
6 | +# Package Files # | ||
7 | +*.war | ||
8 | +*.ear | ||
9 | + | ||
10 | +# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml | ||
11 | +hs_err_pid* | ||
12 | + | ||
13 | +.idea/ | ||
14 | +*.iml | ||
15 | + | ||
16 | +/logs | ||
17 | +/target | ||
18 | + | ||
19 | +rebel.xml | ||
20 | +resources.dev/ | ||
21 | +/resources.dev/ | ||
22 | +*/target |
.idea/compiler.xml
0 → 100644
1 | +++ a/.idea/compiler.xml | ||
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<project version="4"> | ||
3 | + <component name="CompilerConfiguration"> | ||
4 | + <annotationProcessing> | ||
5 | + <profile default="true" name="Default" enabled="true" /> | ||
6 | + <profile name="Maven default annotation processors profile" enabled="true"> | ||
7 | + <sourceOutputDir name="target/generated-sources/annotations" /> | ||
8 | + <sourceTestOutputDir name="target/generated-test-sources/test-annotations" /> | ||
9 | + <outputRelativeToContentRoot value="true" /> | ||
10 | + <module name="zhyx-api" /> | ||
11 | + <module name="bin-api" /> | ||
12 | + </profile> | ||
13 | + </annotationProcessing> | ||
14 | + </component> | ||
15 | + <component name="JavacSettings"> | ||
16 | + <option name="ADDITIONAL_OPTIONS_OVERRIDE"> | ||
17 | + <module name="zhyx-api" options="-parameters" /> | ||
18 | + </option> | ||
19 | + </component> | ||
20 | +</project> | ||
0 | \ No newline at end of file | 21 | \ No newline at end of file |
.idea/encodings.xml
0 → 100644
1 | +++ a/.idea/encodings.xml | ||
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<project version="4"> | ||
3 | + <component name="Encoding"> | ||
4 | + <file url="file://$PROJECT_DIR$/zhyx-api/src/main/java" charset="UTF-8" /> | ||
5 | + <file url="file://$APPLICATION_HOME_DIR$/jbr/bin/src/main/java" charset="UTF-8" /> | ||
6 | + <file url="file://$APPLICATION_HOME_DIR$/jbr/bin/src/main/resources" charset="UTF-8" /> | ||
7 | + </component> | ||
8 | +</project> | ||
0 | \ No newline at end of file | 9 | \ No newline at end of file |
.idea/jarRepositories.xml
0 → 100644
1 | +++ a/.idea/jarRepositories.xml | ||
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<project version="4"> | ||
3 | + <component name="RemoteRepositoriesConfiguration"> | ||
4 | + <remote-repository> | ||
5 | + <option name="id" value="central" /> | ||
6 | + <option name="name" value="Central Repository" /> | ||
7 | + <option name="url" value="http://maven.aliyun.com/nexus/content/groups/public/" /> | ||
8 | + </remote-repository> | ||
9 | + <remote-repository> | ||
10 | + <option name="id" value="central" /> | ||
11 | + <option name="name" value="Central Repository" /> | ||
12 | + <option name="url" value="https://repo.maven.apache.org/maven2" /> | ||
13 | + </remote-repository> | ||
14 | + <remote-repository> | ||
15 | + <option name="id" value="central" /> | ||
16 | + <option name="name" value="Central Repository" /> | ||
17 | + <option name="url" value="http://maven.aliyun.com/nexus/content/repositories/central/" /> | ||
18 | + </remote-repository> | ||
19 | + <remote-repository> | ||
20 | + <option name="id" value="central" /> | ||
21 | + <option name="name" value="Maven Central repository" /> | ||
22 | + <option name="url" value="https://repo1.maven.org/maven2" /> | ||
23 | + </remote-repository> | ||
24 | + <remote-repository> | ||
25 | + <option name="id" value="jboss.community" /> | ||
26 | + <option name="name" value="JBoss Community repository" /> | ||
27 | + <option name="url" value="https://repository.jboss.org/nexus/content/repositories/public/" /> | ||
28 | + </remote-repository> | ||
29 | + <remote-repository> | ||
30 | + <option name="id" value="central" /> | ||
31 | + <option name="name" value="Central Repository" /> | ||
32 | + <option name="url" value="https://maven.aliyun.com/repository/public" /> | ||
33 | + </remote-repository> | ||
34 | + </component> | ||
35 | +</project> | ||
0 | \ No newline at end of file | 36 | \ No newline at end of file |
.idea/misc.xml
0 → 100644
1 | +++ a/.idea/misc.xml | ||
1 | +<project version="4"> | ||
2 | + <component name="ExternalStorageConfigurationManager" enabled="true" /> | ||
3 | + <component name="MavenProjectsManager"> | ||
4 | + <option name="originalFiles"> | ||
5 | + <list> | ||
6 | + <option value="$PROJECT_DIR$/pom.xml" /> | ||
7 | + <option value="$PROJECT_DIR$/zhyx-api/pom.xml" /> | ||
8 | + </list> | ||
9 | + </option> | ||
10 | + </component> | ||
11 | + <component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="1.8" project-jdk-type="JavaSDK" /> | ||
12 | +</project> | ||
0 | \ No newline at end of file | 13 | \ No newline at end of file |
.idea/modules.xml
0 → 100644
1 | +++ a/.idea/modules.xml | ||
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<project version="4"> | ||
3 | + <component name="ProjectModuleManager"> | ||
4 | + <modules> | ||
5 | + <module fileurl="file://$PROJECT_DIR$/zhyx-api/zhyx-api.iml" filepath="$PROJECT_DIR$/zhyx-api/zhyx-api.iml" /> | ||
6 | + </modules> | ||
7 | + </component> | ||
8 | +</project> | ||
0 | \ No newline at end of file | 9 | \ No newline at end of file |
.idea/uiDesigner.xml
0 → 100644
1 | +++ a/.idea/uiDesigner.xml | ||
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<project version="4"> | ||
3 | + <component name="Palette2"> | ||
4 | + <group name="Swing"> | ||
5 | + <item class="com.intellij.uiDesigner.HSpacer" tooltip-text="Horizontal Spacer" icon="/com/intellij/uiDesigner/icons/hspacer.png" removable="false" auto-create-binding="false" can-attach-label="false"> | ||
6 | + <default-constraints vsize-policy="1" hsize-policy="6" anchor="0" fill="1" /> | ||
7 | + </item> | ||
8 | + <item class="com.intellij.uiDesigner.VSpacer" tooltip-text="Vertical Spacer" icon="/com/intellij/uiDesigner/icons/vspacer.png" removable="false" auto-create-binding="false" can-attach-label="false"> | ||
9 | + <default-constraints vsize-policy="6" hsize-policy="1" anchor="0" fill="2" /> | ||
10 | + </item> | ||
11 | + <item class="javax.swing.JPanel" icon="/com/intellij/uiDesigner/icons/panel.png" removable="false" auto-create-binding="false" can-attach-label="false"> | ||
12 | + <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3" /> | ||
13 | + </item> | ||
14 | + <item class="javax.swing.JScrollPane" icon="/com/intellij/uiDesigner/icons/scrollPane.png" removable="false" auto-create-binding="false" can-attach-label="true"> | ||
15 | + <default-constraints vsize-policy="7" hsize-policy="7" anchor="0" fill="3" /> | ||
16 | + </item> | ||
17 | + <item class="javax.swing.JButton" icon="/com/intellij/uiDesigner/icons/button.png" removable="false" auto-create-binding="true" can-attach-label="false"> | ||
18 | + <default-constraints vsize-policy="0" hsize-policy="3" anchor="0" fill="1" /> | ||
19 | + <initial-values> | ||
20 | + <property name="text" value="Button" /> | ||
21 | + </initial-values> | ||
22 | + </item> | ||
23 | + <item class="javax.swing.JRadioButton" icon="/com/intellij/uiDesigner/icons/radioButton.png" removable="false" auto-create-binding="true" can-attach-label="false"> | ||
24 | + <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" /> | ||
25 | + <initial-values> | ||
26 | + <property name="text" value="RadioButton" /> | ||
27 | + </initial-values> | ||
28 | + </item> | ||
29 | + <item class="javax.swing.JCheckBox" icon="/com/intellij/uiDesigner/icons/checkBox.png" removable="false" auto-create-binding="true" can-attach-label="false"> | ||
30 | + <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" /> | ||
31 | + <initial-values> | ||
32 | + <property name="text" value="CheckBox" /> | ||
33 | + </initial-values> | ||
34 | + </item> | ||
35 | + <item class="javax.swing.JLabel" icon="/com/intellij/uiDesigner/icons/label.png" removable="false" auto-create-binding="false" can-attach-label="false"> | ||
36 | + <default-constraints vsize-policy="0" hsize-policy="0" anchor="8" fill="0" /> | ||
37 | + <initial-values> | ||
38 | + <property name="text" value="Label" /> | ||
39 | + </initial-values> | ||
40 | + </item> | ||
41 | + <item class="javax.swing.JTextField" icon="/com/intellij/uiDesigner/icons/textField.png" removable="false" auto-create-binding="true" can-attach-label="true"> | ||
42 | + <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1"> | ||
43 | + <preferred-size width="150" height="-1" /> | ||
44 | + </default-constraints> | ||
45 | + </item> | ||
46 | + <item class="javax.swing.JPasswordField" icon="/com/intellij/uiDesigner/icons/passwordField.png" removable="false" auto-create-binding="true" can-attach-label="true"> | ||
47 | + <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1"> | ||
48 | + <preferred-size width="150" height="-1" /> | ||
49 | + </default-constraints> | ||
50 | + </item> | ||
51 | + <item class="javax.swing.JFormattedTextField" icon="/com/intellij/uiDesigner/icons/formattedTextField.png" removable="false" auto-create-binding="true" can-attach-label="true"> | ||
52 | + <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1"> | ||
53 | + <preferred-size width="150" height="-1" /> | ||
54 | + </default-constraints> | ||
55 | + </item> | ||
56 | + <item class="javax.swing.JTextArea" icon="/com/intellij/uiDesigner/icons/textArea.png" removable="false" auto-create-binding="true" can-attach-label="true"> | ||
57 | + <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3"> | ||
58 | + <preferred-size width="150" height="50" /> | ||
59 | + </default-constraints> | ||
60 | + </item> | ||
61 | + <item class="javax.swing.JTextPane" icon="/com/intellij/uiDesigner/icons/textPane.png" removable="false" auto-create-binding="true" can-attach-label="true"> | ||
62 | + <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3"> | ||
63 | + <preferred-size width="150" height="50" /> | ||
64 | + </default-constraints> | ||
65 | + </item> | ||
66 | + <item class="javax.swing.JEditorPane" icon="/com/intellij/uiDesigner/icons/editorPane.png" removable="false" auto-create-binding="true" can-attach-label="true"> | ||
67 | + <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3"> | ||
68 | + <preferred-size width="150" height="50" /> | ||
69 | + </default-constraints> | ||
70 | + </item> | ||
71 | + <item class="javax.swing.JComboBox" icon="/com/intellij/uiDesigner/icons/comboBox.png" removable="false" auto-create-binding="true" can-attach-label="true"> | ||
72 | + <default-constraints vsize-policy="0" hsize-policy="2" anchor="8" fill="1" /> | ||
73 | + </item> | ||
74 | + <item class="javax.swing.JTable" icon="/com/intellij/uiDesigner/icons/table.png" removable="false" auto-create-binding="true" can-attach-label="false"> | ||
75 | + <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3"> | ||
76 | + <preferred-size width="150" height="50" /> | ||
77 | + </default-constraints> | ||
78 | + </item> | ||
79 | + <item class="javax.swing.JList" icon="/com/intellij/uiDesigner/icons/list.png" removable="false" auto-create-binding="true" can-attach-label="false"> | ||
80 | + <default-constraints vsize-policy="6" hsize-policy="2" anchor="0" fill="3"> | ||
81 | + <preferred-size width="150" height="50" /> | ||
82 | + </default-constraints> | ||
83 | + </item> | ||
84 | + <item class="javax.swing.JTree" icon="/com/intellij/uiDesigner/icons/tree.png" removable="false" auto-create-binding="true" can-attach-label="false"> | ||
85 | + <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3"> | ||
86 | + <preferred-size width="150" height="50" /> | ||
87 | + </default-constraints> | ||
88 | + </item> | ||
89 | + <item class="javax.swing.JTabbedPane" icon="/com/intellij/uiDesigner/icons/tabbedPane.png" removable="false" auto-create-binding="true" can-attach-label="false"> | ||
90 | + <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3"> | ||
91 | + <preferred-size width="200" height="200" /> | ||
92 | + </default-constraints> | ||
93 | + </item> | ||
94 | + <item class="javax.swing.JSplitPane" icon="/com/intellij/uiDesigner/icons/splitPane.png" removable="false" auto-create-binding="false" can-attach-label="false"> | ||
95 | + <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3"> | ||
96 | + <preferred-size width="200" height="200" /> | ||
97 | + </default-constraints> | ||
98 | + </item> | ||
99 | + <item class="javax.swing.JSpinner" icon="/com/intellij/uiDesigner/icons/spinner.png" removable="false" auto-create-binding="true" can-attach-label="true"> | ||
100 | + <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" /> | ||
101 | + </item> | ||
102 | + <item class="javax.swing.JSlider" icon="/com/intellij/uiDesigner/icons/slider.png" removable="false" auto-create-binding="true" can-attach-label="false"> | ||
103 | + <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" /> | ||
104 | + </item> | ||
105 | + <item class="javax.swing.JSeparator" icon="/com/intellij/uiDesigner/icons/separator.png" removable="false" auto-create-binding="false" can-attach-label="false"> | ||
106 | + <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3" /> | ||
107 | + </item> | ||
108 | + <item class="javax.swing.JProgressBar" icon="/com/intellij/uiDesigner/icons/progressbar.png" removable="false" auto-create-binding="true" can-attach-label="false"> | ||
109 | + <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1" /> | ||
110 | + </item> | ||
111 | + <item class="javax.swing.JToolBar" icon="/com/intellij/uiDesigner/icons/toolbar.png" removable="false" auto-create-binding="false" can-attach-label="false"> | ||
112 | + <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1"> | ||
113 | + <preferred-size width="-1" height="20" /> | ||
114 | + </default-constraints> | ||
115 | + </item> | ||
116 | + <item class="javax.swing.JToolBar$Separator" icon="/com/intellij/uiDesigner/icons/toolbarSeparator.png" removable="false" auto-create-binding="false" can-attach-label="false"> | ||
117 | + <default-constraints vsize-policy="0" hsize-policy="0" anchor="0" fill="1" /> | ||
118 | + </item> | ||
119 | + <item class="javax.swing.JScrollBar" icon="/com/intellij/uiDesigner/icons/scrollbar.png" removable="false" auto-create-binding="true" can-attach-label="false"> | ||
120 | + <default-constraints vsize-policy="6" hsize-policy="0" anchor="0" fill="2" /> | ||
121 | + </item> | ||
122 | + </group> | ||
123 | + </component> | ||
124 | +</project> | ||
0 | \ No newline at end of file | 125 | \ No newline at end of file |
.idea/vcs.xml
0 → 100644
.idea/workspace.xml
0 → 100644
1 | +++ a/.idea/workspace.xml | ||
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<project version="4"> | ||
3 | + <component name="AutoImportSettings"> | ||
4 | + <option name="autoReloadType" value="SELECTIVE" /> | ||
5 | + </component> | ||
6 | + <component name="BranchesTreeState"> | ||
7 | + <expand> | ||
8 | + <path> | ||
9 | + <item name="ROOT" type="e8cecc67:BranchNodeDescriptor" /> | ||
10 | + <item name="LOCAL_ROOT" type="e8cecc67:BranchNodeDescriptor" /> | ||
11 | + </path> | ||
12 | + <path> | ||
13 | + <item name="ROOT" type="e8cecc67:BranchNodeDescriptor" /> | ||
14 | + <item name="REMOTE_ROOT" type="e8cecc67:BranchNodeDescriptor" /> | ||
15 | + </path> | ||
16 | + <path> | ||
17 | + <item name="ROOT" type="e8cecc67:BranchNodeDescriptor" /> | ||
18 | + <item name="REMOTE_ROOT" type="e8cecc67:BranchNodeDescriptor" /> | ||
19 | + <item name="GROUP_NODE:origin" type="e8cecc67:BranchNodeDescriptor" /> | ||
20 | + </path> | ||
21 | + </expand> | ||
22 | + <select /> | ||
23 | + </component> | ||
24 | + <component name="ChangeListManager"> | ||
25 | + <list default="true" id="b883c22b-106a-4a16-bb9f-eb95a11bc9e4" name="Default Changelist" comment="提交" /> | ||
26 | + <option name="SHOW_DIALOG" value="false" /> | ||
27 | + <option name="HIGHLIGHT_CONFLICTS" value="true" /> | ||
28 | + <option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" /> | ||
29 | + <option name="LAST_RESOLUTION" value="IGNORE" /> | ||
30 | + </component> | ||
31 | + <component name="ChangesViewManager"> | ||
32 | + <option name="groupingKeys"> | ||
33 | + <option value="directory" /> | ||
34 | + </option> | ||
35 | + </component> | ||
36 | + <component name="FileTemplateManagerImpl"> | ||
37 | + <option name="RECENT_TEMPLATES"> | ||
38 | + <list> | ||
39 | + <option value="Class" /> | ||
40 | + </list> | ||
41 | + </option> | ||
42 | + </component> | ||
43 | + <component name="Git.Settings"> | ||
44 | + <option name="RECENT_BRANCH_BY_REPOSITORY"> | ||
45 | + <map> | ||
46 | + <entry key="$PROJECT_DIR$" value="zfb" /> | ||
47 | + </map> | ||
48 | + </option> | ||
49 | + <option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" /> | ||
50 | + </component> | ||
51 | + <component name="MarkdownSettingsMigration"> | ||
52 | + <option name="stateVersion" value="1" /> | ||
53 | + </component> | ||
54 | + <component name="MavenImportPreferences"> | ||
55 | + <option name="generalSettings"> | ||
56 | + <MavenGeneralSettings> | ||
57 | + <option name="localRepository" value="D:\mavenRepository" /> | ||
58 | + <option name="userSettingsFile" value="D:\IDEA\IntelliJ IDEA 2023.2.1\plugins\maven\lib\maven3\conf\settings.xml" /> | ||
59 | + </MavenGeneralSettings> | ||
60 | + </option> | ||
61 | + </component> | ||
62 | + <component name="ProjectColorInfo">{ | ||
63 | + "associatedIndex": 2 | ||
64 | +}</component> | ||
65 | + <component name="ProjectId" id="1n62SmY3gsBlYuYTjMqtf82AD7F" /> | ||
66 | + <component name="ProjectViewState"> | ||
67 | + <option name="hideEmptyMiddlePackages" value="true" /> | ||
68 | + <option name="showLibraryContents" value="true" /> | ||
69 | + <option name="showMembers" value="true" /> | ||
70 | + </component> | ||
71 | + <component name="PropertiesComponent"><![CDATA[{ | ||
72 | + "keyToString": { | ||
73 | + "RequestMappingsPanelOrder0": "0", | ||
74 | + "RequestMappingsPanelOrder1": "1", | ||
75 | + "RequestMappingsPanelWidth0": "75", | ||
76 | + "RequestMappingsPanelWidth1": "75", | ||
77 | + "RunOnceActivity.OpenProjectViewOnStart": "true", | ||
78 | + "RunOnceActivity.ShowReadmeOnStart": "true", | ||
79 | + "WebServerToolWindowFactoryState": "false", | ||
80 | + "last_opened_file_path": "D:/histroy/gitWork/tool/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder", | ||
81 | + "node.js.detected.package.eslint": "true", | ||
82 | + "node.js.detected.package.tslint": "true", | ||
83 | + "node.js.selected.package.eslint": "(autodetect)", | ||
84 | + "node.js.selected.package.tslint": "(autodetect)", | ||
85 | + "project.structure.last.edited": "Facets", | ||
86 | + "project.structure.proportion": "0.0", | ||
87 | + "project.structure.side.proportion": "0.2", | ||
88 | + "settings.editor.selected.configurable": "MavenSettings", | ||
89 | + "spring.configuration.checksum": "d0ca1506a06be3d4e1c7415d9ab9252d", | ||
90 | + "vue.rearranger.settings.migration": "true" | ||
91 | + } | ||
92 | +}]]></component> | ||
93 | + <component name="RecentsManager"> | ||
94 | + <key name="CopyFile.RECENT_KEYS"> | ||
95 | + <recent name="D:\histroy\gitWork\tool\zhyx-api\src\main\java\com\ectrip\cyt\client\cyt\model\cytOrder" /> | ||
96 | + <recent name="D:\histroy\gitWork\tool\zhyx-api\src\main\java\com\ectrip\cyt\client\cyt\model\cytOrder\response" /> | ||
97 | + <recent name="D:\histroy\gitWork\tool\zhyx-api\src\main\java\com\ectrip\cyt\client\cyt\model\cytOrder\request" /> | ||
98 | + <recent name="D:\histroy\gitWork\tool\zhyx-api\src\main\java\com\ectrip\cyt\utils" /> | ||
99 | + <recent name="D:\gitWork\tool\zhyx-api" /> | ||
100 | + </key> | ||
101 | + <key name="CopyClassDialog.RECENTS_KEY"> | ||
102 | + <recent name="com.ectrip.cyt.client.cyt.model.cytOrder.request" /> | ||
103 | + <recent name="com.ectrip.cyt.utils" /> | ||
104 | + <recent name="com.ectrip.cyt.model" /> | ||
105 | + <recent name="com.ectrip.cyt.model.param" /> | ||
106 | + <recent name="com.ectrip.cyt.client.cyt.model.cytOrder.response" /> | ||
107 | + </key> | ||
108 | + </component> | ||
109 | + <component name="RunManager" selected="Spring Boot.CytApplication"> | ||
110 | + <configuration default="true" type="ArquillianTestNG" factoryName="" nameIsGenerated="true"> | ||
111 | + <option name="arquillianRunConfiguration"> | ||
112 | + <value> | ||
113 | + <option name="containerStateName" value="" /> | ||
114 | + </value> | ||
115 | + </option> | ||
116 | + <option name="TEST_OBJECT" value="CLASS" /> | ||
117 | + <properties /> | ||
118 | + <listeners /> | ||
119 | + <method v="2"> | ||
120 | + <option name="Make" enabled="true" /> | ||
121 | + </method> | ||
122 | + </configuration> | ||
123 | + <configuration name="AesTools" type="Application" factoryName="Application" temporary="true" nameIsGenerated="true"> | ||
124 | + <option name="MAIN_CLASS_NAME" value="com.ectrip.cyt.utils.AesTools" /> | ||
125 | + <module name="zhyx-api" /> | ||
126 | + <extension name="coverage"> | ||
127 | + <pattern> | ||
128 | + <option name="PATTERN" value="com.ectrip.cyt.utils.*" /> | ||
129 | + <option name="ENABLED" value="true" /> | ||
130 | + </pattern> | ||
131 | + </extension> | ||
132 | + <method v="2"> | ||
133 | + <option name="Make" enabled="true" /> | ||
134 | + </method> | ||
135 | + </configuration> | ||
136 | + <configuration name="SM4Tools" type="Application" factoryName="Application" temporary="true" nameIsGenerated="true"> | ||
137 | + <option name="MAIN_CLASS_NAME" value="com.ectrip.cyt.utils.SM4Tools" /> | ||
138 | + <module name="zhyx-api" /> | ||
139 | + <extension name="coverage"> | ||
140 | + <pattern> | ||
141 | + <option name="PATTERN" value="com.ectrip.cyt.utils.*" /> | ||
142 | + <option name="ENABLED" value="true" /> | ||
143 | + </pattern> | ||
144 | + </extension> | ||
145 | + <method v="2"> | ||
146 | + <option name="Make" enabled="true" /> | ||
147 | + </method> | ||
148 | + </configuration> | ||
149 | + <configuration name="SecurityTools" type="Application" factoryName="Application" temporary="true" nameIsGenerated="true"> | ||
150 | + <option name="MAIN_CLASS_NAME" value="com.ectrip.cyt.utils.SecurityTools" /> | ||
151 | + <module name="zhyx-api" /> | ||
152 | + <extension name="coverage"> | ||
153 | + <pattern> | ||
154 | + <option name="PATTERN" value="com.ectrip.cyt.utils.*" /> | ||
155 | + <option name="ENABLED" value="true" /> | ||
156 | + </pattern> | ||
157 | + </extension> | ||
158 | + <method v="2"> | ||
159 | + <option name="Make" enabled="true" /> | ||
160 | + </method> | ||
161 | + </configuration> | ||
162 | + <configuration name="CytApplication" type="SpringBootApplicationConfigurationType" factoryName="Spring Boot" nameIsGenerated="true"> | ||
163 | + <module name="zhyx-api" /> | ||
164 | + <option name="SPRING_BOOT_MAIN_CLASS" value="com.ectrip.cyt.CytApplication" /> | ||
165 | + <method v="2"> | ||
166 | + <option name="Make" enabled="true" /> | ||
167 | + </method> | ||
168 | + </configuration> | ||
169 | + <list> | ||
170 | + <item itemvalue="Application.AesTools" /> | ||
171 | + <item itemvalue="Application.SM4Tools" /> | ||
172 | + <item itemvalue="Application.SecurityTools" /> | ||
173 | + <item itemvalue="Spring Boot.CytApplication" /> | ||
174 | + </list> | ||
175 | + <recent_temporary> | ||
176 | + <list> | ||
177 | + <item itemvalue="Application.SM4Tools" /> | ||
178 | + <item itemvalue="Application.SecurityTools" /> | ||
179 | + <item itemvalue="Application.AesTools" /> | ||
180 | + <item itemvalue="Spring Boot.CytApplication" /> | ||
181 | + </list> | ||
182 | + </recent_temporary> | ||
183 | + </component> | ||
184 | + <component name="SpellCheckerSettings" RuntimeDictionaries="0" Folders="0" CustomDictionaries="0" DefaultDictionary="application-level" UseSingleDictionary="true" transferred="true" /> | ||
185 | + <component name="TaskManager"> | ||
186 | + <task active="true" id="Default" summary="Default task"> | ||
187 | + <changelist id="b883c22b-106a-4a16-bb9f-eb95a11bc9e4" name="Default Changelist" comment="" /> | ||
188 | + <created>1610696222426</created> | ||
189 | + <option name="number" value="Default" /> | ||
190 | + <option name="presentableId" value="Default" /> | ||
191 | + <updated>1610696222426</updated> | ||
192 | + <workItem from="1610696224692" duration="1029000" /> | ||
193 | + <workItem from="1610697394235" duration="1430000" /> | ||
194 | + <workItem from="1610773111891" duration="556000" /> | ||
195 | + <workItem from="1611280579051" duration="3881000" /> | ||
196 | + <workItem from="1611383412509" duration="1371000" /> | ||
197 | + <workItem from="1611552783052" duration="4956000" /> | ||
198 | + <workItem from="1611665821657" duration="937000" /> | ||
199 | + <workItem from="1611711152189" duration="601000" /> | ||
200 | + <workItem from="1611712158754" duration="1376000" /> | ||
201 | + <workItem from="1611996901855" duration="607000" /> | ||
202 | + <workItem from="1613957220600" duration="1199000" /> | ||
203 | + <workItem from="1616394870470" duration="7604000" /> | ||
204 | + <workItem from="1617092258023" duration="399000" /> | ||
205 | + <workItem from="1617096626489" duration="871000" /> | ||
206 | + <workItem from="1617151935384" duration="653000" /> | ||
207 | + <workItem from="1617675772885" duration="117000" /> | ||
208 | + <workItem from="1618384603564" duration="2801000" /> | ||
209 | + <workItem from="1618398826402" duration="5836000" /> | ||
210 | + <workItem from="1618492518491" duration="664000" /> | ||
211 | + <workItem from="1618741405267" duration="36000" /> | ||
212 | + <workItem from="1618741477253" duration="656000" /> | ||
213 | + <workItem from="1618819447100" duration="871000" /> | ||
214 | + <workItem from="1618826286070" duration="602000" /> | ||
215 | + <workItem from="1619084083310" duration="1277000" /> | ||
216 | + <workItem from="1619313497438" duration="4068000" /> | ||
217 | + <workItem from="1619398875595" duration="2690000" /> | ||
218 | + <workItem from="1619510997385" duration="1264000" /> | ||
219 | + <workItem from="1619597641006" duration="2465000" /> | ||
220 | + <workItem from="1619676209481" duration="1843000" /> | ||
221 | + <workItem from="1619770543133" duration="2210000" /> | ||
222 | + <workItem from="1619830774526" duration="482000" /> | ||
223 | + <workItem from="1619923901137" duration="5867000" /> | ||
224 | + <workItem from="1620630003288" duration="95000" /> | ||
225 | + <workItem from="1620630244330" duration="597000" /> | ||
226 | + <workItem from="1620635026401" duration="787000" /> | ||
227 | + <workItem from="1620636498341" duration="600000" /> | ||
228 | + <workItem from="1620695559429" duration="1891000" /> | ||
229 | + <workItem from="1620781032026" duration="595000" /> | ||
230 | + <workItem from="1620868638113" duration="1908000" /> | ||
231 | + <workItem from="1620889243602" duration="905000" /> | ||
232 | + <workItem from="1620970454243" duration="3206000" /> | ||
233 | + <workItem from="1620982224137" duration="517000" /> | ||
234 | + <workItem from="1621213658015" duration="594000" /> | ||
235 | + <workItem from="1621216659658" duration="7666000" /> | ||
236 | + <workItem from="1621385617124" duration="3968000" /> | ||
237 | + <workItem from="1621413147755" duration="3326000" /> | ||
238 | + <workItem from="1621493287174" duration="5395000" /> | ||
239 | + <workItem from="1622086506456" duration="1242000" /> | ||
240 | + <workItem from="1622110603780" duration="331000" /> | ||
241 | + <workItem from="1622169455648" duration="4877000" /> | ||
242 | + <workItem from="1622426260542" duration="597000" /> | ||
243 | + <workItem from="1622452921764" duration="201000" /> | ||
244 | + <workItem from="1622511322015" duration="597000" /> | ||
245 | + <workItem from="1623745201646" duration="236000" /> | ||
246 | + <workItem from="1624330307790" duration="1705000" /> | ||
247 | + <workItem from="1626246550746" duration="10155000" /> | ||
248 | + <workItem from="1626329931005" duration="825000" /> | ||
249 | + <workItem from="1627980180095" duration="768000" /> | ||
250 | + <workItem from="1627983644325" duration="13000" /> | ||
251 | + <workItem from="1637738954629" duration="3037000" /> | ||
252 | + <workItem from="1637826914326" duration="3072000" /> | ||
253 | + <workItem from="1637919474031" duration="603000" /> | ||
254 | + <workItem from="1638120518829" duration="8470000" /> | ||
255 | + <workItem from="1638498953866" duration="957000" /> | ||
256 | + <workItem from="1638858583203" duration="3571000" /> | ||
257 | + <workItem from="1641975406979" duration="4071000" /> | ||
258 | + <workItem from="1642036382502" duration="768000" /> | ||
259 | + <workItem from="1644313195716" duration="1097000" /> | ||
260 | + <workItem from="1650444107721" duration="2462000" /> | ||
261 | + <workItem from="1650607655702" duration="2301000" /> | ||
262 | + <workItem from="1650611846603" duration="3945000" /> | ||
263 | + <workItem from="1650789139147" duration="4081000" /> | ||
264 | + <workItem from="1650848930307" duration="4845000" /> | ||
265 | + <workItem from="1650939348887" duration="2249000" /> | ||
266 | + <workItem from="1651046827406" duration="5342000" /> | ||
267 | + <workItem from="1651915566427" duration="1079000" /> | ||
268 | + <workItem from="1652064344129" duration="1092000" /> | ||
269 | + <workItem from="1652163875121" duration="6000" /> | ||
270 | + <workItem from="1653337857159" duration="755000" /> | ||
271 | + <workItem from="1653352806018" duration="796000" /> | ||
272 | + <workItem from="1657500920269" duration="6287000" /> | ||
273 | + <workItem from="1657587624093" duration="19100000" /> | ||
274 | + <workItem from="1658303161354" duration="2137000" /> | ||
275 | + <workItem from="1658915476295" duration="1757000" /> | ||
276 | + <workItem from="1659511475365" duration="4461000" /> | ||
277 | + <workItem from="1659582643339" duration="4602000" /> | ||
278 | + <workItem from="1659941749433" duration="15053000" /> | ||
279 | + <workItem from="1660035335038" duration="2777000" /> | ||
280 | + <workItem from="1660666991679" duration="905000" /> | ||
281 | + <workItem from="1660729299803" duration="5383000" /> | ||
282 | + <workItem from="1661249846363" duration="366000" /> | ||
283 | + <workItem from="1661387393682" duration="732000" /> | ||
284 | + <workItem from="1661735799005" duration="597000" /> | ||
285 | + <workItem from="1666564538014" duration="2209000" /> | ||
286 | + <workItem from="1666573753200" duration="2341000" /> | ||
287 | + <workItem from="1668395826714" duration="1226000" /> | ||
288 | + <workItem from="1668404977246" duration="1651000" /> | ||
289 | + <workItem from="1670826067076" duration="1500000" /> | ||
290 | + <workItem from="1675734885102" duration="4171000" /> | ||
291 | + <workItem from="1677571939276" duration="2200000" /> | ||
292 | + <workItem from="1678240444041" duration="25000" /> | ||
293 | + <workItem from="1678421151845" duration="3694000" /> | ||
294 | + <workItem from="1678444350879" duration="1215000" /> | ||
295 | + <workItem from="1678671238454" duration="3245000" /> | ||
296 | + <workItem from="1678689383892" duration="175000" /> | ||
297 | + <workItem from="1679282591363" duration="2479000" /> | ||
298 | + <workItem from="1679620997488" duration="32000" /> | ||
299 | + <workItem from="1681262384461" duration="7176000" /> | ||
300 | + <workItem from="1681719723787" duration="296000" /> | ||
301 | + <workItem from="1682210929715" duration="2807000" /> | ||
302 | + <workItem from="1682232220968" duration="7809000" /> | ||
303 | + <workItem from="1682647238314" duration="2327000" /> | ||
304 | + <workItem from="1682740636011" duration="51000" /> | ||
305 | + <workItem from="1682856404628" duration="1284000" /> | ||
306 | + <workItem from="1684395373024" duration="7658000" /> | ||
307 | + <workItem from="1684456915089" duration="113000" /> | ||
308 | + <workItem from="1684457042484" duration="106000" /> | ||
309 | + <workItem from="1684717368830" duration="997000" /> | ||
310 | + <workItem from="1685351780537" duration="2632000" /> | ||
311 | + <workItem from="1686797621504" duration="1348000" /> | ||
312 | + <workItem from="1686799810064" duration="1196000" /> | ||
313 | + <workItem from="1686810643195" duration="622000" /> | ||
314 | + <workItem from="1686906987257" duration="646000" /> | ||
315 | + <workItem from="1687136068626" duration="1737000" /> | ||
316 | + <workItem from="1689576225139" duration="4092000" /> | ||
317 | + <workItem from="1689640941707" duration="5880000" /> | ||
318 | + <workItem from="1689679622849" duration="806000" /> | ||
319 | + <workItem from="1690092660314" duration="1000" /> | ||
320 | + <workItem from="1690994847042" duration="2592000" /> | ||
321 | + <workItem from="1692690839945" duration="1487000" /> | ||
322 | + <workItem from="1692751914295" duration="6340000" /> | ||
323 | + <workItem from="1692865760889" duration="569000" /> | ||
324 | + <workItem from="1693189870169" duration="2043000" /> | ||
325 | + <workItem from="1693202366819" duration="4610000" /> | ||
326 | + <workItem from="1694501511154" duration="31000" /> | ||
327 | + <workItem from="1694501549601" duration="4709000" /> | ||
328 | + <workItem from="1694567933669" duration="4511000" /> | ||
329 | + <workItem from="1694619551556" duration="7000" /> | ||
330 | + <workItem from="1694620187457" duration="835000" /> | ||
331 | + <workItem from="1695016353509" duration="2683000" /> | ||
332 | + <workItem from="1695021376266" duration="1145000" /> | ||
333 | + <workItem from="1696843275899" duration="1042000" /> | ||
334 | + <workItem from="1696859075323" duration="523000" /> | ||
335 | + <workItem from="1696902166977" duration="687000" /> | ||
336 | + <workItem from="1696902862753" duration="1578000" /> | ||
337 | + <workItem from="1696908495093" duration="3139000" /> | ||
338 | + <workItem from="1697505839612" duration="4000" /> | ||
339 | + <workItem from="1697608170743" duration="7253000" /> | ||
340 | + <workItem from="1698223705077" duration="7000000" /> | ||
341 | + <workItem from="1698368395857" duration="2775000" /> | ||
342 | + <workItem from="1698893523509" duration="1759000" /> | ||
343 | + <workItem from="1698972665284" duration="1118000" /> | ||
344 | + <workItem from="1699492395443" duration="3322000" /> | ||
345 | + <workItem from="1700027111881" duration="4574000" /> | ||
346 | + <workItem from="1700181732445" duration="5959000" /> | ||
347 | + <workItem from="1700644753773" duration="785000" /> | ||
348 | + <workItem from="1701160156501" duration="3038000" /> | ||
349 | + <workItem from="1701689894696" duration="5642000" /> | ||
350 | + <workItem from="1705997544613" duration="2681000" /> | ||
351 | + <workItem from="1707271221945" duration="602000" /> | ||
352 | + <workItem from="1709081544946" duration="17079000" /> | ||
353 | + <workItem from="1709260283769" duration="11355000" /> | ||
354 | + <workItem from="1709515440372" duration="3019000" /> | ||
355 | + <workItem from="1709519926299" duration="169000" /> | ||
356 | + </task> | ||
357 | + <task id="LOCAL-00001" summary="优化"> | ||
358 | + <created>1610696337509</created> | ||
359 | + <option name="number" value="00001" /> | ||
360 | + <option name="presentableId" value="LOCAL-00001" /> | ||
361 | + <option name="project" value="LOCAL" /> | ||
362 | + <updated>1610696337509</updated> | ||
363 | + </task> | ||
364 | + <task id="LOCAL-00002" summary="优化"> | ||
365 | + <created>1610696587982</created> | ||
366 | + <option name="number" value="00002" /> | ||
367 | + <option name="presentableId" value="LOCAL-00002" /> | ||
368 | + <option name="project" value="LOCAL" /> | ||
369 | + <updated>1610696587982</updated> | ||
370 | + </task> | ||
371 | + <task id="LOCAL-00003" summary="优化"> | ||
372 | + <created>1610696652896</created> | ||
373 | + <option name="number" value="00003" /> | ||
374 | + <option name="presentableId" value="LOCAL-00003" /> | ||
375 | + <option name="project" value="LOCAL" /> | ||
376 | + <updated>1610696652896</updated> | ||
377 | + </task> | ||
378 | + <task id="LOCAL-00004" summary="优化"> | ||
379 | + <created>1610696684032</created> | ||
380 | + <option name="number" value="00004" /> | ||
381 | + <option name="presentableId" value="LOCAL-00004" /> | ||
382 | + <option name="project" value="LOCAL" /> | ||
383 | + <updated>1610696684032</updated> | ||
384 | + </task> | ||
385 | + <task id="LOCAL-00005" summary="优化"> | ||
386 | + <created>1610697080892</created> | ||
387 | + <option name="number" value="00005" /> | ||
388 | + <option name="presentableId" value="LOCAL-00005" /> | ||
389 | + <option name="project" value="LOCAL" /> | ||
390 | + <updated>1610697080892</updated> | ||
391 | + </task> | ||
392 | + <task id="LOCAL-00006" summary="优化"> | ||
393 | + <created>1638499893941</created> | ||
394 | + <option name="number" value="00006" /> | ||
395 | + <option name="presentableId" value="LOCAL-00006" /> | ||
396 | + <option name="project" value="LOCAL" /> | ||
397 | + <updated>1638499893941</updated> | ||
398 | + </task> | ||
399 | + <task id="LOCAL-00007" summary="座位"> | ||
400 | + <created>1660008678245</created> | ||
401 | + <option name="number" value="00007" /> | ||
402 | + <option name="presentableId" value="LOCAL-00007" /> | ||
403 | + <option name="project" value="LOCAL" /> | ||
404 | + <updated>1660008678245</updated> | ||
405 | + </task> | ||
406 | + <task id="LOCAL-00008" summary="座位"> | ||
407 | + <created>1660034836851</created> | ||
408 | + <option name="number" value="00008" /> | ||
409 | + <option name="presentableId" value="LOCAL-00008" /> | ||
410 | + <option name="project" value="LOCAL" /> | ||
411 | + <updated>1660034836851</updated> | ||
412 | + </task> | ||
413 | + <task id="LOCAL-00009" summary="提交"> | ||
414 | + <created>1681719768299</created> | ||
415 | + <option name="number" value="00009" /> | ||
416 | + <option name="presentableId" value="LOCAL-00009" /> | ||
417 | + <option name="project" value="LOCAL" /> | ||
418 | + <updated>1681719768299</updated> | ||
419 | + </task> | ||
420 | + <option name="localTasksCounter" value="10" /> | ||
421 | + <servers /> | ||
422 | + </component> | ||
423 | + <component name="TypeScriptGeneratedFilesManager"> | ||
424 | + <option name="version" value="3" /> | ||
425 | + </component> | ||
426 | + <component name="Vcs.Log.Tabs.Properties"> | ||
427 | + <option name="OPEN_GENERIC_TABS"> | ||
428 | + <map> | ||
429 | + <entry key="0de0c0e6-52a8-4c5d-b05d-8f59e40a9a76" value="TOOL_WINDOW" /> | ||
430 | + </map> | ||
431 | + </option> | ||
432 | + <option name="TAB_STATES"> | ||
433 | + <map> | ||
434 | + <entry key="0de0c0e6-52a8-4c5d-b05d-8f59e40a9a76"> | ||
435 | + <value> | ||
436 | + <State> | ||
437 | + <option name="FILTERS"> | ||
438 | + <map> | ||
439 | + <entry key="branch"> | ||
440 | + <value> | ||
441 | + <list> | ||
442 | + <option value="HEAD" /> | ||
443 | + </list> | ||
444 | + </value> | ||
445 | + </entry> | ||
446 | + <entry key="roots"> | ||
447 | + <value> | ||
448 | + <list> | ||
449 | + <option value="$PROJECT_DIR$" /> | ||
450 | + </list> | ||
451 | + </value> | ||
452 | + </entry> | ||
453 | + </map> | ||
454 | + </option> | ||
455 | + <option name="SHOW_ONLY_AFFECTED_CHANGES" value="true" /> | ||
456 | + </State> | ||
457 | + </value> | ||
458 | + </entry> | ||
459 | + <entry key="MAIN"> | ||
460 | + <value> | ||
461 | + <State /> | ||
462 | + </value> | ||
463 | + </entry> | ||
464 | + </map> | ||
465 | + </option> | ||
466 | + </component> | ||
467 | + <component name="VcsManagerConfiguration"> | ||
468 | + <MESSAGE value="优化" /> | ||
469 | + <MESSAGE value="座位" /> | ||
470 | + <MESSAGE value="提交" /> | ||
471 | + <option name="LAST_COMMIT_MESSAGE" value="提交" /> | ||
472 | + </component> | ||
473 | +</project> | ||
0 | \ No newline at end of file | 474 | \ No newline at end of file |
pom.xml
0 → 100644
1 | +++ a/pom.xml | ||
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<project xmlns="http://maven.apache.org/POM/4.0.0" | ||
3 | + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
4 | + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
5 | + <modelVersion>4.0.0</modelVersion> | ||
6 | + | ||
7 | + <groupId>com.ectrip</groupId> | ||
8 | + <artifactId>bin-api</artifactId> | ||
9 | + <version>1.0-SNAPSHOT</version> | ||
10 | + | ||
11 | + | ||
12 | +</project> | ||
0 | \ No newline at end of file | 13 | \ No newline at end of file |
zhyx-api/pom.xml
0 → 100644
1 | +++ a/zhyx-api/pom.xml | ||
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<project xmlns="http://maven.apache.org/POM/4.0.0" | ||
3 | + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
4 | + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
5 | + <modelVersion>4.0.0</modelVersion> | ||
6 | + <parent> | ||
7 | + <groupId>org.springframework.boot</groupId> | ||
8 | + <artifactId>spring-boot-starter-parent</artifactId> | ||
9 | + <version>2.2.4.RELEASE</version> | ||
10 | + <relativePath/> <!-- lookup parent from repository --> | ||
11 | + </parent> | ||
12 | + <groupId>com.ectrip</groupId> | ||
13 | + <artifactId>zhyx-api</artifactId> | ||
14 | + <version>1.0.0</version> | ||
15 | + <name>zhyx-api</name> | ||
16 | + <description>整合营销-接口测试平台</description> | ||
17 | + <packaging>jar</packaging> | ||
18 | + | ||
19 | + <properties> | ||
20 | + <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> | ||
21 | + <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> | ||
22 | + <java.version>1.8</java.version> | ||
23 | + </properties> | ||
24 | + | ||
25 | + <dependencies> | ||
26 | + <dependency> | ||
27 | + <groupId>org.springframework.boot</groupId> | ||
28 | + <artifactId>spring-boot-starter-web</artifactId> | ||
29 | + </dependency> | ||
30 | + | ||
31 | + <dependency> | ||
32 | + <groupId>org.springframework.boot</groupId> | ||
33 | + <artifactId>spring-boot-starter-test</artifactId> | ||
34 | + <scope>test</scope> | ||
35 | + </dependency> | ||
36 | + | ||
37 | + <dependency> | ||
38 | + <groupId>org.mybatis.spring.boot</groupId> | ||
39 | + <artifactId>mybatis-spring-boot-starter</artifactId> | ||
40 | + <version>1.3.2</version> | ||
41 | + </dependency> | ||
42 | + | ||
43 | + <dependency> | ||
44 | + <groupId>ch.qos.logback</groupId> | ||
45 | + <artifactId>logback-classic</artifactId> | ||
46 | + <version>1.2.3</version> | ||
47 | + </dependency> | ||
48 | + | ||
49 | + <dependency> | ||
50 | + <groupId>ch.qos.logback</groupId> | ||
51 | + <artifactId>logback-core</artifactId> | ||
52 | + <version>1.2.3</version> | ||
53 | + </dependency> | ||
54 | + | ||
55 | + <dependency> | ||
56 | + <groupId>log4j</groupId> | ||
57 | + <artifactId>log4j</artifactId> | ||
58 | + <version>1.2.17</version> | ||
59 | + </dependency> | ||
60 | + | ||
61 | + <dependency> | ||
62 | + <groupId>com.alibaba</groupId> | ||
63 | + <artifactId>fastjson</artifactId> | ||
64 | + <version>1.2.31</version> | ||
65 | + </dependency> | ||
66 | + | ||
67 | + <!-- 数据源 --> | ||
68 | + <dependency> | ||
69 | + <groupId>com.alibaba</groupId> | ||
70 | + <artifactId>druid</artifactId> | ||
71 | + <version>1.0.15</version> | ||
72 | + </dependency> | ||
73 | + | ||
74 | + <dependency> | ||
75 | + <groupId>mysql</groupId> | ||
76 | + <artifactId>mysql-connector-java</artifactId> | ||
77 | + <version>5.1.47</version> | ||
78 | + </dependency> | ||
79 | + | ||
80 | + <!-- 分页插件 --> | ||
81 | + <dependency> | ||
82 | + <groupId>com.github.pagehelper</groupId> | ||
83 | + <artifactId>pagehelper</artifactId> | ||
84 | + <version>5.1.2</version> | ||
85 | + </dependency> | ||
86 | + | ||
87 | + <dependency> | ||
88 | + <groupId>com.github.pagehelper</groupId> | ||
89 | + <artifactId>pagehelper-spring-boot-autoconfigure</artifactId> | ||
90 | + <version>1.2.3</version> | ||
91 | + </dependency> | ||
92 | + | ||
93 | + <dependency> | ||
94 | + <groupId>com.github.pagehelper</groupId> | ||
95 | + <artifactId>pagehelper-spring-boot-starter</artifactId> | ||
96 | + <version>1.2.3</version> | ||
97 | + </dependency> | ||
98 | + | ||
99 | + <dependency> | ||
100 | + <groupId>org.apache.commons</groupId> | ||
101 | + <artifactId>commons-lang3</artifactId> | ||
102 | + <version>3.4</version> | ||
103 | + </dependency> | ||
104 | + | ||
105 | + <!--<dependency> | ||
106 | + <groupId>org.apache.httpcomponents</groupId> | ||
107 | + <artifactId>httpclient</artifactId> | ||
108 | + <version>4.5.5</version> | ||
109 | + </dependency> | ||
110 | + <dependency> | ||
111 | + <groupId>org.apache.httpcomponents</groupId> | ||
112 | + <artifactId>httpcore</artifactId> | ||
113 | + <version>4.4.12</version> | ||
114 | + </dependency>--> | ||
115 | + <dependency> | ||
116 | + <groupId>org.apache.httpcomponents</groupId> | ||
117 | + <artifactId>httpclient</artifactId> | ||
118 | + <version>4.5</version> | ||
119 | + </dependency> | ||
120 | + | ||
121 | + <dependency> | ||
122 | + <groupId>commons-httpclient</groupId> | ||
123 | + <artifactId>commons-httpclient</artifactId> | ||
124 | + <version>3.1</version> | ||
125 | + </dependency> | ||
126 | + | ||
127 | + <dependency> | ||
128 | + <groupId>org.apache.httpcomponents</groupId> | ||
129 | + <artifactId>httpmime</artifactId> | ||
130 | + <version>4.5</version> | ||
131 | + </dependency> | ||
132 | + | ||
133 | + <!--AOP--> | ||
134 | + <dependency> | ||
135 | + <groupId>org.aspectj</groupId> | ||
136 | + <artifactId>aspectjrt</artifactId> | ||
137 | + <version>1.8.13</version> | ||
138 | + </dependency> | ||
139 | + | ||
140 | + <dependency> | ||
141 | + <groupId>org.aspectj</groupId> | ||
142 | + <artifactId>aspectjweaver</artifactId> | ||
143 | + <version>1.8.6</version> | ||
144 | + </dependency> | ||
145 | + | ||
146 | + | ||
147 | + | ||
148 | + <!-- swagger2 --> | ||
149 | + <dependency> | ||
150 | + <groupId>io.springfox</groupId> | ||
151 | + <artifactId>springfox-swagger2</artifactId> | ||
152 | + <version>2.6.0</version> | ||
153 | + </dependency> | ||
154 | + <dependency> | ||
155 | + <groupId>io.springfox</groupId> | ||
156 | + <artifactId>springfox-swagger-ui</artifactId> | ||
157 | + <version>2.6.0</version> | ||
158 | + </dependency> | ||
159 | + | ||
160 | + <dependency> | ||
161 | + <groupId>com.github.xiaoymin</groupId> | ||
162 | + <artifactId>swagger-bootstrap-ui</artifactId> | ||
163 | + <version>1.9.5</version> | ||
164 | + </dependency> | ||
165 | + | ||
166 | + <dependency> | ||
167 | + <groupId>org.apache.poi</groupId> | ||
168 | + <artifactId>poi-ooxml</artifactId> | ||
169 | + <version>3.9</version> | ||
170 | + </dependency> | ||
171 | + | ||
172 | + <dependency> | ||
173 | + <groupId>org.springframework.boot</groupId> | ||
174 | + <artifactId>spring-boot-starter-thymeleaf</artifactId> | ||
175 | + </dependency> | ||
176 | + | ||
177 | + <dependency> | ||
178 | + <groupId>org.projectlombok</groupId> | ||
179 | + <artifactId>lombok</artifactId> | ||
180 | + <optional>true</optional> | ||
181 | + </dependency> | ||
182 | + | ||
183 | + <dependency> | ||
184 | + <groupId>com.thoughtworks.xstream</groupId> | ||
185 | + <artifactId>xstream</artifactId> | ||
186 | + <version>1.4.10</version> | ||
187 | + </dependency> | ||
188 | + | ||
189 | + <!--微信支付--> | ||
190 | + <dependency> | ||
191 | + <groupId>com.github.binarywang</groupId> | ||
192 | + <artifactId>weixin-java-pay</artifactId> | ||
193 | + <version>3.6.0</version> | ||
194 | + </dependency> | ||
195 | + </dependencies> | ||
196 | + <!--多环境配置--> | ||
197 | + <profiles> | ||
198 | + <profile> | ||
199 | + <id>dev</id> | ||
200 | + <activation> | ||
201 | + <activeByDefault>true</activeByDefault> | ||
202 | + </activation> | ||
203 | + <properties> | ||
204 | + <activatedProperties>dev</activatedProperties> | ||
205 | + </properties> | ||
206 | + </profile> | ||
207 | + <profile> | ||
208 | + <id>qingdao</id> | ||
209 | + <activation> | ||
210 | + <activeByDefault>false</activeByDefault> | ||
211 | + </activation> | ||
212 | + <properties> | ||
213 | + <activatedProperties>qingdao</activatedProperties> | ||
214 | + </properties> | ||
215 | + </profile> | ||
216 | + </profiles> | ||
217 | + | ||
218 | + <build> | ||
219 | + <resources> | ||
220 | + <resource> | ||
221 | + <directory>src/main/resources</directory> | ||
222 | + <filtering>true</filtering> | ||
223 | + </resource> | ||
224 | + </resources> | ||
225 | + <plugins> | ||
226 | + <plugin> | ||
227 | + <groupId>org.springframework.boot</groupId> | ||
228 | + <artifactId>spring-boot-maven-plugin</artifactId> | ||
229 | + <configuration> | ||
230 | + <fork>true</fork> | ||
231 | + </configuration> | ||
232 | + </plugin> | ||
233 | + <plugin> | ||
234 | + <groupId>org.apache.maven.plugins</groupId> | ||
235 | + <artifactId>maven-resources-plugin</artifactId> | ||
236 | + <version>${maven-resources-plugin.version}</version> | ||
237 | + <configuration> | ||
238 | + <delimiters> | ||
239 | + <delimiter>@</delimiter> | ||
240 | + </delimiters> | ||
241 | + <useDefaultDelimiters>false</useDefaultDelimiters> | ||
242 | + </configuration> | ||
243 | + </plugin> | ||
244 | + <plugin> | ||
245 | + <groupId>org.apache.maven.plugins</groupId> | ||
246 | + <artifactId>maven-surefire-plugin</artifactId> | ||
247 | + <version>${maven-surefire-plugin.version}</version> | ||
248 | + <configuration> | ||
249 | + <skipTests>true</skipTests> | ||
250 | + </configuration> | ||
251 | + </plugin> | ||
252 | + <plugin> | ||
253 | + <groupId>org.apache.maven.plugins</groupId> | ||
254 | + <artifactId>maven-compiler-plugin</artifactId> | ||
255 | + <version>${maven-compiler-plugin.version}</version> | ||
256 | + <configuration> | ||
257 | + <source>${java.version}</source> | ||
258 | + <target>${java.version}</target> | ||
259 | + <fork>true</fork> | ||
260 | + </configuration> | ||
261 | + </plugin> | ||
262 | + </plugins> | ||
263 | + </build> | ||
264 | + | ||
265 | + <!--<build> | ||
266 | + <resources> | ||
267 | + <resource> | ||
268 | + <directory>src/main/resources/lib</directory> | ||
269 | + <targetPath>BOOT-INF/lib/</targetPath> | ||
270 | + <includes> | ||
271 | + <include>**/*.jar</include> | ||
272 | + </includes> | ||
273 | + </resource> | ||
274 | + <resource> | ||
275 | + <directory>src/main/resources</directory> | ||
276 | + <!–<excludes> | ||
277 | + <exclude>application.yml</exclude> | ||
278 | + <exclude>logback.xml</exclude> | ||
279 | + </excludes>–> | ||
280 | + </resource> | ||
281 | + </resources> | ||
282 | + | ||
283 | + <plugins> | ||
284 | + <plugin> | ||
285 | + <groupId>org.springframework.boot</groupId> | ||
286 | + <artifactId>spring-boot-maven-plugin</artifactId> | ||
287 | + </plugin> | ||
288 | + <plugin> | ||
289 | + <groupId>org.mybatis.generator</groupId> | ||
290 | + <artifactId>mybatis-generator-maven-plugin</artifactId> | ||
291 | + <version>1.3.2</version> | ||
292 | + <configuration> | ||
293 | + <!–允许移动生成的文件 –> | ||
294 | + <verbose>true</verbose> | ||
295 | + <!– 是否覆盖 –> | ||
296 | + <overwrite>true</overwrite> | ||
297 | + </configuration> | ||
298 | + </plugin> | ||
299 | + </plugins> | ||
300 | + </build>--> | ||
301 | +</project> |
zhyx-api/src/main/java/com/ectrip/cyt/CytApplication.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/CytApplication.java | ||
1 | +package com.ectrip.cyt; | ||
2 | + | ||
3 | +import org.springframework.boot.SpringApplication; | ||
4 | +import org.springframework.boot.autoconfigure.SpringBootApplication; | ||
5 | +import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration; | ||
6 | +import org.springframework.context.annotation.EnableAspectJAutoProxy; | ||
7 | +import org.springframework.scheduling.annotation.EnableScheduling; | ||
8 | +import org.springframework.transaction.annotation.EnableTransactionManagement; | ||
9 | +import org.springframework.web.bind.annotation.CrossOrigin; | ||
10 | + | ||
11 | +@SpringBootApplication(exclude={DataSourceAutoConfiguration.class}) | ||
12 | +@EnableAspectJAutoProxy//开启AOP | ||
13 | +@EnableTransactionManagement//开启事务 | ||
14 | +@CrossOrigin//跨域 | ||
15 | +@EnableScheduling | ||
16 | +//不链接数据库 | ||
17 | +public class CytApplication { | ||
18 | + | ||
19 | + public static void main(String[] args) { | ||
20 | + SpringApplication.run(CytApplication.class, args); | ||
21 | + } | ||
22 | + | ||
23 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/common/Parameter.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/common/Parameter.java | ||
1 | +package com.ectrip.cyt.client.cyt.common; | ||
2 | + | ||
3 | +import java.io.Serializable; | ||
4 | + | ||
5 | +public class Parameter implements Serializable, Comparable<Parameter> { | ||
6 | + | ||
7 | + private static final long serialVersionUID = 2721340807561333705L; | ||
8 | + | ||
9 | + private String name; | ||
10 | + private String value; | ||
11 | + | ||
12 | + public Parameter() { | ||
13 | + super(); | ||
14 | + } | ||
15 | + | ||
16 | + public Parameter(String name, String value) { | ||
17 | + super(); | ||
18 | + this.name = name; | ||
19 | + this.value = value; | ||
20 | + } | ||
21 | + | ||
22 | + public String getName() { | ||
23 | + return name; | ||
24 | + } | ||
25 | + | ||
26 | + public void setName(String name) { | ||
27 | + this.name = name; | ||
28 | + } | ||
29 | + | ||
30 | + public String getValue() { | ||
31 | + return value; | ||
32 | + } | ||
33 | + | ||
34 | + public void setValue(String value) { | ||
35 | + this.value = value; | ||
36 | + } | ||
37 | + | ||
38 | + @Override | ||
39 | + public boolean equals(Object obj) { | ||
40 | + //对象不为空 | ||
41 | + if (obj == null) { | ||
42 | + return false; | ||
43 | + } | ||
44 | + //hashCode相等 | ||
45 | + if (this == obj) { | ||
46 | + return true; | ||
47 | + } | ||
48 | + | ||
49 | + if (obj instanceof Parameter) { | ||
50 | + Parameter param = (Parameter) obj; | ||
51 | + return this.getName().equals(param.getName()) | ||
52 | + && this.getValue().equals(param.getValue()); | ||
53 | + } | ||
54 | + | ||
55 | + return false; | ||
56 | + } | ||
57 | + | ||
58 | + @Override | ||
59 | + public String toString() { | ||
60 | + return super.toString(); | ||
61 | + } | ||
62 | + | ||
63 | + @Override | ||
64 | + public int compareTo(Parameter arg0) { | ||
65 | + return 0; | ||
66 | + } | ||
67 | + | ||
68 | +} | ||
0 | \ No newline at end of file | 69 | \ No newline at end of file |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/common/Transient.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/common/Transient.java | ||
1 | +package com.ectrip.cyt.client.cyt.common; | ||
2 | + | ||
3 | +import java.lang.annotation.ElementType; | ||
4 | +import java.lang.annotation.Retention; | ||
5 | +import java.lang.annotation.RetentionPolicy; | ||
6 | +import java.lang.annotation.Target; | ||
7 | + | ||
8 | +/** | ||
9 | + * 实现描述:标识不需要Json序列化的属性 | ||
10 | + * | ||
11 | + * @version v1.0.0 | ||
12 | + * @see | ||
13 | + */ | ||
14 | +@Target({ElementType.FIELD, ElementType.PARAMETER}) | ||
15 | +@Retention(RetentionPolicy.RUNTIME) | ||
16 | +public @interface Transient { | ||
17 | + | ||
18 | + boolean value() default true; | ||
19 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/Base64Util.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/Base64Util.java | ||
1 | +package com.ectrip.cyt.client.cyt.model; | ||
2 | + | ||
3 | +import sun.misc.BASE64Decoder; | ||
4 | +import sun.misc.BASE64Encoder; | ||
5 | + | ||
6 | +import java.io.IOException; | ||
7 | + | ||
8 | +/** | ||
9 | + * Base64转换工具类 | ||
10 | + * | ||
11 | + * @author | ||
12 | + */ | ||
13 | +public class Base64Util { | ||
14 | + | ||
15 | + /** | ||
16 | + * 将 s进行 BASE64 编码 | ||
17 | + * | ||
18 | + * @param s | ||
19 | + * @return | ||
20 | + * @throws java.io.UnsupportedEncodingException | ||
21 | + */ | ||
22 | + public static String getBASE64(String s) { | ||
23 | + if (s == null) { | ||
24 | + return null; | ||
25 | + } | ||
26 | + return new BASE64Encoder().encode(s.getBytes()); | ||
27 | + } | ||
28 | + | ||
29 | + /** | ||
30 | + * 将 BASE64 编码的字符串 s进行解码 | ||
31 | + * | ||
32 | + * @param s | ||
33 | + * @return | ||
34 | + */ | ||
35 | + public static String getFromBASE64(String s) { | ||
36 | + if (s == null) { | ||
37 | + return null; | ||
38 | + } | ||
39 | + BASE64Decoder decoder = new BASE64Decoder(); | ||
40 | + try { | ||
41 | + byte[] b = decoder.decodeBuffer(s); | ||
42 | + return new String(b); | ||
43 | + } catch (Exception e) { | ||
44 | + return null; | ||
45 | + } | ||
46 | + } | ||
47 | + | ||
48 | + public static void main(String[] args) { | ||
49 | + System.out.println(System.getProperty("file.encoding")); | ||
50 | + System.out.println(Base64Util.getBASE64("颐和园")); | ||
51 | + System.out | ||
52 | + .println(Base64Util | ||
53 | + .getFromBASE64("PG9yZGVyPjxvcmRlcklkPjEzMjkwMTQ8L29yZGVySWQ+PHN0YXR1cz5OT1JNQUw8L3N0YXR1cz48 cGF5bWVudFN0YXR1cz5VTlBBWTwvcGF5bWVudFN0YXR1cz48L29yZGVyPg==")); | ||
54 | + } | ||
55 | + | ||
56 | + public static String encodeToString(byte[] byteArray) { | ||
57 | + return new BASE64Encoder().encode(byteArray); | ||
58 | + } | ||
59 | + | ||
60 | + public static byte[] decode(String planString) { | ||
61 | + try { | ||
62 | + return new BASE64Decoder().decodeBuffer(planString); | ||
63 | + } catch (IOException e) { | ||
64 | + e.printStackTrace(); | ||
65 | + return null; | ||
66 | + } | ||
67 | + } | ||
68 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/OtaBase.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/OtaBase.java | ||
1 | +package com.ectrip.cyt.client.cyt.model; | ||
2 | + | ||
3 | +import java.util.Map; | ||
4 | + | ||
5 | +/** | ||
6 | + * OTA基本交互数据类型实体 | ||
7 | + * Created by lingkitho on 2017/4/27. | ||
8 | + */ | ||
9 | +public class OtaBase { | ||
10 | + private String data;//base64的xml加密串 | ||
11 | + private String xmlData;//解密后的xml字符串 | ||
12 | + private Map<String, Object> mapData;//处理后的map对象 | ||
13 | + | ||
14 | + private String signed;//签名, MD5(signkey + data) | ||
15 | + private String securityType = "MD5"; | ||
16 | + | ||
17 | + public String getData() { | ||
18 | + return data; | ||
19 | + } | ||
20 | + | ||
21 | + public void setData(String data) { | ||
22 | + this.data = data; | ||
23 | + } | ||
24 | + | ||
25 | + public String getSigned() { | ||
26 | + return signed; | ||
27 | + } | ||
28 | + | ||
29 | + public void setSigned(String signed) { | ||
30 | + this.signed = signed; | ||
31 | + } | ||
32 | + | ||
33 | + public String getSecurityType() { | ||
34 | + return securityType; | ||
35 | + } | ||
36 | + | ||
37 | + public void setSecurityType(String securityType) { | ||
38 | + this.securityType = securityType; | ||
39 | + } | ||
40 | + | ||
41 | + public String getXmlData() { | ||
42 | + return xmlData; | ||
43 | + } | ||
44 | + | ||
45 | + public void setXmlData(String xmlData) { | ||
46 | + this.xmlData = xmlData; | ||
47 | + } | ||
48 | + | ||
49 | + public Map<String, Object> getMapData() { | ||
50 | + return mapData; | ||
51 | + } | ||
52 | + | ||
53 | + public void setMapData(Map<String, Object> mapData) { | ||
54 | + this.mapData = mapData; | ||
55 | + } | ||
56 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/ApplyOrderRefundByUserRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/ApplyOrderRefundByUserRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "ApplyOrderRefundByUserRequestBody", propOrder = {"orderInfo"}) | ||
14 | +@Data | ||
15 | +public class ApplyOrderRefundByUserRequestBody extends RequestBody { | ||
16 | + @XmlElement(required = true) | ||
17 | + protected OrderInfo orderInfo; | ||
18 | + | ||
19 | + public ApplyOrderRefundByUserRequestBody() { | ||
20 | + super(); | ||
21 | + this.orderInfo = new OrderInfo(); | ||
22 | + } | ||
23 | + | ||
24 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
25 | + @XmlType(name = "", propOrder = {"partnerorderId","partnerOrderId","orderId", "refundSeq", "orderPrice", "orderQuantity", "refundQuantity", "orderRefundPrice", "orderRefundCharge", "refundExplain", "visitPerson"}) | ||
26 | + @Data | ||
27 | + public static class OrderInfo { | ||
28 | + public String getPartnerorderId() { | ||
29 | + return partnerorderId; | ||
30 | + } | ||
31 | + | ||
32 | + public void setPartnerorderId(String partnerorderId) { | ||
33 | + this.partnerorderId = partnerorderId; | ||
34 | + } | ||
35 | + | ||
36 | + public String getPartnerOrderId() { | ||
37 | + return partnerOrderId; | ||
38 | + } | ||
39 | + | ||
40 | + public void setPartnerOrderId(String partnerOrderId) { | ||
41 | + this.partnerOrderId = partnerOrderId; | ||
42 | + } | ||
43 | + | ||
44 | + @XmlElement(required = true) | ||
45 | + protected String partnerorderId; | ||
46 | + @XmlElement(required = true) | ||
47 | + protected String partnerOrderId; | ||
48 | + @XmlElement(required = true) | ||
49 | + protected String orderId; | ||
50 | + @XmlElement(required = true) | ||
51 | + protected String refundSeq; | ||
52 | + @XmlElement(required = true) | ||
53 | + protected String orderPrice; | ||
54 | + @XmlElement(required = true) | ||
55 | + protected String orderQuantity; | ||
56 | + @XmlElement(required = true) | ||
57 | + protected String refundQuantity; | ||
58 | + @XmlElement(required = true) | ||
59 | + protected String orderRefundPrice; | ||
60 | + @XmlElement(required = true) | ||
61 | + protected String orderRefundCharge; | ||
62 | + @XmlElement(required = true) | ||
63 | + protected String refundExplain; | ||
64 | + @XmlElement(required = true) | ||
65 | + protected VisitPerson visitPerson; | ||
66 | + | ||
67 | + public OrderInfo() { | ||
68 | + super(); | ||
69 | + this.partnerorderId = ""; | ||
70 | + this.partnerOrderId = ""; | ||
71 | + this.orderId =""; | ||
72 | + this.refundSeq = ""; | ||
73 | + this.orderPrice = ""; | ||
74 | + this.orderQuantity = ""; | ||
75 | + this.refundQuantity = ""; | ||
76 | + this.orderRefundPrice = ""; | ||
77 | + this.orderRefundCharge = ""; | ||
78 | + this.refundExplain = ""; | ||
79 | + this.visitPerson = new VisitPerson(); | ||
80 | + } | ||
81 | + | ||
82 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
83 | + @XmlType(name = "", propOrder = {"person"}) | ||
84 | + @Data | ||
85 | + public static class VisitPerson { | ||
86 | + protected List<Person> person; | ||
87 | + | ||
88 | + public VisitPerson() { | ||
89 | + super(); | ||
90 | + this.person = new ArrayList<Person>(); | ||
91 | + } | ||
92 | + | ||
93 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
94 | + @XmlType(name = "", propOrder = {"name", "credentials", "credentialsType", "voucherCode"}) | ||
95 | + @Data | ||
96 | + public static class Person { | ||
97 | + | ||
98 | + @XmlElement(required = true) | ||
99 | + protected String name; | ||
100 | + @XmlElement(required = true) | ||
101 | + protected String credentials; | ||
102 | + @XmlElement(required = true) | ||
103 | + protected String credentialsType; | ||
104 | + @XmlElement | ||
105 | + protected String voucherCode; | ||
106 | + | ||
107 | + public Person() { | ||
108 | + super(); | ||
109 | + this.name = ""; | ||
110 | + this.credentials = ""; | ||
111 | + this.credentialsType = ""; | ||
112 | + this.voucherCode=""; | ||
113 | + } | ||
114 | + } | ||
115 | + } | ||
116 | + } | ||
117 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/CancelOrderRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/CancelOrderRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "CancelOrderRequestBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class CancelOrderRequestBody extends RequestBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected OrderInfo orderInfo; | ||
16 | + | ||
17 | + public CancelOrderRequestBody() { | ||
18 | + super(); | ||
19 | + this.orderInfo = new OrderInfo(); | ||
20 | + } | ||
21 | + | ||
22 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
23 | + @XmlType(name = "", propOrder = {"partnerOrderId", "orderId"}) | ||
24 | + @Data | ||
25 | + public static class OrderInfo { | ||
26 | + @XmlElement(required = true) | ||
27 | + protected String partnerOrderId; | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String orderId; | ||
30 | + | ||
31 | + public OrderInfo() { | ||
32 | + super(); | ||
33 | + this.orderId=""; | ||
34 | + this.partnerOrderId = ""; | ||
35 | + } | ||
36 | + } | ||
37 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/CheckOrderRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/CheckOrderRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "CheckOrderRequestBody", propOrder = {"orderInfo"}) | ||
14 | +@Data | ||
15 | +public class CheckOrderRequestBody extends RequestBody { | ||
16 | + @XmlElement(required = true) | ||
17 | + protected OrderInfo orderInfo; | ||
18 | + | ||
19 | + public CheckOrderRequestBody() { | ||
20 | + super(); | ||
21 | + this.orderInfo = new OrderInfo(); | ||
22 | + } | ||
23 | + | ||
24 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
25 | + @XmlType(name = "", propOrder = {"orderId", "product", "contactPerson", "visitPerson", "orderQuantity", "orderPrice", "orderStatus", "token"}) | ||
26 | + @Data | ||
27 | + public static class OrderInfo { | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String orderId; | ||
30 | + @XmlElement(required = true) | ||
31 | + protected Product product; | ||
32 | + @XmlElement(required = true) | ||
33 | + protected ContactPerson contactPerson; | ||
34 | + @XmlElement(required = true) | ||
35 | + protected VisitPerson visitPerson; | ||
36 | + @XmlElement(required = true) | ||
37 | + protected String orderQuantity; | ||
38 | + @XmlElement(required = true) | ||
39 | + protected String orderPrice; | ||
40 | + @XmlElement(required = true) | ||
41 | + protected String orderStatus; | ||
42 | + @XmlElement(required = true) | ||
43 | + protected String token; | ||
44 | + | ||
45 | + public OrderInfo() { | ||
46 | + super(); | ||
47 | + this.orderId = ""; | ||
48 | + this.product = new Product(); | ||
49 | + this.contactPerson = new ContactPerson(); | ||
50 | + this.visitPerson = new VisitPerson(); | ||
51 | + this.orderQuantity = ""; | ||
52 | + this.orderPrice = ""; | ||
53 | + this.orderStatus = ""; | ||
54 | + this.token = ""; | ||
55 | + } | ||
56 | + | ||
57 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
58 | + @XmlType(name = "", propOrder = {"name", "mobile", "credentials", "credentialsType"}) | ||
59 | + @Data | ||
60 | + public static class ContactPerson { | ||
61 | + @XmlElement(required = true) | ||
62 | + protected String name; | ||
63 | + @XmlElement(required = true) | ||
64 | + protected String mobile; | ||
65 | + @XmlElement(required = true) | ||
66 | + protected String credentials; | ||
67 | + @XmlElement(required = true) | ||
68 | + protected String credentialsType; | ||
69 | + | ||
70 | + public ContactPerson() { | ||
71 | + super(); | ||
72 | + this.name = ""; | ||
73 | + this.mobile = ""; | ||
74 | + this.credentials = ""; | ||
75 | + this.credentialsType = ""; | ||
76 | + } | ||
77 | + } | ||
78 | + | ||
79 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
80 | + @XmlType(name = "", propOrder = {"resourceId", "timeOfBookId", "productName", "visitDate", "sellPrice"}) | ||
81 | + @Data | ||
82 | + public static class Product { | ||
83 | + @XmlElement(required = true) | ||
84 | + protected String resourceId; | ||
85 | + @XmlElement(required = true) | ||
86 | + protected String timeOfBookId; | ||
87 | + @XmlElement(required = true) | ||
88 | + protected String productName; | ||
89 | + @XmlElement(required = true) | ||
90 | + protected String visitDate; | ||
91 | + @XmlElement(required = true) | ||
92 | + protected String sellPrice; | ||
93 | + | ||
94 | + public Product() { | ||
95 | + super(); | ||
96 | + this.resourceId = ""; | ||
97 | + this.timeOfBookId = ""; | ||
98 | + this.productName = ""; | ||
99 | + this.visitDate = ""; | ||
100 | + this.sellPrice = ""; | ||
101 | + } | ||
102 | + } | ||
103 | + | ||
104 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
105 | + @XmlType(name = "", propOrder = {"person"}) | ||
106 | + @Data | ||
107 | + public static class VisitPerson { | ||
108 | + protected List<Person> person; | ||
109 | + | ||
110 | + public VisitPerson() { | ||
111 | + super(); | ||
112 | + this.person = new ArrayList<Person>(); | ||
113 | + } | ||
114 | + | ||
115 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
116 | + @XmlType(name = "", propOrder = {"name", "credentials", "credentialsType"}) | ||
117 | + @Data | ||
118 | + public static class Person { | ||
119 | + @XmlElement(required = true) | ||
120 | + protected String name; | ||
121 | + @XmlElement(required = true) | ||
122 | + protected String credentials; | ||
123 | + @XmlElement(required = true) | ||
124 | + protected String credentialsType; | ||
125 | + @XmlElement(required = false) | ||
126 | + protected String mobile; | ||
127 | + | ||
128 | + public Person() { | ||
129 | + super(); | ||
130 | + this.name = ""; | ||
131 | + this.credentials = ""; | ||
132 | + this.credentialsType = ""; | ||
133 | + this.mobile = ""; | ||
134 | + } | ||
135 | + } | ||
136 | + } | ||
137 | + } | ||
138 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreateOrderRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreateOrderRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "CreateOrderRequestBody", propOrder = {"orderInfo"}) | ||
14 | +@Data | ||
15 | +public class CreateOrderRequestBody extends RequestBody { | ||
16 | + @XmlElement(required = true) | ||
17 | + protected OrderInfo orderInfo; | ||
18 | + | ||
19 | + public CreateOrderRequestBody() { | ||
20 | + super(); | ||
21 | + this.orderInfo = new OrderInfo(); | ||
22 | + } | ||
23 | + | ||
24 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
25 | + @XmlType(name = "", propOrder = {"orderId", "product", "contactPerson", "visitPerson", "orderQuantity", "orderPrice", "orderStatus", "token"}) | ||
26 | + @Data | ||
27 | + public static class OrderInfo { | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String orderId; | ||
30 | + @XmlElement(required = true) | ||
31 | + protected Product product; | ||
32 | + @XmlElement(required = true) | ||
33 | + protected ContactPerson contactPerson; | ||
34 | + @XmlElement(required = true) | ||
35 | + protected VisitPerson visitPerson; | ||
36 | + @XmlElement(required = true) | ||
37 | + protected String orderQuantity; | ||
38 | + @XmlElement(required = true) | ||
39 | + protected String orderPrice; | ||
40 | + @XmlElement(required = true) | ||
41 | + protected String orderStatus; | ||
42 | + @XmlElement(required = true) | ||
43 | + protected String token; | ||
44 | + | ||
45 | + public OrderInfo() { | ||
46 | + super(); | ||
47 | + this.orderId = ""; | ||
48 | + this.product = new Product(); | ||
49 | + this.contactPerson = new ContactPerson(); | ||
50 | + this.visitPerson = new VisitPerson(); | ||
51 | + this.orderQuantity = ""; | ||
52 | + this.orderPrice = ""; | ||
53 | + this.orderStatus = ""; | ||
54 | + this.token = ""; | ||
55 | + } | ||
56 | + | ||
57 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
58 | + @XmlType(name = "", propOrder = {"name", "mobile", "credentials", "credentialsType"}) | ||
59 | + @Data | ||
60 | + public static class ContactPerson { | ||
61 | + @XmlElement(required = true) | ||
62 | + protected String name; | ||
63 | + @XmlElement(required = true) | ||
64 | + protected String mobile; | ||
65 | + @XmlElement(required = true) | ||
66 | + protected String credentials; | ||
67 | + @XmlElement(required = true) | ||
68 | + protected String credentialsType; | ||
69 | + | ||
70 | + public ContactPerson() { | ||
71 | + super(); | ||
72 | + this.name = ""; | ||
73 | + this.mobile = ""; | ||
74 | + this.credentials = ""; | ||
75 | + this.credentialsType = ""; | ||
76 | + } | ||
77 | + } | ||
78 | + | ||
79 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
80 | + @XmlType(name = "", propOrder = {"resourceId", "timeOfBookId", "productName", "visitDate", "sellPrice"}) | ||
81 | + @Data | ||
82 | + public static class Product { | ||
83 | + @XmlElement(required = true) | ||
84 | + protected String resourceId; | ||
85 | + @XmlElement(required = true) | ||
86 | + protected String timeOfBookId; | ||
87 | + @XmlElement(required = true) | ||
88 | + protected String productName; | ||
89 | + @XmlElement(required = true) | ||
90 | + protected String visitDate; | ||
91 | + @XmlElement(required = true) | ||
92 | + protected String sellPrice; | ||
93 | + | ||
94 | + public Product() { | ||
95 | + super(); | ||
96 | + this.resourceId = ""; | ||
97 | + this.timeOfBookId = ""; | ||
98 | + this.productName = ""; | ||
99 | + this.visitDate = ""; | ||
100 | + this.sellPrice = ""; | ||
101 | + } | ||
102 | + } | ||
103 | + | ||
104 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
105 | + @XmlType(name = "", propOrder = {"person"}) | ||
106 | + @Data | ||
107 | + public static class VisitPerson { | ||
108 | + | ||
109 | + protected List<Person> person; | ||
110 | + | ||
111 | + public VisitPerson() { | ||
112 | + super(); | ||
113 | + this.person = new ArrayList<Person>(); | ||
114 | + } | ||
115 | + | ||
116 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
117 | + @XmlType(name = "", propOrder = {"name", "credentials", "credentialsType", "mobile", "groupId"}) | ||
118 | + @Data | ||
119 | + public static class Person { | ||
120 | + @XmlElement(required = true) | ||
121 | + protected String name; | ||
122 | + @XmlElement(required = true) | ||
123 | + protected String credentials; | ||
124 | + @XmlElement(required = true) | ||
125 | + protected String credentialsType; | ||
126 | + @XmlElement(required = false) | ||
127 | + protected String mobile; | ||
128 | + @XmlElement(required = false) | ||
129 | + protected String groupId; | ||
130 | + | ||
131 | + public Person() { | ||
132 | + super(); | ||
133 | + this.name = ""; | ||
134 | + this.credentials = ""; | ||
135 | + this.credentialsType = ""; | ||
136 | + this.mobile = ""; | ||
137 | + } | ||
138 | + } | ||
139 | + } | ||
140 | + } | ||
141 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreatePaymentOrderRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreatePaymentOrderRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "CreatePaymentOrderRequestBody", propOrder = {"orderInfo"}) | ||
14 | +@Data | ||
15 | +public class CreatePaymentOrderRequestBody extends RequestBody { | ||
16 | + @XmlElement(required = true) | ||
17 | + protected OrderInfo orderInfo; | ||
18 | + | ||
19 | + public CreatePaymentOrderRequestBody() { | ||
20 | + super(); | ||
21 | + this.orderInfo = new OrderInfo(); | ||
22 | + } | ||
23 | + | ||
24 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
25 | + @XmlType(name = "", propOrder = {"orderId", "product", "contactPerson", "visitPerson", "orderQuantity", "orderPrice", "orderStatus"}) | ||
26 | + @Data | ||
27 | + public static class OrderInfo { | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String orderId; | ||
30 | + @XmlElement(required = true) | ||
31 | + protected Product product; | ||
32 | + @XmlElement(required = true) | ||
33 | + protected ContactPerson contactPerson; | ||
34 | + @XmlElement(required = true) | ||
35 | + protected VisitPerson visitPerson; | ||
36 | + @XmlElement(required = true) | ||
37 | + protected String orderQuantity; | ||
38 | + @XmlElement(required = true) | ||
39 | + protected String orderPrice; | ||
40 | + @XmlElement(required = true) | ||
41 | + protected String orderStatus; | ||
42 | + @XmlElement(required = true) | ||
43 | + protected String token; | ||
44 | + | ||
45 | + | ||
46 | + public OrderInfo() { | ||
47 | + super(); | ||
48 | + this.orderId = ""; | ||
49 | + this.product = new Product(); | ||
50 | + this.contactPerson = new ContactPerson(); | ||
51 | + this.visitPerson = new VisitPerson(); | ||
52 | + this.orderQuantity = ""; | ||
53 | + this.orderPrice = ""; | ||
54 | + this.orderStatus = ""; | ||
55 | + this.token = ""; | ||
56 | + } | ||
57 | + | ||
58 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
59 | + @XmlType(name = "", propOrder = {"name", "mobile", "credentials", "credentialsType"}) | ||
60 | + @Data | ||
61 | + public static class ContactPerson { | ||
62 | + @XmlElement(required = true) | ||
63 | + protected String name; | ||
64 | + @XmlElement(required = true) | ||
65 | + protected String mobile; | ||
66 | + @XmlElement(required = true) | ||
67 | + protected String credentials; | ||
68 | + @XmlElement(required = true) | ||
69 | + protected String credentialsType; | ||
70 | + | ||
71 | + public ContactPerson() { | ||
72 | + super(); | ||
73 | + this.name = ""; | ||
74 | + this.mobile = ""; | ||
75 | + this.credentials = ""; | ||
76 | + this.credentialsType = ""; | ||
77 | + } | ||
78 | + } | ||
79 | + | ||
80 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
81 | + @XmlType(name = "", propOrder = {"resourceId", "timeOfBookId", "productName", "visitDate", "sellPrice"}) | ||
82 | + @Data | ||
83 | + public static class Product { | ||
84 | + @XmlElement(required = true) | ||
85 | + protected String resourceId; | ||
86 | + @XmlElement(required = true) | ||
87 | + protected String timeOfBookId; | ||
88 | + @XmlElement(required = true) | ||
89 | + protected String productName; | ||
90 | + @XmlElement(required = true) | ||
91 | + protected String visitDate; | ||
92 | + @XmlElement(required = false) | ||
93 | + protected String leaveDate; | ||
94 | + @XmlElement(required = true) | ||
95 | + protected String sellPrice; | ||
96 | + | ||
97 | + public Product() { | ||
98 | + super(); | ||
99 | + this.resourceId = ""; | ||
100 | + this.timeOfBookId = ""; | ||
101 | + this.productName = ""; | ||
102 | + this.visitDate = ""; | ||
103 | + this.leaveDate = ""; | ||
104 | + this.sellPrice = ""; | ||
105 | + } | ||
106 | + } | ||
107 | + | ||
108 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
109 | + @XmlType(name = "", propOrder = {"person"}) | ||
110 | + @Data | ||
111 | + public static class VisitPerson { | ||
112 | + protected List<Person> person; | ||
113 | + | ||
114 | + public VisitPerson() { | ||
115 | + super(); | ||
116 | + this.person = new ArrayList<Person>(); | ||
117 | + } | ||
118 | + | ||
119 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
120 | + @XmlType(name = "", propOrder = {"name", "credentials", "credentialsType", "mobile", "groupId"}) | ||
121 | + @Data | ||
122 | + public static class Person { | ||
123 | + @XmlElement(required = true) | ||
124 | + protected String name; | ||
125 | + @XmlElement(required = true) | ||
126 | + protected String credentials; | ||
127 | + @XmlElement(required = true) | ||
128 | + protected String credentialsType; | ||
129 | + @XmlElement(required = false) | ||
130 | + protected String mobile; | ||
131 | + @XmlElement(required = false) | ||
132 | + protected String groupId; | ||
133 | + | ||
134 | + public Person() { | ||
135 | + super(); | ||
136 | + this.name = ""; | ||
137 | + this.credentials = ""; | ||
138 | + this.credentialsType = ""; | ||
139 | + this.mobile = ""; | ||
140 | + this.groupId = ""; | ||
141 | + } | ||
142 | + } | ||
143 | + } | ||
144 | + } | ||
145 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/GetOrderByOTARequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/GetOrderByOTARequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "GetOrderByOTARequestBody", propOrder = {"partnerOrderId","orderId"}) | ||
12 | +@Data | ||
13 | +public class GetOrderByOTARequestBody extends RequestBody { | ||
14 | + @XmlElement(required = false) | ||
15 | + protected String partnerOrderId; | ||
16 | + | ||
17 | + @XmlElement(required = false) | ||
18 | + protected String orderId; | ||
19 | + | ||
20 | + public GetOrderByOTARequestBody() { | ||
21 | + super(); | ||
22 | + this.partnerOrderId = ""; | ||
23 | + this.orderId =""; | ||
24 | + } | ||
25 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/GetProductByOTARequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/GetProductByOTARequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "GetProductByOTARequestBody", propOrder = {"method", "currentPage", "pageSize", "resourceId"}) | ||
12 | +@Data | ||
13 | +public class GetProductByOTARequestBody extends RequestBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String method; | ||
16 | + @XmlElement(required = true) | ||
17 | + protected String currentPage; | ||
18 | + @XmlElement(required = true) | ||
19 | + protected String pageSize; | ||
20 | + @XmlElement(required = true) | ||
21 | + protected String resourceId; | ||
22 | + @XmlElement(required = true) | ||
23 | + protected String queryStartDay; | ||
24 | + @XmlElement(required = true) | ||
25 | + protected String queryEndDay; | ||
26 | + | ||
27 | + public GetProductByOTARequestBody() { | ||
28 | + super(); | ||
29 | + this.method = ""; | ||
30 | + this.currentPage = ""; | ||
31 | + this.pageSize = ""; | ||
32 | + this.resourceId = ""; | ||
33 | + this.queryStartDay = ""; | ||
34 | + this.queryEndDay = ""; | ||
35 | + } | ||
36 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/GetStockProductInfoRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/GetStockProductInfoRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | +import lombok.Data; | ||
3 | + | ||
4 | +import javax.xml.bind.annotation.XmlAccessType; | ||
5 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
6 | +import javax.xml.bind.annotation.XmlElement; | ||
7 | +import javax.xml.bind.annotation.XmlType; | ||
8 | + | ||
9 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
10 | +@XmlType(name = "GetStockProductInfoRequestBody", propOrder = {"startDate", "endDate", "resourceId"}) | ||
11 | +@Data | ||
12 | +public class GetStockProductInfoRequestBody extends RequestBody { | ||
13 | + @XmlElement(required = true) | ||
14 | + protected String startDate; | ||
15 | + @XmlElement(required = true) | ||
16 | + protected String endDate; | ||
17 | + @XmlElement(required = true) | ||
18 | + protected String resourceId; | ||
19 | + | ||
20 | + public GetStockProductInfoRequestBody() { | ||
21 | + super(); | ||
22 | + this.startDate = ""; | ||
23 | + this.endDate = ""; | ||
24 | + this.resourceId = ""; | ||
25 | + } | ||
26 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderConsumedRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderConsumedRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "NoticeOrderConsumedRequestBody", propOrder = {"orderInfo"}) | ||
14 | +@Data | ||
15 | +public class NoticeOrderConsumedRequestBody extends RequestBody { | ||
16 | + @XmlElement(required = true) | ||
17 | + protected OrderInfo orderInfo; | ||
18 | + | ||
19 | + public NoticeOrderConsumedRequestBody() { | ||
20 | + super(); | ||
21 | + this.orderInfo = new OrderInfo(); | ||
22 | + } | ||
23 | + | ||
24 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
25 | + @XmlType(name = "", propOrder = {"partnerorderId", "otaorderId", "orderQuantity", "useQuantity", "useTotalQuantity", "consumeInfo", "consumedSeq", "orderId", "vouchers"}) | ||
26 | + @Data | ||
27 | + public static class OrderInfo { | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String partnerorderId; | ||
30 | + @XmlElement(required = true) | ||
31 | + protected String otaorderId; | ||
32 | + @XmlElement(required = true) | ||
33 | + protected String orderQuantity; | ||
34 | + @XmlElement(required = true) | ||
35 | + protected String useQuantity; | ||
36 | + @XmlElement(required = true) | ||
37 | + protected String useTotalQuantity; | ||
38 | + @XmlElement(required = true) | ||
39 | + protected String consumeInfo; | ||
40 | + @XmlElement(required = true) | ||
41 | + protected String consumedSeq; | ||
42 | + @XmlElement(required = true) | ||
43 | + protected String consumedTime; | ||
44 | + @XmlElement(required = true) | ||
45 | + protected String orderId; | ||
46 | + @XmlElement(required = false) | ||
47 | + protected Vouchers vouchers; | ||
48 | + | ||
49 | + public OrderInfo() { | ||
50 | + super(); | ||
51 | + this.partnerorderId = ""; | ||
52 | + this.otaorderId=""; | ||
53 | + this.orderQuantity = ""; | ||
54 | + this.useQuantity = ""; | ||
55 | + this.consumeInfo = ""; | ||
56 | + this.consumedSeq=""; | ||
57 | + this.consumedTime=""; | ||
58 | + this.orderId=""; | ||
59 | + this.useTotalQuantity=""; | ||
60 | + this.vouchers=new Vouchers(); | ||
61 | + } | ||
62 | + | ||
63 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
64 | + @XmlType(name = "voucher", propOrder = { | ||
65 | + "voucher" | ||
66 | + }) | ||
67 | + @Data | ||
68 | + public static class Vouchers{ | ||
69 | + @XmlElement(required = false) | ||
70 | + protected List<Voucher> voucher; | ||
71 | + | ||
72 | + public Vouchers(){ | ||
73 | + super(); | ||
74 | + this.voucher = new ArrayList<Voucher>(); | ||
75 | + } | ||
76 | + | ||
77 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
78 | + @XmlType(name = "voucher", propOrder = { | ||
79 | + "voucherCard", | ||
80 | + "voucherCode", | ||
81 | + "voucherCodeUrl", | ||
82 | + }) | ||
83 | + @Data | ||
84 | + public static class Voucher{ | ||
85 | + @XmlElement(required = false) | ||
86 | + protected String voucherCard; | ||
87 | + @XmlElement(required = false) | ||
88 | + protected String voucherCode; | ||
89 | + @XmlElement(required = false) | ||
90 | + protected String voucherCodeUrl; | ||
91 | + | ||
92 | + public Voucher(){ | ||
93 | + super(); | ||
94 | + this.voucherCard = ""; | ||
95 | + this.voucherCode = ""; | ||
96 | + this.voucherCodeUrl=""; | ||
97 | + } | ||
98 | + } | ||
99 | + } | ||
100 | + } | ||
101 | + | ||
102 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderEticketSendedRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderEticketSendedRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeOrderEticketSendedRequestBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class NoticeOrderEticketSendedRequestBody extends RequestBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected OrderInfo orderInfo; | ||
16 | + | ||
17 | + public NoticeOrderEticketSendedRequestBody() { | ||
18 | + super(); | ||
19 | + this.orderInfo = new OrderInfo(); | ||
20 | + } | ||
21 | + | ||
22 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
23 | + @XmlType(name = "", propOrder = {"partnerorderId", "eticketNo", "eticketSended"}) | ||
24 | + @Data | ||
25 | + public static class OrderInfo { | ||
26 | + @XmlElement(required = true) | ||
27 | + protected String partnerorderId; | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String eticketNo; | ||
30 | + @XmlElement(required = true) | ||
31 | + protected String eticketSended; | ||
32 | + | ||
33 | + public OrderInfo() { | ||
34 | + super(); | ||
35 | + this.partnerorderId = ""; | ||
36 | + this.eticketNo = ""; | ||
37 | + this.eticketSended = ""; | ||
38 | + } | ||
39 | + } | ||
40 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderModifyRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderModifyRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeOrderPrintSuccessRequestBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class NoticeOrderModifyRequestBody extends RequestBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected OrderInfo orderInfo; | ||
16 | + | ||
17 | + public NoticeOrderModifyRequestBody() { | ||
18 | + super(); | ||
19 | + this.orderInfo = new OrderInfo(); | ||
20 | + } | ||
21 | + | ||
22 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
23 | + @XmlType(name = "", propOrder = {"partnerorderId", "otaorderId", "orderStatus","operateData","originalData"}) | ||
24 | + @Data | ||
25 | + public static class OrderInfo { | ||
26 | + @XmlElement(required = true) | ||
27 | + protected String partnerorderId; | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String otaorderId; | ||
30 | + @XmlElement(required = true) | ||
31 | + protected String orderStatus; | ||
32 | + @XmlElement(required = true) | ||
33 | + protected String operateData; | ||
34 | + @XmlElement(required = true) | ||
35 | + protected String originalData; | ||
36 | + | ||
37 | + public OrderInfo() { | ||
38 | + super(); | ||
39 | + this.partnerorderId = ""; | ||
40 | + this.otaorderId = ""; | ||
41 | + this.orderStatus = ""; | ||
42 | + this.operateData = ""; | ||
43 | + this.originalData = ""; | ||
44 | + } | ||
45 | + } | ||
46 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderPrintSuccessRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderPrintSuccessRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "NoticeOrderPrintSuccessRequestBody", propOrder = {"orderInfo"}) | ||
14 | +@Data | ||
15 | +public class NoticeOrderPrintSuccessRequestBody extends RequestBody { | ||
16 | + public NoticeOrderPrintSuccessRequestBody() { | ||
17 | + super(); | ||
18 | + this.orderInfo = new OrderInfo(); | ||
19 | + } | ||
20 | + | ||
21 | + @XmlElement(required = true) | ||
22 | + protected OrderInfo orderInfo; | ||
23 | + | ||
24 | + | ||
25 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
26 | + @XmlType(name = "", propOrder = { | ||
27 | + "partnerorderId", | ||
28 | + "orderStatus", | ||
29 | + "qrCodeStr", | ||
30 | + "qrCodeUrl", | ||
31 | + "verifyCode", | ||
32 | + "vouchers" | ||
33 | + }) | ||
34 | + @Data | ||
35 | + public static class OrderInfo { | ||
36 | + | ||
37 | + @XmlElement(required = true) | ||
38 | + protected String partnerorderId; | ||
39 | + @XmlElement(required = true) | ||
40 | + protected String otaorderId; | ||
41 | + @XmlElement(required = true) | ||
42 | + protected String distributorOrderId; | ||
43 | + @XmlElement(required = true) | ||
44 | + protected String description; | ||
45 | + @XmlElement(required = true) | ||
46 | + protected String orderStatus; | ||
47 | + @XmlElement(required = false) | ||
48 | + protected String qrCodeStr; | ||
49 | + @XmlElement(required = false) | ||
50 | + protected String qrCodeUrl; | ||
51 | + @XmlElement(required = false) | ||
52 | + protected String onlyQrCodeUrl; | ||
53 | + @XmlElement(required = false) | ||
54 | + protected String verifyCode; | ||
55 | + @XmlElement(required = false) | ||
56 | + protected Vouchers vouchers; | ||
57 | + | ||
58 | + public OrderInfo() { | ||
59 | + super(); | ||
60 | + this.partnerorderId = ""; | ||
61 | + this.otaorderId = ""; | ||
62 | + this.distributorOrderId = ""; | ||
63 | + this.description = ""; | ||
64 | + this.orderStatus = ""; | ||
65 | + this.qrCodeStr = ""; | ||
66 | + this.qrCodeUrl = ""; | ||
67 | + this.onlyQrCodeUrl=""; | ||
68 | + this.verifyCode = ""; | ||
69 | + this.vouchers = new Vouchers(); | ||
70 | + } | ||
71 | + | ||
72 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
73 | + @XmlType(name = "", propOrder = { | ||
74 | + "voucher" | ||
75 | + }) | ||
76 | + @Data | ||
77 | + public static class Vouchers{ | ||
78 | + @XmlElement(required = false) | ||
79 | + protected List<Voucher> voucher; | ||
80 | + | ||
81 | + public Vouchers(){ | ||
82 | + super(); | ||
83 | + this.voucher = new ArrayList<Voucher>(); | ||
84 | + } | ||
85 | + | ||
86 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
87 | + @XmlType(name = "", propOrder = { | ||
88 | + "voucherCard", | ||
89 | + "voucherCode", | ||
90 | + "voucherCodeUrl" | ||
91 | + }) | ||
92 | + @Data | ||
93 | + public static class Voucher{ | ||
94 | + @XmlElement(required = false) | ||
95 | + protected String voucherCard; | ||
96 | + @XmlElement(required = false) | ||
97 | + protected String voucherCode; | ||
98 | + @XmlElement(required = false) | ||
99 | + protected String voucherCodeUrl; | ||
100 | + | ||
101 | + public Voucher(){ | ||
102 | + super(); | ||
103 | + this.voucherCard = ""; | ||
104 | + this.voucherCode = ""; | ||
105 | + this.voucherCodeUrl = ""; | ||
106 | + } | ||
107 | + } | ||
108 | + } | ||
109 | + } | ||
110 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundApproveResultRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundApproveResultRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "NoticeOrderRefundApproveResultRequestBody", propOrder = {"orderInfo"}) | ||
14 | +@Data | ||
15 | +public class NoticeOrderRefundApproveResultRequestBody extends RequestBody { | ||
16 | + @XmlElement(required = true) | ||
17 | + protected OrderInfo orderInfo; | ||
18 | + | ||
19 | + public NoticeOrderRefundApproveResultRequestBody() { | ||
20 | + super(); | ||
21 | + this.orderInfo = new OrderInfo(); | ||
22 | + } | ||
23 | + | ||
24 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
25 | + @XmlType(name = "", propOrder = { | ||
26 | + "partnerorderId", | ||
27 | + "otaorderId", | ||
28 | + "refundSeq", | ||
29 | + "orderQuantity", | ||
30 | + "refundResult", | ||
31 | + "refundQuantity", | ||
32 | + "refundResult", | ||
33 | + "description", | ||
34 | + "orderRefundPrice", | ||
35 | + "orderRefundCharge" | ||
36 | + }) | ||
37 | + @Data | ||
38 | + public static class OrderInfo { | ||
39 | + | ||
40 | + @XmlElement(required = true) | ||
41 | + protected String partnerorderId; | ||
42 | + @XmlElement(required = true) | ||
43 | + protected String otaorderId; | ||
44 | + @XmlElement(required = true) | ||
45 | + protected String refundSeq; | ||
46 | + @XmlElement(required = true) | ||
47 | + protected String orderQuantity; | ||
48 | + @XmlElement(required = true) | ||
49 | + protected String refundResult; | ||
50 | + @XmlElement(required = true) | ||
51 | + protected String description; | ||
52 | + @XmlElement(required = true) | ||
53 | + protected String refundQuantity; | ||
54 | + @XmlElement(required = true) | ||
55 | + protected String orderRefundPrice; | ||
56 | + @XmlElement(required = true) | ||
57 | + protected String orderRefundCharge; | ||
58 | + @XmlElement(required = true) | ||
59 | + protected Vouchers vouchers; | ||
60 | + | ||
61 | + public OrderInfo() { | ||
62 | + super(); | ||
63 | + this.partnerorderId = ""; | ||
64 | + this.otaorderId=""; | ||
65 | + this.refundSeq = ""; | ||
66 | + this.orderQuantity = ""; | ||
67 | + this.refundResult = ""; | ||
68 | + this.description = ""; | ||
69 | + this.refundQuantity = ""; | ||
70 | + this.orderRefundPrice = ""; | ||
71 | + this.orderRefundCharge = ""; | ||
72 | + this.vouchers = new Vouchers(); | ||
73 | + } | ||
74 | + | ||
75 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
76 | + @XmlType(name = "vouchers", propOrder = { | ||
77 | + "voucher" | ||
78 | + }) | ||
79 | + @Data | ||
80 | + public static class Vouchers{ | ||
81 | + @XmlElement(required = false) | ||
82 | + protected List<Voucher> voucher; | ||
83 | + | ||
84 | + public Vouchers(){ | ||
85 | + super(); | ||
86 | + this.voucher = new ArrayList<Voucher>(); | ||
87 | + } | ||
88 | + | ||
89 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
90 | + @XmlType(name = "voucher", propOrder = { | ||
91 | + "voucherCard", | ||
92 | + "voucherCode", | ||
93 | + "voucherStatus", | ||
94 | + "voucherCodeUrl", | ||
95 | + }) | ||
96 | + @Data | ||
97 | + public static class Voucher{ | ||
98 | + @XmlElement(required = false) | ||
99 | + protected String voucherCard; | ||
100 | + @XmlElement(required = false) | ||
101 | + protected String voucherCode; | ||
102 | + @XmlElement(required = false) | ||
103 | + protected String voucherStatus; | ||
104 | + @XmlElement(required = false) | ||
105 | + protected String voucherCodeUrl; | ||
106 | + | ||
107 | + public Voucher(){ | ||
108 | + super(); | ||
109 | + this.voucherCard = ""; | ||
110 | + this.voucherCode = ""; | ||
111 | + this.voucherStatus = ""; | ||
112 | + this.voucherCodeUrl=""; | ||
113 | + } | ||
114 | + } | ||
115 | + } | ||
116 | + } | ||
117 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "NoticeOrderRefundRequestBody", propOrder = {"orderInfo"}) | ||
14 | +@Data | ||
15 | +public class NoticeOrderRefundRequestBody extends RequestBody { | ||
16 | + @XmlElement(required = true) | ||
17 | + protected OrderInfo orderInfo; | ||
18 | + | ||
19 | + public NoticeOrderRefundRequestBody() { | ||
20 | + super(); | ||
21 | + this.orderInfo = new OrderInfo(); | ||
22 | + } | ||
23 | + | ||
24 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
25 | + @XmlType(name = "", propOrder = {"partnerorderId", "otaorderId", "refundSeq", "orderQuantity", "refundQuantity", "orderRefundPrice", "orderRefundCharge", "vouchers"}) | ||
26 | + @Data | ||
27 | + public static class OrderInfo { | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String partnerorderId; | ||
30 | + @XmlElement(required = true) | ||
31 | + protected String otaorderId; | ||
32 | + @XmlElement(required = true) | ||
33 | + protected String refundSeq; | ||
34 | + @XmlElement(required = true) | ||
35 | + protected String orderQuantity; | ||
36 | + @XmlElement(required = true) | ||
37 | + protected String refundQuantity; | ||
38 | + @XmlElement(required = true) | ||
39 | + protected String orderRefundPrice; | ||
40 | + @XmlElement(required = true) | ||
41 | + protected String orderRefundCharge; | ||
42 | + @XmlElement(required = false) | ||
43 | + protected Vouchers vouchers; | ||
44 | + | ||
45 | + public OrderInfo() { | ||
46 | + super(); | ||
47 | + this.partnerorderId = ""; | ||
48 | + this.otaorderId=""; | ||
49 | + this.refundSeq = ""; | ||
50 | + this.orderQuantity = ""; | ||
51 | + this.refundQuantity = ""; | ||
52 | + this.orderRefundPrice = ""; | ||
53 | + this.orderRefundCharge = ""; | ||
54 | + this.vouchers=new Vouchers(); | ||
55 | + } | ||
56 | + | ||
57 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
58 | + @XmlType(name = "vouchers", propOrder = {"voucher"}) | ||
59 | + @Data | ||
60 | + public static class Vouchers{ | ||
61 | + @XmlElement(required = false) | ||
62 | + protected List<Voucher> voucher; | ||
63 | + | ||
64 | + public Vouchers(){ | ||
65 | + super(); | ||
66 | + this.voucher = new ArrayList<Voucher>(); | ||
67 | + } | ||
68 | + | ||
69 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
70 | + @XmlType(name = "voucher", propOrder = {"voucherCard", "voucherCode", "voucherStatus", "voucherCodeUrl",}) | ||
71 | + @Data | ||
72 | + public static class Voucher{ | ||
73 | + @XmlElement(required = false) | ||
74 | + protected String voucherCard; | ||
75 | + @XmlElement(required = false) | ||
76 | + protected String voucherCode; | ||
77 | + @XmlElement(required = false) | ||
78 | + protected String voucherStatus; | ||
79 | + @XmlElement(required = false) | ||
80 | + protected String voucherCodeUrl; | ||
81 | + | ||
82 | + public Voucher(){ | ||
83 | + super(); | ||
84 | + this.voucherCard = ""; | ||
85 | + this.voucherCode = ""; | ||
86 | + this.voucherStatus = ""; | ||
87 | + this.voucherCodeUrl=""; | ||
88 | + } | ||
89 | + } | ||
90 | + } | ||
91 | + } | ||
92 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundedByOTARequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundedByOTARequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeOrderRefundedByOTARequestBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class NoticeOrderRefundedByOTARequestBody extends RequestBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected OrderInfo orderInfo; | ||
16 | + | ||
17 | + public NoticeOrderRefundedByOTARequestBody() { | ||
18 | + super(); | ||
19 | + this.orderInfo = new OrderInfo(); | ||
20 | + } | ||
21 | + | ||
22 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
23 | + @XmlType(name = "", propOrder = {"partnerorderId", "refundSeq", "orderQuantity", "orderPrice", "refundQuantity", "orderRefundPrice", "orderRefundCharge", "refundExplain"}) | ||
24 | + @Data | ||
25 | + public static class OrderInfo { | ||
26 | + @XmlElement(required = true) | ||
27 | + protected String partnerorderId; //订单id | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String refundSeq; //退订流水号 | ||
30 | + @XmlElement(required = true) | ||
31 | + protected String orderQuantity; //订单数量 | ||
32 | + @XmlElement(required = true) | ||
33 | + protected String orderPrice; //订单金额 | ||
34 | + @XmlElement(required = true) | ||
35 | + protected String refundQuantity; //退订数量 | ||
36 | + @XmlElement(required = true) | ||
37 | + protected String orderRefundPrice; //退订金额 | ||
38 | + @XmlElement(required = true) | ||
39 | + protected String orderRefundCharge; // 退款手续费 | ||
40 | + @XmlElement(required = true) | ||
41 | + protected String refundExplain; //退款说明 | ||
42 | + | ||
43 | + public OrderInfo() { | ||
44 | + super(); | ||
45 | + this.partnerorderId = ""; | ||
46 | + this.refundSeq = ""; | ||
47 | + this.orderQuantity = ""; | ||
48 | + this.orderPrice = ""; | ||
49 | + this.refundQuantity = ""; | ||
50 | + this.orderRefundPrice = ""; | ||
51 | + this.orderRefundCharge = ""; | ||
52 | + this.refundExplain = ""; | ||
53 | + } | ||
54 | + } | ||
55 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderReserveRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderReserveRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeOrderPrintSuccessRequestBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class NoticeOrderReserveRequestBody extends RequestBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected OrderInfo orderInfo; | ||
16 | + | ||
17 | + public NoticeOrderReserveRequestBody() { | ||
18 | + super(); | ||
19 | + this.orderInfo = new OrderInfo(); | ||
20 | + } | ||
21 | + | ||
22 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
23 | + @XmlType(name = "", propOrder = {"partnerorderId","otaorderId","orderStatus","price","totalQuantity","totalMoney","quantity"}) | ||
24 | + @Data | ||
25 | + public static class OrderInfo { | ||
26 | + @XmlElement(required = true) | ||
27 | + private String partnerorderId; | ||
28 | + @XmlElement(required = true) | ||
29 | + private String otaorderId; | ||
30 | + @XmlElement(required = true) | ||
31 | + private String orderStatus; | ||
32 | + @XmlElement(required = true) | ||
33 | + private String price; | ||
34 | + @XmlElement(required = true) | ||
35 | + private String totalQuantity; | ||
36 | + @XmlElement(required = true) | ||
37 | + private String totalMoney; | ||
38 | + @XmlElement(required = true) | ||
39 | + private String quantity; | ||
40 | + | ||
41 | + public OrderInfo() { | ||
42 | + super(); | ||
43 | + this.partnerorderId = ""; | ||
44 | + this.otaorderId = ""; | ||
45 | + this.orderStatus = ""; | ||
46 | + this.price = ""; | ||
47 | + this.totalQuantity = ""; | ||
48 | + this.totalMoney = ""; | ||
49 | + this.quantity = ""; | ||
50 | + } | ||
51 | + } | ||
52 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeProductChangeRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeProductChangeRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeProductChangeRequestBody", propOrder = {"resourceId","changeType"}) | ||
12 | +@Data | ||
13 | +public class NoticeProductChangeRequestBody extends RequestBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String resourceId; | ||
16 | + | ||
17 | + @XmlElement(required = true) | ||
18 | + protected String changeType; | ||
19 | + | ||
20 | + public NoticeProductChangeRequestBody(){ | ||
21 | + this.resourceId = ""; | ||
22 | + this.changeType = ""; | ||
23 | + } | ||
24 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/PayOrderRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/PayOrderRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "PayOrderRequestBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class PayOrderRequestBody extends RequestBody { | ||
14 | + | ||
15 | + @XmlElement(required = true) | ||
16 | + protected OrderInfo orderInfo; | ||
17 | + | ||
18 | + public PayOrderRequestBody() { | ||
19 | + super(); | ||
20 | + this.orderInfo = new OrderInfo(); | ||
21 | + } | ||
22 | + | ||
23 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
24 | + @XmlType(name = "", propOrder = {"partnerOrderId","otaOrderId","orderId","orderStatus","orderPrice"}) | ||
25 | + @Data | ||
26 | + public static class OrderInfo { | ||
27 | + @XmlElement(required = true) | ||
28 | + protected String partnerOrderId; | ||
29 | + @XmlElement(required = true) | ||
30 | + protected String otaOrderId; | ||
31 | + @XmlElement(required = true) | ||
32 | + protected String orderId; | ||
33 | + @XmlElement(required = true) | ||
34 | + protected String orderStatus; | ||
35 | + @XmlElement(required = true) | ||
36 | + protected String orderPrice; | ||
37 | + | ||
38 | + public OrderInfo() { | ||
39 | + super(); | ||
40 | + this.otaOrderId=""; | ||
41 | + this.orderId=""; | ||
42 | + this.partnerOrderId = ""; | ||
43 | + this.orderStatus = ""; | ||
44 | + this.orderPrice = ""; | ||
45 | + } | ||
46 | + } | ||
47 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/PostFaceInfoRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/PostFaceInfoRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "PostFaceInfoRequestBody", propOrder = {"orderId","serialNumber","faceInfos"}) | ||
14 | +@Data | ||
15 | +public class PostFaceInfoRequestBody extends RequestBody { | ||
16 | + /** 订单id */ | ||
17 | + @XmlElement(required = true) | ||
18 | + protected String orderId; | ||
19 | + | ||
20 | + /** 流水号 */ | ||
21 | + @XmlElement(required = true) | ||
22 | + protected String serialNumber; | ||
23 | + | ||
24 | + /** 人脸信息 */ | ||
25 | + @XmlElement(required = true) | ||
26 | + protected FaceInfos faceInfos; | ||
27 | + | ||
28 | + public PostFaceInfoRequestBody(){ | ||
29 | + super(); | ||
30 | + this.orderId = ""; | ||
31 | + this.serialNumber = ""; | ||
32 | + this.faceInfos = new FaceInfos(); | ||
33 | + } | ||
34 | + | ||
35 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
36 | + @XmlType(name = "", propOrder = {"faceInfo"}) | ||
37 | + @Data | ||
38 | + public static class FaceInfos{ | ||
39 | + protected List<FaceInfo> faceInfo; | ||
40 | + | ||
41 | + public FaceInfos(){ | ||
42 | + super(); | ||
43 | + this.faceInfo = new ArrayList<FaceInfo>(); | ||
44 | + } | ||
45 | + | ||
46 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
47 | + @XmlType(name = "", propOrder = {"credentials", "url"}) | ||
48 | + @Data | ||
49 | + public static class FaceInfo { | ||
50 | + /** 游客身份证credentials */ | ||
51 | + @XmlElement(required = true) | ||
52 | + protected String credentials; | ||
53 | + | ||
54 | + /** 人脸图片地址url */ | ||
55 | + @XmlElement(required = true) | ||
56 | + protected String url; | ||
57 | + | ||
58 | + public FaceInfo() { | ||
59 | + super(); | ||
60 | + this.credentials = ""; | ||
61 | + this.url = ""; | ||
62 | + } | ||
63 | + } | ||
64 | + } | ||
65 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/PushOrderRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/PushOrderRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "PushOrderRequestBody", propOrder = {"orderInfo"}) | ||
14 | +@Data | ||
15 | +public class PushOrderRequestBody extends RequestBody { | ||
16 | + @XmlElement(required = true) | ||
17 | + protected OrderInfo orderInfo; | ||
18 | + | ||
19 | + public PushOrderRequestBody() { | ||
20 | + super(); | ||
21 | + this.orderInfo = new OrderInfo(); | ||
22 | + } | ||
23 | + | ||
24 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
25 | + @XmlType(name = "", propOrder = {"partnerOrderId", "contactPerson", "visitPerson","visitDate"}) | ||
26 | + @Data | ||
27 | + public static class OrderInfo { | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String partnerOrderId; | ||
30 | + @XmlElement(required = true) | ||
31 | + protected ContactPerson contactPerson; | ||
32 | + @XmlElement(required = true) | ||
33 | + protected VisitPerson visitPerson; | ||
34 | + @XmlElement(required = true) | ||
35 | + protected String visitDate; | ||
36 | + | ||
37 | + public OrderInfo() { | ||
38 | + super(); | ||
39 | + this.partnerOrderId = ""; | ||
40 | + this.contactPerson = new ContactPerson(); | ||
41 | + this.visitPerson = new VisitPerson(); | ||
42 | + this.visitDate = ""; | ||
43 | + } | ||
44 | + | ||
45 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
46 | + @XmlType(name = "", propOrder = {"name", "mobile", "credentials", "credentialsType"}) | ||
47 | + @Data | ||
48 | + public static class ContactPerson { | ||
49 | + @XmlElement(required = true) | ||
50 | + protected String name; | ||
51 | + @XmlElement(required = true) | ||
52 | + protected String mobile; | ||
53 | + @XmlElement(required = true) | ||
54 | + protected String credentials; | ||
55 | + @XmlElement(required = true) | ||
56 | + protected String credentialsType; | ||
57 | + | ||
58 | + public ContactPerson() { | ||
59 | + super(); | ||
60 | + this.name = ""; | ||
61 | + this.mobile = ""; | ||
62 | + this.credentials = ""; | ||
63 | + this.credentialsType = ""; | ||
64 | + } | ||
65 | + } | ||
66 | + | ||
67 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
68 | + @XmlType(name = "", propOrder = {"person"}) | ||
69 | + @Data | ||
70 | + public static class VisitPerson { | ||
71 | + protected List<Person> person; | ||
72 | + | ||
73 | + public VisitPerson() { | ||
74 | + super(); | ||
75 | + this.person = new ArrayList<Person>(); | ||
76 | + } | ||
77 | + | ||
78 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
79 | + @XmlType(name = "", propOrder = {"name", "credentials", "credentialsType"}) | ||
80 | + @Data | ||
81 | + public static class Person { | ||
82 | + @XmlElement(required = true) | ||
83 | + protected String name; | ||
84 | + @XmlElement(required = true) | ||
85 | + protected String credentials; | ||
86 | + @XmlElement(required = true) | ||
87 | + protected String credentialsType; | ||
88 | + | ||
89 | + public Person() { | ||
90 | + super(); | ||
91 | + this.name = ""; | ||
92 | + this.credentials = ""; | ||
93 | + this.credentialsType = ""; | ||
94 | + } | ||
95 | + } | ||
96 | + } | ||
97 | + } | ||
98 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/QueryOtaOrderRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/QueryOtaOrderRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "queryOtaOrderRequestBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class QueryOtaOrderRequestBody extends RequestBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected OrderInfo orderInfo; | ||
16 | + | ||
17 | + public QueryOtaOrderRequestBody() { | ||
18 | + super(); | ||
19 | + this.orderInfo=new OrderInfo(); | ||
20 | + } | ||
21 | + | ||
22 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
23 | + @XmlType(name = "", propOrder = {"orderId"}) | ||
24 | + @Data | ||
25 | + public static class OrderInfo { | ||
26 | + @XmlElement(required = true) | ||
27 | + protected String orderId; | ||
28 | + | ||
29 | + public OrderInfo() { | ||
30 | + super(); | ||
31 | + this.orderId = ""; | ||
32 | + } | ||
33 | + } | ||
34 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/Request.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/Request.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.*; | ||
6 | + | ||
7 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
8 | +@XmlType(name = "", propOrder = {"header", "body"}) | ||
9 | +@XmlRootElement(name = "request") | ||
10 | +@Data | ||
11 | +public class Request { | ||
12 | + @XmlElement(required = true) | ||
13 | + protected RequestHeader header; | ||
14 | + @XmlElement(required = true) | ||
15 | + protected RequestBody body; | ||
16 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/RequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/RequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlType; | ||
8 | + | ||
9 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
10 | +@XmlType(name = "RequestBody") | ||
11 | +@Data | ||
12 | +public class RequestBody { | ||
13 | + | ||
14 | + | ||
15 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/RequestHeader.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/RequestHeader.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "RequestHeader", propOrder = {"application", "processor", "version", "bodyType", "createUser", "createTime", "supplierIdentity"}) | ||
12 | +@Data | ||
13 | +public class RequestHeader { | ||
14 | + @XmlElement(required = true, defaultValue = "tour.ectrip.com") | ||
15 | + protected String application; | ||
16 | + @XmlElement(required = true, defaultValue = "DataExchangeProcessor") | ||
17 | + protected String processor; | ||
18 | + @XmlElement(required = true) | ||
19 | + protected String version; | ||
20 | + @XmlElement(required = true) | ||
21 | + protected String bodyType; | ||
22 | + @XmlElement(required = true) | ||
23 | + protected String createUser; | ||
24 | + @XmlElement(required = true) | ||
25 | + protected String createTime; | ||
26 | + @XmlElement(required = true) | ||
27 | + protected String supplierIdentity; | ||
28 | + | ||
29 | + public RequestHeader() { | ||
30 | + super(); | ||
31 | + this.application = ""; | ||
32 | + this.processor = ""; | ||
33 | + this.version = ""; | ||
34 | + this.bodyType = ""; | ||
35 | + this.createUser = ""; | ||
36 | + this.createTime = ""; | ||
37 | + this.supplierIdentity = ""; | ||
38 | + } | ||
39 | + | ||
40 | + public RequestHeader(String application, String processor, String version, String bodyType, String createUser, String createTime, String supplierIdentity) { | ||
41 | + super(); | ||
42 | + this.application = application; | ||
43 | + this.processor = processor; | ||
44 | + this.version = version; | ||
45 | + this.bodyType = bodyType; | ||
46 | + this.createUser = createUser; | ||
47 | + this.createTime = createTime; | ||
48 | + this.supplierIdentity = supplierIdentity; | ||
49 | + } | ||
50 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/SendOrderEticketRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/SendOrderEticketRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "SendOrderEticketRequestBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class SendOrderEticketRequestBody extends RequestBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected OrderInfo orderInfo; | ||
16 | + | ||
17 | + public SendOrderEticketRequestBody() { | ||
18 | + super(); | ||
19 | + this.orderInfo = new OrderInfo(); | ||
20 | + } | ||
21 | + | ||
22 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
23 | + @XmlType(name = "", propOrder = {"partnerOrderId", "phoneNumber"}) | ||
24 | + @Data | ||
25 | + public static class OrderInfo { | ||
26 | + @XmlElement(required = true) | ||
27 | + protected String partnerOrderId; | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String phoneNumber; | ||
30 | + | ||
31 | + public OrderInfo() { | ||
32 | + super(); | ||
33 | + this.partnerOrderId = ""; | ||
34 | + this.phoneNumber = ""; | ||
35 | + } | ||
36 | + } | ||
37 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/VerifyConsumeRequestBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/request/VerifyConsumeRequestBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.request; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "VerifyConsumeRequestBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class VerifyConsumeRequestBody extends RequestBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected OrderInfo orderInfo; | ||
16 | + | ||
17 | + public VerifyConsumeRequestBody() { | ||
18 | + super(); | ||
19 | + this.orderInfo = new OrderInfo(); | ||
20 | + } | ||
21 | + | ||
22 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
23 | + @XmlType(name = "", propOrder = {"otaOrderId", "cytOrderId", "orderQuantity", "token", "posid", "verifyConsumeInfo"}) | ||
24 | + @Data | ||
25 | + public static class OrderInfo { | ||
26 | + @XmlElement(required = true) | ||
27 | + protected String otaOrderId; | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String cytOrderId; | ||
30 | + @XmlElement(required = true) | ||
31 | + protected String orderQuantity; | ||
32 | + @XmlElement(required = true) | ||
33 | + protected String token; | ||
34 | + @XmlElement(required = true) | ||
35 | + protected String posid; | ||
36 | + @XmlElement(required = true) | ||
37 | + protected String verifyConsumeInfo; | ||
38 | + | ||
39 | + public OrderInfo() { | ||
40 | + super(); | ||
41 | + this.otaOrderId = ""; | ||
42 | + this.cytOrderId = ""; | ||
43 | + this.orderQuantity = ""; | ||
44 | + this.token = ""; | ||
45 | + this.posid = ""; | ||
46 | + this.verifyConsumeInfo = ""; | ||
47 | + } | ||
48 | + } | ||
49 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/ApplyOrderRefundByUserResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/ApplyOrderRefundByUserResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "ApplyOrderRefundByUserResponseBody", propOrder = {"message"}) | ||
12 | +@Data | ||
13 | +public class ApplyOrderRefundByUserResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String message; | ||
16 | + | ||
17 | + public ApplyOrderRefundByUserResponseBody() { | ||
18 | + super(); | ||
19 | + this.message = ""; | ||
20 | + } | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/CancelOrderResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/CancelOrderResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "CancelOrderResponseBody", propOrder = {"message"}) | ||
12 | +@Data | ||
13 | +public class CancelOrderResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String message; | ||
16 | + | ||
17 | + public CancelOrderResponseBody(){ | ||
18 | + super(); | ||
19 | + this.message = ""; | ||
20 | + } | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/CheckOrderResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/CheckOrderResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "CheckOrderResponseBody", propOrder = {"message"}) | ||
12 | +@Data | ||
13 | +public class CheckOrderResponseBody extends ResponseBody { | ||
14 | + | ||
15 | + @XmlElement(required = true) | ||
16 | + protected String message; | ||
17 | + | ||
18 | + public CheckOrderResponseBody() { | ||
19 | + super(); | ||
20 | + this.message = ""; | ||
21 | + } | ||
22 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/CreateOrderResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/CreateOrderResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "CreateOrderResponseBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class CreateOrderResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected OrderInfo orderInfo; | ||
16 | + | ||
17 | + public CreateOrderResponseBody() { | ||
18 | + super(); | ||
19 | + this.orderInfo = new OrderInfo(); | ||
20 | + } | ||
21 | + | ||
22 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
23 | + @XmlType(name = "", propOrder = {"partnerorderId","partnerOrderId","otaOrderId","orderStatus","qrCodeStr","qrCodeUrl","onlyQrCodeUrl","verifyCode"}) | ||
24 | + @Data | ||
25 | + public static class OrderInfo { | ||
26 | + @XmlElement(required = true) | ||
27 | + protected String partnerorderId; | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String partnerOrderId; | ||
30 | + @XmlElement(required = true) | ||
31 | + protected String otaOrderId; | ||
32 | + @XmlElement(required = true) | ||
33 | + protected String orderStatus; | ||
34 | + @XmlElement(required = false) | ||
35 | + protected String qrCodeStr; | ||
36 | + @XmlElement(required = false) | ||
37 | + protected String qrCodeUrl; | ||
38 | + @XmlElement(required = false) | ||
39 | + protected String onlyQrCodeUrl; | ||
40 | + @XmlElement(required = false) | ||
41 | + protected String verifyCode; | ||
42 | + | ||
43 | + public OrderInfo() { | ||
44 | + super(); | ||
45 | + this.partnerOrderId = ""; | ||
46 | + this.otaOrderId=""; | ||
47 | + this.partnerorderId = ""; | ||
48 | + this.orderStatus = ""; | ||
49 | + this.qrCodeUrl=""; | ||
50 | + this.onlyQrCodeUrl=""; | ||
51 | + this.qrCodeStr=""; | ||
52 | + this.verifyCode = ""; | ||
53 | + } | ||
54 | + } | ||
55 | + | ||
56 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/CreatePaymentOrderResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/CreatePaymentOrderResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "CreatePaymentOrderResponseBody", propOrder = {"orderInfo"}) | ||
14 | +@Data | ||
15 | +public class CreatePaymentOrderResponseBody extends ResponseBody { | ||
16 | + @XmlElement(required = true) | ||
17 | + protected OrderInfo orderInfo; | ||
18 | + | ||
19 | + public CreatePaymentOrderResponseBody() { | ||
20 | + super(); | ||
21 | + this.orderInfo = new OrderInfo(); | ||
22 | + } | ||
23 | + | ||
24 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
25 | + @XmlType(name = "", propOrder = {"partnerorderId","otaorderId", "orderStatus", "qrCodeStr", "qrCodeUrl","onlyQrCodeUrl", "verifyCode", "vouchers"}) | ||
26 | + @Data | ||
27 | + public static class OrderInfo { | ||
28 | + @XmlElement(required = false) | ||
29 | + protected String partnerorderId; | ||
30 | + @XmlElement(required = false) | ||
31 | + protected String otaorderId; | ||
32 | + @XmlElement(required = true) | ||
33 | + protected String orderStatus; | ||
34 | + @XmlElement(required = false) | ||
35 | + protected String qrCodeStr; | ||
36 | + @XmlElement(required = false) | ||
37 | + protected String qrCodeUrl; | ||
38 | + @XmlElement(required = false) | ||
39 | + protected String onlyQrCodeUrl; | ||
40 | + @XmlElement(required = false) | ||
41 | + protected String verifyCode; | ||
42 | + @XmlElement(required = false) | ||
43 | + protected Vouchers vouchers; | ||
44 | + | ||
45 | + public OrderInfo() { | ||
46 | + super(); | ||
47 | + this.partnerorderId = ""; | ||
48 | + this.otaorderId = ""; | ||
49 | + this.orderStatus = ""; | ||
50 | + this.qrCodeStr = ""; | ||
51 | + this.qrCodeUrl = ""; | ||
52 | + this.onlyQrCodeUrl=""; | ||
53 | + this.verifyCode = ""; | ||
54 | + this.vouchers = new Vouchers(); | ||
55 | + } | ||
56 | + | ||
57 | + | ||
58 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
59 | + @XmlType(name = "", propOrder = {"voucher"}) | ||
60 | + @Data | ||
61 | + public static class Vouchers{ | ||
62 | + @XmlElement(required = false) | ||
63 | + protected List<Voucher> voucher; | ||
64 | + | ||
65 | + public Vouchers(){ | ||
66 | + super(); | ||
67 | + this.voucher = new ArrayList<Voucher>(); | ||
68 | + } | ||
69 | + | ||
70 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
71 | + @XmlType(name = "", propOrder = {"voucherCard", "voucherCode", "voucherCodeUrl"}) | ||
72 | + @Data | ||
73 | + public static class Voucher{ | ||
74 | + @XmlElement(required = false) | ||
75 | + protected String voucherCard; | ||
76 | + @XmlElement(required = false) | ||
77 | + protected String voucherCode; | ||
78 | + @XmlElement(required = false) | ||
79 | + protected String voucherCodeUrl; | ||
80 | + | ||
81 | + public Voucher(){ | ||
82 | + super(); | ||
83 | + this.voucherCard = ""; | ||
84 | + this.voucherCode = ""; | ||
85 | + this.voucherCodeUrl = ""; | ||
86 | + } | ||
87 | + } | ||
88 | + } | ||
89 | + } | ||
90 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetAvailableProductResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetAvailableProductResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | + | ||
13 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
14 | +@XmlType(name = "GetProductByOTAResponseBody", propOrder = {"pois"}) | ||
15 | +@Data | ||
16 | +public class GetAvailableProductResponseBody extends ResponseBody { | ||
17 | + @XmlElement(required = true) | ||
18 | + protected Pois pois; | ||
19 | + | ||
20 | + public GetAvailableProductResponseBody() { | ||
21 | + super(); | ||
22 | + this.pois = new Pois(); | ||
23 | + } | ||
24 | + | ||
25 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
26 | + @XmlType(name = "", propOrder = {"poi"}) | ||
27 | + @Data | ||
28 | + public static class Pois { | ||
29 | + protected List<Poi> poi; | ||
30 | + | ||
31 | + public Pois(){ | ||
32 | + this.poi=new ArrayList<>(); | ||
33 | + } | ||
34 | + | ||
35 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
36 | + @XmlType(name = "", propOrder = {"poiId","poiName","poiDescription","poiLevel","poiMobile","addressProvince","addressCity","addressDistrict","poiAddress","poiLongitudeAndlatitude","poiOpenTime","poiImages","products"}) | ||
37 | + @Data | ||
38 | + public static class Poi { | ||
39 | + protected String poiId; | ||
40 | + protected String poiName; | ||
41 | + protected String poiDescription; | ||
42 | + protected String poiLevel; | ||
43 | + protected String poiMobile; | ||
44 | + protected String addressProvince; | ||
45 | + protected String addressCity; | ||
46 | + protected String addressDistrict; | ||
47 | + protected String poiAddress; | ||
48 | + protected String poiLongitudeAndlatitude; | ||
49 | + protected String poiOpenTime; | ||
50 | + protected List<String> poiImages; | ||
51 | + protected Products products; | ||
52 | + | ||
53 | + public Poi(){ | ||
54 | + this.poiId = ""; | ||
55 | + this.poiName = ""; | ||
56 | + this.poiDescription = ""; | ||
57 | + this.poiLevel = ""; | ||
58 | + this.poiMobile = ""; | ||
59 | + this.addressProvince = ""; | ||
60 | + this.addressCity = ""; | ||
61 | + this.addressDistrict = ""; | ||
62 | + this.poiAddress = ""; | ||
63 | + this.poiLongitudeAndlatitude = ""; | ||
64 | + this.poiOpenTime = ""; | ||
65 | + this.poiImages=new ArrayList<>(); | ||
66 | + this.products=new Products(); | ||
67 | + } | ||
68 | + | ||
69 | + @Data | ||
70 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
71 | + @XmlType(name = "", propOrder = {"product"}) | ||
72 | + public static class Products { | ||
73 | + protected List<Product> product; | ||
74 | + | ||
75 | + public Products(){ | ||
76 | + this.product=new ArrayList<>(); | ||
77 | + } | ||
78 | + | ||
79 | + @Data | ||
80 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
81 | + @XmlType(name = "", propOrder = {"resourceId", "productName"}) | ||
82 | + public static class Product { | ||
83 | + protected String resourceId; | ||
84 | + protected String productName; | ||
85 | + | ||
86 | + public Product(){ | ||
87 | + this.resourceId = ""; | ||
88 | + this.productName = ""; | ||
89 | + } | ||
90 | + } | ||
91 | + } | ||
92 | + | ||
93 | + } | ||
94 | + } | ||
95 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetBalanceResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetBalanceResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlType; | ||
8 | +import java.util.ArrayList; | ||
9 | +import java.util.List; | ||
10 | + | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "GetBalanceResponseBody", propOrder = {"supplierBalances"}) | ||
14 | +@Data | ||
15 | +public class GetBalanceResponseBody extends ResponseBody { | ||
16 | + protected SupplierBalances supplierBalances; | ||
17 | + | ||
18 | + public GetBalanceResponseBody() { | ||
19 | + super(); | ||
20 | + this.supplierBalances = new SupplierBalances(); | ||
21 | + } | ||
22 | + | ||
23 | + @Data | ||
24 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
25 | + @XmlType(name = "",propOrder = {"supplierBalance"}) | ||
26 | + public static class SupplierBalances { | ||
27 | + protected List<SupplierBalance> supplierBalance; | ||
28 | + | ||
29 | + public SupplierBalances(){ | ||
30 | + this.supplierBalance=new ArrayList<>(); | ||
31 | + } | ||
32 | + | ||
33 | + @Data | ||
34 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
35 | + @XmlType(name = "",propOrder = {"name","supplierIdentity","fundType","balance"}) | ||
36 | + public static class SupplierBalance { | ||
37 | + protected String name; | ||
38 | + protected String supplierIdentity; | ||
39 | + protected String fundType; | ||
40 | + protected String balance; | ||
41 | + | ||
42 | + public SupplierBalance() { | ||
43 | + this.name = ""; | ||
44 | + this.supplierIdentity = ""; | ||
45 | + this.fundType = ""; | ||
46 | + this.balance = ""; | ||
47 | + } | ||
48 | + } | ||
49 | + } | ||
50 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetOrderByOTAResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetOrderByOTAResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "GetOrderByOTAResponseBody", propOrder = {"orderInfo"}) | ||
14 | +@Data | ||
15 | +public class GetOrderByOTAResponseBody extends ResponseBody { | ||
16 | + @XmlElement(required = true) | ||
17 | + protected OrderInfo orderInfo; | ||
18 | + | ||
19 | + public GetOrderByOTAResponseBody() { | ||
20 | + super(); | ||
21 | + this.orderInfo = new OrderInfo(); | ||
22 | + } | ||
23 | + | ||
24 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
25 | + @XmlType(name = "", propOrder = {"partnerorderId","partnerOrderId","otaOrderId", "orderStatus","orderMsg","totalQuantity", "orderQuantity", "eticketNo", "eticketSended", "useQuantity","refundQuantity", "consumeInfo", "vouchers","qrCodeStr","qrCodeUrl","onlyQrCodeUrl","otherQRCode"}) | ||
26 | + @Data | ||
27 | + public static class OrderInfo { | ||
28 | + public String getPartnerorderId() { | ||
29 | + return partnerorderId; | ||
30 | + } | ||
31 | + | ||
32 | + public void setPartnerorderId(String partnerorderId) { | ||
33 | + this.partnerorderId = partnerorderId; | ||
34 | + } | ||
35 | + | ||
36 | + public String getPartnerOrderId() { | ||
37 | + return partnerOrderId; | ||
38 | + } | ||
39 | + | ||
40 | + public void setPartnerOrderId(String partnerOrderId) { | ||
41 | + this.partnerOrderId = partnerOrderId; | ||
42 | + } | ||
43 | + | ||
44 | + @XmlElement(required = true) | ||
45 | + protected String partnerorderId; | ||
46 | + @XmlElement(required = true) | ||
47 | + protected String partnerOrderId; | ||
48 | + @XmlElement(required = true) | ||
49 | + protected String otaOrderId; | ||
50 | + @XmlElement(required = true) | ||
51 | + protected String orderStatus; | ||
52 | + @XmlElement(required = true) | ||
53 | + protected String orderMsg; | ||
54 | + @XmlElement(required = true) | ||
55 | + protected String totalQuantity; | ||
56 | + @XmlElement(required = true) | ||
57 | + protected String orderQuantity; | ||
58 | + @XmlElement(required = true) | ||
59 | + protected String eticketNo; | ||
60 | + @XmlElement(required = true) | ||
61 | + protected String eticketSended; | ||
62 | + @XmlElement(required = true) | ||
63 | + protected String useQuantity; | ||
64 | + @XmlElement(required = true) | ||
65 | + protected String refundQuantity; | ||
66 | + @XmlElement(required = true) | ||
67 | + protected String consumeInfo; | ||
68 | + @XmlElement(required = false) | ||
69 | + protected Vouchers vouchers; | ||
70 | + @XmlElement(required = false) | ||
71 | + protected String qrCodeStr; | ||
72 | + @XmlElement(required = false) | ||
73 | + protected String qrCodeUrl; | ||
74 | + @XmlElement(required = false) | ||
75 | + protected String onlyQrCodeUrl; | ||
76 | + @XmlElement(required = false) | ||
77 | + protected String otherQRCode;//第三方取票码 | ||
78 | + | ||
79 | + public OrderInfo() { | ||
80 | + super(); | ||
81 | + this.partnerorderId = ""; | ||
82 | + this.partnerOrderId = ""; | ||
83 | + this.otaOrderId = ""; | ||
84 | + this.orderStatus = ""; | ||
85 | + this.orderMsg = ""; | ||
86 | + this.totalQuantity=""; | ||
87 | + this.orderQuantity = ""; | ||
88 | + this.eticketNo = ""; | ||
89 | + this.eticketSended = ""; | ||
90 | + this.useQuantity = ""; | ||
91 | + this.refundQuantity=""; | ||
92 | + this.consumeInfo = ""; | ||
93 | + this.qrCodeStr = ""; | ||
94 | + this.qrCodeUrl = ""; | ||
95 | + this.onlyQrCodeUrl=""; | ||
96 | + this.otherQRCode = ""; | ||
97 | + this.vouchers= new Vouchers(); | ||
98 | + } | ||
99 | + | ||
100 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
101 | + @XmlType(name = "", propOrder = {"voucher"}) | ||
102 | + @Data | ||
103 | + public static class Vouchers{ | ||
104 | + @XmlElement(required = false) | ||
105 | + protected List<Voucher> voucher; | ||
106 | + | ||
107 | + public Vouchers(){ | ||
108 | + super(); | ||
109 | + this.voucher = new ArrayList<Voucher>(); | ||
110 | + } | ||
111 | + | ||
112 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
113 | + @XmlType(name = "", propOrder = {"voucherCard", "voucherCode", "voucherCodeUrl"}) | ||
114 | + @Data | ||
115 | + public static class Voucher{ | ||
116 | + @XmlElement(required = false) | ||
117 | + protected String voucherCard; | ||
118 | + @XmlElement(required = false) | ||
119 | + protected String voucherCode; | ||
120 | + @XmlElement(required = false) | ||
121 | + protected String voucherCodeUrl; | ||
122 | + | ||
123 | + public Voucher(){ | ||
124 | + super(); | ||
125 | + this.voucherCard = ""; | ||
126 | + this.voucherCode = ""; | ||
127 | + this.voucherCodeUrl = ""; | ||
128 | + } | ||
129 | + } | ||
130 | + } | ||
131 | + } | ||
132 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "GetProductByOTAResponseBody", propOrder = {"count", "productInfos"}) | ||
14 | +@Data | ||
15 | +public class GetProductByOTAResponseBody extends ResponseBody { | ||
16 | + @XmlElement(required = true) | ||
17 | + protected String count; | ||
18 | + @XmlElement(required = true) | ||
19 | + protected ProductInfos productInfos; | ||
20 | + | ||
21 | + public GetProductByOTAResponseBody() { | ||
22 | + super(); | ||
23 | + this.count = ""; | ||
24 | + this.productInfos = new ProductInfos(); | ||
25 | + } | ||
26 | + | ||
27 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
28 | + @XmlType(name = "", propOrder = {"productInfo"}) | ||
29 | + @Data | ||
30 | + public static class ProductInfos { | ||
31 | + protected List<ProductInfo> productInfo; | ||
32 | + | ||
33 | + public ProductInfos() { | ||
34 | + super(); | ||
35 | + this.productInfo = new ArrayList<ProductInfo>(); | ||
36 | + } | ||
37 | + | ||
38 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
39 | + @XmlType(name = "", propOrder = {"timeOfBooks", "baseInfo", "bookConfig", "priceConfig", "productDescription", "otherConfig"}) | ||
40 | + @Data | ||
41 | + public static class ProductInfo { | ||
42 | + @XmlElement(required = true) | ||
43 | + protected TimeOfBooks timeOfBooks; | ||
44 | + @XmlElement(required = true) | ||
45 | + protected BaseInfo baseInfo; | ||
46 | + @XmlElement(required = true) | ||
47 | + protected BookConfig bookConfig; | ||
48 | + @XmlElement(required = true) | ||
49 | + protected PriceConfig priceConfig; | ||
50 | + @XmlElement(required = true) | ||
51 | + protected ProductDescription productDescription; | ||
52 | + @XmlElement(required = true) | ||
53 | + protected OtherConfig otherConfig; | ||
54 | + | ||
55 | + public ProductInfo() { | ||
56 | + super(); | ||
57 | + this.baseInfo = new BaseInfo(); | ||
58 | + this.timeOfBooks = new TimeOfBooks(); | ||
59 | + this.bookConfig = new BookConfig(); | ||
60 | + this.priceConfig = new PriceConfig(); | ||
61 | + this.productDescription = new ProductDescription(); | ||
62 | + this.otherConfig = new OtherConfig(); | ||
63 | + } | ||
64 | + | ||
65 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
66 | + @XmlType(name = "", propOrder = {"timeOfBook"}) | ||
67 | + @Data | ||
68 | + public static class TimeOfBooks { | ||
69 | + @XmlElement(required = true) | ||
70 | + protected List<TimeOfBook> timeOfBook; | ||
71 | + | ||
72 | + public TimeOfBooks() { | ||
73 | + super(); | ||
74 | + this.timeOfBook = new ArrayList<TimeOfBook>(); | ||
75 | + } | ||
76 | + | ||
77 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
78 | + @XmlType(name = "", propOrder = {"id", "startTime", "endTime", "price", "stock"}) | ||
79 | + @Data | ||
80 | + public static class TimeOfBook { | ||
81 | + @XmlElement(required = true) | ||
82 | + protected String id; | ||
83 | + @XmlElement(required = true) | ||
84 | + protected String startTime; | ||
85 | + @XmlElement(required = true) | ||
86 | + protected String endTime; | ||
87 | + @XmlElement(required = true) | ||
88 | + protected String price; | ||
89 | + @XmlElement(required = true) | ||
90 | + protected String stock; | ||
91 | + | ||
92 | + public TimeOfBook() { | ||
93 | + super(); | ||
94 | + this.id = ""; | ||
95 | + this.startTime = ""; | ||
96 | + this.endTime = ""; | ||
97 | + this.price = ""; | ||
98 | + this.stock = ""; | ||
99 | + } | ||
100 | + } | ||
101 | + } | ||
102 | + | ||
103 | + | ||
104 | + | ||
105 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
106 | + @XmlType(name = "", propOrder = {"resourceId", "productType", "sights", "productName"}) | ||
107 | + @Data | ||
108 | + public static class BaseInfo { | ||
109 | + @XmlElement(required = true) | ||
110 | + protected String resourceId; | ||
111 | + @XmlElement(required = true) | ||
112 | + protected String productType; | ||
113 | + @XmlElement(required = true) | ||
114 | + protected Sights sights; | ||
115 | + @XmlElement(required = true) | ||
116 | + protected String productName; | ||
117 | + | ||
118 | + public BaseInfo() { | ||
119 | + super(); | ||
120 | + this.resourceId = ""; | ||
121 | + this.productType = ""; | ||
122 | + this.sights = new Sights(); | ||
123 | + this.productName = ""; | ||
124 | + } | ||
125 | + | ||
126 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
127 | + @XmlType(name = "", propOrder = {"sight"}) | ||
128 | + @Data | ||
129 | + public static class Sights { | ||
130 | + @XmlElement(required = true) | ||
131 | + protected List<Sight> sight; | ||
132 | + | ||
133 | + public Sights() { | ||
134 | + super(); | ||
135 | + this.sight = new ArrayList<Sight>(); | ||
136 | + } | ||
137 | + | ||
138 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
139 | + @XmlType(name = "", propOrder = {"sightName", "city"}) | ||
140 | + @Data | ||
141 | + public static class Sight { | ||
142 | + @XmlElement(required = true) | ||
143 | + protected String sightName; | ||
144 | + @XmlElement(required = true) | ||
145 | + protected String city; | ||
146 | + | ||
147 | + public Sight() { | ||
148 | + super(); | ||
149 | + this.sightName = ""; | ||
150 | + this.city = ""; | ||
151 | + } | ||
152 | + } | ||
153 | + } | ||
154 | + } | ||
155 | + | ||
156 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
157 | + @XmlType(name = "", propOrder = {"paymentType", "advanceOption", "autoCancelTime", "bookPersonType", "visitPersonRequiredForQuantity"}) | ||
158 | + @Data | ||
159 | + public static class BookConfig { | ||
160 | + @XmlElement(required = true) | ||
161 | + protected String paymentType; | ||
162 | + @XmlElement(required = true) | ||
163 | + protected AdvanceOption advanceOption; | ||
164 | + @XmlElement(required = true) | ||
165 | + protected String autoCancelTime; | ||
166 | + @XmlElement(required = true) | ||
167 | + protected String bookPersonType; | ||
168 | + @XmlElement(required = true) | ||
169 | + protected String visitPersonRequiredForQuantity; | ||
170 | + | ||
171 | + public BookConfig() { | ||
172 | + super(); | ||
173 | + this.paymentType = ""; | ||
174 | + this.advanceOption = new AdvanceOption(); | ||
175 | + this.autoCancelTime = ""; | ||
176 | + this.bookPersonType = ""; | ||
177 | + this.visitPersonRequiredForQuantity = ""; | ||
178 | + } | ||
179 | + | ||
180 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
181 | + @XmlType(name = "", propOrder = {"bookAdvanceDay", "bookAdvanceTime", "useAdvanceHour"}) | ||
182 | + @Data | ||
183 | + public static class AdvanceOption { | ||
184 | + @XmlElement(required = true, defaultValue = "0") | ||
185 | + protected String bookAdvanceDay; | ||
186 | + @XmlElement(required = true) | ||
187 | + protected String bookAdvanceTime; | ||
188 | + @XmlElement(required = true) | ||
189 | + protected String useAdvanceHour; | ||
190 | + | ||
191 | + public AdvanceOption() { | ||
192 | + super(); | ||
193 | + this.bookAdvanceDay = ""; | ||
194 | + this.bookAdvanceTime = ""; | ||
195 | + this.useAdvanceHour = ""; | ||
196 | + } | ||
197 | + } | ||
198 | + } | ||
199 | + | ||
200 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
201 | + @XmlType(name = "", propOrder = {"smsTemplet", "eticketType"}) | ||
202 | + @Data | ||
203 | + public static class OtherConfig { | ||
204 | + @XmlElement(required = true) | ||
205 | + protected String smsTemplet; | ||
206 | + @XmlElement(required = true) | ||
207 | + protected String eticketType; | ||
208 | + | ||
209 | + public OtherConfig() { | ||
210 | + super(); | ||
211 | + this.smsTemplet = ""; | ||
212 | + this.eticketType = ""; | ||
213 | + } | ||
214 | + } | ||
215 | + | ||
216 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
217 | + @XmlType(name = "", propOrder = {"validType", "daysAfterUseDateValid", "calendarPrices"}) | ||
218 | + @Data | ||
219 | + public static class PriceConfig { | ||
220 | + @XmlElement(required = true) | ||
221 | + protected String validType; | ||
222 | + @XmlElement(required = true) | ||
223 | + protected String daysAfterUseDateValid; | ||
224 | + @XmlElement(required = true) | ||
225 | + protected CalendarPrices calendarPrices; | ||
226 | + | ||
227 | + public PriceConfig() { | ||
228 | + super(); | ||
229 | + this.validType = ""; | ||
230 | + this.daysAfterUseDateValid = ""; | ||
231 | + this.calendarPrices = new CalendarPrices(); | ||
232 | + } | ||
233 | + | ||
234 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
235 | + @XmlType(name = "", propOrder = {"calendarPrice"}) | ||
236 | + @Data | ||
237 | + public static class CalendarPrices { | ||
238 | + @XmlElement(required = true) | ||
239 | + protected List<CalendarPrice> calendarPrice; | ||
240 | + | ||
241 | + public CalendarPrices() { | ||
242 | + super(); | ||
243 | + this.calendarPrice = new ArrayList<CalendarPrice>(); | ||
244 | + } | ||
245 | + | ||
246 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
247 | + @XmlType(name = "", propOrder = {"useDate", "marketPrice", "sellPrice", "sellstock"}) | ||
248 | + @Data | ||
249 | + public static class CalendarPrice { | ||
250 | + @XmlElement(required = true) | ||
251 | + protected String useDate; | ||
252 | + @XmlElement(required = true) | ||
253 | + protected String marketPrice; | ||
254 | + @XmlElement(required = true) | ||
255 | + protected String sellPrice; | ||
256 | + @XmlElement(required = true) | ||
257 | + protected String sellstock; | ||
258 | + | ||
259 | + public CalendarPrice() { | ||
260 | + super(); | ||
261 | + this.useDate = ""; | ||
262 | + this.marketPrice = ""; | ||
263 | + this.sellPrice = ""; | ||
264 | + this.sellstock = ""; | ||
265 | + } | ||
266 | + } | ||
267 | + } | ||
268 | + } | ||
269 | + | ||
270 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
271 | + @XmlType(name = "", propOrder = {"remind", "refundOption"}) | ||
272 | + @Data | ||
273 | + public static class ProductDescription { | ||
274 | + @XmlElement(required = true) | ||
275 | + protected String remind; | ||
276 | + @XmlElement(required = true) | ||
277 | + protected RefundOption refundOption; | ||
278 | + | ||
279 | + public ProductDescription() { | ||
280 | + super(); | ||
281 | + this.remind = ""; | ||
282 | + this.refundOption = new RefundOption(); | ||
283 | + } | ||
284 | + | ||
285 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
286 | + @XmlType(name = "", propOrder = {"canRefund","canOverdueRefund", "refundApplyTimeBeforeValidEndDay", "refundCharge", "refundChargeType", "refundInfo"}) | ||
287 | + @Data | ||
288 | + public static class RefundOption { | ||
289 | + @XmlElement(required = true) | ||
290 | + protected String canRefund; | ||
291 | + @XmlElement(required = true) | ||
292 | + protected String canOverdueRefund; | ||
293 | + @XmlElement(required = true) | ||
294 | + protected String refundApplyTimeBeforeValidEndDay; | ||
295 | + @XmlElement(required = true) | ||
296 | + protected String refundCharge; | ||
297 | + @XmlElement(required = true) | ||
298 | + protected String refundChargeType; | ||
299 | + @XmlElement(required = true) | ||
300 | + protected String refundInfo; | ||
301 | + | ||
302 | + public RefundOption() { | ||
303 | + super(); | ||
304 | + this.canRefund = ""; | ||
305 | + this.canOverdueRefund = ""; | ||
306 | + this.refundApplyTimeBeforeValidEndDay = ""; | ||
307 | + this.refundCharge = ""; | ||
308 | + this.refundChargeType = ""; | ||
309 | + this.refundInfo = ""; | ||
310 | + } | ||
311 | + } | ||
312 | + } | ||
313 | + } | ||
314 | + } | ||
315 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetStockProductInfoResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetStockProductInfoResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | + | ||
13 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
14 | +@XmlType(name = "GetStockProductInfoResponseBody", propOrder = {"resourceId", "timeOfBooks", "stockInfos"}) | ||
15 | +@Data | ||
16 | +public class GetStockProductInfoResponseBody extends ResponseBody { | ||
17 | + @XmlElement(required = true) | ||
18 | + protected String resourceId; | ||
19 | + @XmlElement(required = true) | ||
20 | + protected TimeOfBooks timeOfBooks; | ||
21 | + @XmlElement(required = true) | ||
22 | + protected StockInfos stockInfos; | ||
23 | + | ||
24 | + public GetStockProductInfoResponseBody() { | ||
25 | + super(); | ||
26 | + this.resourceId = ""; | ||
27 | + this.stockInfos = new StockInfos(); | ||
28 | + this.timeOfBooks = new TimeOfBooks(); | ||
29 | + } | ||
30 | + | ||
31 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
32 | + @XmlType(name = "", propOrder = {"timeOfBook"}) | ||
33 | + @Data | ||
34 | + public static class TimeOfBooks { | ||
35 | + @XmlElement(required = true) | ||
36 | + protected List<TimeOfBook> timeOfBook; | ||
37 | + | ||
38 | + public TimeOfBooks() { | ||
39 | + super(); | ||
40 | + this.timeOfBook = new ArrayList<TimeOfBook>(); | ||
41 | + } | ||
42 | + | ||
43 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
44 | + @XmlType(name = "", propOrder = {"id", "title", "date", "startTime", "endTime", "remainingNumb"}) | ||
45 | + @Data | ||
46 | + public static class TimeOfBook { | ||
47 | + @XmlElement(required = true) | ||
48 | + protected String id; | ||
49 | + @XmlElement(required = true) | ||
50 | + protected String title; | ||
51 | + @XmlElement(required = true) | ||
52 | + protected String date; | ||
53 | + @XmlElement(required = true) | ||
54 | + protected String startTime; | ||
55 | + @XmlElement(required = true) | ||
56 | + protected String endTime; | ||
57 | + @XmlElement(required = true) | ||
58 | + protected String remainingNumb; | ||
59 | + | ||
60 | + public TimeOfBook() { | ||
61 | + super(); | ||
62 | + this.id = ""; | ||
63 | + this.title = ""; | ||
64 | + this.date = ""; | ||
65 | + this.startTime = ""; | ||
66 | + this.endTime = ""; | ||
67 | + this.remainingNumb = ""; | ||
68 | + } | ||
69 | + } | ||
70 | + } | ||
71 | + | ||
72 | + | ||
73 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
74 | + @XmlType(name = "", propOrder = {"stockInfo"}) | ||
75 | + @Data | ||
76 | + public static class StockInfos { | ||
77 | + @XmlElement(required = true) | ||
78 | + protected List<StockInfo> stockInfo; | ||
79 | + | ||
80 | + public StockInfos() { | ||
81 | + this.stockInfo = new ArrayList<>(); | ||
82 | + } | ||
83 | + | ||
84 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
85 | + @XmlType(name = "", propOrder = {"date", "channelStock", "commonStock", "productSaleStock"}) | ||
86 | + @Data | ||
87 | + public static class StockInfo { | ||
88 | + @XmlElement(required = true) | ||
89 | + protected String date; | ||
90 | + @XmlElement(required = true) | ||
91 | + protected String channelStock; | ||
92 | + @XmlElement(required = true) | ||
93 | + protected String commonStock; | ||
94 | + @XmlElement(required = true) | ||
95 | + protected String productSaleStock; | ||
96 | + | ||
97 | + public StockInfo() { | ||
98 | + super(); | ||
99 | + this.date = ""; | ||
100 | + this.channelStock = ""; | ||
101 | + this.commonStock = ""; | ||
102 | + this.productSaleStock = ""; | ||
103 | + } | ||
104 | + } | ||
105 | + } | ||
106 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderConsumedResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderConsumedResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeOrderConsumedResponseBody", propOrder = {"message"}) | ||
12 | +@Data | ||
13 | +public class NoticeOrderConsumedResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String message; | ||
16 | + | ||
17 | + public NoticeOrderConsumedResponseBody() { | ||
18 | + super(); | ||
19 | + this.message = ""; | ||
20 | + } | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderEticketSendedResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderEticketSendedResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeOrderEticketSendedResponseBody", propOrder = {"message"}) | ||
12 | +@Data | ||
13 | +public class NoticeOrderEticketSendedResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String message; | ||
16 | + | ||
17 | + public NoticeOrderEticketSendedResponseBody() { | ||
18 | + super(); | ||
19 | + this.message = ""; | ||
20 | + } | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderPrintSuccessResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderPrintSuccessResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeOrderPrintSuccessResponseBody", propOrder = {"message"}) | ||
12 | +@Data | ||
13 | +public class NoticeOrderPrintSuccessResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String message; | ||
16 | + | ||
17 | + public NoticeOrderPrintSuccessResponseBody() { | ||
18 | + super(); | ||
19 | + this.message=""; | ||
20 | + } | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderRefundApproveResultResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderRefundApproveResultResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeOrderRefundApproveResultResponseBody", propOrder = {"message"}) | ||
12 | +@Data | ||
13 | +public class NoticeOrderRefundApproveResultResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String message; | ||
16 | + | ||
17 | + public NoticeOrderRefundApproveResultResponseBody() { | ||
18 | + super(); | ||
19 | + this.message = ""; | ||
20 | + } | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderRefundResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderRefundResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeOrderRefundResponseBody", propOrder = {"message"}) | ||
12 | +@Data | ||
13 | +public class NoticeOrderRefundResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String message; | ||
16 | + | ||
17 | + public NoticeOrderRefundResponseBody() { | ||
18 | + super(); | ||
19 | + this.message = ""; | ||
20 | + } | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderRefundedByOTAResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderRefundedByOTAResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeOrderRefundedByOTAResponseBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class NoticeOrderRefundedByOTAResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected OrderInfo orderInfo; | ||
16 | + | ||
17 | + public NoticeOrderRefundedByOTAResponseBody() { | ||
18 | + super(); | ||
19 | + this.orderInfo = new OrderInfo(); | ||
20 | + } | ||
21 | + | ||
22 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
23 | + @XmlType(name = "", propOrder = {"partnerorderId", "refundSeq", "refundResult", "refundQuantity", "orderRefundPrice", "orderRefundCharge"}) | ||
24 | + @Data | ||
25 | + public static class OrderInfo { | ||
26 | + @XmlElement(required = true) | ||
27 | + protected String partnerorderId; | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String refundSeq; | ||
30 | + @XmlElement(required = true) | ||
31 | + protected String refundResult; | ||
32 | + @XmlElement(required = true) | ||
33 | + protected String refundQuantity; | ||
34 | + @XmlElement(required = true) | ||
35 | + protected String orderRefundPrice; | ||
36 | + @XmlElement(required = true) | ||
37 | + protected String orderRefundCharge; | ||
38 | + | ||
39 | + public OrderInfo() { | ||
40 | + super(); | ||
41 | + this.partnerorderId = ""; | ||
42 | + this.refundSeq = ""; | ||
43 | + this.refundResult = ""; | ||
44 | + this.refundQuantity = ""; | ||
45 | + this.orderRefundPrice = ""; | ||
46 | + this.orderRefundCharge = ""; | ||
47 | + } | ||
48 | + } | ||
49 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeProductChangedResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeProductChangedResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeProductChangedResponseBody", propOrder = {"message"}) | ||
12 | +@Data | ||
13 | +public class NoticeProductChangedResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String message; | ||
16 | + | ||
17 | + public NoticeProductChangedResponseBody() { | ||
18 | + super(); | ||
19 | + this.message = ""; | ||
20 | + } | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/PayOrderResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/PayOrderResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | +import java.util.ArrayList; | ||
10 | +import java.util.List; | ||
11 | + | ||
12 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
13 | +@XmlType(name = "PayOrderResponseBody", propOrder = {"orderInfo"}) | ||
14 | +@Data | ||
15 | +public class PayOrderResponseBody extends ResponseBody { | ||
16 | + @XmlElement(required = true) | ||
17 | + protected OrderInfo orderInfo; | ||
18 | + | ||
19 | + public PayOrderResponseBody() { | ||
20 | + super(); | ||
21 | + this.orderInfo = new OrderInfo(); | ||
22 | + } | ||
23 | + | ||
24 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
25 | + @XmlType(name = "", propOrder = {"partnerorderId", "partnerOrderId", "otaOrderId", "orderStatus", "qrCodeStr", "qrCodeUrl","onlyQrCodeUrl", "verifyCode", "vouchers"}) | ||
26 | + @Data | ||
27 | + public static class OrderInfo { | ||
28 | + public String getPartnerorderId() { | ||
29 | + return partnerorderId; | ||
30 | + } | ||
31 | + | ||
32 | + public void setPartnerorderId(String partnerorderId) { | ||
33 | + this.partnerorderId = partnerorderId; | ||
34 | + } | ||
35 | + | ||
36 | + public String getPartnerOrderId() { | ||
37 | + return partnerOrderId; | ||
38 | + } | ||
39 | + | ||
40 | + public void setPartnerOrderId(String partnerOrderId) { | ||
41 | + this.partnerOrderId = partnerOrderId; | ||
42 | + } | ||
43 | + | ||
44 | + @XmlElement(required = true) | ||
45 | + protected String partnerorderId; | ||
46 | + @XmlElement(required = true) | ||
47 | + protected String partnerOrderId; | ||
48 | + @XmlElement(required = true) | ||
49 | + protected String otaOrderId; | ||
50 | + @XmlElement(required = true) | ||
51 | + protected String orderStatus; | ||
52 | + @XmlElement(required = false) | ||
53 | + protected String qrCodeStr; | ||
54 | + @XmlElement(required = false) | ||
55 | + protected String qrCodeUrl; | ||
56 | + @XmlElement(required = false) | ||
57 | + protected String onlyQrCodeUrl; | ||
58 | + @XmlElement(required = false) | ||
59 | + protected String verifyCode; | ||
60 | + @XmlElement(required = false) | ||
61 | + protected Vouchers vouchers; | ||
62 | + | ||
63 | + public OrderInfo() { | ||
64 | + super(); | ||
65 | + this.partnerorderId = ""; | ||
66 | + this.partnerOrderId = ""; | ||
67 | + this.otaOrderId=""; | ||
68 | + this.orderStatus = ""; | ||
69 | + this.qrCodeStr = ""; | ||
70 | + this.qrCodeUrl = ""; | ||
71 | + this.onlyQrCodeUrl=""; | ||
72 | + this.verifyCode = ""; | ||
73 | + this.vouchers = new Vouchers(); | ||
74 | + } | ||
75 | + | ||
76 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
77 | + @XmlType(name = "", propOrder = {"voucher"}) | ||
78 | + @Data | ||
79 | + public static class Vouchers{ | ||
80 | + @XmlElement(required = false) | ||
81 | + protected List<Voucher> voucher; | ||
82 | + | ||
83 | + public Vouchers(){ | ||
84 | + super(); | ||
85 | + this.voucher = new ArrayList<Voucher>(); | ||
86 | + } | ||
87 | + | ||
88 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
89 | + @XmlType(name = "", propOrder = {"voucherCard", "voucherCode", "voucherCodeUrl"}) | ||
90 | + @Data | ||
91 | + public static class Voucher{ | ||
92 | + @XmlElement(required = false) | ||
93 | + protected String voucherCard; | ||
94 | + @XmlElement(required = false) | ||
95 | + protected String voucherCode; | ||
96 | + @XmlElement(required = false) | ||
97 | + protected String voucherCodeUrl; | ||
98 | + | ||
99 | + public Voucher(){ | ||
100 | + super(); | ||
101 | + this.voucherCard = ""; | ||
102 | + this.voucherCode = ""; | ||
103 | + this.voucherCodeUrl = ""; | ||
104 | + } | ||
105 | + } | ||
106 | + } | ||
107 | + } | ||
108 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/PostFaceInfoResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/PostFaceInfoResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "NoticeOrderPrintSuccessResponseBody", propOrder = {"message"}) | ||
12 | +@Data | ||
13 | +public class PostFaceInfoResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String message; | ||
16 | + | ||
17 | + public PostFaceInfoResponseBody() { | ||
18 | + super(); | ||
19 | + this.message=""; | ||
20 | + } | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/PushOrderResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/PushOrderResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "PushOrderResponseBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class PushOrderResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected OrderInfo orderInfo; | ||
16 | + | ||
17 | + public PushOrderResponseBody() { | ||
18 | + super(); | ||
19 | + this.orderInfo = new OrderInfo(); | ||
20 | + } | ||
21 | + | ||
22 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
23 | + @XmlType(name = "", propOrder = {"partnerorderId","partnerOrderId"}) | ||
24 | + @Data | ||
25 | + public static class OrderInfo { | ||
26 | + public String getPartnerorderId() { | ||
27 | + return partnerorderId; | ||
28 | + } | ||
29 | + | ||
30 | + public void setPartnerorderId(String partnerorderId) { | ||
31 | + this.partnerorderId = partnerorderId; | ||
32 | + } | ||
33 | + | ||
34 | + public String getPartnerOrderId() { | ||
35 | + return partnerOrderId; | ||
36 | + } | ||
37 | + | ||
38 | + public void setPartnerOrderId(String partnerOrderId) { | ||
39 | + this.partnerOrderId = partnerOrderId; | ||
40 | + } | ||
41 | + | ||
42 | + @XmlElement(required = true) | ||
43 | + protected String partnerorderId; | ||
44 | + @XmlElement(required = true) | ||
45 | + protected String partnerOrderId; | ||
46 | + | ||
47 | + public OrderInfo() { | ||
48 | + super(); | ||
49 | + this.partnerorderId = ""; | ||
50 | + this.partnerOrderId = ""; | ||
51 | + } | ||
52 | + } | ||
53 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/QueryOtaOrderResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/QueryOtaOrderResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "queryOtaOrderRequestBody", propOrder = {"orderInfo"}) | ||
12 | +@Data | ||
13 | +public class QueryOtaOrderResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected OrderInfo orderInfo; | ||
16 | + | ||
17 | + public QueryOtaOrderResponseBody() { | ||
18 | + super(); | ||
19 | + this.orderInfo=new OrderInfo(); | ||
20 | + } | ||
21 | + | ||
22 | + @XmlAccessorType(XmlAccessType.FIELD) | ||
23 | + @XmlType(name = "", propOrder = {"orderId", "orderStatus"}) | ||
24 | + @Data | ||
25 | + public static class OrderInfo { | ||
26 | + @XmlElement(required = true) | ||
27 | + protected String orderId; | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String orderStatus; | ||
30 | + | ||
31 | + public OrderInfo() { | ||
32 | + super(); | ||
33 | + this.orderId = ""; | ||
34 | + this.orderStatus = ""; | ||
35 | + } | ||
36 | + } | ||
37 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/Response.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/Response.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.*; | ||
6 | + | ||
7 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
8 | +@XmlType(name = "", propOrder = {"header", "body"}) | ||
9 | +@XmlRootElement(name = "response") | ||
10 | +@Data | ||
11 | +public class Response { | ||
12 | + @XmlElement(required = true) | ||
13 | + protected ResponseHeader header; | ||
14 | + @XmlElement(required = true) | ||
15 | + protected ResponseBody body; | ||
16 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/ResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/ResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlType; | ||
8 | + | ||
9 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
10 | +@XmlType(name = "ResponseBody") | ||
11 | +@Data | ||
12 | +public class ResponseBody { | ||
13 | + | ||
14 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/ResponseHeader.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/ResponseHeader.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "ResponseHeader", propOrder = {"application", "processor", "version", "bodyType", "createUser", "createTime", "code", "describe"}) | ||
12 | +@Data | ||
13 | +public class ResponseHeader { | ||
14 | + @XmlElement(required = true, defaultValue = "tour.ectrip.com") | ||
15 | + protected String application; | ||
16 | + @XmlElement(required = true, defaultValue = "DataExchangeProcessor") | ||
17 | + protected String processor; | ||
18 | + @XmlElement(required = true) | ||
19 | + protected String version; | ||
20 | + @XmlElement(required = true) | ||
21 | + protected String bodyType; | ||
22 | + @XmlElement(required = true) | ||
23 | + protected String createUser; | ||
24 | + @XmlElement(required = true) | ||
25 | + protected String createTime; | ||
26 | + @XmlElement(required = true) | ||
27 | + protected String code; | ||
28 | + @XmlElement(required = true) | ||
29 | + protected String describe; | ||
30 | + | ||
31 | + public ResponseHeader() { | ||
32 | + super(); | ||
33 | + this.application = ""; | ||
34 | + this.processor = ""; | ||
35 | + this.version = ""; | ||
36 | + this.bodyType = ""; | ||
37 | + this.createUser = ""; | ||
38 | + this.createTime = ""; | ||
39 | + this.code = ""; | ||
40 | + this.describe = ""; | ||
41 | + } | ||
42 | + | ||
43 | + public ResponseHeader(String application, String processor, String version, String bodyType, String createUser, String createTime, String code, String describe) { | ||
44 | + super(); | ||
45 | + this.application = application; | ||
46 | + this.processor = processor; | ||
47 | + this.version = version; | ||
48 | + this.bodyType = bodyType; | ||
49 | + this.createUser = createUser; | ||
50 | + this.createTime = createTime; | ||
51 | + this.code = code; | ||
52 | + this.describe = describe; | ||
53 | + } | ||
54 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/SendOrderEticketResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/SendOrderEticketResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "SendOrderEticketResponseBody", propOrder = {"message"}) | ||
12 | +@Data | ||
13 | +public class SendOrderEticketResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String message; | ||
16 | + | ||
17 | + public SendOrderEticketResponseBody() { | ||
18 | + super(); | ||
19 | + this.message = ""; | ||
20 | + } | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/VerifyConsumeResponseBody.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/model/cytOrder/response/VerifyConsumeResponseBody.java | ||
1 | +package com.ectrip.cyt.client.cyt.model.cytOrder.response; | ||
2 | + | ||
3 | +import lombok.Data; | ||
4 | + | ||
5 | +import javax.xml.bind.annotation.XmlAccessType; | ||
6 | +import javax.xml.bind.annotation.XmlAccessorType; | ||
7 | +import javax.xml.bind.annotation.XmlElement; | ||
8 | +import javax.xml.bind.annotation.XmlType; | ||
9 | + | ||
10 | +@XmlAccessorType(XmlAccessType.FIELD) | ||
11 | +@XmlType(name = "VerifyConsumeResponseBody", propOrder = {"message"}) | ||
12 | +@Data | ||
13 | +public class VerifyConsumeResponseBody extends ResponseBody { | ||
14 | + @XmlElement(required = true) | ||
15 | + protected String message; | ||
16 | + | ||
17 | + public VerifyConsumeResponseBody() { | ||
18 | + super(); | ||
19 | + this.message = ""; | ||
20 | + } | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/service/TdosApiClient.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/client/cyt/service/TdosApiClient.java | ||
1 | +package com.ectrip.cyt.client.cyt.service; | ||
2 | + | ||
3 | +import com.alibaba.fastjson.JSONObject; | ||
4 | + | ||
5 | +import com.ectrip.cyt.client.cyt.common.Parameter; | ||
6 | +import com.ectrip.cyt.client.cyt.model.cytOrder.request.*; | ||
7 | +import com.ectrip.cyt.client.cyt.model.cytOrder.response.CreateOrderResponseBody; | ||
8 | +import com.ectrip.cyt.client.cyt.model.cytOrder.response.CreatePaymentOrderResponseBody; | ||
9 | +import com.ectrip.cyt.client.cyt.model.cytOrder.response.ResponseHeader; | ||
10 | +import com.ectrip.cyt.exception.BusinessException; | ||
11 | +import com.ectrip.cyt.model.enums.ApiMethodType; | ||
12 | +import com.ectrip.cyt.model.param.*; | ||
13 | +import com.ectrip.cyt.model.pojo.EditPerson; | ||
14 | +import com.ectrip.cyt.model.pojo.Person; | ||
15 | +import com.ectrip.cyt.model.result.Result; | ||
16 | +import com.ectrip.cyt.model.enums.CredentialsType; | ||
17 | +import com.ectrip.cyt.model.enums.OrderStatusType; | ||
18 | +import com.ectrip.cyt.model.rt.CommonReturn; | ||
19 | +import com.ectrip.cyt.utils.*; | ||
20 | +import com.google.common.collect.Lists; | ||
21 | +import com.google.common.collect.Maps; | ||
22 | +import org.apache.commons.collections.CollectionUtils; | ||
23 | +import org.apache.commons.httpclient.HttpClient; | ||
24 | +import org.apache.commons.httpclient.methods.PostMethod; | ||
25 | +import org.apache.commons.httpclient.params.HttpMethodParams; | ||
26 | +import org.apache.commons.lang3.StringUtils; | ||
27 | +import org.apache.commons.lang3.time.DateFormatUtils; | ||
28 | +import org.apache.http.HttpStatus; | ||
29 | + | ||
30 | +import java.io.IOException; | ||
31 | +import java.io.UnsupportedEncodingException; | ||
32 | +import java.net.SocketTimeoutException; | ||
33 | +import java.nio.charset.Charset; | ||
34 | +import java.util.*; | ||
35 | + | ||
36 | +public class TdosApiClient{ | ||
37 | + public static Result heartBeat(AccountParam accountParam){ | ||
38 | + return commonApi(accountParam,new RequestBody(),OtaUtils.HEART_BEAT); | ||
39 | + } | ||
40 | + | ||
41 | + public static Result getBalance(AccountParam accountParam) { | ||
42 | + return commonApi(accountParam,new RequestBody(),OtaUtils.GET_BALANCE); | ||
43 | + } | ||
44 | + | ||
45 | + public static Result checkOrder(CreateOrderParam orderParam, AccountParam accountParam) { | ||
46 | + CreateOrderRequestBody requestBody = new CreateOrderRequestBody(); | ||
47 | + CreateOrderRequestBody.OrderInfo requestOrderInfo = new CreateOrderRequestBody.OrderInfo(); | ||
48 | + requestOrderInfo.setOrderId(orderParam.getOrderCode()); | ||
49 | + //测试接口不支持淘宝 | ||
50 | + //requestOrderInfo.setToken();//淘宝订单(令牌信息) | ||
51 | + //产品信息 | ||
52 | + CreateOrderRequestBody.OrderInfo.Product product = new CreateOrderRequestBody.OrderInfo.Product(); | ||
53 | + product.setResourceId(orderParam.getProduct().getProductNo()); //产品id | ||
54 | + product.setVisitDate(formatDate(DateUtils.convertDate(orderParam.getVisitDate(),DateUtils.DATE_PATTERN)));//游玩日期 | ||
55 | + /*if(StringUtils.isNotBlank(orderParam.getLeaveDate())) { | ||
56 | + product.setLeaveDate(formatDate(DateUtils.convertDate(orderParam.getLeaveDate(), DateUtils.DATE_PATTERN)));//住店日期 | ||
57 | + }*/ | ||
58 | + product.setSellPrice(Long.toString(convertCents(orderParam.getProduct().getSellPrice())));//产品售卖价格,转换为分 | ||
59 | + product.setTimeOfBookId(Long.toString(orderParam.getProduct().getTimeOfBookId())); | ||
60 | + requestOrderInfo.setProduct(product); | ||
61 | + //取票人信息 | ||
62 | + CreateOrderRequestBody.OrderInfo.ContactPerson contactPerson = new CreateOrderRequestBody.OrderInfo.ContactPerson(); | ||
63 | + contactPerson.setName(orderParam.getContactPerson().getName()); | ||
64 | + contactPerson.setMobile(orderParam.getContactPerson().getPhone()); | ||
65 | + contactPerson.setCredentials(orderParam.getContactPerson().getCredentials()); | ||
66 | + CredentialsType credentialsType=CredentialsType.typeOf(orderParam.getContactPerson().getCredentialsType()); | ||
67 | + contactPerson.setCredentialsType(OtaUtils.credentialsTypeStringMap.get(credentialsType)); | ||
68 | + requestOrderInfo.setContactPerson(contactPerson); | ||
69 | + //游玩人信息 | ||
70 | + CreateOrderRequestBody.OrderInfo.VisitPerson visitPerson = new CreateOrderRequestBody.OrderInfo.VisitPerson(); | ||
71 | + List<CreateOrderRequestBody.OrderInfo.VisitPerson.Person> persons = Lists.newArrayList(); | ||
72 | + if (CollectionUtils.isNotEmpty(orderParam.getVisitPersons())) { | ||
73 | + for (Person p : orderParam.getVisitPersons()) { | ||
74 | + CreateOrderRequestBody.OrderInfo.VisitPerson.Person person = new CreateOrderRequestBody.OrderInfo.VisitPerson.Person(); | ||
75 | + person.setName(p.getName()); | ||
76 | + person.setCredentials(p.getCredentials()); | ||
77 | + CredentialsType ct=CredentialsType.typeOf(p.getCredentialsType()); | ||
78 | + person.setCredentialsType(OtaUtils.credentialsTypeStringMap.get(ct) | ||
79 | + ); | ||
80 | + person.setMobile(p.getPhone()); | ||
81 | + persons.add(person); | ||
82 | + } | ||
83 | + } | ||
84 | + visitPerson.setPerson(persons); | ||
85 | + requestOrderInfo.setVisitPerson(visitPerson); | ||
86 | + OrderStatusType orderStatusType=OrderStatusType.ORDER_RESERVE_SUCCESSFUL; | ||
87 | + //订单票数 | ||
88 | + requestOrderInfo.setOrderQuantity(orderParam.getOrderQuantity().toString()); | ||
89 | + //订单金额 | ||
90 | + requestOrderInfo.setOrderPrice(Long.toString(convertCents(orderParam.getOrderPrice()))); | ||
91 | + //只支持预付 | ||
92 | + requestOrderInfo.setOrderStatus(OtaUtils.prepayOrderStatusTypeStringMap.get(orderStatusType)); | ||
93 | + requestBody.setOrderInfo(requestOrderInfo); | ||
94 | + return commonApi(accountParam,requestBody,OtaUtils.CHECK_ORDER); | ||
95 | + } | ||
96 | + | ||
97 | + public static Result createOrder(CreateOrderParam orderParam, AccountParam accountParam) { | ||
98 | + CreateOrderRequestBody requestBody = new CreateOrderRequestBody(); | ||
99 | + CreateOrderRequestBody.OrderInfo requestOrderInfo = new CreateOrderRequestBody.OrderInfo(); | ||
100 | + requestOrderInfo.setOrderId(orderParam.getOrderCode()); | ||
101 | + //测试接口不支持淘宝 | ||
102 | + //requestOrderInfo.setToken();//淘宝订单(令牌信息) | ||
103 | + //产品信息 | ||
104 | + CreateOrderRequestBody.OrderInfo.Product product = new CreateOrderRequestBody.OrderInfo.Product(); | ||
105 | + product.setResourceId(orderParam.getProduct().getProductNo()); //产品id | ||
106 | + product.setVisitDate(formatDate(DateUtils.convertDate(orderParam.getVisitDate(),DateUtils.DATE_PATTERN)));//游玩日期 | ||
107 | + /*if(StringUtils.isNotBlank(orderParam.getLeaveDate())) { | ||
108 | + product.setLeaveDate(formatDate(DateUtils.convertDate(orderParam.getLeaveDate(), DateUtils.DATE_PATTERN)));//住店日期 | ||
109 | + }*/ | ||
110 | + product.setSellPrice(Long.toString(convertCents(orderParam.getProduct().getSellPrice())));//产品售卖价格,转换为分 | ||
111 | + product.setTimeOfBookId(Long.toString(orderParam.getProduct().getTimeOfBookId())); | ||
112 | + //product.setSeatIds(orderParam.getProduct().getSeatIds()); | ||
113 | + requestOrderInfo.setProduct(product); | ||
114 | + //取票人信息 | ||
115 | + CreateOrderRequestBody.OrderInfo.ContactPerson contactPerson = new CreateOrderRequestBody.OrderInfo.ContactPerson(); | ||
116 | + contactPerson.setName(orderParam.getContactPerson().getName()); | ||
117 | + contactPerson.setMobile(orderParam.getContactPerson().getPhone()); | ||
118 | + //contactPerson.setCredentials(orderParam.getContactPerson().getCredentials()); | ||
119 | + CredentialsType credentialsType=CredentialsType.typeOf(orderParam.getContactPerson().getCredentialsType()); | ||
120 | + //contactPerson.setCredentialsType(OtaUtils.credentialsTypeStringMap.get(credentialsType)); | ||
121 | + requestOrderInfo.setContactPerson(contactPerson); | ||
122 | + //游玩人信息 | ||
123 | + CreateOrderRequestBody.OrderInfo.VisitPerson visitPerson = new CreateOrderRequestBody.OrderInfo.VisitPerson(); | ||
124 | + List<CreateOrderRequestBody.OrderInfo.VisitPerson.Person> persons = Lists.newArrayList(); | ||
125 | + if (CollectionUtils.isNotEmpty(orderParam.getVisitPersons())) { | ||
126 | + for (Person p : orderParam.getVisitPersons()) { | ||
127 | + CreateOrderRequestBody.OrderInfo.VisitPerson.Person person = new CreateOrderRequestBody.OrderInfo.VisitPerson.Person(); | ||
128 | + person.setName(p.getName()); | ||
129 | + person.setCredentials(p.getCredentials()); | ||
130 | + CredentialsType ct=CredentialsType.typeOf(p.getCredentialsType()); | ||
131 | + person.setCredentialsType(OtaUtils.credentialsTypeStringMap.get(ct) | ||
132 | + ); | ||
133 | + person.setMobile(p.getPhone()); | ||
134 | + persons.add(person); | ||
135 | + } | ||
136 | + } | ||
137 | + visitPerson.setPerson(persons); | ||
138 | + requestOrderInfo.setVisitPerson(visitPerson); | ||
139 | + OrderStatusType orderStatusType=OrderStatusType.ORDER_NOT_PAYED_YET; | ||
140 | + //订单票数 | ||
141 | + requestOrderInfo.setOrderQuantity(orderParam.getOrderQuantity().toString()); | ||
142 | + //订单金额 | ||
143 | + requestOrderInfo.setOrderPrice(Long.toString(convertCents(orderParam.getOrderPrice()))); | ||
144 | + //只支持预付 | ||
145 | + requestOrderInfo.setOrderStatus(OtaUtils.prepayOrderStatusTypeStringMap.get(orderStatusType)); | ||
146 | + requestBody.setOrderInfo(requestOrderInfo); | ||
147 | + return commonApi(accountParam,requestBody,OtaUtils.CREATE_ORDER); | ||
148 | + } | ||
149 | + | ||
150 | + public static Result cancelOrder(CancelOrderParam cancelOrder,AccountParam accountParam) { | ||
151 | + CancelOrderRequestBody requestBody=new CancelOrderRequestBody(); | ||
152 | + CancelOrderRequestBody.OrderInfo oiRequest = new CancelOrderRequestBody.OrderInfo(); | ||
153 | + oiRequest.setPartnerOrderId(cancelOrder.getCytOrderCode()); | ||
154 | + oiRequest.setOrderId(cancelOrder.getOtaOrderCode()); | ||
155 | + requestBody.setOrderInfo(oiRequest); | ||
156 | + return commonApi(accountParam,requestBody,OtaUtils.CANCEL_ORDER); | ||
157 | + } | ||
158 | + | ||
159 | + public static Result payOrder(PayOrderParam payOrder,AccountParam accountParam) { | ||
160 | + PayOrderRequestBody requestBody=new PayOrderRequestBody(); | ||
161 | + PayOrderRequestBody.OrderInfo oiRequest = new PayOrderRequestBody.OrderInfo(); | ||
162 | + oiRequest.setPartnerOrderId(payOrder.getCytOrderCode()); | ||
163 | + oiRequest.setOtaOrderId(payOrder.getOtaOrderCode()); | ||
164 | + oiRequest.setOrderPrice(Long.toString(convertCents(payOrder.getOrderPrice()))); | ||
165 | + oiRequest.setOrderStatus(OrderStatusUtils.PREPAY_ORDER_PRINT_SUCCESS); | ||
166 | + requestBody.setOrderInfo(oiRequest); | ||
167 | + return commonApi(accountParam,requestBody,OtaUtils.PAY_ORDER); | ||
168 | + } | ||
169 | + | ||
170 | + public static Result queryOrder(QueryOrderParam queryOrder,AccountParam accountParam) { | ||
171 | + GetOrderByOTARequestBody requestBody=new GetOrderByOTARequestBody(); | ||
172 | + //ota订单查询 | ||
173 | + requestBody.setOrderId(queryOrder.getOrderCode()); | ||
174 | + requestBody.setPartnerOrderId(queryOrder.getCytOrderCode()); | ||
175 | + return commonApi(accountParam,requestBody,OtaUtils.GET_ORDER_BY_OTA); | ||
176 | + } | ||
177 | + | ||
178 | + public static Result pushOrder(PushOrderParam pushOrder,AccountParam accountParam) { | ||
179 | + PushOrderRequestBody requestBody=new PushOrderRequestBody(); | ||
180 | + PushOrderRequestBody.OrderInfo oiRequest = new PushOrderRequestBody.OrderInfo(); | ||
181 | + //联系人信息 | ||
182 | + Person contact = pushOrder.getContactPerson(); | ||
183 | + if (contact != null) { | ||
184 | + PushOrderRequestBody.OrderInfo.ContactPerson contactPerson = new PushOrderRequestBody.OrderInfo.ContactPerson(); | ||
185 | + contactPerson.setName(contact.getName()); | ||
186 | + contactPerson.setMobile(contact.getPhone()); | ||
187 | + contactPerson.setCredentials(contact.getCredentials()); | ||
188 | + CredentialsType ct=CredentialsType.typeOf(contact.getCredentialsType()); | ||
189 | + contactPerson.setCredentialsType(OtaUtils.credentialsTypeStringMap.get(ct)); | ||
190 | + oiRequest.setContactPerson(contactPerson); | ||
191 | + } | ||
192 | + //游玩人信息 | ||
193 | + if (CollectionUtils.isNotEmpty(pushOrder.getVisitPersons())) { | ||
194 | + PushOrderRequestBody.OrderInfo.VisitPerson visitPerson = new PushOrderRequestBody.OrderInfo.VisitPerson(); | ||
195 | + List<PushOrderRequestBody.OrderInfo.VisitPerson.Person> persons = Lists.newArrayList(); | ||
196 | + for (EditPerson visitor : pushOrder.getVisitPersons()) { | ||
197 | + PushOrderRequestBody.OrderInfo.VisitPerson.Person person = new PushOrderRequestBody.OrderInfo.VisitPerson.Person(); | ||
198 | + person.setCredentials(visitor.getEditCredentials()); | ||
199 | + person.setName(visitor.getEditName()); | ||
200 | + persons.add(person); | ||
201 | + } | ||
202 | + visitPerson.setPerson(persons); | ||
203 | + oiRequest.setVisitPerson(visitPerson); | ||
204 | + } | ||
205 | + oiRequest.setVisitDate(pushOrder.getVisitDate()); | ||
206 | + oiRequest.setPartnerOrderId(pushOrder.getCytOrderCode()); | ||
207 | + requestBody.setOrderInfo(oiRequest); | ||
208 | + return commonApi(accountParam,requestBody,OtaUtils.PUSH_ORDER); | ||
209 | + } | ||
210 | + | ||
211 | + public static Result applyOrderRefundByUser(RefundOrderParam refundOrder,AccountParam accountParam) { | ||
212 | + ApplyOrderRefundByUserRequestBody requestBody=new ApplyOrderRefundByUserRequestBody(); | ||
213 | + ApplyOrderRefundByUserRequestBody.OrderInfo oiRequest = new ApplyOrderRefundByUserRequestBody.OrderInfo(); | ||
214 | + //畅游通订单号 | ||
215 | + oiRequest.setPartnerOrderId(refundOrder.getCytOrderCode()); | ||
216 | + //退款流水号 | ||
217 | + oiRequest.setRefundSeq(refundOrder.getRefundSeq()); | ||
218 | + //订单金额 | ||
219 | + //oiRequest.setOrderPrice(Long.toString(convertCents(refundOrder.getOrderMoney()))); | ||
220 | + //订单票数 | ||
221 | + //oiRequest.setOrderQuantity(Integer.toString(refundOrder.getOrderQuantity())); | ||
222 | + //退款票数 | ||
223 | + oiRequest.setRefundQuantity(Integer.toString(refundOrder.getRefundQuantity())); | ||
224 | + //订单退订金额,转换成分 | ||
225 | + oiRequest.setOrderRefundPrice(Long.toString(convertCents(refundOrder.getRefundMoney()))); | ||
226 | + //退订手续费,转换成分 | ||
227 | + //oiRequest.setOrderRefundCharge(Long.toString(convertCents(refundOrder.getRefundCharge()))); | ||
228 | + | ||
229 | + if (CollectionUtils.isNotEmpty(refundOrder.getVisitPersons())) { | ||
230 | + ApplyOrderRefundByUserRequestBody.OrderInfo.VisitPerson visitPerson = new ApplyOrderRefundByUserRequestBody.OrderInfo.VisitPerson(); | ||
231 | + List<ApplyOrderRefundByUserRequestBody.OrderInfo.VisitPerson.Person> persons = Lists.newArrayList(); | ||
232 | + for (Person visitor : refundOrder.getVisitPersons()) { | ||
233 | + ApplyOrderRefundByUserRequestBody.OrderInfo.VisitPerson.Person person = new ApplyOrderRefundByUserRequestBody.OrderInfo.VisitPerson.Person(); | ||
234 | + person.setName(visitor.getName()); | ||
235 | + CredentialsType ct=CredentialsType.typeOf(visitor.getCredentialsType()); | ||
236 | + person.setCredentialsType(OtaUtils.credentialsTypeStringMap.get(ct)); | ||
237 | + person.setCredentials(visitor.getCredentials()); | ||
238 | + person.setVoucherCode(visitor.getVoucher()); | ||
239 | + persons.add(person); | ||
240 | + } | ||
241 | + visitPerson.setPerson(persons); | ||
242 | + oiRequest.setVisitPerson(visitPerson); | ||
243 | + } | ||
244 | + | ||
245 | + String refundReason = refundOrder.getRefundReason(); | ||
246 | + if (org.apache.commons.lang3.StringUtils.isBlank(refundReason)) { | ||
247 | + refundReason = "客人想退款"; | ||
248 | + } | ||
249 | + oiRequest.setRefundExplain(refundReason); | ||
250 | + requestBody.setOrderInfo(oiRequest); | ||
251 | + return commonApi(accountParam,requestBody,OtaUtils.APPLY_ORDER_REFUND_BY_USER); | ||
252 | + } | ||
253 | + | ||
254 | + public static Result queryPois(AccountParam accountParam){ | ||
255 | + return commonApi(accountParam,new RequestBody(),OtaUtils.GET_AVAILABLE_PRODUCT); | ||
256 | + } | ||
257 | + | ||
258 | + public static Result queryStockAndTsds(GetStockParam param,AccountParam accountParam){ | ||
259 | + GetStockProductInfoRequestBody requestBody=new GetStockProductInfoRequestBody(); | ||
260 | + requestBody.setResourceId(param.getResourceId()); | ||
261 | + requestBody.setStartDate(param.getStartDate()); | ||
262 | + requestBody.setEndDate(param.getEndDate()); | ||
263 | + return commonApi(accountParam,requestBody,OtaUtils.GET_STOCK_PRODUCT_INFO); | ||
264 | + } | ||
265 | + | ||
266 | + /*public static Result querySeatList(GetSeatParam param,AccountParam accountParam){ | ||
267 | + GetSeatInfoRequestBody requestBody=new GetSeatInfoRequestBody(); | ||
268 | + requestBody.setTimeOfBookId(param.getTimeOfBookId()); | ||
269 | + return commonApi(accountParam,requestBody,OtaUtils.GET_SEAT_INFO); | ||
270 | + }*/ | ||
271 | + | ||
272 | + public static Result sendOrderEticket(SendOrderEticketParam param,AccountParam accountParam){ | ||
273 | + SendOrderEticketRequestBody requestBody=new SendOrderEticketRequestBody(); | ||
274 | + requestBody.getOrderInfo().setPartnerOrderId(param.getCytOrderCode()); | ||
275 | + requestBody.getOrderInfo().setPhoneNumber(param.getPhone()); | ||
276 | + return commonApi(accountParam,requestBody,OtaUtils.SEND_ORDER_ETICKET); | ||
277 | + } | ||
278 | + | ||
279 | + public static Result queryProducts(GetProductParam productParam, AccountParam accountParam) { | ||
280 | + GetProductByOTARequestBody requestBody=new GetProductByOTARequestBody(); | ||
281 | + if(StringUtils.isNotBlank(productParam.getResourceId())){ | ||
282 | + requestBody.setResourceId(productParam.getResourceId()); | ||
283 | + requestBody.setCurrentPage(""); | ||
284 | + requestBody.setPageSize(""); | ||
285 | + }else{ | ||
286 | + requestBody.setCurrentPage(productParam.getCurrentPage().toString()); | ||
287 | + requestBody.setPageSize(productParam.getPageSize().toString()); | ||
288 | + } | ||
289 | + return commonApi(accountParam,requestBody,OtaUtils.GET_PRODUCT_BY_OTA); | ||
290 | + } | ||
291 | + | ||
292 | + public static Result createPaymentOrder(CreateOrderParam orderParam, AccountParam accountParam) { | ||
293 | + CreatePaymentOrderRequestBody requestBody = new CreatePaymentOrderRequestBody(); | ||
294 | + CreatePaymentOrderRequestBody.OrderInfo requestOrderInfo = new CreatePaymentOrderRequestBody.OrderInfo(); | ||
295 | + requestOrderInfo.setOrderId(orderParam.getOrderCode()); | ||
296 | + //产品信息 | ||
297 | + CreatePaymentOrderRequestBody.OrderInfo.Product product = new CreatePaymentOrderRequestBody.OrderInfo.Product(); | ||
298 | + product.setResourceId(orderParam.getProduct().getProductNo()); //产品id | ||
299 | + product.setVisitDate(formatDate(DateUtils.convertDate(orderParam.getVisitDate(),DateUtils.DATE_PATTERN))); //游玩日期 | ||
300 | + if(StringUtils.isNotBlank(orderParam.getLeaveDate())) { | ||
301 | + product.setLeaveDate(formatDate(DateUtils.convertDate(orderParam.getLeaveDate(), DateUtils.DATE_PATTERN)));//住店日期 | ||
302 | + } | ||
303 | + product.setSellPrice(Long.toString(convertCents(orderParam.getProduct().getSellPrice())));//产品售卖价格,转换为分 | ||
304 | + product.setTimeOfBookId(Long.toString(orderParam.getProduct().getTimeOfBookId())); | ||
305 | + //product.setSeatIds(orderParam.getProduct().getSeatIds()); | ||
306 | + requestOrderInfo.setProduct(product); | ||
307 | + //取票人信息 | ||
308 | + CreatePaymentOrderRequestBody.OrderInfo.ContactPerson contactPerson = new CreatePaymentOrderRequestBody.OrderInfo.ContactPerson(); | ||
309 | + contactPerson.setName(orderParam.getContactPerson().getName()); | ||
310 | + contactPerson.setMobile(orderParam.getContactPerson().getPhone()); | ||
311 | + contactPerson.setCredentials(orderParam.getContactPerson().getCredentials()); | ||
312 | + CredentialsType credentialsType=CredentialsType.typeOf(orderParam.getContactPerson().getCredentialsType()); | ||
313 | + contactPerson.setCredentialsType(OtaUtils.credentialsTypeStringMap.get(credentialsType) | ||
314 | + ); | ||
315 | + requestOrderInfo.setContactPerson(contactPerson); | ||
316 | + //游玩人信息 | ||
317 | + CreatePaymentOrderRequestBody.OrderInfo.VisitPerson visitPerson = new CreatePaymentOrderRequestBody.OrderInfo.VisitPerson(); | ||
318 | + List<CreatePaymentOrderRequestBody.OrderInfo.VisitPerson.Person> persons = Lists.newArrayList(); | ||
319 | + if (CollectionUtils.isNotEmpty(orderParam.getVisitPersons())) { | ||
320 | + for (Person p : orderParam.getVisitPersons()) { | ||
321 | + CreatePaymentOrderRequestBody.OrderInfo.VisitPerson.Person person = new CreatePaymentOrderRequestBody.OrderInfo.VisitPerson.Person(); | ||
322 | + person.setName(p.getName()); | ||
323 | + person.setMobile(p.getPhone()); | ||
324 | + person.setCredentials(p.getCredentials()); | ||
325 | + CredentialsType ct=CredentialsType.typeOf(p.getCredentialsType()); | ||
326 | + person.setCredentialsType(OtaUtils.credentialsTypeStringMap.get(ct) | ||
327 | + ); | ||
328 | + persons.add(person); | ||
329 | + } | ||
330 | + } | ||
331 | + visitPerson.setPerson(persons); | ||
332 | + requestOrderInfo.setVisitPerson(visitPerson); | ||
333 | + OrderStatusType orderStatusType=OrderStatusType.ORDER_RESERVE_SUCCESSFUL; | ||
334 | + //订单票数 | ||
335 | + requestOrderInfo.setOrderQuantity(orderParam.getOrderQuantity().toString()); | ||
336 | + //订单金额 | ||
337 | + requestOrderInfo.setOrderPrice(Long.toString(convertCents(orderParam.getOrderPrice()))); | ||
338 | + //只支持预付 | ||
339 | + requestOrderInfo.setOrderStatus(OtaUtils.prepayOrderStatusTypeStringMap.get(orderStatusType)); | ||
340 | + requestBody.setOrderInfo(requestOrderInfo); | ||
341 | + return commonApi(accountParam,requestBody,OtaUtils.CREATE_PAY_ORDER); | ||
342 | + } | ||
343 | + | ||
344 | + //<!=============================通用请求====================================!> | ||
345 | + public static Result commonApi(AccountParam account,RequestBody requestBody,String method){ | ||
346 | + ApiMethodType methodType=ApiMethodType.typeOf(method); | ||
347 | + | ||
348 | + CommonReturn data=new CommonReturn(); | ||
349 | + | ||
350 | + Date dateTimeStart = new Date(); //开始时间 | ||
351 | + data.setRequestTime(DateUtils.formatDate(dateTimeStart,DateUtils.DATETIME_PATTERN)); | ||
352 | + | ||
353 | + Map<String, Object> mapRequest = parseRequest(requestBody,account.getDistributorName(), account.getIdentity(), account.getKey(),account.getSecurityType()); | ||
354 | + | ||
355 | + //定义请求的报文 | ||
356 | + String requestXml = (String) mapRequest.get(OtaUtils.REQUEST_XML); | ||
357 | + JSONObject requestJson = (JSONObject) mapRequest.get(OtaUtils.REQUEST_JSON_OBJECT); | ||
358 | + | ||
359 | + Result<String> resultSend = sendData(account.getUrl(), method, | ||
360 | + requestJson.toJSONString()); | ||
361 | + if (!resultSend.isSuccess()) { | ||
362 | + return Result.error(resultSend.getThrowable(), resultSend.getDescription()); | ||
363 | + } | ||
364 | + | ||
365 | + String response = resultSend.getData(); | ||
366 | + | ||
367 | + //返回报文 | ||
368 | + String responseXml = getResponseXml(response,account.getKey(),account.getSecurityType()); | ||
369 | + | ||
370 | + Date dateTimeEnd = new Date(); //结束时间 | ||
371 | + data.setResponseTime(DateUtils.formatDate(dateTimeEnd,DateUtils.DATETIME_PATTERN)); | ||
372 | + //记录日志 | ||
373 | + data.setRequestJson(requestJson); | ||
374 | + data.setRequestXml(requestXml); | ||
375 | + | ||
376 | + JSONObject res=JSONObject.parseObject(response); | ||
377 | + if(res.get("xml")!=null){ | ||
378 | + res.remove("xml"); | ||
379 | + } | ||
380 | + data.setResponseJson(res); | ||
381 | + data.setResponseXml(responseXml); | ||
382 | + data.setInterfaceType("整合营销接口"); | ||
383 | + data.setInterfaceMethod(method); | ||
384 | + data.setDescription(methodType.getName()); | ||
385 | + //解析报文 | ||
386 | + Map map = xmlToBean(responseXml, new ResponseHeader(), new CreateOrderResponseBody()); | ||
387 | + ResponseHeader header = (ResponseHeader) map.get(OtaUtils.DOM_HEADER); | ||
388 | + // 判定header返回值,是否为1000 | ||
389 | + String codeResponse = header.getCode(); | ||
390 | + if (!OtaUtils.SUCCESS_CODE.equals(codeResponse)) { | ||
391 | + data.setApiStatus(false); | ||
392 | + }else{ | ||
393 | + data.setApiStatus(true); | ||
394 | + if(method.equals(ApiMethodType.CREATE_ORDER.getType())) { | ||
395 | + CreateOrderResponseBody responseBody = (CreateOrderResponseBody) map.get(OtaUtils.DOM_BODY); | ||
396 | + data.setCytOrderCode(responseBody.getOrderInfo().getPartnerorderId()); | ||
397 | + }else if(method.equals(ApiMethodType.CREATE_PAY_ORDER)){ | ||
398 | + CreatePaymentOrderResponseBody responseBody = (CreatePaymentOrderResponseBody) map.get(OtaUtils.DOM_BODY); | ||
399 | + data.setCytOrderCode(responseBody.getOrderInfo().getPartnerorderId()); | ||
400 | + } | ||
401 | + } | ||
402 | + return Result.success(data); | ||
403 | + } | ||
404 | + | ||
405 | + //<!=============================工具类或通用方法====================================!> | ||
406 | + public static String formatDate(Date date) { | ||
407 | + return DateFormatUtils.format(date, DateUtils.DATE_PATTERN); | ||
408 | + } | ||
409 | + | ||
410 | + public static long convertCents(double money) { | ||
411 | + return BigDecimalUtils.amplify2long(money, 2); | ||
412 | + } | ||
413 | + | ||
414 | + /* | ||
415 | + 发送数据 | ||
416 | + */ | ||
417 | + private static Result<String> sendData(String url, String method, String requestJson) { | ||
418 | + String response = ""; | ||
419 | + HttpClient client = new HttpClient(); | ||
420 | + | ||
421 | + //Platfrom_sign platfrom_sign=Platfrom_sign.typeOf(platfrom_sign_type); | ||
422 | + //PostMethod postMethod = new UTF8PostMethod(platfrom_sign.getName() + ota_api_method_url); | ||
423 | + PostMethod postMethod = new UTF8PostMethod(url); | ||
424 | + | ||
425 | + postMethod.addParameter("Connection", "Keep-Alive"); | ||
426 | + postMethod.addParameter("Charset", OtaUtils.ENCODE_UTF8); | ||
427 | + postMethod.addParameter("Content-Type", "application/x-www-form-urlencoded"); | ||
428 | + postMethod.getParams().setParameter(HttpMethodParams.SO_TIMEOUT, 30000);//30S超时 | ||
429 | + | ||
430 | + List<Parameter> params = new ArrayList<Parameter>(); | ||
431 | + params.add(new Parameter("method", method)); | ||
432 | + params.add(new Parameter("requestParam", requestJson)); | ||
433 | + postMethod.setRequestBody(buildNameValuePair(params)); | ||
434 | + | ||
435 | + try { | ||
436 | + /*java.net.URL endpointURL = new java.net.URL(url); | ||
437 | + CytDataServiceSoapBindingStub ssl = new CytDataServiceSoapBindingStub(endpointURL, null); | ||
438 | + ssl.setMaintainSession(true); | ||
439 | + String responseString = ssl.doCYTRequest(method, requestJson); | ||
440 | + return Result.success(responseString);*/ | ||
441 | + int statusCode = client.executeMethod(postMethod); | ||
442 | + if (statusCode == HttpStatus.SC_OK) { | ||
443 | + response = postMethod.getResponseBodyAsString(); | ||
444 | + } else { | ||
445 | + throw new IOException("Http Post Exception Of Code: " + statusCode); | ||
446 | + } | ||
447 | + postMethod.releaseConnection(); | ||
448 | + client = null; | ||
449 | + | ||
450 | + return Result.success(response); | ||
451 | + } | ||
452 | + //PMS数据发送异常,将异常信息返回 | ||
453 | + catch (Exception e) { | ||
454 | + if(e instanceof SocketTimeoutException){ | ||
455 | + return Result.error(e, "畅游通网络超时,请稍后再试."); | ||
456 | + } | ||
457 | + return Result.error(e, "自测平台请求["+method+"]接口发生异常."+e.getMessage()); | ||
458 | + } | ||
459 | + } | ||
460 | + | ||
461 | + private static org.apache.commons.httpclient.NameValuePair[] buildNameValuePair(List<Parameter> list) { | ||
462 | + int length = list.size(); | ||
463 | + org.apache.commons.httpclient.NameValuePair[] pais = new org.apache.commons.httpclient.NameValuePair[length]; | ||
464 | + for (int i = 0; i < length; i++) { | ||
465 | + Parameter param = list.get(i); | ||
466 | + pais[i] = new org.apache.commons.httpclient.NameValuePair(param.getName(), param.getValue()); | ||
467 | + } | ||
468 | + return pais; | ||
469 | + } | ||
470 | + | ||
471 | + /* | ||
472 | + * 对象转XML | ||
473 | + */ | ||
474 | + private static String beanToXml(RequestBody requestBody, String distributorName, String supplierIdentity) { | ||
475 | + try { | ||
476 | + RequestHeader header = new RequestHeader(); | ||
477 | + header.setApplication("tour.ectrip.com"); | ||
478 | + header.setProcessor("DataExchangeProcessor"); | ||
479 | + header.setVersion("1.0.0"); | ||
480 | + header.setCreateUser(distributorName); | ||
481 | + header.setCreateTime(DateUtils.formatDate(new Date(),DateUtils.DATETIME_PATTERN)); | ||
482 | + header.setSupplierIdentity(supplierIdentity); | ||
483 | + | ||
484 | + return XmlParseUtil.beanToXML(requestBody, header, OtaUtils.ECTRIP); | ||
485 | + } catch (Throwable throwable) { | ||
486 | + throw new BusinessException(throwable); | ||
487 | + } | ||
488 | + } | ||
489 | + | ||
490 | + /* | ||
491 | + * XML转成map对象 | ||
492 | + */ | ||
493 | + private static Map xmlToBean(String xml, Object head, Object body) { | ||
494 | + try { | ||
495 | + return XmlParseUtil.xmlToBean(xml, head, body); | ||
496 | + } | ||
497 | + //XML解析异常 | ||
498 | + catch (Exception e) { | ||
499 | + e.printStackTrace(); | ||
500 | + throw new BusinessException(e); | ||
501 | + } | ||
502 | + } | ||
503 | + | ||
504 | + public static Map<String, Object> parseRequest(RequestBody requestBody, | ||
505 | + String distributorName, | ||
506 | + String supplierIdentity, | ||
507 | + String key, | ||
508 | + String securityType) { | ||
509 | + String requestXml = beanToXml(requestBody, distributorName, supplierIdentity); | ||
510 | + | ||
511 | + JSONObject requestJSON = new JSONObject(); | ||
512 | + | ||
513 | + if(StringUtils.isBlank(securityType)){ | ||
514 | + //默认MD5加密 | ||
515 | + securityType = OtaUtils.SECURITY_MD5; | ||
516 | + } | ||
517 | + securityType = securityType.toUpperCase(); | ||
518 | + | ||
519 | + String requestData; | ||
520 | + if(securityType.equals(OtaUtils.SECURITY_MD5)){ | ||
521 | + String responseSigned = EncryptUtil.MD5Hex(key + requestXml).toUpperCase(); | ||
522 | + requestJSON.put(OtaUtils.JSON_SIGNED, responseSigned); | ||
523 | + | ||
524 | + byte[] requestByte = requestXml.getBytes(Charset.forName(OtaUtils.ENCODE_UTF8)); | ||
525 | + requestData = Base64Utils.encode(requestByte); | ||
526 | + }else{ | ||
527 | + String iv = SecurityTools.generatorIv(); | ||
528 | + if(securityType.equals(OtaUtils.SECURITY_AES_CBC)){ | ||
529 | + requestData = AesTools.encryptCBC(requestXml,key,iv); | ||
530 | + }else if(securityType.equals(OtaUtils.SECURITY_SM4_CBC)){ | ||
531 | + requestData = SM4Tools.encryptCBC(requestXml,key,iv); | ||
532 | + }else{ | ||
533 | + throw new BusinessException("不支持的加密算法!"); | ||
534 | + } | ||
535 | + requestJSON.put(OtaUtils.JSON_IV, iv); | ||
536 | + requestJSON.put(OtaUtils.JSON_CREATEUSER,distributorName); | ||
537 | + } | ||
538 | + | ||
539 | + requestJSON.put(OtaUtils.JSON_DATA, requestData); | ||
540 | + requestJSON.put(OtaUtils.JSON_SECURITY_TYPE,securityType); | ||
541 | + | ||
542 | + //返回结果 | ||
543 | + Map<String, Object> mapResult = Maps.newHashMap(); | ||
544 | + mapResult.put(OtaUtils.REQUEST_XML, requestXml); | ||
545 | + mapResult.put(OtaUtils.REQUEST_JSON_OBJECT, requestJSON); | ||
546 | + return mapResult; | ||
547 | + } | ||
548 | + | ||
549 | + /* | ||
550 | + 获得返回的xml字符串 | ||
551 | + */ | ||
552 | + private static String getResponseXml(String responseJson, String key,String securityType) { | ||
553 | + JSONObject jsonObject = JSONObject.parseObject(responseJson); | ||
554 | + Object dataObject = jsonObject.get(OtaUtils.JSON_DATA); | ||
555 | + Object signedObject = jsonObject.get(OtaUtils.JSON_SIGNED); | ||
556 | + Object ivObject = jsonObject.get(OtaUtils.JSON_IV); | ||
557 | + //String securityType = jsonObject.get(OtaUtils.JSON_SECURITY_TYPE).toString(); | ||
558 | + | ||
559 | + if(dataObject == null && dataObject.toString().equals("")){ | ||
560 | + throw new BusinessException("data返回为空"); | ||
561 | + } | ||
562 | + | ||
563 | + String data = dataObject.toString(); | ||
564 | + String xml; | ||
565 | + if (OtaUtils.SECURITY_MD5.equals(securityType)) { | ||
566 | + if(signedObject == null || signedObject.toString().equals("")){ | ||
567 | + throw new BusinessException("signed返回为空"); | ||
568 | + } | ||
569 | + String signed = signedObject.toString(); | ||
570 | + | ||
571 | + String signedEncryption = EncryptUtil.MD5Hex(key + data).toUpperCase(); | ||
572 | + if (!signedEncryption.equalsIgnoreCase(signed)) { | ||
573 | + throw new BusinessException("签证验证不通过"); | ||
574 | + } | ||
575 | + | ||
576 | + try { | ||
577 | + byte[] xmlByte = Base64Utils.decode(data); | ||
578 | + xml = new String(xmlByte,OtaUtils.ENCODE_UTF8); | ||
579 | + } catch (UnsupportedEncodingException e) { | ||
580 | + e.printStackTrace(); | ||
581 | + throw new BusinessException("Base64解密失败"); | ||
582 | + } | ||
583 | + | ||
584 | + } else { | ||
585 | + if(ivObject == null || ivObject.toString().equals("")){ | ||
586 | + throw new BusinessException("iv返回为空"); | ||
587 | + } | ||
588 | + String iv = ivObject.toString(); | ||
589 | + | ||
590 | + if (securityType.equals(OtaUtils.SECURITY_AES_CBC)) { | ||
591 | + xml = AesTools.decryptCBC(data,key,iv); | ||
592 | + }else if (securityType.equals(OtaUtils.SECURITY_SM4_CBC)) { | ||
593 | + xml = SM4Tools.decryptCBC(data,key,iv); | ||
594 | + }else { | ||
595 | + throw new BusinessException("不支持的加密算法"); | ||
596 | + } | ||
597 | + } | ||
598 | + return xml; | ||
599 | + } | ||
600 | + | ||
601 | + | ||
602 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/config/DruidConfig.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/config/DruidConfig.java | ||
1 | +package com.ectrip.cyt.config; | ||
2 | + | ||
3 | +import com.alibaba.druid.pool.DruidDataSource; | ||
4 | +import org.springframework.boot.context.properties.ConfigurationProperties; | ||
5 | +import org.springframework.context.annotation.Bean; | ||
6 | +import org.springframework.context.annotation.Configuration; | ||
7 | + | ||
8 | +import javax.sql.DataSource; | ||
9 | + | ||
10 | +/** | ||
11 | + * Created by chenxinhao on 2018/11/2. | ||
12 | + */ | ||
13 | +@Configuration | ||
14 | +public class DruidConfig { | ||
15 | + | ||
16 | + @Bean | ||
17 | + @ConfigurationProperties(prefix = "spring.datasource") | ||
18 | + public DataSource druidDataSource() { | ||
19 | + return new DruidDataSource(); | ||
20 | + } | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/config/Swagger2.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/config/Swagger2.java | ||
1 | +package com.ectrip.cyt.config; | ||
2 | + | ||
3 | +import com.github.xiaoymin.swaggerbootstrapui.annotations.EnableSwaggerBootstrapUI; | ||
4 | +import org.springframework.context.annotation.Bean; | ||
5 | +import org.springframework.context.annotation.Configuration; | ||
6 | +import springfox.documentation.builders.ApiInfoBuilder; | ||
7 | +import springfox.documentation.builders.PathSelectors; | ||
8 | +import springfox.documentation.builders.RequestHandlerSelectors; | ||
9 | +import springfox.documentation.service.ApiInfo; | ||
10 | +import springfox.documentation.spi.DocumentationType; | ||
11 | +import springfox.documentation.spring.web.plugins.Docket; | ||
12 | +import springfox.documentation.swagger2.annotations.EnableSwagger2; | ||
13 | + | ||
14 | +/** | ||
15 | + * Created by chenxinhao on 2019-10-16. | ||
16 | + */ | ||
17 | +@Configuration | ||
18 | +@EnableSwagger2 | ||
19 | +@EnableSwaggerBootstrapUI | ||
20 | +public class Swagger2 { | ||
21 | + | ||
22 | + /** | ||
23 | + * 通过 createRestApi函数来构建一个DocketBean | ||
24 | + * 函数名,可以随意命名,喜欢什么命名就什么命名 | ||
25 | + */ | ||
26 | + @Bean | ||
27 | + public Docket createRestApi() { | ||
28 | + return new Docket(DocumentationType.SWAGGER_2) | ||
29 | + .apiInfo(apiInfo())//调用apiInfo方法,创建一个ApiInfo实例,里面是展示在文档页面信息内容 | ||
30 | + .select() | ||
31 | + //控制暴露出去的路径下的实例 | ||
32 | + //如果某个接口不想暴露,可以使用以下注解 | ||
33 | + //@ApiIgnore 这样,该接口就不会暴露在 swagger2 的页面下 | ||
34 | + .apis(RequestHandlerSelectors.basePackage("com.ectrip.cyt.controller")) | ||
35 | + .paths(PathSelectors.any()) | ||
36 | + .build(); | ||
37 | + } | ||
38 | + | ||
39 | + //构建 api文档的详细信息函数 | ||
40 | + private ApiInfo apiInfo() { | ||
41 | + return new ApiInfoBuilder() | ||
42 | + //页面标题 | ||
43 | + .title("整合营销-自测接口平台") | ||
44 | + //条款地址 | ||
45 | + .termsOfServiceUrl("http://despairyoke.github.io/") | ||
46 | + .version("1.0") | ||
47 | + //描述 | ||
48 | + .description("接口文档") | ||
49 | + .build(); | ||
50 | + } | ||
51 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/controller/TdosApiController.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/controller/TdosApiController.java | ||
1 | +package com.ectrip.cyt.controller; | ||
2 | + | ||
3 | +import com.alibaba.fastjson.JSONObject; | ||
4 | +import com.ectrip.cyt.client.cyt.service.TdosApiClient; | ||
5 | +import com.ectrip.cyt.model.*; | ||
6 | +import com.ectrip.cyt.model.Request; | ||
7 | +import com.ectrip.cyt.model.param.AccountParam; | ||
8 | +import com.ectrip.cyt.model.param.CreateOrderParam; | ||
9 | +import com.ectrip.cyt.model.param.ProductParam; | ||
10 | +import com.ectrip.cyt.model.pojo.Person; | ||
11 | +import com.ectrip.cyt.model.result.AjaxResult; | ||
12 | +import com.ectrip.cyt.model.result.Result; | ||
13 | +import com.ectrip.cyt.model.rt.CommonReturn; | ||
14 | +import com.ectrip.cyt.model.rt.PushOrderRequest; | ||
15 | +import com.ectrip.cyt.utils.DateUtils; | ||
16 | +import com.ectrip.cyt.utils.UUIDTools; | ||
17 | +import io.swagger.annotations.Api; | ||
18 | +import io.swagger.annotations.ApiOperation; | ||
19 | +import org.apache.commons.lang3.StringUtils; | ||
20 | +import org.springframework.validation.BindingResult; | ||
21 | +import org.springframework.web.bind.annotation.*; | ||
22 | +import org.springframework.web.bind.annotation.RequestBody; | ||
23 | +import org.springframework.web.bind.annotation.ResponseBody; | ||
24 | + | ||
25 | +import javax.validation.Valid; | ||
26 | +import java.util.*; | ||
27 | + | ||
28 | +@RestController | ||
29 | +@RequestMapping(value = "/tdos") | ||
30 | +@Api(value = "整合营销OTA自测接口",tags = {"整合营销OTA自测接口"}) | ||
31 | +public class TdosApiController { | ||
32 | + @ApiOperation(value = "心跳检测接口",notes = "心跳检测接口") | ||
33 | + @ResponseBody | ||
34 | + @PostMapping("/heartBeat") | ||
35 | + public AjaxResult heartBeat(@RequestBody @Valid Request request, BindingResult results) { | ||
36 | + AjaxResult ajaxResult = new AjaxResult(); | ||
37 | + ajaxResult.setSuccess(false); | ||
38 | + try { | ||
39 | + if (results.hasErrors()) { | ||
40 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
41 | + return ajaxResult; | ||
42 | + } | ||
43 | + Result result=TdosApiClient.heartBeat(request.getAccount()); | ||
44 | + if(result.isSuccess()) { | ||
45 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
46 | + ajaxResult.setSuccess(true); | ||
47 | + ajaxResult.setDescription("接口联通成功"); | ||
48 | + ajaxResult.setData(commonReturn); | ||
49 | + }else{ | ||
50 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
51 | + } | ||
52 | + } catch (Exception e) { | ||
53 | + e.printStackTrace(); | ||
54 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
55 | + } | ||
56 | + return ajaxResult; | ||
57 | + } | ||
58 | + | ||
59 | + | ||
60 | + @ApiOperation(value = "查询用户余额",notes = "获取产品接口") | ||
61 | + @ResponseBody | ||
62 | + @PostMapping("/getBalance") | ||
63 | + public AjaxResult getBalance(@RequestBody @Valid Request request, BindingResult results) { | ||
64 | + AjaxResult ajaxResult = new AjaxResult(); | ||
65 | + ajaxResult.setSuccess(false); | ||
66 | + try { | ||
67 | + if (results.hasErrors()) { | ||
68 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
69 | + return ajaxResult; | ||
70 | + } | ||
71 | + //判断方法类型 | ||
72 | + StringBuffer errorMsg=new StringBuffer(); | ||
73 | + if(StringUtils.isNotBlank(errorMsg)){ | ||
74 | + ajaxResult.setDescription(errorMsg.toString()); | ||
75 | + return ajaxResult; | ||
76 | + } | ||
77 | + Result result=TdosApiClient.getBalance(request.getAccount()); | ||
78 | + if(result.isSuccess()) { | ||
79 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
80 | + ajaxResult.setSuccess(true); | ||
81 | + ajaxResult.setDescription("接口联通成功"); | ||
82 | + ajaxResult.setData(commonReturn); | ||
83 | + }else{ | ||
84 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
85 | + } | ||
86 | + } catch (Exception e) { | ||
87 | + e.printStackTrace(); | ||
88 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
89 | + } | ||
90 | + return ajaxResult; | ||
91 | + } | ||
92 | + | ||
93 | + @ApiOperation(value = "获取景区接口",notes = "获取景区接口") | ||
94 | + @ResponseBody | ||
95 | + @PostMapping("/queryPois") | ||
96 | + public AjaxResult queryPois(@RequestBody @Valid Request request, BindingResult results) { | ||
97 | + AjaxResult ajaxResult = new AjaxResult(); | ||
98 | + ajaxResult.setSuccess(false); | ||
99 | + try { | ||
100 | + if (results.hasErrors()) { | ||
101 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
102 | + return ajaxResult; | ||
103 | + } | ||
104 | + Result result=TdosApiClient.queryPois(request.getAccount()); | ||
105 | + if(result.isSuccess()) { | ||
106 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
107 | + ajaxResult.setSuccess(true); | ||
108 | + ajaxResult.setDescription("接口联通成功"); | ||
109 | + ajaxResult.setData(commonReturn); | ||
110 | + }else{ | ||
111 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
112 | + } | ||
113 | + } catch (Exception e) { | ||
114 | + e.printStackTrace(); | ||
115 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
116 | + } | ||
117 | + return ajaxResult; | ||
118 | + } | ||
119 | + | ||
120 | + | ||
121 | + @ApiOperation(value = "获取产品接口",notes = "获取产品接口") | ||
122 | + @ResponseBody | ||
123 | + @PostMapping("/queryProducts") | ||
124 | + public AjaxResult queryProducts(@RequestBody @Valid GetProductRequest request, BindingResult results) { | ||
125 | + AjaxResult ajaxResult = new AjaxResult(); | ||
126 | + ajaxResult.setSuccess(false); | ||
127 | + try { | ||
128 | + if (results.hasErrors()) { | ||
129 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
130 | + return ajaxResult; | ||
131 | + } | ||
132 | + //判断方法类型 | ||
133 | + StringBuffer errorMsg=new StringBuffer(); | ||
134 | + if(StringUtils.isBlank(request.getQueryProducts().getResourceId())){ | ||
135 | + if(request.getQueryProducts().getCurrentPage()==null){ | ||
136 | + errorMsg.append("查询所有可分销商品时,未设置页数"); | ||
137 | + }else{ | ||
138 | + if(request.getQueryProducts().getCurrentPage()<=0){ | ||
139 | + errorMsg.append("查询所有可分销商品时,设置页数必须大于0"); | ||
140 | + } | ||
141 | + } | ||
142 | + if(request.getQueryProducts().getPageSize()==null){ | ||
143 | + errorMsg.append("查询所有可分销商品时,未设置每页条数"); | ||
144 | + }else{ | ||
145 | + if(request.getQueryProducts().getPageSize()>5||request.getQueryProducts().getPageSize()<=0){ | ||
146 | + errorMsg.append("查询所有可分销商品时,每页条数范围在[1,5]内"); | ||
147 | + } | ||
148 | + } | ||
149 | + } | ||
150 | + | ||
151 | + if(StringUtils.isNotBlank(errorMsg)){ | ||
152 | + ajaxResult.setDescription(errorMsg.toString()); | ||
153 | + return ajaxResult; | ||
154 | + } | ||
155 | + | ||
156 | + /*if(request.getQueryProducts().getMethod().equals("SINGLE")){ | ||
157 | + if(!StringUtils.isBlank(request.getQueryProducts().getResourceId())){ | ||
158 | + ajaxResult.setDescription("获取产品方法为单个时, 产品ID必填"); | ||
159 | + return ajaxResult; | ||
160 | + } | ||
161 | + }*/ | ||
162 | + Result result=TdosApiClient.queryProducts(request.getQueryProducts(),request.getAccount()); | ||
163 | + if(result.isSuccess()) { | ||
164 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
165 | + ajaxResult.setSuccess(true); | ||
166 | + ajaxResult.setDescription("接口联通成功"); | ||
167 | + ajaxResult.setData(commonReturn); | ||
168 | + }else{ | ||
169 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
170 | + } | ||
171 | + } catch (Exception e) { | ||
172 | + e.printStackTrace(); | ||
173 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
174 | + } | ||
175 | + return ajaxResult; | ||
176 | + } | ||
177 | + | ||
178 | + @ApiOperation(value = "获取库存接口",notes = "获取库存接口") | ||
179 | + @ResponseBody | ||
180 | + @PostMapping("/queryStock") | ||
181 | + public AjaxResult queryStock(@RequestBody @Valid GetStockRequest request, BindingResult results) { | ||
182 | + AjaxResult ajaxResult = new AjaxResult(); | ||
183 | + ajaxResult.setSuccess(false); | ||
184 | + try { | ||
185 | + if (results.hasErrors()) { | ||
186 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
187 | + return ajaxResult; | ||
188 | + } | ||
189 | + Result result=TdosApiClient.queryStockAndTsds(request.getGetStockParam(),request.getAccount()); | ||
190 | + if(result.isSuccess()) { | ||
191 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
192 | + ajaxResult.setSuccess(true); | ||
193 | + ajaxResult.setDescription("接口联通成功"); | ||
194 | + ajaxResult.setData(commonReturn); | ||
195 | + }else{ | ||
196 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
197 | + } | ||
198 | + } catch (Exception e) { | ||
199 | + e.printStackTrace(); | ||
200 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
201 | + } | ||
202 | + return ajaxResult; | ||
203 | + } | ||
204 | + | ||
205 | + /*@ApiOperation(value = "获取座位接口",notes = "获取座位接口") | ||
206 | + @ResponseBody | ||
207 | + @PostMapping("/querySeatList") | ||
208 | + public AjaxResult querySeatList(@RequestBody @Valid GetSeatRequset request, BindingResult results) { | ||
209 | + AjaxResult ajaxResult = new AjaxResult(); | ||
210 | + ajaxResult.setSuccess(false); | ||
211 | + try { | ||
212 | + if (results.hasErrors()) { | ||
213 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
214 | + return ajaxResult; | ||
215 | + } | ||
216 | + Result result=TdosApiClient.querySeatList(request.getGetSeatParam(),request.getAccount()); | ||
217 | + if(result.isSuccess()) { | ||
218 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
219 | + ajaxResult.setSuccess(true); | ||
220 | + ajaxResult.setDescription("接口联通成功"); | ||
221 | + ajaxResult.setData(commonReturn); | ||
222 | + }else{ | ||
223 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
224 | + } | ||
225 | + } catch (Exception e) { | ||
226 | + e.printStackTrace(); | ||
227 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
228 | + } | ||
229 | + return ajaxResult; | ||
230 | + }*/ | ||
231 | + | ||
232 | + @ApiOperation(value = "重发短信接口",notes = "重发短信接口") | ||
233 | + @ResponseBody | ||
234 | + @PostMapping("/sendOrderEticket") | ||
235 | + public AjaxResult sendOrderEticket(@RequestBody @Valid SendOrderEticketRequest request, BindingResult results) { | ||
236 | + AjaxResult ajaxResult = new AjaxResult(); | ||
237 | + ajaxResult.setSuccess(false); | ||
238 | + try { | ||
239 | + if (results.hasErrors()) { | ||
240 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
241 | + return ajaxResult; | ||
242 | + } | ||
243 | + Result result=TdosApiClient.sendOrderEticket(request.getParam(),request.getAccount()); | ||
244 | + if(result.isSuccess()) { | ||
245 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
246 | + ajaxResult.setSuccess(true); | ||
247 | + ajaxResult.setDescription("接口联通成功"); | ||
248 | + ajaxResult.setData(commonReturn); | ||
249 | + }else{ | ||
250 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
251 | + } | ||
252 | + } catch (Exception e) { | ||
253 | + e.printStackTrace(); | ||
254 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
255 | + } | ||
256 | + return ajaxResult; | ||
257 | + } | ||
258 | + | ||
259 | + @ApiOperation(value = "下单接口",notes = "下单接口") | ||
260 | + @ResponseBody | ||
261 | + @PostMapping("/createOrder") | ||
262 | + public AjaxResult createOrder(@RequestBody @Valid CreateOrderRequest request, BindingResult results) { | ||
263 | + AjaxResult ajaxResult = new AjaxResult(); | ||
264 | + ajaxResult.setSuccess(false); | ||
265 | + try { | ||
266 | + if (results.hasErrors()) { | ||
267 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
268 | + return ajaxResult; | ||
269 | + } | ||
270 | + Result result=TdosApiClient.createOrder(request.getCreateOrder(),request.getAccount()); | ||
271 | + if(result.isSuccess()) { | ||
272 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
273 | + ajaxResult.setSuccess(true); | ||
274 | + ajaxResult.setDescription("接口联通成功"); | ||
275 | + ajaxResult.setData(commonReturn); | ||
276 | + }else{ | ||
277 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
278 | + } | ||
279 | + } catch (Exception e) { | ||
280 | + e.printStackTrace(); | ||
281 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
282 | + } | ||
283 | + return ajaxResult; | ||
284 | + } | ||
285 | + | ||
286 | + | ||
287 | + @ApiOperation(value = "查询订单接口",notes = "查询订单接口") | ||
288 | + @ResponseBody | ||
289 | + @PostMapping("/queryOrder") | ||
290 | + public AjaxResult queryOrder(@RequestBody @Valid QueryOrderRequest request, BindingResult results) { | ||
291 | + AjaxResult ajaxResult = new AjaxResult(); | ||
292 | + ajaxResult.setSuccess(false); | ||
293 | + try { | ||
294 | + if (results.hasErrors()) { | ||
295 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
296 | + return ajaxResult; | ||
297 | + } | ||
298 | + //判断订单状态 | ||
299 | + Result result=TdosApiClient.queryOrder(request.getQueryOrder(),request.getAccount()); | ||
300 | + if(result.isSuccess()) { | ||
301 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
302 | + ajaxResult.setSuccess(true); | ||
303 | + ajaxResult.setDescription("接口联通成功"); | ||
304 | + ajaxResult.setData(commonReturn); | ||
305 | + }else{ | ||
306 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
307 | + } | ||
308 | + } catch (Exception e) { | ||
309 | + e.printStackTrace(); | ||
310 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
311 | + } | ||
312 | + return ajaxResult; | ||
313 | + } | ||
314 | + | ||
315 | + | ||
316 | + @ApiOperation(value = "改签接口",notes = "改签接口") | ||
317 | + @ResponseBody | ||
318 | + @PostMapping("/pushOrder") | ||
319 | + public AjaxResult pushOrder(@RequestBody @Valid PushOrderRequest request, BindingResult results) { | ||
320 | + AjaxResult ajaxResult = new AjaxResult(); | ||
321 | + ajaxResult.setSuccess(false); | ||
322 | + try { | ||
323 | + if (results.hasErrors()) { | ||
324 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
325 | + return ajaxResult; | ||
326 | + } | ||
327 | + Result result=TdosApiClient.pushOrder(request.getPushOrder(),request.getAccount()); | ||
328 | + if(result.isSuccess()) { | ||
329 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
330 | + ajaxResult.setSuccess(true); | ||
331 | + ajaxResult.setDescription("接口联通成功"); | ||
332 | + ajaxResult.setData(commonReturn); | ||
333 | + }else{ | ||
334 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
335 | + } | ||
336 | + } catch (Exception e) { | ||
337 | + e.printStackTrace(); | ||
338 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
339 | + } | ||
340 | + return ajaxResult; | ||
341 | + } | ||
342 | + | ||
343 | + @ApiOperation(value = "申请退订接口",notes = "申请退订接口") | ||
344 | + @ResponseBody | ||
345 | + @PostMapping("/refundOrder") | ||
346 | + public AjaxResult refundOrder(@RequestBody @Valid RefundOrderRequest request, BindingResult results) { | ||
347 | + AjaxResult ajaxResult = new AjaxResult(); | ||
348 | + ajaxResult.setSuccess(false); | ||
349 | + try { | ||
350 | + if (results.hasErrors()) { | ||
351 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
352 | + return ajaxResult; | ||
353 | + } | ||
354 | + Result result=TdosApiClient.applyOrderRefundByUser(request.getRefundOrder(),request.getAccount()); | ||
355 | + if(result.isSuccess()) { | ||
356 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
357 | + ajaxResult.setSuccess(true); | ||
358 | + ajaxResult.setDescription("接口联通成功"); | ||
359 | + ajaxResult.setData(commonReturn); | ||
360 | + }else{ | ||
361 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
362 | + } | ||
363 | + } catch (Exception e) { | ||
364 | + e.printStackTrace(); | ||
365 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
366 | + } | ||
367 | + return ajaxResult; | ||
368 | + } | ||
369 | + | ||
370 | + @ApiOperation(value = "取消订单接口",notes = "取消订单接口") | ||
371 | + @ResponseBody | ||
372 | + @PostMapping("/cancelOrder") | ||
373 | + public AjaxResult cancelOrder(@RequestBody @Valid CancelOrderRequest request, BindingResult results) { | ||
374 | + AjaxResult ajaxResult = new AjaxResult(); | ||
375 | + ajaxResult.setSuccess(false); | ||
376 | + try { | ||
377 | + if (results.hasErrors()) { | ||
378 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
379 | + return ajaxResult; | ||
380 | + } | ||
381 | + Result result=TdosApiClient.cancelOrder(request.getCancelOrder(),request.getAccount()); | ||
382 | + if(result.isSuccess()) { | ||
383 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
384 | + ajaxResult.setSuccess(true); | ||
385 | + ajaxResult.setDescription("接口联通成功"); | ||
386 | + ajaxResult.setData(commonReturn); | ||
387 | + }else{ | ||
388 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
389 | + } | ||
390 | + } catch (Exception e) { | ||
391 | + e.printStackTrace(); | ||
392 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
393 | + } | ||
394 | + return ajaxResult; | ||
395 | + } | ||
396 | + | ||
397 | + @ApiOperation(value = "支付接口",notes = "支付接口") | ||
398 | + @ResponseBody | ||
399 | + @PostMapping("/payOrder") | ||
400 | + public AjaxResult payOrder(@RequestBody @Valid PayOrderRequest request, BindingResult results) { | ||
401 | + AjaxResult ajaxResult = new AjaxResult(); | ||
402 | + ajaxResult.setSuccess(false); | ||
403 | + try { | ||
404 | + if (results.hasErrors()) { | ||
405 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
406 | + return ajaxResult; | ||
407 | + } | ||
408 | + Result result=TdosApiClient.payOrder(request.getPayOrder(),request.getAccount()); | ||
409 | + if(result.isSuccess()) { | ||
410 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
411 | + ajaxResult.setSuccess(true); | ||
412 | + ajaxResult.setDescription("接口联通成功"); | ||
413 | + ajaxResult.setData(commonReturn); | ||
414 | + }else{ | ||
415 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
416 | + } | ||
417 | + } catch (Exception e) { | ||
418 | + e.printStackTrace(); | ||
419 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
420 | + } | ||
421 | + return ajaxResult; | ||
422 | + } | ||
423 | + | ||
424 | + @ApiOperation(value = "下单前校验接口",notes = "下单前校验接口") | ||
425 | + @ResponseBody | ||
426 | + @PostMapping("/checkOrder") | ||
427 | + public AjaxResult checkOrder(@RequestBody @Valid CreateOrderRequest request, BindingResult results) { | ||
428 | + AjaxResult ajaxResult = new AjaxResult(); | ||
429 | + ajaxResult.setSuccess(false); | ||
430 | + try { | ||
431 | + if (results.hasErrors()) { | ||
432 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
433 | + return ajaxResult; | ||
434 | + } | ||
435 | + Result result=TdosApiClient.checkOrder(request.getCreateOrder(),request.getAccount()); | ||
436 | + if(result.isSuccess()) { | ||
437 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
438 | + ajaxResult.setSuccess(true); | ||
439 | + ajaxResult.setDescription("接口联通成功"); | ||
440 | + ajaxResult.setData(commonReturn); | ||
441 | + }else{ | ||
442 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
443 | + } | ||
444 | + } catch (Exception e) { | ||
445 | + e.printStackTrace(); | ||
446 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
447 | + } | ||
448 | + return ajaxResult; | ||
449 | + } | ||
450 | + | ||
451 | + @ApiOperation(value = "下单并支付接口",notes = "下单并支付接口") | ||
452 | + @ResponseBody | ||
453 | + @PostMapping("/createPaymentOrder") | ||
454 | + public AjaxResult createPaymentOrder(@RequestBody @Valid CreateOrderRequest request, BindingResult results) { | ||
455 | + AjaxResult ajaxResult = new AjaxResult(); | ||
456 | + ajaxResult.setSuccess(false); | ||
457 | + try { | ||
458 | + if (results.hasErrors()) { | ||
459 | + ajaxResult.setDescription("请求参数错误:"+results.getFieldError().getDefaultMessage()); | ||
460 | + return ajaxResult; | ||
461 | + } | ||
462 | + Result result=TdosApiClient.createPaymentOrder(request.getCreateOrder(),request.getAccount()); | ||
463 | + if(result.isSuccess()) { | ||
464 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
465 | + ajaxResult.setSuccess(true); | ||
466 | + ajaxResult.setDescription("接口联通成功"); | ||
467 | + ajaxResult.setData(commonReturn); | ||
468 | + }else{ | ||
469 | + ajaxResult.setDescription("接口联通失败,错误原因:"+result.getDescription()); | ||
470 | + } | ||
471 | + } catch (Exception e) { | ||
472 | + e.printStackTrace(); | ||
473 | + ajaxResult.setDescription("接口联通异常!"+e.getMessage()); | ||
474 | + } | ||
475 | + return ajaxResult; | ||
476 | + } | ||
477 | + | ||
478 | + @ApiOperation(value = "批量下单测试接口",notes = "批量下单测试接口") | ||
479 | + @ResponseBody | ||
480 | + @PostMapping("/testCreateOrders") | ||
481 | + public Object testCreateOrders() { | ||
482 | + JSONObject returnJson=new JSONObject(); | ||
483 | + String otaCode = UUIDTools.get16UUID(); | ||
484 | + returnJson.put("ota订单号",otaCode); | ||
485 | + CreateOrderRequest request=new CreateOrderRequest(); | ||
486 | + CreateOrderParam createOrder=new CreateOrderParam(); | ||
487 | + createOrder.setOrderCode(otaCode); | ||
488 | + createOrder.setVisitDate(DateUtils.formatDate(DateUtils.today())); | ||
489 | + | ||
490 | + ProductParam productParam=new ProductParam(); | ||
491 | + productParam.setProductNo("21"); | ||
492 | + productParam.setSellPrice(0.01); | ||
493 | + createOrder.setProduct(productParam); | ||
494 | + | ||
495 | + createOrder.setOrderQuantity(2); | ||
496 | + createOrder.setOrderPrice(createOrder.getOrderQuantity()*productParam.getSellPrice()); | ||
497 | + | ||
498 | + Person person=new Person(); | ||
499 | + person.setName("测试A"); | ||
500 | + person.setCredentialsType(0); | ||
501 | + person.setCredentials("445222199608083833"); | ||
502 | + person.setPhone("15622980172"); | ||
503 | + | ||
504 | + Person personB=new Person(); | ||
505 | + personB.setName("测试B"); | ||
506 | + personB.setCredentialsType(0); | ||
507 | + personB.setCredentials("110101199003070476"); | ||
508 | + personB.setPhone("15622980172"); | ||
509 | + | ||
510 | + List<Person> persons=new ArrayList<Person>(); | ||
511 | + persons.add(person); | ||
512 | + persons.add(personB); | ||
513 | + | ||
514 | + createOrder.setContactPerson(person); | ||
515 | + createOrder.setVisitPersons(persons); | ||
516 | + | ||
517 | + AccountParam account=new AccountParam(); | ||
518 | + account.setDistributorName("binFxs"); | ||
519 | + account.setIdentity(""); | ||
520 | + account.setKey("12345678"); | ||
521 | + account.setUrl("http://127.0.0.1:8080/service_/distributor_.do"); | ||
522 | + | ||
523 | + request.setCreateOrder(createOrder); | ||
524 | + request.setAccount(account); | ||
525 | + | ||
526 | + | ||
527 | + AjaxResult ajaxResult = new AjaxResult(); | ||
528 | + ajaxResult.setSuccess(false); | ||
529 | + | ||
530 | + String cytCode=""; | ||
531 | + | ||
532 | + try { | ||
533 | + Result result=TdosApiClient.createPaymentOrder(request.getCreateOrder(),request.getAccount()); | ||
534 | + if(result.isSuccess()) { | ||
535 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
536 | + cytCode= commonReturn.getCytOrderCode(); | ||
537 | + returnJson.put("畅游通订单号",cytCode); | ||
538 | + returnJson.put("下单",commonReturn); | ||
539 | + }else{ | ||
540 | + return "下单接口联通失败,错误原因:"+result.getDescription(); | ||
541 | + } | ||
542 | + } catch (Exception e) { | ||
543 | + e.printStackTrace(); | ||
544 | + return"下单接口联通异常!"+e.getMessage(); | ||
545 | + } | ||
546 | + | ||
547 | + /*PayOrderParam payOrderParam=new PayOrderParam(); | ||
548 | + payOrderParam.setCytOrderCode(cytCode); | ||
549 | + payOrderParam.setOrderPrice(createOrder.getOrderQuantity()*productParam.getSellPrice()); | ||
550 | + | ||
551 | + try { | ||
552 | + Result result=TdosApiClient.payOrder(payOrderParam,request.getAccount()); | ||
553 | + if(result.isSuccess()) { | ||
554 | + CommonReturn commonReturn=(CommonReturn)result.getData(); | ||
555 | + returnJson.put("支付",commonReturn); | ||
556 | + }else{ | ||
557 | + return "支付接口联通失败,错误原因:"+result.getDescription(); | ||
558 | + } | ||
559 | + } catch (Exception e) { | ||
560 | + e.printStackTrace(); | ||
561 | + return"支付接口联通异常!"+e.getMessage(); | ||
562 | + }*/ | ||
563 | + return returnJson; | ||
564 | + } | ||
565 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/exception/BusinessException.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/exception/BusinessException.java | ||
1 | +package com.ectrip.cyt.exception; | ||
2 | + | ||
3 | +/** | ||
4 | + * 业务异常信息 | ||
5 | + * | ||
6 | + * @author changjiang.tang Date:8/18/15 Time:5:33 PM | ||
7 | + */ | ||
8 | +public class BusinessException extends RuntimeException{ | ||
9 | + | ||
10 | + private static final long serialVersionUID = 6401507641198338287L; | ||
11 | + | ||
12 | + /** 异常代码 */ | ||
13 | + protected String code; | ||
14 | + | ||
15 | + /** 异常消息 */ | ||
16 | + protected String message; | ||
17 | + | ||
18 | + @Override | ||
19 | + public String getMessage() { | ||
20 | + return message; | ||
21 | + } | ||
22 | + | ||
23 | + public void setMessage(String message) { | ||
24 | + this.message = message; | ||
25 | + } | ||
26 | + | ||
27 | + public String getCode() { | ||
28 | + return code; | ||
29 | + } | ||
30 | + | ||
31 | + public void setCode(String code) { | ||
32 | + this.code = code; | ||
33 | + } | ||
34 | + | ||
35 | + public BusinessException() { | ||
36 | + super(); | ||
37 | + } | ||
38 | + | ||
39 | + public BusinessException(String message) { | ||
40 | + this("99999", message); | ||
41 | + } | ||
42 | + | ||
43 | + public BusinessException(String code, String message) { | ||
44 | + super(message); | ||
45 | + this.code = code; | ||
46 | + this.message = message; | ||
47 | + } | ||
48 | + | ||
49 | + public BusinessException(String message, Throwable cause) { | ||
50 | + this("99999", message, cause); | ||
51 | + } | ||
52 | + | ||
53 | + public BusinessException(String code, String message, Throwable cause) { | ||
54 | + super(message, cause); | ||
55 | + this.code = code; | ||
56 | + this.message = message; | ||
57 | + } | ||
58 | + | ||
59 | + public BusinessException(Throwable cause) { | ||
60 | + super(cause); | ||
61 | + } | ||
62 | + | ||
63 | + @Override | ||
64 | + public String toString() { | ||
65 | + return "错误代码: " + code + ", 描述: " + message; | ||
66 | + } | ||
67 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/CancelOrderRequest.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/CancelOrderRequest.java | ||
1 | +package com.ectrip.cyt.model; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.param.CancelOrderParam; | ||
4 | +import com.ectrip.cyt.model.param.PayOrderParam; | ||
5 | +import io.swagger.annotations.ApiModel; | ||
6 | +import lombok.AllArgsConstructor; | ||
7 | +import lombok.Data; | ||
8 | +import lombok.NoArgsConstructor; | ||
9 | + | ||
10 | +import javax.validation.Valid; | ||
11 | +import javax.validation.constraints.NotNull; | ||
12 | + | ||
13 | +@Data | ||
14 | +@AllArgsConstructor | ||
15 | +@NoArgsConstructor | ||
16 | +@ApiModel(description = "取消订单参数") | ||
17 | +public class CancelOrderRequest extends Request { | ||
18 | + @Valid | ||
19 | + @NotNull(message = "必须传入取消订单参数") | ||
20 | + private CancelOrderParam cancelOrder; | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/CreateOrderRequest.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/CreateOrderRequest.java | ||
1 | +package com.ectrip.cyt.model; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.param.CreateOrderParam; | ||
4 | +import io.swagger.annotations.ApiModel; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import javax.validation.Valid; | ||
10 | +import javax.validation.constraints.NotNull; | ||
11 | + | ||
12 | +@Data | ||
13 | +@AllArgsConstructor | ||
14 | +@NoArgsConstructor | ||
15 | +@ApiModel(description = "下单请求参数") | ||
16 | +public class CreateOrderRequest extends Request { | ||
17 | + @Valid | ||
18 | + @NotNull(message = "必须传入下单参数") | ||
19 | + private CreateOrderParam createOrder; | ||
20 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/GetProductRequest.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/GetProductRequest.java | ||
1 | +package com.ectrip.cyt.model; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.param.GetProductParam; | ||
4 | +import io.swagger.annotations.ApiModel; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import javax.validation.Valid; | ||
10 | +import javax.validation.constraints.NotNull; | ||
11 | + | ||
12 | +@Data | ||
13 | +@AllArgsConstructor | ||
14 | +@NoArgsConstructor | ||
15 | +@ApiModel(description = "获取产品参数") | ||
16 | +public class GetProductRequest extends Request { | ||
17 | + @Valid | ||
18 | + @NotNull(message = "必须传入获取产品参数") | ||
19 | + private GetProductParam queryProducts; | ||
20 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/GetSeatRequset.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/GetSeatRequset.java | ||
1 | +package com.ectrip.cyt.model; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.param.GetSeatParam; | ||
4 | +import com.ectrip.cyt.model.param.GetStockParam; | ||
5 | +import io.swagger.annotations.ApiModel; | ||
6 | +import lombok.AllArgsConstructor; | ||
7 | +import lombok.Data; | ||
8 | +import lombok.NoArgsConstructor; | ||
9 | + | ||
10 | +import javax.validation.Valid; | ||
11 | +import javax.validation.constraints.NotNull; | ||
12 | + | ||
13 | +@Data | ||
14 | +@AllArgsConstructor | ||
15 | +@NoArgsConstructor | ||
16 | +@ApiModel(description = "获取座位参数") | ||
17 | +public class GetSeatRequset extends Request { | ||
18 | + @Valid | ||
19 | + @NotNull(message = "必须传入座位参数") | ||
20 | + private GetSeatParam getSeatParam; | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/GetStockRequest.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/GetStockRequest.java | ||
1 | +package com.ectrip.cyt.model; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.param.GetProductParam; | ||
4 | +import com.ectrip.cyt.model.param.GetStockParam; | ||
5 | +import io.swagger.annotations.ApiModel; | ||
6 | +import lombok.AllArgsConstructor; | ||
7 | +import lombok.Data; | ||
8 | +import lombok.NoArgsConstructor; | ||
9 | + | ||
10 | +import javax.validation.Valid; | ||
11 | +import javax.validation.constraints.NotNull; | ||
12 | + | ||
13 | +@Data | ||
14 | +@AllArgsConstructor | ||
15 | +@NoArgsConstructor | ||
16 | +@ApiModel(description = "获取产品参数") | ||
17 | +public class GetStockRequest extends Request { | ||
18 | + @Valid | ||
19 | + @NotNull(message = "必须传入获取产品参数") | ||
20 | + private GetStockParam getStockParam; | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/PayOrderRequest.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/PayOrderRequest.java | ||
1 | +package com.ectrip.cyt.model; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.param.PayOrderParam; | ||
4 | +import io.swagger.annotations.ApiModel; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import javax.validation.Valid; | ||
10 | +import javax.validation.constraints.NotNull; | ||
11 | + | ||
12 | +@Data | ||
13 | +@AllArgsConstructor | ||
14 | +@NoArgsConstructor | ||
15 | +@ApiModel(description = "支付订单参数") | ||
16 | +public class PayOrderRequest extends Request { | ||
17 | + @Valid | ||
18 | + @NotNull(message = "必须传入支付订单参数") | ||
19 | + private PayOrderParam payOrder; | ||
20 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/QueryOrderRequest.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/QueryOrderRequest.java | ||
1 | +package com.ectrip.cyt.model; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.param.QueryOrderParam; | ||
4 | +import io.swagger.annotations.ApiModel; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import javax.validation.Valid; | ||
10 | +import javax.validation.constraints.NotNull; | ||
11 | + | ||
12 | +@Data | ||
13 | +@AllArgsConstructor | ||
14 | +@NoArgsConstructor | ||
15 | +@ApiModel(description = "查询订单参数") | ||
16 | +public class QueryOrderRequest extends Request { | ||
17 | + @Valid | ||
18 | + @NotNull(message = "必须传入查询订单参数") | ||
19 | + private QueryOrderParam queryOrder; | ||
20 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/RefundOrderRequest.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/RefundOrderRequest.java | ||
1 | +package com.ectrip.cyt.model; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.param.RefundOrderParam; | ||
4 | +import io.swagger.annotations.ApiModel; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import javax.validation.Valid; | ||
10 | +import javax.validation.constraints.NotNull; | ||
11 | + | ||
12 | +@Data | ||
13 | +@AllArgsConstructor | ||
14 | +@NoArgsConstructor | ||
15 | +@ApiModel(description = "退订请求参数") | ||
16 | +public class RefundOrderRequest extends Request { | ||
17 | + @Valid | ||
18 | + @NotNull(message = "必须传入退订参数") | ||
19 | + private RefundOrderParam refundOrder; | ||
20 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/Request.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/Request.java | ||
1 | +package com.ectrip.cyt.model; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.param.AccountParam; | ||
4 | +import lombok.AllArgsConstructor; | ||
5 | +import lombok.Data; | ||
6 | +import lombok.NoArgsConstructor; | ||
7 | + | ||
8 | + | ||
9 | +import javax.validation.Valid; | ||
10 | +import javax.validation.constraints.NotNull; | ||
11 | + | ||
12 | + | ||
13 | +@Data | ||
14 | +@AllArgsConstructor | ||
15 | +@NoArgsConstructor | ||
16 | +//通用请求参数 | ||
17 | +public class Request { | ||
18 | + @Valid | ||
19 | + @NotNull(message = "必须传入分销用户信息") | ||
20 | + private AccountParam account; | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/SendOrderEticketRequest.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/SendOrderEticketRequest.java | ||
1 | +package com.ectrip.cyt.model; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.param.CreateOrderParam; | ||
4 | +import com.ectrip.cyt.model.param.SendOrderEticketParam; | ||
5 | +import io.swagger.annotations.ApiModel; | ||
6 | +import lombok.AllArgsConstructor; | ||
7 | +import lombok.Data; | ||
8 | +import lombok.NoArgsConstructor; | ||
9 | + | ||
10 | +import javax.validation.Valid; | ||
11 | +import javax.validation.constraints.NotNull; | ||
12 | + | ||
13 | +@Data | ||
14 | +@AllArgsConstructor | ||
15 | +@NoArgsConstructor | ||
16 | +@ApiModel(description = "重发短信") | ||
17 | +public class SendOrderEticketRequest extends Request { | ||
18 | + @Valid | ||
19 | + @NotNull(message = "必须传入下单参数") | ||
20 | + private SendOrderEticketParam param; | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/enums/ApiMethodType.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/enums/ApiMethodType.java | ||
1 | +package com.ectrip.cyt.model.enums; | ||
2 | + | ||
3 | +public enum ApiMethodType { | ||
4 | + HEART_BEAT("heartBeat","同步订单"), | ||
5 | + get_Balance("getBalance","获取余额"), | ||
6 | + PUSH_ORDER("pushOrder","同步订单"), | ||
7 | + CHECK_ORDER("checkOrder","下单前校验"), | ||
8 | + GET_ORDER_BY_OTA("getOrderByOTA","查询订单信息"), | ||
9 | + APPLY_ORDER_REFUND_BY_USER( "applyOrderRefundByUser","申请退订"), | ||
10 | + CREATE_ORDER ("createOrder","创建订单"), | ||
11 | + CREATE_PAY_ORDER ("createPaymentOrder","创建订单"), | ||
12 | + PAY_ORDER ("payOrder","支付订单"), | ||
13 | + CANCEL_ORDER ("cancelOrder","取消订单"), | ||
14 | + GET_PRODUCT_BY_OTA("getProductByOTA","获取产品"), | ||
15 | + GET_AVAILABLE_PRODUCT("getAvailableProduct","获取POI"), | ||
16 | + GET_STOCK_PRODUCT_INFO("getStockProductInfo","获取库存"), | ||
17 | + GET_SEAT_INFO("getSeatInfo","获取库存"), | ||
18 | + SEND_ORDER_ETICKET("sendOrderEticket","重发短信"); | ||
19 | + | ||
20 | + /** | ||
21 | + * 类型 | ||
22 | + */ | ||
23 | + private String type; | ||
24 | + | ||
25 | + /** | ||
26 | + * 名称 | ||
27 | + */ | ||
28 | + private String name; | ||
29 | + | ||
30 | + /** | ||
31 | + * 构造函数,枚举类型构造函数只能私有 | ||
32 | + */ | ||
33 | + ApiMethodType(String type, String name) { | ||
34 | + this.type = type; | ||
35 | + this.name = name; | ||
36 | + } | ||
37 | + | ||
38 | + public String getType() { | ||
39 | + return this.type; | ||
40 | + } | ||
41 | + | ||
42 | + public String getName() { | ||
43 | + return this.name; | ||
44 | + } | ||
45 | + | ||
46 | + /** | ||
47 | + * 根据类型获取枚举对象 | ||
48 | + * | ||
49 | + * @param type 枚举类型值 | ||
50 | + * @return 枚举对象 | ||
51 | + */ | ||
52 | + public static ApiMethodType typeOf(String type) { | ||
53 | + for(ApiMethodType apiMethodType : values()) { | ||
54 | + if(apiMethodType.getType().equals(type)) { | ||
55 | + return apiMethodType; | ||
56 | + } | ||
57 | + } | ||
58 | + throw new IllegalArgumentException("Invalid ApiMethodType type: " + type); | ||
59 | + } | ||
60 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/enums/CredentialsType.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/enums/CredentialsType.java | ||
1 | +package com.ectrip.cyt.model.enums; | ||
2 | + | ||
3 | +import java.util.HashMap; | ||
4 | +import java.util.Map; | ||
5 | + | ||
6 | +/** | ||
7 | + * 游客证件类型枚举:(身份证 : ID_CARD,护照 : HUZHAO,台胞证 : TAIBAO ,港澳通行证: GANGAO 其它:OTHER) | ||
8 | + * Created by weiyu.huang on 2015/9/2. | ||
9 | + */ | ||
10 | +public enum CredentialsType { | ||
11 | + | ||
12 | + /** | ||
13 | + * 身份证 | ||
14 | + */ | ||
15 | + ID_CARD(0, "身份证"), | ||
16 | + | ||
17 | + /** | ||
18 | + * 护照 | ||
19 | + */ | ||
20 | + HUZHAO(1, "护照 PASSPORT"), | ||
21 | + | ||
22 | + /** | ||
23 | + * 军官证 | ||
24 | + */ | ||
25 | + OFFICER(2, "军官证"), | ||
26 | + | ||
27 | + /** | ||
28 | + * 台胞证 | ||
29 | + */ | ||
30 | + TAIBAO(3, "台胞证"), | ||
31 | + | ||
32 | + /** | ||
33 | + * 港澳通行证 | ||
34 | + */ | ||
35 | + GANGAO(4, "港澳通行证"), | ||
36 | + | ||
37 | + /** | ||
38 | + * 其它 | ||
39 | + */ | ||
40 | + OTHER(5, "其它"), | ||
41 | + | ||
42 | + /** | ||
43 | + * 皈依证 | ||
44 | + */ | ||
45 | + GUIYI(6, "皈依证"), | ||
46 | + | ||
47 | + /** | ||
48 | + * 学生证 | ||
49 | + */ | ||
50 | + STUDENT(7,"学生证"); | ||
51 | + | ||
52 | + /** | ||
53 | + * 类型 | ||
54 | + */ | ||
55 | + private int type; | ||
56 | + | ||
57 | + /** | ||
58 | + * 名称 | ||
59 | + */ | ||
60 | + private String name; | ||
61 | + | ||
62 | + /** | ||
63 | + * 构造函数,枚举类型构造函数只能私有 | ||
64 | + */ | ||
65 | + CredentialsType(int type, String name) { | ||
66 | + this.type = type; | ||
67 | + this.name = name; | ||
68 | + } | ||
69 | + | ||
70 | + public int getType() { | ||
71 | + return this.type; | ||
72 | + } | ||
73 | + | ||
74 | + public String getName() { | ||
75 | + return this.name; | ||
76 | + } | ||
77 | + | ||
78 | + /** | ||
79 | + * 根据类型获取枚举对象 | ||
80 | + * | ||
81 | + * @param type 枚举类型值 | ||
82 | + * @return 枚举对象 | ||
83 | + */ | ||
84 | + public static CredentialsType typeOf(int type) { | ||
85 | + for(CredentialsType credentialsType : values()) { | ||
86 | + if(credentialsType.getType() == type) { | ||
87 | + return credentialsType; | ||
88 | + } | ||
89 | + } | ||
90 | + throw new IllegalArgumentException("Invalid CredentialsType type: " + type); | ||
91 | + } | ||
92 | + | ||
93 | + /** | ||
94 | + * 枚举转成 Map | ||
95 | + * @return Map | ||
96 | + */ | ||
97 | + public static Map<Integer, Object> convertToMap() { | ||
98 | + Map<Integer, Object> map = new HashMap<Integer, Object>(); | ||
99 | + for(CredentialsType credentialsType : values()) { | ||
100 | + map.put(credentialsType.getType(), credentialsType.getName()); | ||
101 | + } | ||
102 | + return map; | ||
103 | + } | ||
104 | + | ||
105 | + /** | ||
106 | + * 判断是否存在该证件类型值 | ||
107 | + * @param type 证件类型值 | ||
108 | + * @return true/false | ||
109 | + */ | ||
110 | + public static boolean contains(int type) { | ||
111 | + return CredentialsType.convertToMap().containsKey(type); | ||
112 | + } | ||
113 | + | ||
114 | + @Override | ||
115 | + public String toString() { | ||
116 | + return "CredentialsType{" + | ||
117 | + "type=" + type + | ||
118 | + ", name='" + name + '\'' + | ||
119 | + '}'; | ||
120 | + } | ||
121 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/enums/OrderStatusType.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/enums/OrderStatusType.java | ||
1 | +package com.ectrip.cyt.model.enums; | ||
2 | + | ||
3 | +import java.util.ArrayList; | ||
4 | +import java.util.HashMap; | ||
5 | +import java.util.List; | ||
6 | +import java.util.Map; | ||
7 | + | ||
8 | +/** | ||
9 | + * 订单状态 | ||
10 | + * @author Jiehao Ling, date:9/26/2015, time:11:24 AM | ||
11 | + */ | ||
12 | +public enum OrderStatusType { | ||
13 | + | ||
14 | + /** 订单状态 */ | ||
15 | + ORDER_NOT_PAYED_YET ( 0 , "未付款"), | ||
16 | + | ||
17 | + ORDER_CANCELED ( 1 , "已取消"), | ||
18 | + | ||
19 | + ORDER_WAITING_CONFIRM ( 2 , "待确认"), | ||
20 | + | ||
21 | + ORDER_RESERVE_FAILED ( 3 , "预订失败"), | ||
22 | + | ||
23 | + ORDER_RESERVE_SUCCESSFUL ( 4 , "预订成功"), | ||
24 | + | ||
25 | + ORDER_CONSUMED(5, "已消费"), | ||
26 | + | ||
27 | + ORDER_REFUNDED(6, "已退款"), | ||
28 | + | ||
29 | + ORDER_CONSUME_CONFIRM(7,"消费待确认"), | ||
30 | + | ||
31 | + ORDER_REFUNDED_CONFIRM(8,"退订待确认"), | ||
32 | + | ||
33 | + ORDER_RESERVE_CONFIRM(9,"订单待确认"), | ||
34 | + | ||
35 | + ORDER_OVERDUE(10,"订单过期"), | ||
36 | + | ||
37 | + ORDER_EXCEPTION(11,"订单异常"), | ||
38 | + | ||
39 | + ORDER_REFUNDED_WAIT_AUDIT(12,"退订待审核"), | ||
40 | + | ||
41 | + LMM_ORDER_PUSH(13,"预定成功待推送"),//驴妈妈酒店订单异步用 | ||
42 | + | ||
43 | + ORDER_NOT_PUSH_SUCCESS(14,"订单未推送成功或已全退");//驴妈妈酒店订单异步用 | ||
44 | + | ||
45 | + OrderStatusType(int statusIndex, String statusName) { | ||
46 | + this.statusIndex = statusIndex; | ||
47 | + this.statusName = statusName; | ||
48 | + } | ||
49 | + | ||
50 | + /** 状态下标 */ | ||
51 | + private int statusIndex; | ||
52 | + | ||
53 | + /** 状态名称 */ | ||
54 | + private String statusName; | ||
55 | + | ||
56 | + public int getStatusIndex() { | ||
57 | + return statusIndex; | ||
58 | + } | ||
59 | + | ||
60 | + public void setStatusIndex(int statusIndex) { | ||
61 | + this.statusIndex = statusIndex; | ||
62 | + } | ||
63 | + | ||
64 | + public String getStatusName() { | ||
65 | + return statusName; | ||
66 | + } | ||
67 | + | ||
68 | + public void setStatusName(String statusName) { | ||
69 | + this.statusName = statusName; | ||
70 | + } | ||
71 | + | ||
72 | + /** | ||
73 | + * 根据订单状态ID类型获取枚举对象 | ||
74 | + * @param orderStatusIndex 支付类型值 | ||
75 | + * @return 支付类型枚举 | ||
76 | + */ | ||
77 | + public static OrderStatusType typeOf(int orderStatusIndex){ | ||
78 | + OrderStatusType[] OrderStatusTypes = OrderStatusType.values(); | ||
79 | + for(OrderStatusType OrderStatusType: OrderStatusTypes){ | ||
80 | + if(OrderStatusType.getStatusIndex() == orderStatusIndex){ | ||
81 | + return OrderStatusType; | ||
82 | + } | ||
83 | + } | ||
84 | + throw new IllegalArgumentException("非法订单类型: " + orderStatusIndex); | ||
85 | + } | ||
86 | + | ||
87 | + /** | ||
88 | + * 枚举转Map | ||
89 | + * @return Map | ||
90 | + */ | ||
91 | + public static Map<Integer,String> convertToMap(){ | ||
92 | + Map<Integer,String> OrderStatusTypeMap = new HashMap<Integer, String>(); | ||
93 | + OrderStatusType[] OrderStatusTypes = OrderStatusType.values(); | ||
94 | + for(OrderStatusType OrderStatusType : OrderStatusTypes){ | ||
95 | + OrderStatusTypeMap.put(OrderStatusType.getStatusIndex(),OrderStatusType.getStatusName()); | ||
96 | + } | ||
97 | + return OrderStatusTypeMap; | ||
98 | + } | ||
99 | + | ||
100 | + /** | ||
101 | + * 枚举转换成JSON字符串 | ||
102 | + * @author yongkang.liao | ||
103 | + * @date 2015-12-03 | ||
104 | + * @return String | ||
105 | + */ | ||
106 | + public static String convertJson(){ | ||
107 | + OrderStatusType[] orderStatusTypes = OrderStatusType.values(); | ||
108 | + StringBuffer sb = new StringBuffer(); | ||
109 | + sb.append("{\"orderStatus\":["); | ||
110 | + for(int i = 0; i < orderStatusTypes.length; i++){ | ||
111 | + OrderStatusType orderStatusType = orderStatusTypes[i]; | ||
112 | + sb.append("{\"type\":" + orderStatusType.getStatusIndex() + ",\"name\":\"" | ||
113 | + + orderStatusType.getStatusName() + "\"}"); | ||
114 | + if((i + 1) != orderStatusTypes.length){ | ||
115 | + sb.append(","); | ||
116 | + } | ||
117 | + } | ||
118 | + sb.append("]}"); | ||
119 | + return sb.toString(); | ||
120 | + } | ||
121 | + | ||
122 | + @Override | ||
123 | + public String toString() { | ||
124 | + return "OrderStatusType{" + | ||
125 | + "statusIndex=" + statusIndex + | ||
126 | + ", statusName='" + statusName + '\'' + | ||
127 | + '}'; | ||
128 | + } | ||
129 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/enums/PaymentWay.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/enums/PaymentWay.java | ||
1 | +package com.ectrip.cyt.model.enums; | ||
2 | + | ||
3 | +import java.util.HashMap; | ||
4 | +import java.util.Map; | ||
5 | + | ||
6 | +/** | ||
7 | + * 支付类型枚举 | ||
8 | + * @author wenqiang.luo date:15-9-3 | ||
9 | + */ | ||
10 | +public enum PaymentWay { | ||
11 | + | ||
12 | + /** | ||
13 | + * 在线支付 | ||
14 | + */ | ||
15 | + PRE_PAY(0, "预付"), | ||
16 | + | ||
17 | + /** | ||
18 | + * 现场支付 | ||
19 | + */ | ||
20 | + CASH_PAY(1, "到付"); | ||
21 | + | ||
22 | + /** 支付类型 */ | ||
23 | + private int way; | ||
24 | + | ||
25 | + /** 支付名称 */ | ||
26 | + private String name; | ||
27 | + | ||
28 | + PaymentWay(int way, String name) { | ||
29 | + this.way = way; | ||
30 | + this.name = name; | ||
31 | + } | ||
32 | + | ||
33 | + public int getWay() { | ||
34 | + return way; | ||
35 | + } | ||
36 | + | ||
37 | + public String getName() { | ||
38 | + return name; | ||
39 | + } | ||
40 | + | ||
41 | + /** | ||
42 | + * 根据支付类型获取枚举对象 | ||
43 | + * @param type 支付类型值 | ||
44 | + * @return 支付类型枚举 | ||
45 | + */ | ||
46 | + public static PaymentWay wayOf(int type) { | ||
47 | + //枚举结果 | ||
48 | + PaymentWay[] paymentWays = PaymentWay.values(); | ||
49 | + for (PaymentWay paymentWay : paymentWays) { | ||
50 | + if (paymentWay.getWay() == type) { | ||
51 | + return paymentWay; | ||
52 | + } | ||
53 | + } | ||
54 | + throw new IllegalArgumentException("Invalid PaymentType way: " + type); | ||
55 | + } | ||
56 | + | ||
57 | + /** | ||
58 | + * 枚举转Map | ||
59 | + * @return Map | ||
60 | + */ | ||
61 | + public static Map<Integer, String> convertToMap() { | ||
62 | + Map<Integer, String> integerStringMap = new HashMap<Integer, String>(); | ||
63 | + PaymentWay[] paymentWays = PaymentWay.values(); | ||
64 | + for (PaymentWay paymentWay : paymentWays) { | ||
65 | + integerStringMap.put(paymentWay.getWay(), paymentWay.getName()); | ||
66 | + } | ||
67 | + return integerStringMap; | ||
68 | + } | ||
69 | + | ||
70 | + @Override | ||
71 | + public String toString() { | ||
72 | + return "PaymentWay{" + | ||
73 | + "way=" + way + | ||
74 | + ", name='" + name + '\'' + | ||
75 | + '}'; | ||
76 | + } | ||
77 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/param/AccountParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/param/AccountParam.java | ||
1 | +package com.ectrip.cyt.model.param; | ||
2 | + | ||
3 | +import io.swagger.annotations.ApiModel; | ||
4 | +import io.swagger.annotations.ApiModelProperty; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | +import org.hibernate.validator.constraints.Range; | ||
9 | + | ||
10 | +import javax.validation.constraints.NotBlank; | ||
11 | + | ||
12 | +@Data | ||
13 | +@AllArgsConstructor | ||
14 | +@NoArgsConstructor | ||
15 | +@ApiModel(description = "用户信息") | ||
16 | +public class AccountParam { | ||
17 | + @NotBlank(message = "加密算法必填") | ||
18 | + @ApiModelProperty(value = "OTA接口加密算法:0:MD5 1:AES/CBC 2:SM4/CBC", required = false) | ||
19 | + private String securityType; | ||
20 | + | ||
21 | + //分销商名称 | ||
22 | + @NotBlank(message = "分销商名不能为空") | ||
23 | + @ApiModelProperty(value = "分销商名", required = true) | ||
24 | + private String distributorName; | ||
25 | + | ||
26 | + //分销商密钥 | ||
27 | + @NotBlank(message = "分销商密钥不能为空") | ||
28 | + @ApiModelProperty(value = "分销商密钥", required = true) | ||
29 | + private String key; | ||
30 | + | ||
31 | + //供应商标识 | ||
32 | + @ApiModelProperty(value = "供应商标识", required = false) | ||
33 | + private String identity; | ||
34 | + | ||
35 | + @NotBlank(message = "平台接口地址不能为空") | ||
36 | + @ApiModelProperty(value = "平台接口地址", required = true) | ||
37 | + private String url; | ||
38 | + | ||
39 | + //接口地址 | ||
40 | + //@Range(min=0,max=2,message ="对接平台范围不在[0,2]內") | ||
41 | + /*@ApiModelProperty(value = "对接平台 {" + | ||
42 | + "0:tour.12301cn.cn(整合营销测试版)," + | ||
43 | + "1:jy.12301cn.cn(整合营销公共版)," + | ||
44 | + "2:www.12301cn.cn(整合营销独立版)" + | ||
45 | + "3:59.59.7.54:8081(瘦西湖)" + | ||
46 | + "4:cyt.51yzly.com(土楼)" + | ||
47 | + "10:cyt.jingqu.cn/tdos(整合营销3.0)" + | ||
48 | + "11:w.qdocti.com/tdos(青岛3.0)" + | ||
49 | + "99:本地环境(8038端口)" + | ||
50 | + "}", required = true) | ||
51 | + private Integer platfrom_sign;*/ | ||
52 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/param/CancelOrderParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/param/CancelOrderParam.java | ||
1 | +package com.ectrip.cyt.model.param; | ||
2 | + | ||
3 | +import io.swagger.annotations.ApiModel; | ||
4 | +import io.swagger.annotations.ApiModelProperty; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import javax.validation.constraints.Min; | ||
10 | +import javax.validation.constraints.NotBlank; | ||
11 | + | ||
12 | +@Data | ||
13 | +@AllArgsConstructor | ||
14 | +@NoArgsConstructor | ||
15 | +@ApiModel(description = "取消订单参数") | ||
16 | +public class CancelOrderParam { | ||
17 | + @ApiModelProperty(value = "畅游通订单号", required = true) | ||
18 | + private String cytOrderCode; | ||
19 | + | ||
20 | + @ApiModelProperty(value = "OTA订单号", required = true) | ||
21 | + private String otaOrderCode; | ||
22 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/param/CreateOrderParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/param/CreateOrderParam.java | ||
1 | +package com.ectrip.cyt.model.param; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.pojo.Person; | ||
4 | +import com.ectrip.cyt.utils.DateUtils; | ||
5 | +import com.ectrip.cyt.utils.TestOrderUtils; | ||
6 | +import io.swagger.annotations.ApiModel; | ||
7 | +import io.swagger.annotations.ApiModelProperty; | ||
8 | +import lombok.AllArgsConstructor; | ||
9 | +import lombok.Data; | ||
10 | +import lombok.NoArgsConstructor; | ||
11 | +import org.apache.commons.collections.CollectionUtils; | ||
12 | +import org.apache.commons.lang3.StringUtils; | ||
13 | +import org.hibernate.validator.constraints.Range; | ||
14 | + | ||
15 | +import javax.validation.Valid; | ||
16 | +import javax.validation.constraints.Min; | ||
17 | +import javax.validation.constraints.NotNull; | ||
18 | +import java.util.ArrayList; | ||
19 | +import java.util.Date; | ||
20 | +import java.util.List; | ||
21 | + | ||
22 | +@Data | ||
23 | +@AllArgsConstructor | ||
24 | +@NoArgsConstructor | ||
25 | +@ApiModel(description = "创建订单参数") | ||
26 | +public class CreateOrderParam { | ||
27 | + //ota订单号 | ||
28 | + //@NotBlank(message = "OTA订单号不能为空") | ||
29 | + @ApiModelProperty(value = "OTA订单号", required = true) | ||
30 | + private String orderCode; | ||
31 | + | ||
32 | + public String getOrderCode() { | ||
33 | + if(StringUtils.isBlank(orderCode)){ | ||
34 | + orderCode = TestOrderUtils.get16UUID(); | ||
35 | + } | ||
36 | + return orderCode; | ||
37 | + } | ||
38 | + | ||
39 | + //游览日期 | ||
40 | + //@NotBlank(message = "游览日期不能为空") | ||
41 | + //@Pattern(regexp = "(([0-9]{3}[1-9]|[0-9]{2}[1-9][0-9]{1}|[0-9]{1}[1-9][0-9]{2}|[1-9][0-9]{3})-(((0[13578]|1[02])-(0[1-9]|[12][0-9]|3[01]))|((0[469]|11)-(0[1-9]|[12][0-9]|30))|(02-(0[1-9]|[1][0-9]|2[0-8]))))|((([0-9]{2})(0[48]|[2468][048]|[13579][26])|((0[48]|[2468][048]|[3579][26])00))-02-29)",message = "游览日期格式不对") | ||
42 | + @ApiModelProperty(value = "住店日期", required = true) | ||
43 | + private String visitDate; | ||
44 | + | ||
45 | + @ApiModelProperty(value = "离店日期", required = true) | ||
46 | + private String leaveDate; | ||
47 | + | ||
48 | + public String getVisitDate() { | ||
49 | + if(StringUtils.isBlank(visitDate)){ | ||
50 | + visitDate = DateUtils.formatDate(new Date(),DateUtils.DATE_PATTERN); | ||
51 | + } | ||
52 | + return visitDate; | ||
53 | + } | ||
54 | + | ||
55 | + //票数 | ||
56 | + @Min(value = 1,message = "订单数量必须大于或等于1") | ||
57 | + @ApiModelProperty(value = "订单数量", required = true) | ||
58 | + private Integer orderQuantity; | ||
59 | + | ||
60 | + //金额 | ||
61 | + @Min(value = 0,message = "订单金额必须大于或等于0") | ||
62 | + @ApiModelProperty(value = "订单金额", required = true) | ||
63 | + private Double orderPrice; | ||
64 | + | ||
65 | + @ApiModelProperty(value = "一票几人 默认一票一人", required = false) | ||
66 | + private Integer ticketPersonNum; | ||
67 | + | ||
68 | + @Valid | ||
69 | + @NotNull(message = "必须传入产品信息") | ||
70 | + @ApiModelProperty(value = "产品信息", required = true) | ||
71 | + //产品信息 | ||
72 | + private ProductParam product; | ||
73 | + | ||
74 | + //@NotNull(message = "必须传入联系人信息 至少保留手机号") | ||
75 | + @ApiModelProperty(value = "联系人信息", required = true) | ||
76 | + //联系人 | ||
77 | + private Person contactPerson; | ||
78 | + | ||
79 | + @ApiModelProperty(value = "游客信息", required = false) | ||
80 | + //游客信息 | ||
81 | + private List<Person> visitPersons; | ||
82 | + | ||
83 | + public Person getContactPerson() { | ||
84 | + if(contactPerson == null){ | ||
85 | + contactPerson = new Person(); | ||
86 | + } | ||
87 | + if(StringUtils.isBlank(contactPerson.getName())){ | ||
88 | + contactPerson.setName("测试联系人"); | ||
89 | + } | ||
90 | + if(contactPerson.getCredentialsType() == null){ | ||
91 | + contactPerson.setCredentialsType(0); | ||
92 | + } | ||
93 | + if(StringUtils.isBlank(contactPerson.getPhone())){ | ||
94 | + contactPerson.setPhone(TestOrderUtils.createMobile(2)); | ||
95 | + } | ||
96 | + if(StringUtils.isBlank(contactPerson.getCredentials())){ | ||
97 | + contactPerson.setCredentials(TestOrderUtils.getIdNo(false)); | ||
98 | + } | ||
99 | + return contactPerson; | ||
100 | + } | ||
101 | + | ||
102 | + public List<Person> getVisitPersons() { | ||
103 | + if(CollectionUtils.isEmpty(visitPersons)){ | ||
104 | + visitPersons = new ArrayList<>(); | ||
105 | + visitPersons.add(contactPerson); | ||
106 | + | ||
107 | + if(ticketPersonNum == null){ | ||
108 | + ticketPersonNum = 1; | ||
109 | + } | ||
110 | + | ||
111 | + if((ticketPersonNum * orderQuantity) >1) { | ||
112 | + for (int i = 0; i < ((ticketPersonNum * orderQuantity) - 1); i++) { | ||
113 | + Person p = new Person(); | ||
114 | + p.setName("测试游客" + (i+1)); | ||
115 | + p.setCredentialsType(0); | ||
116 | + p.setPhone(TestOrderUtils.createMobile(2)); | ||
117 | + p.setCredentials(TestOrderUtils.getIdNo(false)); | ||
118 | + visitPersons.add(p); | ||
119 | + } | ||
120 | + } | ||
121 | + } | ||
122 | + return visitPersons; | ||
123 | + } | ||
124 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/param/GetProductParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/param/GetProductParam.java | ||
1 | +package com.ectrip.cyt.model.param; | ||
2 | + | ||
3 | +import io.swagger.annotations.ApiModel; | ||
4 | +import io.swagger.annotations.ApiModelProperty; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | +import org.hibernate.validator.constraints.Range; | ||
9 | +import org.omg.PortableInterceptor.INACTIVE; | ||
10 | + | ||
11 | +import javax.validation.constraints.Min; | ||
12 | +import javax.validation.constraints.NotBlank; | ||
13 | + | ||
14 | +@Data | ||
15 | +@AllArgsConstructor | ||
16 | +@NoArgsConstructor | ||
17 | +@ApiModel(description = "获取产品参数") | ||
18 | +public class GetProductParam { | ||
19 | + //获取产品方法 全部ALL 单个SINGLE | ||
20 | + //@NotBlank(message = "获取产品方法不能为空") | ||
21 | + /*@ApiModelProperty(value = "获取产品方法 全部ALL 单个SINGLE", required = true) | ||
22 | + private String method;*/ | ||
23 | + | ||
24 | + //分页数 | ||
25 | + //@Min(value = 1,message = "分页数必须大于或等于1") | ||
26 | + @ApiModelProperty(value = "分页数", required = true) | ||
27 | + private Integer currentPage; | ||
28 | + //分页大小 | ||
29 | + | ||
30 | + //@Range(min=1,max=5,message ="分页大小不在[1,5]內") | ||
31 | + @ApiModelProperty(value = "分页大小(最大5条)", required = true) | ||
32 | + private Integer pageSize; | ||
33 | + //产品ID | ||
34 | + @ApiModelProperty(value = "产品ID 获取产品方法为SINGLE必填", required = false) | ||
35 | + private String resourceId; | ||
36 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/param/GetSeatParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/param/GetSeatParam.java | ||
1 | +package com.ectrip.cyt.model.param; | ||
2 | + | ||
3 | +import io.swagger.annotations.ApiModel; | ||
4 | +import io.swagger.annotations.ApiModelProperty; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import javax.validation.constraints.NotBlank; | ||
10 | + | ||
11 | +@Data | ||
12 | +@AllArgsConstructor | ||
13 | +@NoArgsConstructor | ||
14 | +@ApiModel(description = "获取座位参数") | ||
15 | +public class GetSeatParam { | ||
16 | + @NotBlank(message = "分时ID不能为空") | ||
17 | + @ApiModelProperty(value = "分时ID", required = false) | ||
18 | + private String timeOfBookId; | ||
19 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/param/GetStockParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/param/GetStockParam.java | ||
1 | +package com.ectrip.cyt.model.param; | ||
2 | + | ||
3 | +import io.swagger.annotations.ApiModel; | ||
4 | +import io.swagger.annotations.ApiModelProperty; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import javax.validation.constraints.NotBlank; | ||
10 | + | ||
11 | +@Data | ||
12 | +@AllArgsConstructor | ||
13 | +@NoArgsConstructor | ||
14 | +@ApiModel(description = "获取库存参数") | ||
15 | +public class GetStockParam { | ||
16 | + @ApiModelProperty(value = "开始日期", required = false) | ||
17 | + private String startDate; | ||
18 | + @ApiModelProperty(value = "截至日期", required = false) | ||
19 | + private String endDate; | ||
20 | + @NotBlank(message = "资源ID不能为空") | ||
21 | + @ApiModelProperty(value = "资源ID", required = false) | ||
22 | + private String resourceId; | ||
23 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/param/PayOrderParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/param/PayOrderParam.java | ||
1 | +package com.ectrip.cyt.model.param; | ||
2 | + | ||
3 | +import io.swagger.annotations.ApiModel; | ||
4 | +import io.swagger.annotations.ApiModelProperty; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import javax.validation.constraints.Min; | ||
10 | + | ||
11 | +import javax.validation.constraints.NotBlank; | ||
12 | + | ||
13 | +@Data | ||
14 | +@AllArgsConstructor | ||
15 | +@NoArgsConstructor | ||
16 | +@ApiModel(description = "支付订单参数") | ||
17 | +public class PayOrderParam { | ||
18 | + @ApiModelProperty(value = "畅游通订单号", required = true) | ||
19 | + private String cytOrderCode; | ||
20 | + | ||
21 | + @ApiModelProperty(value = "OTA订单号", required = true) | ||
22 | + private String otaOrderCode; | ||
23 | + | ||
24 | + //金额 | ||
25 | + @Min(value = 0,message = "支付金额必须大于或等于0") | ||
26 | + @ApiModelProperty(value = "支付金额", required = true) | ||
27 | + private Double orderPrice; | ||
28 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/param/ProductParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/param/ProductParam.java | ||
1 | +package com.ectrip.cyt.model.param; | ||
2 | + | ||
3 | +import io.swagger.annotations.ApiModel; | ||
4 | +import io.swagger.annotations.ApiModelProperty; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import javax.validation.constraints.Min; | ||
10 | +import javax.validation.constraints.NotBlank; | ||
11 | +import java.util.List; | ||
12 | + | ||
13 | +@Data | ||
14 | +@AllArgsConstructor | ||
15 | +@NoArgsConstructor | ||
16 | +@ApiModel(description = "产品信息") | ||
17 | +public class ProductParam { | ||
18 | + @NotBlank(message = "产品编号不能为空") | ||
19 | + @ApiModelProperty(value = "产品编号", required = true) | ||
20 | + private String productNo; | ||
21 | + | ||
22 | + @Min(value = 0,message = "产品结算价必须大于或等于0") | ||
23 | + @ApiModelProperty(value = "产品结算价", required = true) | ||
24 | + private Double sellPrice; | ||
25 | + | ||
26 | + @ApiModelProperty(value = "分时ID", required = true) | ||
27 | + private Integer timeOfBookId; | ||
28 | + | ||
29 | + @ApiModelProperty(value = "座位集合", required = true) | ||
30 | + private String seatIds; | ||
31 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/param/PushOrderParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/param/PushOrderParam.java | ||
1 | +package com.ectrip.cyt.model.param; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.pojo.EditPerson; | ||
4 | +import com.ectrip.cyt.model.pojo.Person; | ||
5 | +import io.swagger.annotations.ApiModel; | ||
6 | +import io.swagger.annotations.ApiModelProperty; | ||
7 | +import lombok.AllArgsConstructor; | ||
8 | +import lombok.Data; | ||
9 | +import lombok.NoArgsConstructor; | ||
10 | +import javax.validation.constraints.NotBlank; | ||
11 | +import javax.validation.constraints.Pattern; | ||
12 | +import java.util.List; | ||
13 | + | ||
14 | +@Data | ||
15 | +@AllArgsConstructor | ||
16 | +@NoArgsConstructor | ||
17 | +@ApiModel(description = "改签订单参数") | ||
18 | +public class PushOrderParam { | ||
19 | + @NotBlank(message = "畅游通订单号不能为空") | ||
20 | + @ApiModelProperty(value = "畅游通订单号", required = true) | ||
21 | + private String cytOrderCode; | ||
22 | + | ||
23 | + @NotBlank(message = "改签日期不能为空") | ||
24 | + @Pattern(regexp = "(([0-9]{3}[1-9]|[0-9]{2}[1-9][0-9]{1}|[0-9]{1}[1-9][0-9]{2}|[1-9][0-9]{3})-(((0[13578]|1[02])-(0[1-9]|[12][0-9]|3[01]))|((0[469]|11)-(0[1-9]|[12][0-9]|30))|(02-(0[1-9]|[1][0-9]|2[0-8]))))|((([0-9]{2})(0[48]|[2468][048]|[13579][26])|((0[48]|[2468][048]|[3579][26])00))-02-29)",message = "改签日期格式不对") | ||
25 | + @ApiModelProperty(value = "改签日期", required = true) | ||
26 | + private String visitDate; | ||
27 | + | ||
28 | + @ApiModelProperty(value = "改签联系人信息", required = false) | ||
29 | + //联系人 | ||
30 | + private Person contactPerson; | ||
31 | + | ||
32 | + @ApiModelProperty(value = "改签游客信息", required = false) | ||
33 | + //游客信息 | ||
34 | + private List<EditPerson> visitPersons; | ||
35 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/param/QueryOrderParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/param/QueryOrderParam.java | ||
1 | +package com.ectrip.cyt.model.param; | ||
2 | + | ||
3 | +import io.swagger.annotations.ApiModel; | ||
4 | +import io.swagger.annotations.ApiModelProperty; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import javax.validation.constraints.Min; | ||
10 | +import javax.validation.constraints.NotBlank; | ||
11 | + | ||
12 | +@Data | ||
13 | +@AllArgsConstructor | ||
14 | +@NoArgsConstructor | ||
15 | +@ApiModel(description = "查询订单参数") | ||
16 | +public class QueryOrderParam { | ||
17 | + @ApiModelProperty(value = "畅游通订单号(二选一 优先级)", required = false) | ||
18 | + private String cytOrderCode; | ||
19 | + | ||
20 | + @ApiModelProperty(value = "OTA订单号(二选一)", required = false) | ||
21 | + private String orderCode; | ||
22 | + | ||
23 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/param/RefundOrderParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/param/RefundOrderParam.java | ||
1 | +package com.ectrip.cyt.model.param; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.pojo.Person; | ||
4 | +import io.swagger.annotations.ApiModel; | ||
5 | +import io.swagger.annotations.ApiModelProperty; | ||
6 | +import lombok.AllArgsConstructor; | ||
7 | +import lombok.Data; | ||
8 | +import lombok.NoArgsConstructor; | ||
9 | + | ||
10 | +import javax.validation.constraints.Min; | ||
11 | +import javax.validation.constraints.NotBlank; | ||
12 | +import java.util.List; | ||
13 | + | ||
14 | +@Data | ||
15 | +@AllArgsConstructor | ||
16 | +@NoArgsConstructor | ||
17 | +@ApiModel(description = "退订订单参数") | ||
18 | +public class RefundOrderParam { | ||
19 | + @NotBlank(message = "畅游通订单号不能为空") | ||
20 | + @ApiModelProperty(value = "畅游通订单号", required = true) | ||
21 | + private String cytOrderCode; | ||
22 | + | ||
23 | + @NotBlank(message = "退订流水号不能为空") | ||
24 | + @ApiModelProperty(value = "退订流水号", required = true) | ||
25 | + private String refundSeq; | ||
26 | + | ||
27 | + @Min(value = 0,message = "退订金额必须大于或等于0") | ||
28 | + @ApiModelProperty(value = "退订金额", required = true) | ||
29 | + private Double refundMoney; | ||
30 | + | ||
31 | + @Min(value = 1,message = "退订数量必须大于或等于1") | ||
32 | + @ApiModelProperty(value = "退订数量", required = true) | ||
33 | + private Integer refundQuantity; | ||
34 | + | ||
35 | + @ApiModelProperty(value = "退订游客信息", required = false) | ||
36 | + private List<Person> visitPersons; | ||
37 | + | ||
38 | + @ApiModelProperty(value = "退订原因", required = false) | ||
39 | + private String refundReason; | ||
40 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/param/SendOrderEticketParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/param/SendOrderEticketParam.java | ||
1 | +package com.ectrip.cyt.model.param; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.pojo.Person; | ||
4 | +import io.swagger.annotations.ApiModel; | ||
5 | +import io.swagger.annotations.ApiModelProperty; | ||
6 | +import lombok.AllArgsConstructor; | ||
7 | +import lombok.Data; | ||
8 | +import lombok.NoArgsConstructor; | ||
9 | +import org.hibernate.validator.constraints.Range; | ||
10 | + | ||
11 | +import javax.validation.Valid; | ||
12 | +import javax.validation.constraints.Min; | ||
13 | +import javax.validation.constraints.NotBlank; | ||
14 | +import javax.validation.constraints.NotNull; | ||
15 | +import javax.validation.constraints.Pattern; | ||
16 | +import java.util.List; | ||
17 | + | ||
18 | +@Data | ||
19 | +@AllArgsConstructor | ||
20 | +@NoArgsConstructor | ||
21 | +@ApiModel(description = "重发短信参数") | ||
22 | +public class SendOrderEticketParam { | ||
23 | + @NotBlank(message = "畅游通订单号不能为空") | ||
24 | + @ApiModelProperty(value = "畅游通订单号", required = true) | ||
25 | + private String cytOrderCode; | ||
26 | + /** 游客电话 */ | ||
27 | + @ApiModelProperty(value = "电话号", required = false) | ||
28 | + private String phone; | ||
29 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/pojo/EditPerson.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/pojo/EditPerson.java | ||
1 | +package com.ectrip.cyt.model.pojo; | ||
2 | + | ||
3 | +import io.swagger.annotations.ApiModel; | ||
4 | +import io.swagger.annotations.ApiModelProperty; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import java.io.Serializable; | ||
10 | + | ||
11 | +@Data | ||
12 | +@AllArgsConstructor | ||
13 | +@NoArgsConstructor | ||
14 | +@ApiModel(description = "联系人/游客信息") | ||
15 | +public class EditPerson implements Serializable { | ||
16 | + /** 游客证件号码 */ | ||
17 | + @ApiModelProperty(value = "原游客证件号码", required = true) | ||
18 | + private String credentials; | ||
19 | + | ||
20 | + /** 游客姓名 */ | ||
21 | + @ApiModelProperty(value = "修改后的游客姓名", required = false) | ||
22 | + private String editName; | ||
23 | + | ||
24 | + /** 游客电话 */ | ||
25 | + @ApiModelProperty(value = "修改后的游客电话 ", required = false) | ||
26 | + private String editPhone; | ||
27 | + | ||
28 | + /** 游客证件号码 */ | ||
29 | + @ApiModelProperty(value = "修改后的游客证件号码", required = false) | ||
30 | + private String editCredentials; | ||
31 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/pojo/Person.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/pojo/Person.java | ||
1 | +package com.ectrip.cyt.model.pojo; | ||
2 | + | ||
3 | +import io.swagger.annotations.ApiModel; | ||
4 | +import io.swagger.annotations.ApiModelProperty; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +import java.io.Serializable; | ||
10 | + | ||
11 | +@Data | ||
12 | +@AllArgsConstructor | ||
13 | +@NoArgsConstructor | ||
14 | +@ApiModel(description = "联系人/游客信息") | ||
15 | +public class Person implements Serializable { | ||
16 | + /** 游客姓名 */ | ||
17 | + @ApiModelProperty(value = "游客姓名", required = false) | ||
18 | + private String name; | ||
19 | + | ||
20 | + /** 游客电话 */ | ||
21 | + @ApiModelProperty(value = "游客电话 ", required = false) | ||
22 | + private String phone; | ||
23 | + | ||
24 | + /** 游客证件类型 */ | ||
25 | + @ApiModelProperty(value = "游客证件类型(0身份证,1护照,2军官证,3台胞证,4港澳通行证,5其它,6皈依证,7学生证)", required = false) | ||
26 | + private Integer credentialsType; | ||
27 | + | ||
28 | + /** 游客证件号码 */ | ||
29 | + @ApiModelProperty(value = "游客证件号码", required = false) | ||
30 | + private String credentials; | ||
31 | + | ||
32 | + @ApiModelProperty(value = "票码", required = false) | ||
33 | + private String voucher; | ||
34 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/result/AjaxResult.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/result/AjaxResult.java | ||
1 | +package com.ectrip.cyt.model.result; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.rt.CommonReturn; | ||
4 | +import io.swagger.annotations.ApiModelProperty; | ||
5 | + | ||
6 | +import java.io.Serializable; | ||
7 | + | ||
8 | +/** | ||
9 | + * 处理ajax返回的结果信息 | ||
10 | + * @author wenqiang.luo date:15-9-7 | ||
11 | + */ | ||
12 | +public class AjaxResult implements Serializable { | ||
13 | + | ||
14 | + private static final long serialVersionUID = 5837409853066710012L; | ||
15 | + | ||
16 | + private static final String SUCCESS_DESCRIPTION = "success"; | ||
17 | + | ||
18 | + /** ajax 交互结果 */ | ||
19 | + @ApiModelProperty(value = "请求状态", required = true) | ||
20 | + private boolean success; | ||
21 | + | ||
22 | + /** 交互描述信息 */ | ||
23 | + @ApiModelProperty(value = "请求描述", required = true) | ||
24 | + private String description; | ||
25 | + | ||
26 | + /** 交互数据 */ | ||
27 | + @ApiModelProperty(value = "接口返回信息", required = true) | ||
28 | + private CommonReturn data; | ||
29 | + | ||
30 | + | ||
31 | + //construct//////////////////////////////////////////////////////////////// | ||
32 | + | ||
33 | + public AjaxResult() { | ||
34 | + this(false); | ||
35 | + } | ||
36 | + | ||
37 | + public AjaxResult(boolean success) { | ||
38 | + this(success, SUCCESS_DESCRIPTION); | ||
39 | + } | ||
40 | + | ||
41 | + public AjaxResult(boolean success, String description) { | ||
42 | + this(success, description, null); | ||
43 | + } | ||
44 | + | ||
45 | + public AjaxResult(boolean success, String description, CommonReturn data) { | ||
46 | + this.success = success; | ||
47 | + this.description = description; | ||
48 | + this.data = data; | ||
49 | + } | ||
50 | + | ||
51 | + //get and set////////////////////////////////////////////////////////////// | ||
52 | + | ||
53 | + public boolean isSuccess() { | ||
54 | + return success; | ||
55 | + } | ||
56 | + | ||
57 | + public void setSuccess(boolean success) { | ||
58 | + this.success = success; | ||
59 | + } | ||
60 | + | ||
61 | + public String getDescription() { | ||
62 | + return description; | ||
63 | + } | ||
64 | + | ||
65 | + public void setDescription(String description) { | ||
66 | + this.description = description; | ||
67 | + } | ||
68 | + | ||
69 | + public CommonReturn getData() { | ||
70 | + return data; | ||
71 | + } | ||
72 | + | ||
73 | + public void setData(CommonReturn data) { | ||
74 | + this.data = data; | ||
75 | + } | ||
76 | + | ||
77 | + | ||
78 | + //public static method///////////////////////////////////////////////////// | ||
79 | + | ||
80 | + public static AjaxResult error(String description) { | ||
81 | + return new AjaxResult(false, description); | ||
82 | + } | ||
83 | + | ||
84 | + public static AjaxResult success(String description) { | ||
85 | + return new AjaxResult(true, description); | ||
86 | + } | ||
87 | + | ||
88 | + public static AjaxResult success(CommonReturn data) { | ||
89 | + return new AjaxResult(true, null, data); | ||
90 | + } | ||
91 | + | ||
92 | + public static AjaxResult success(String description, CommonReturn data) { | ||
93 | + return new AjaxResult(true, description, data); | ||
94 | + } | ||
95 | + | ||
96 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/result/Result.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/result/Result.java | ||
1 | +package com.ectrip.cyt.model.result; | ||
2 | + | ||
3 | +import java.io.Serializable; | ||
4 | + | ||
5 | +/** | ||
6 | + * @author wenqiang.luo date:16/7/28 | ||
7 | + */ | ||
8 | +public class Result<T> implements Serializable { | ||
9 | + | ||
10 | + private static final long serialVersionUID = -2336951543661721293L; | ||
11 | + | ||
12 | + /** 交互成功标识 */ | ||
13 | + private boolean success; | ||
14 | + | ||
15 | + /** 交互异常信息 */ | ||
16 | + private Throwable throwable; | ||
17 | + | ||
18 | + /** 结果描述 */ | ||
19 | + private String description; | ||
20 | + | ||
21 | + /** 附加信息 */ | ||
22 | + private T data; | ||
23 | + | ||
24 | + //constructor////////////////////////////////////////////////////////////// | ||
25 | + | ||
26 | + private Result(boolean success, Throwable throwable, String description, T data) { | ||
27 | + this.success = success; | ||
28 | + this.description = description; | ||
29 | + this.throwable = throwable; | ||
30 | + this.data = data; | ||
31 | + } | ||
32 | + | ||
33 | + //public static method///////////////////////////////////////////////////// | ||
34 | + | ||
35 | + public static <T> Result<T> success() { | ||
36 | + return Result.success(null); | ||
37 | + } | ||
38 | + | ||
39 | + public static <T> Result<T> success(T data) { | ||
40 | + return Result.success("SUCCESS", data); | ||
41 | + } | ||
42 | + | ||
43 | + public static <T> Result<T> success(String description, T data) { | ||
44 | + return new Result<T>(true, null, description, data); | ||
45 | + } | ||
46 | + | ||
47 | + public static <T> Result<T> error(String description) { | ||
48 | + return new Result<T>(false, null, description, null); | ||
49 | + } | ||
50 | + | ||
51 | + public static <T> Result<T> error(String description,T data) { | ||
52 | + return new Result<T>(false, null, description, data); | ||
53 | + } | ||
54 | + | ||
55 | + public static <T> Result<T> error(Throwable throwable, String description) { | ||
56 | + return new Result<T>(false, throwable, description, null); | ||
57 | + } | ||
58 | + | ||
59 | + //get and set////////////////////////////////////////////////////////////// | ||
60 | + | ||
61 | + public boolean isSuccess() { | ||
62 | + return success; | ||
63 | + } | ||
64 | + | ||
65 | + public void setSuccess(boolean success) { | ||
66 | + this.success = success; | ||
67 | + } | ||
68 | + | ||
69 | + public Throwable getThrowable() { | ||
70 | + return throwable; | ||
71 | + } | ||
72 | + | ||
73 | + public void setThrowable(Throwable throwable) { | ||
74 | + this.throwable = throwable; | ||
75 | + } | ||
76 | + | ||
77 | + public String getDescription() { | ||
78 | + return description; | ||
79 | + } | ||
80 | + | ||
81 | + public void setDescription(String description) { | ||
82 | + this.description = description; | ||
83 | + } | ||
84 | + | ||
85 | + public T getData() { | ||
86 | + return data; | ||
87 | + } | ||
88 | + | ||
89 | + public void setData(T data) { | ||
90 | + this.data = data; | ||
91 | + } | ||
92 | + | ||
93 | + @Override | ||
94 | + public String toString() { | ||
95 | + return "Result{" + | ||
96 | + "success=" + success + | ||
97 | + ", description='" + description + '\'' + | ||
98 | + ", data=" + data + | ||
99 | + '}'; | ||
100 | + } | ||
101 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/model/result/ResultStatus.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/result/ResultStatus.java | ||
1 | +package com.ectrip.cyt.model.result; | ||
2 | + | ||
3 | +/** | ||
4 | + * @Author:zhangkangdi | ||
5 | + * @Description: | ||
6 | + * @Date: Create in 2020/3/31 14:15 | ||
7 | + * @Modified By: | ||
8 | + */ | ||
9 | +public enum ResultStatus { | ||
10 | + | ||
11 | + SUCCESS("200","请求成功"), | ||
12 | + FAIL("201","请求失败"), | ||
13 | + ERROR("400","请求异常"); | ||
14 | + | ||
15 | + private String code; | ||
16 | + | ||
17 | + private String message; | ||
18 | + | ||
19 | + ResultStatus(String code, String message) { | ||
20 | + this.code = code; | ||
21 | + this.message = message; | ||
22 | + } | ||
23 | + | ||
24 | + public String getCode() { | ||
25 | + return code; | ||
26 | + } | ||
27 | + | ||
28 | + public void setCode(String code) { | ||
29 | + this.code = code; | ||
30 | + } | ||
31 | + | ||
32 | + public String getMessage() { | ||
33 | + return message; | ||
34 | + } | ||
35 | + | ||
36 | + public void setMessage(String message) { | ||
37 | + this.message = message; | ||
38 | + } | ||
39 | +} | ||
0 | \ No newline at end of file | 40 | \ No newline at end of file |
zhyx-api/src/main/java/com/ectrip/cyt/model/rt/CommonReturn.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/rt/CommonReturn.java | ||
1 | +package com.ectrip.cyt.model.rt; | ||
2 | + | ||
3 | +import com.alibaba.fastjson.JSONObject; | ||
4 | +import io.swagger.annotations.ApiModelProperty; | ||
5 | +import lombok.AllArgsConstructor; | ||
6 | +import lombok.Data; | ||
7 | +import lombok.NoArgsConstructor; | ||
8 | + | ||
9 | +@Data | ||
10 | +@AllArgsConstructor | ||
11 | +@NoArgsConstructor | ||
12 | +public class CommonReturn { | ||
13 | + //请求参数XML | ||
14 | + @ApiModelProperty(value = "请求参数XML", required = true) | ||
15 | + private String requestXml; | ||
16 | + //返回参数XML | ||
17 | + @ApiModelProperty(value = "返回参数XML", required = true) | ||
18 | + private String responseXml; | ||
19 | + //最外层返回参数 | ||
20 | + @ApiModelProperty(value = "返回参数json", required = true) | ||
21 | + private JSONObject requestJson; | ||
22 | + //最外层请求参数 | ||
23 | + @ApiModelProperty(value = "请求参数json", required = true) | ||
24 | + private JSONObject responseJson; | ||
25 | + //请求时间 | ||
26 | + @ApiModelProperty(value = "请求时间", required = true) | ||
27 | + private String requestTime; | ||
28 | + //返回时间 | ||
29 | + @ApiModelProperty(value = "返回时间", required = true) | ||
30 | + private String responseTime; | ||
31 | + //接口类型 | ||
32 | + @ApiModelProperty(value = "接口类型", required = true) | ||
33 | + private String interfaceType; | ||
34 | + //接口方法 | ||
35 | + @ApiModelProperty(value = "接口方法", required = true) | ||
36 | + private String interfaceMethod; | ||
37 | + //描述 | ||
38 | + @ApiModelProperty(value = "接口描述", required = true) | ||
39 | + private String description; | ||
40 | + //是否下单成功 | ||
41 | + @ApiModelProperty(value = "接口交互结果", required = true) | ||
42 | + private Boolean apiStatus; | ||
43 | + //畅游通单号 | ||
44 | + private String cytOrderCode; | ||
45 | +} | ||
0 | \ No newline at end of file | 46 | \ No newline at end of file |
zhyx-api/src/main/java/com/ectrip/cyt/model/rt/PushOrderRequest.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/model/rt/PushOrderRequest.java | ||
1 | +package com.ectrip.cyt.model.rt; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.Request; | ||
4 | +import com.ectrip.cyt.model.param.PushOrderParam; | ||
5 | +import io.swagger.annotations.ApiModel; | ||
6 | +import lombok.AllArgsConstructor; | ||
7 | +import lombok.Data; | ||
8 | +import lombok.NoArgsConstructor; | ||
9 | + | ||
10 | +import javax.validation.Valid; | ||
11 | +import javax.validation.constraints.NotNull; | ||
12 | + | ||
13 | +@Data | ||
14 | +@AllArgsConstructor | ||
15 | +@NoArgsConstructor | ||
16 | +@ApiModel(description = "同步订单参数") | ||
17 | +public class PushOrderRequest extends Request { | ||
18 | + @Valid | ||
19 | + @NotNull(message = "必须传入同步订单参数") | ||
20 | + private PushOrderParam pushOrder; | ||
21 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/utils/AesTools.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/AesTools.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +import com.ectrip.cyt.exception.BusinessException; | ||
4 | +import org.apache.commons.codec.binary.Base64; | ||
5 | +import org.bouncycastle.jce.provider.BouncyCastleProvider; | ||
6 | + | ||
7 | +import javax.crypto.Cipher; | ||
8 | +import javax.crypto.KeyGenerator; | ||
9 | +import javax.crypto.SecretKey; | ||
10 | +import javax.crypto.spec.IvParameterSpec; | ||
11 | +import javax.crypto.spec.SecretKeySpec; | ||
12 | +import java.security.NoSuchAlgorithmException; | ||
13 | +import java.security.Security; | ||
14 | + | ||
15 | +/** | ||
16 | + * @author chenys | ||
17 | + * @date 2022-12-06 | ||
18 | + */ | ||
19 | +public class AesTools { | ||
20 | + private static final String ALGORITHM = "AES"; | ||
21 | + | ||
22 | + /** | ||
23 | + * AES算法 | ||
24 | + */ | ||
25 | + private static final String AES_CBC_PCK_ALG = "AES/CBC/PKCS5Padding"; | ||
26 | + | ||
27 | + // 128-32位16进制;256-64位16进制 | ||
28 | + public static final int DEFAULT_KEY_SIZE = 256; | ||
29 | + | ||
30 | + | ||
31 | + public static String generateKey() throws Exception { | ||
32 | + KeyGenerator kg = KeyGenerator.getInstance(ALGORITHM); | ||
33 | + //下面调用方法的参数决定了生成密钥的长度,可以修改为128, 192或256 | ||
34 | + kg.init(DEFAULT_KEY_SIZE); | ||
35 | + SecretKey sk = kg.generateKey(); | ||
36 | + byte[] b = sk.getEncoded(); | ||
37 | + String secret = Base64.encodeBase64String(b); | ||
38 | + return secret; | ||
39 | + } | ||
40 | + | ||
41 | + | ||
42 | + | ||
43 | + /** | ||
44 | + * AES加密 | ||
45 | + * | ||
46 | + * @param content | ||
47 | + * @param aesKey | ||
48 | + * @return | ||
49 | + * @throws Exception | ||
50 | + */ | ||
51 | + public static String encryptCBC(String content, String aesKey,String ivBase64){ | ||
52 | + try { | ||
53 | + Cipher cipher = Cipher.getInstance(AES_CBC_PCK_ALG); | ||
54 | + IvParameterSpec ivParameterSpec = new IvParameterSpec(SecurityTools.decodeIv(ivBase64)); | ||
55 | + cipher.init(Cipher.ENCRYPT_MODE, new SecretKeySpec(Base64.decodeBase64(aesKey.getBytes()), ALGORITHM), ivParameterSpec); | ||
56 | + byte[] encryptBytes = cipher.doFinal(content.getBytes(OtaUtils.ENCODE_UTF8)); | ||
57 | + return new String(Base64.encodeBase64(encryptBytes)); | ||
58 | + } catch (Exception e) { | ||
59 | + e.printStackTrace(); | ||
60 | + throw new BusinessException("AES加密失败"); | ||
61 | + } | ||
62 | + } | ||
63 | + | ||
64 | + /** | ||
65 | + * AES解密 | ||
66 | + * | ||
67 | + * @param content | ||
68 | + * @param key | ||
69 | + * @return | ||
70 | + * @throws Exception | ||
71 | + */ | ||
72 | + public static String decryptCBC(String content, String key,String ivBase64) { | ||
73 | + try { | ||
74 | + Cipher cipher = Cipher.getInstance(AES_CBC_PCK_ALG); | ||
75 | + IvParameterSpec ivParameterSpec = new IvParameterSpec(SecurityTools.decodeIv(ivBase64)); | ||
76 | + cipher.init(Cipher.DECRYPT_MODE, new SecretKeySpec(Base64.decodeBase64(key.getBytes()), ALGORITHM), ivParameterSpec); | ||
77 | + byte[] cleanBytes = cipher.doFinal(Base64.decodeBase64(content.getBytes())); | ||
78 | + return new String(cleanBytes, OtaUtils.ENCODE_UTF8); | ||
79 | + } catch (Exception e) { | ||
80 | + e.printStackTrace(); | ||
81 | + throw new BusinessException("AES解密失败"); | ||
82 | + } | ||
83 | + } | ||
84 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/utils/Base64Utils.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/Base64Utils.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +/** | ||
4 | + * 将二制数据流转换成BASE64位码。 | ||
5 | + * @author huhaopeng | ||
6 | + */ | ||
7 | +public class Base64Utils { | ||
8 | + static private final int BASELENGTH = 255; | ||
9 | + static private final int LOOKUPLENGTH = 64; | ||
10 | + static private final int TWENTYFOURBITGROUP = 24; | ||
11 | + static private final int EIGHTBIT = 8; | ||
12 | + static private final int SIXTEENBIT = 16; | ||
13 | + static private final int SIXBIT = 6; | ||
14 | + static private final int FOURBYTE = 4; | ||
15 | + static private final int SIGN = -128; | ||
16 | + static private final char PAD = '='; | ||
17 | + static private final boolean fDebug = false; | ||
18 | + static final private byte[] base64Alphabet = new byte[BASELENGTH]; | ||
19 | + static final private char[] lookUpBase64Alphabet = new char[LOOKUPLENGTH]; | ||
20 | + | ||
21 | + static { | ||
22 | + | ||
23 | + for (int i = 0; i < BASELENGTH; i++) { | ||
24 | + base64Alphabet[i] = -1; | ||
25 | + } | ||
26 | + for (int i = 'Z'; i >= 'A'; i--) { | ||
27 | + base64Alphabet[i] = (byte) (i - 'A'); | ||
28 | + } | ||
29 | + for (int i = 'z'; i >= 'a'; i--) { | ||
30 | + base64Alphabet[i] = (byte) (i - 'a' + 26); | ||
31 | + } | ||
32 | + | ||
33 | + for (int i = '9'; i >= '0'; i--) { | ||
34 | + base64Alphabet[i] = (byte) (i - '0' + 52); | ||
35 | + } | ||
36 | + | ||
37 | + base64Alphabet['+'] = 62; | ||
38 | + base64Alphabet['/'] = 63; | ||
39 | + | ||
40 | + for (int i = 0; i <= 25; i++) | ||
41 | + lookUpBase64Alphabet[i] = (char) ('A' + i); | ||
42 | + | ||
43 | + for (int i = 26, j = 0; i <= 51; i++, j++) | ||
44 | + lookUpBase64Alphabet[i] = (char) ('a' + j); | ||
45 | + | ||
46 | + for (int i = 52, j = 0; i <= 61; i++, j++) | ||
47 | + lookUpBase64Alphabet[i] = (char) ('0' + j); | ||
48 | + lookUpBase64Alphabet[62] = (char) '+'; | ||
49 | + lookUpBase64Alphabet[63] = (char) '/'; | ||
50 | + | ||
51 | + } | ||
52 | + | ||
53 | + protected static boolean isWhiteSpace(char octect) { | ||
54 | + return (octect == 0x20 || octect == 0xd || octect == 0xa || octect == 0x9); | ||
55 | + } | ||
56 | + | ||
57 | + protected static boolean isPad(char octect) { | ||
58 | + return (octect == PAD); | ||
59 | + } | ||
60 | + | ||
61 | + protected static boolean isData(char octect) { | ||
62 | + return (base64Alphabet[octect] != -1); | ||
63 | + } | ||
64 | + | ||
65 | + protected static boolean isBase64(char octect) { | ||
66 | + return (isWhiteSpace(octect) || isPad(octect) || isData(octect)); | ||
67 | + } | ||
68 | + | ||
69 | + /** | ||
70 | + * Encodes hex octects into Base64 | ||
71 | + * | ||
72 | + * @param binaryData Array containing binaryData | ||
73 | + * @return Encoded Base64 array | ||
74 | + */ | ||
75 | + public static String encode(byte[] binaryData) { | ||
76 | + | ||
77 | + if (binaryData == null) | ||
78 | + return null; | ||
79 | + | ||
80 | + int lengthDataBits = binaryData.length * EIGHTBIT; | ||
81 | + if (lengthDataBits == 0) { | ||
82 | + return ""; | ||
83 | + } | ||
84 | + | ||
85 | + int fewerThan24bits = lengthDataBits % TWENTYFOURBITGROUP; | ||
86 | + int numberTriplets = lengthDataBits / TWENTYFOURBITGROUP; | ||
87 | + int numberQuartet = fewerThan24bits != 0 ? numberTriplets + 1 | ||
88 | + : numberTriplets; | ||
89 | + int numberLines = (numberQuartet - 1) / 19 + 1; | ||
90 | + char encodedData[] = null; | ||
91 | + | ||
92 | + encodedData = new char[numberQuartet * 4 + numberLines]; | ||
93 | + | ||
94 | + byte k = 0, l = 0, b1 = 0, b2 = 0, b3 = 0; | ||
95 | + | ||
96 | + int encodedIndex = 0; | ||
97 | + int dataIndex = 0; | ||
98 | + int i = 0; | ||
99 | + if (fDebug) { | ||
100 | + //InfoLog.print("number of triplets = " + numberTriplets); | ||
101 | + } | ||
102 | + | ||
103 | + for (int line = 0; line < numberLines - 1; line++) { | ||
104 | + for (int quartet = 0; quartet < 19; quartet++) { | ||
105 | + b1 = binaryData[dataIndex++]; | ||
106 | + b2 = binaryData[dataIndex++]; | ||
107 | + b3 = binaryData[dataIndex++]; | ||
108 | + | ||
109 | + if (fDebug) { | ||
110 | + //InfoLog.print("b1= " + b1 + ", b2= " + b2 + ", b3= "+ b3); | ||
111 | + } | ||
112 | + | ||
113 | + l = (byte) (b2 & 0x0f); | ||
114 | + k = (byte) (b1 & 0x03); | ||
115 | + | ||
116 | + byte val1 = ((b1 & SIGN) == 0) ? (byte) (b1 >> 2) | ||
117 | + : (byte) ((b1) >> 2 ^ 0xc0); | ||
118 | + | ||
119 | + byte val2 = ((b2 & SIGN) == 0) ? (byte) (b2 >> 4) | ||
120 | + : (byte) ((b2) >> 4 ^ 0xf0); | ||
121 | + byte val3 = ((b3 & SIGN) == 0) ? (byte) (b3 >> 6) | ||
122 | + : (byte) ((b3) >> 6 ^ 0xfc); | ||
123 | + | ||
124 | + if (fDebug) { | ||
125 | + //InfoLog.print("val2 = " + val2); | ||
126 | + //InfoLog.print("k4 = " + (k << 4)); | ||
127 | + //InfoLog.print("vak = " + (val2 | (k << 4))); | ||
128 | + } | ||
129 | + | ||
130 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[val1]; | ||
131 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[val2 | ||
132 | + | (k << 4)]; | ||
133 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[(l << 2) | ||
134 | + | val3]; | ||
135 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[b3 & 0x3f]; | ||
136 | + | ||
137 | + i++; | ||
138 | + } | ||
139 | + encodedData[encodedIndex++] = 0xa; | ||
140 | + } | ||
141 | + | ||
142 | + for (; i < numberTriplets; i++) { | ||
143 | + b1 = binaryData[dataIndex++]; | ||
144 | + b2 = binaryData[dataIndex++]; | ||
145 | + b3 = binaryData[dataIndex++]; | ||
146 | + | ||
147 | + if (fDebug) { | ||
148 | + //InfoLog.print("b1= " + b1 + ", b2= " + b2 + ", b3= " + b3); | ||
149 | + } | ||
150 | + | ||
151 | + l = (byte) (b2 & 0x0f); | ||
152 | + k = (byte) (b1 & 0x03); | ||
153 | + | ||
154 | + byte val1 = ((b1 & SIGN) == 0) ? (byte) (b1 >> 2) | ||
155 | + : (byte) ((b1) >> 2 ^ 0xc0); | ||
156 | + | ||
157 | + byte val2 = ((b2 & SIGN) == 0) ? (byte) (b2 >> 4) | ||
158 | + : (byte) ((b2) >> 4 ^ 0xf0); | ||
159 | + byte val3 = ((b3 & SIGN) == 0) ? (byte) (b3 >> 6) | ||
160 | + : (byte) ((b3) >> 6 ^ 0xfc); | ||
161 | + | ||
162 | + if (fDebug) { | ||
163 | + //InfoLog.print("val2 = " + val2); | ||
164 | + //InfoLog.print("k4 = " + (k << 4)); | ||
165 | + //InfoLog.print("vak = " + (val2 | (k << 4))); | ||
166 | + } | ||
167 | + | ||
168 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[val1]; | ||
169 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[val2 | (k << 4)]; | ||
170 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[(l << 2) | val3]; | ||
171 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[b3 & 0x3f]; | ||
172 | + } | ||
173 | + | ||
174 | + // form integral number of 6-bit groups | ||
175 | + if (fewerThan24bits == EIGHTBIT) { | ||
176 | + b1 = binaryData[dataIndex]; | ||
177 | + k = (byte) (b1 & 0x03); | ||
178 | + if (fDebug) { | ||
179 | + //InfoLog.print("b1=" + b1); | ||
180 | + //InfoLog.print("b1<<2 = " + (b1 >> 2)); | ||
181 | + } | ||
182 | + byte val1 = ((b1 & SIGN) == 0) ? (byte) (b1 >> 2) | ||
183 | + : (byte) ((b1) >> 2 ^ 0xc0); | ||
184 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[val1]; | ||
185 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[k << 4]; | ||
186 | + encodedData[encodedIndex++] = PAD; | ||
187 | + encodedData[encodedIndex++] = PAD; | ||
188 | + } else if (fewerThan24bits == SIXTEENBIT) { | ||
189 | + b1 = binaryData[dataIndex]; | ||
190 | + b2 = binaryData[dataIndex + 1]; | ||
191 | + l = (byte) (b2 & 0x0f); | ||
192 | + k = (byte) (b1 & 0x03); | ||
193 | + | ||
194 | + byte val1 = ((b1 & SIGN) == 0) ? (byte) (b1 >> 2) | ||
195 | + : (byte) ((b1) >> 2 ^ 0xc0); | ||
196 | + byte val2 = ((b2 & SIGN) == 0) ? (byte) (b2 >> 4) | ||
197 | + : (byte) ((b2) >> 4 ^ 0xf0); | ||
198 | + | ||
199 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[val1]; | ||
200 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[val2 | (k << 4)]; | ||
201 | + encodedData[encodedIndex++] = lookUpBase64Alphabet[l << 2]; | ||
202 | + encodedData[encodedIndex++] = PAD; | ||
203 | + } | ||
204 | + | ||
205 | + encodedData[encodedIndex] = 0xa; | ||
206 | + | ||
207 | + return new String(encodedData); | ||
208 | + } | ||
209 | + | ||
210 | + /** | ||
211 | + * Decodes Base64 data into octects | ||
212 | + * | ||
213 | + * @param encoded Byte array containing Base64 data | ||
214 | + * @return Array containind decoded data. | ||
215 | + */ | ||
216 | + public static byte[] decode(String encoded) { | ||
217 | + | ||
218 | + if (encoded == null) | ||
219 | + return null; | ||
220 | + | ||
221 | + char[] base64Data = encoded.toCharArray(); | ||
222 | + // remove white spaces | ||
223 | + int len = removeWhiteSpace(base64Data); | ||
224 | + | ||
225 | + if (len % FOURBYTE != 0) { | ||
226 | + return null;//should be divisible by four | ||
227 | + } | ||
228 | + | ||
229 | + int numberQuadruple = (len / FOURBYTE); | ||
230 | + | ||
231 | + if (numberQuadruple == 0) | ||
232 | + return new byte[0]; | ||
233 | + | ||
234 | + byte decodedData[] = null; | ||
235 | + byte b1 = 0, b2 = 0, b3 = 0, b4 = 0, marker0 = 0, marker1 = 0; | ||
236 | + char d1 = 0, d2 = 0, d3 = 0, d4 = 0; | ||
237 | + | ||
238 | + int i = 0; | ||
239 | + int encodedIndex = 0; | ||
240 | + int dataIndex = 0; | ||
241 | + decodedData = new byte[(numberQuadruple) * 3]; | ||
242 | + | ||
243 | + for (; i < numberQuadruple - 1; i++) { | ||
244 | + | ||
245 | + if (!isData((d1 = base64Data[dataIndex++])) | ||
246 | + || !isData((d2 = base64Data[dataIndex++])) | ||
247 | + || !isData((d3 = base64Data[dataIndex++])) | ||
248 | + || !isData((d4 = base64Data[dataIndex++]))) | ||
249 | + return null;//if found "no data" just return null | ||
250 | + | ||
251 | + b1 = base64Alphabet[d1]; | ||
252 | + b2 = base64Alphabet[d2]; | ||
253 | + b3 = base64Alphabet[d3]; | ||
254 | + b4 = base64Alphabet[d4]; | ||
255 | + | ||
256 | + decodedData[encodedIndex++] = (byte) (b1 << 2 | b2 >> 4); | ||
257 | + decodedData[encodedIndex++] = (byte) (((b2 & 0xf) << 4) | ((b3 >> 2) & 0xf)); | ||
258 | + decodedData[encodedIndex++] = (byte) (b3 << 6 | b4); | ||
259 | + } | ||
260 | + | ||
261 | + if (!isData((d1 = base64Data[dataIndex++])) | ||
262 | + || !isData((d2 = base64Data[dataIndex++]))) { | ||
263 | + return null;//if found "no data" just return null | ||
264 | + } | ||
265 | + | ||
266 | + b1 = base64Alphabet[d1]; | ||
267 | + b2 = base64Alphabet[d2]; | ||
268 | + | ||
269 | + d3 = base64Data[dataIndex++]; | ||
270 | + d4 = base64Data[dataIndex++]; | ||
271 | + if (!isData((d3)) || !isData((d4))) {//Check if they are PAD characters | ||
272 | + if (isPad(d3) && isPad(d4)) { //Two PAD e.g. 3c[Pad][Pad] | ||
273 | + if ((b2 & 0xf) != 0)//last 4 bits should be zero | ||
274 | + return null; | ||
275 | + byte[] tmp = new byte[i * 3 + 1]; | ||
276 | + System.arraycopy(decodedData, 0, tmp, 0, i * 3); | ||
277 | + tmp[encodedIndex] = (byte) (b1 << 2 | b2 >> 4); | ||
278 | + return tmp; | ||
279 | + } else if (!isPad(d3) && isPad(d4)) { //One PAD e.g. 3cQ[Pad] | ||
280 | + b3 = base64Alphabet[d3]; | ||
281 | + if ((b3 & 0x3) != 0)//last 2 bits should be zero | ||
282 | + return null; | ||
283 | + byte[] tmp = new byte[i * 3 + 2]; | ||
284 | + System.arraycopy(decodedData, 0, tmp, 0, i * 3); | ||
285 | + tmp[encodedIndex++] = (byte) (b1 << 2 | b2 >> 4); | ||
286 | + tmp[encodedIndex] = (byte) (((b2 & 0xf) << 4) | ((b3 >> 2) & 0xf)); | ||
287 | + return tmp; | ||
288 | + } else { | ||
289 | + return null;//an error like "3c[Pad]r", "3cdX", "3cXd", "3cXX" where X is non data | ||
290 | + } | ||
291 | + } else { //No PAD e.g 3cQl | ||
292 | + b3 = base64Alphabet[d3]; | ||
293 | + b4 = base64Alphabet[d4]; | ||
294 | + decodedData[encodedIndex++] = (byte) (b1 << 2 | b2 >> 4); | ||
295 | + decodedData[encodedIndex++] = (byte) (((b2 & 0xf) << 4) | ((b3 >> 2) & 0xf)); | ||
296 | + decodedData[encodedIndex++] = (byte) (b3 << 6 | b4); | ||
297 | + | ||
298 | + } | ||
299 | + | ||
300 | + return decodedData; | ||
301 | + } | ||
302 | + | ||
303 | + /** | ||
304 | + * remove WhiteSpace from MIME containing encoded Base64 data. | ||
305 | + * | ||
306 | + * @param data the byte array of base64 data (with WS) | ||
307 | + * @return the new length | ||
308 | + */ | ||
309 | + protected static int removeWhiteSpace(char[] data) { | ||
310 | + if (data == null) | ||
311 | + return 0; | ||
312 | + | ||
313 | + // count characters that's not whitespace | ||
314 | + int newSize = 0; | ||
315 | + int len = data.length; | ||
316 | + for (int i = 0; i < len; i++) { | ||
317 | + if (!isWhiteSpace(data[i])) | ||
318 | + data[newSize++] = data[i]; | ||
319 | + } | ||
320 | + return newSize; | ||
321 | + } | ||
322 | +} | ||
323 | + |
zhyx-api/src/main/java/com/ectrip/cyt/utils/BigDecimalUtils.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/BigDecimalUtils.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +import java.math.BigDecimal; | ||
4 | + | ||
5 | +/** | ||
6 | + * 数字精度工具类 | ||
7 | + * | ||
8 | + * @author changjiang.tang Date:8/19/15 Time:2:24 PM | ||
9 | + * @author wenqiang.luo date: 15-9-17 增加数字精准运算方法 | ||
10 | + */ | ||
11 | +public class BigDecimalUtils { | ||
12 | + | ||
13 | + //默认除法运算精度 | ||
14 | + private static final int DEF_DIV_SCALE = 5; | ||
15 | + | ||
16 | + /** | ||
17 | + * 私有构造方法,禁用new创建对象 | ||
18 | + */ | ||
19 | + private BigDecimalUtils() { | ||
20 | + | ||
21 | + } | ||
22 | + | ||
23 | + /** | ||
24 | + * 保留两位小数 | ||
25 | + * @param number 数值 | ||
26 | + * @return 数值,精确到小数点后两位 | ||
27 | + */ | ||
28 | + public static BigDecimal saleUp2(BigDecimal number) { | ||
29 | + return number == null ? null : number.setScale(2, BigDecimal.ROUND_UP); | ||
30 | + } | ||
31 | + | ||
32 | + /** | ||
33 | + * 提供精确的加法运算。 | ||
34 | + * | ||
35 | + * @param v1 被加数 | ||
36 | + * @param v2 加数 | ||
37 | + * @return 两个参数的和 | ||
38 | + */ | ||
39 | + | ||
40 | + public static double add(double v1, double v2) { | ||
41 | + BigDecimal b1 = new BigDecimal(Double.toString(v1)); | ||
42 | + BigDecimal b2 = new BigDecimal(Double.toString(v2)); | ||
43 | + return b1.add(b2).doubleValue(); | ||
44 | + } | ||
45 | + | ||
46 | + /** | ||
47 | + * 提供精确的减法运算。 | ||
48 | + * | ||
49 | + * @param v1 被减数 | ||
50 | + * @param v2 减数 | ||
51 | + * @return 两个参数的差 | ||
52 | + */ | ||
53 | + public static double sub(double v1, double v2) { | ||
54 | + BigDecimal b1 = new BigDecimal(Double.toString(v1)); | ||
55 | + BigDecimal b2 = new BigDecimal(Double.toString(v2)); | ||
56 | + return b1.subtract(b2).doubleValue(); | ||
57 | + } | ||
58 | + | ||
59 | + /** | ||
60 | + * 提供精确的乘法运算。 | ||
61 | + * | ||
62 | + * @param v1 被乘数 | ||
63 | + * @param v2 乘数 | ||
64 | + * @return 两个参数的积 | ||
65 | + */ | ||
66 | + public static double mul(double v1, double v2) { | ||
67 | + BigDecimal b1 = new BigDecimal(Double.toString(v1)); | ||
68 | + BigDecimal b2 = new BigDecimal(Double.toString(v2)); | ||
69 | + return b1.multiply(b2).doubleValue(); | ||
70 | + } | ||
71 | + | ||
72 | + public static double mul(double v1, double... data) { | ||
73 | + BigDecimal result = new BigDecimal(Double.toString(v1)); | ||
74 | + if (data != null && data.length > 0) { | ||
75 | + for (double v : data) { | ||
76 | + result = result.multiply(new BigDecimal(Double.toString(v))); | ||
77 | + } | ||
78 | + } | ||
79 | + return result.doubleValue(); | ||
80 | + } | ||
81 | + | ||
82 | + /** | ||
83 | + * 提供(相对)精确的除法运算,当发生除不尽的情况时,精确到 | ||
84 | + * 小数点以后10位,以后的数字四舍五入。 | ||
85 | + * | ||
86 | + * @param v1 被除数 | ||
87 | + * @param v2 除数 | ||
88 | + * @return 两个参数的商 | ||
89 | + */ | ||
90 | + public static double div(double v1, double v2) { | ||
91 | + return div(v1, v2, DEF_DIV_SCALE); | ||
92 | + } | ||
93 | + | ||
94 | + /** | ||
95 | + * 提供(相对)精确的除法运算。当发生除不尽的情况时,由scale参数指 | ||
96 | + * 定精度,以后的数字四舍五入。 | ||
97 | + * | ||
98 | + * @param v1 被除数 | ||
99 | + * @param v2 除数 | ||
100 | + * @param scale 表示表示需要精确到小数点以后几位。 | ||
101 | + * @return 两个参数的商 | ||
102 | + */ | ||
103 | + public static double div(double v1, double v2, int scale) { | ||
104 | + if (scale < 0) { | ||
105 | + throw new IllegalArgumentException( | ||
106 | + "The scale must be a positive integer or zero"); | ||
107 | + } | ||
108 | + BigDecimal b1 = new BigDecimal(Double.toString(v1)); | ||
109 | + BigDecimal b2 = new BigDecimal(Double.toString(v2)); | ||
110 | + return b1.divide(b2, scale, BigDecimal.ROUND_HALF_UP).doubleValue(); | ||
111 | + } | ||
112 | + | ||
113 | + /** | ||
114 | + * 提供精确的小数位四舍五入处理。 | ||
115 | + * | ||
116 | + * @param v 需要四舍五入的数字 | ||
117 | + * @param scale 小数点后保留几位 | ||
118 | + * @return 四舍五入后的结果 | ||
119 | + */ | ||
120 | + public static double round(double v, int scale) { | ||
121 | + if (scale < 0) { | ||
122 | + throw new IllegalArgumentException( | ||
123 | + "The scale must be a positive integer or zero"); | ||
124 | + } | ||
125 | + BigDecimal b = new BigDecimal(Double.toString(v)); | ||
126 | + BigDecimal one = new BigDecimal("1"); | ||
127 | + return b.divide(one, scale, BigDecimal.ROUND_HALF_UP).doubleValue(); | ||
128 | + } | ||
129 | + | ||
130 | + /** | ||
131 | + * 将浮点数放大 | ||
132 | + * | ||
133 | + * @param v 需放大的数字 | ||
134 | + * @param n 10的幂数 | ||
135 | + * @return 放大后的结果 | ||
136 | + */ | ||
137 | + public static double amplify(double v, int n) { | ||
138 | + BigDecimal b = new BigDecimal(Double.toString(v)); | ||
139 | + return b.movePointRight(n).doubleValue(); | ||
140 | + } | ||
141 | + | ||
142 | + /** | ||
143 | + * 将浮点数放大后取整 | ||
144 | + * | ||
145 | + * @param v 需放大的数字 | ||
146 | + * @param n 10的幂数 | ||
147 | + * @return 放大后取整的结果 | ||
148 | + */ | ||
149 | + public static long amplify2long(double v, int n) { | ||
150 | + BigDecimal b = new BigDecimal(Double.toString(v)); | ||
151 | + return b.movePointRight(n).longValue(); | ||
152 | + } | ||
153 | + | ||
154 | + /** | ||
155 | + * 将浮点数放大后取整 | ||
156 | + * | ||
157 | + * @param v 需放大的数字 | ||
158 | + * @param n 10的幂数 | ||
159 | + * @return 放大后取整的结果 | ||
160 | + */ | ||
161 | + public static int amplify2int(double v, int n) { | ||
162 | + BigDecimal b = new BigDecimal(Double.toString(v)); | ||
163 | + return b.movePointRight(n).intValue(); | ||
164 | + } | ||
165 | + | ||
166 | + /** | ||
167 | + * 将浮点数缩小 | ||
168 | + * | ||
169 | + * @param v 需缩小的数字 | ||
170 | + * @param n 10的幂数 | ||
171 | + * @return 缩小后的结果 | ||
172 | + */ | ||
173 | + public static double shrink(double v, int n) { | ||
174 | + BigDecimal b = new BigDecimal(Double.toString(v)); | ||
175 | + return b.movePointLeft(n).doubleValue(); | ||
176 | + } | ||
177 | + | ||
178 | + /** | ||
179 | + * 将整数数缩小成浮点数 | ||
180 | + * | ||
181 | + * @param v 需缩小的数字 | ||
182 | + * @param n 10的幂数 | ||
183 | + * @return 缩小成浮点数的结果 | ||
184 | + */ | ||
185 | + public static double shrink2double(long v, int n) { | ||
186 | + BigDecimal b = new BigDecimal(Long.toString(v)); | ||
187 | + return b.movePointLeft(n).doubleValue(); | ||
188 | + } | ||
189 | + | ||
190 | + /** | ||
191 | + * 将整数数缩小成浮点数 | ||
192 | + * | ||
193 | + * @param v 需缩小的数字 | ||
194 | + * @param n 10的幂数 | ||
195 | + * @return 缩小成浮点数的结果 | ||
196 | + */ | ||
197 | + public static double shrink2double(int v, int n) { | ||
198 | + BigDecimal b = new BigDecimal(Integer.toString(v)); | ||
199 | + return b.movePointLeft(n).doubleValue(); | ||
200 | + } | ||
201 | + | ||
202 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/utils/DateUtils.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/DateUtils.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +import org.apache.commons.lang3.StringUtils; | ||
4 | +import org.slf4j.Logger; | ||
5 | +import org.slf4j.LoggerFactory; | ||
6 | + | ||
7 | +import java.sql.Time; | ||
8 | +import java.sql.Timestamp; | ||
9 | +import java.text.ParseException; | ||
10 | +import java.text.SimpleDateFormat; | ||
11 | +import java.util.Calendar; | ||
12 | +import java.util.Date; | ||
13 | + | ||
14 | +/** | ||
15 | + * 实现描述:时间操作工具类 | ||
16 | + * | ||
17 | + * @version v1.0.0 | ||
18 | + * @see | ||
19 | + */ | ||
20 | +public class DateUtils { | ||
21 | + public final static String DATE_CHINESE_PATTERN = "yyyy年MM月dd日"; | ||
22 | + /** | ||
23 | + * 标准日期格式 | ||
24 | + */ | ||
25 | + public final static String DATE_PATTERN = "yyyy-MM-dd"; | ||
26 | + | ||
27 | + public final static String DATE_SHORT_PATTERN = "yyyyMMdd"; | ||
28 | + | ||
29 | + public final static String DATE_SLASH_PATTERN = "yyyy/MM/dd"; | ||
30 | + | ||
31 | + /** | ||
32 | + * 标准日期时分秒毫秒格式 | ||
33 | + */ | ||
34 | + public final static String DATETIME_MILL_SECOND = "yyyy-MM-dd HH:mm:ss.SSS"; | ||
35 | + | ||
36 | + /** | ||
37 | + * 标准时间格式 | ||
38 | + */ | ||
39 | + public final static String DATETIME_PATTERN = "yyyy-MM-dd HH:mm:ss"; | ||
40 | + | ||
41 | + /** | ||
42 | + * 特殊的格式 针对创建订单,拼凑的最晚支付时间 | ||
43 | + */ | ||
44 | + public final static String DATETIME_PATTERN_CREAT_ORDER = "yyyy-MM-ddHH:mm"; | ||
45 | + | ||
46 | + public final static String DATETIME_SHORT_PATTERN = "yyyyMMddHHmmss"; | ||
47 | + | ||
48 | + /** | ||
49 | + * 标准年小时分钟格式 | ||
50 | + */ | ||
51 | + public final static String HOUR_MINUTE = "HH:mm"; | ||
52 | + | ||
53 | + /** | ||
54 | + * 标准年小时分钟秒格式 | ||
55 | + */ | ||
56 | + public final static String HOUR_MINUTE_SECOND = "HH:mm:ss"; | ||
57 | + | ||
58 | + private final static Logger logger = LoggerFactory.getLogger(DateUtils.class); | ||
59 | + | ||
60 | + /** | ||
61 | + * Number of milliseconds in a standard day. | ||
62 | + */ | ||
63 | + public static final long MILLIS_PER_DAY = 24 * DateUtils.MILLIS_PER_HOUR; | ||
64 | + | ||
65 | + /** | ||
66 | + * Number of milliseconds in a standard hour. | ||
67 | + */ | ||
68 | + public static final long MILLIS_PER_HOUR = 60 * DateUtils.MILLIS_PER_MINUTE; | ||
69 | + | ||
70 | + /** | ||
71 | + * Number of milliseconds in a standard minute. | ||
72 | + */ | ||
73 | + public static final long MILLIS_PER_MINUTE = 60 * DateUtils.MILLIS_PER_SECOND; | ||
74 | + | ||
75 | + /** | ||
76 | + * Number of milliseconds in a standard second. | ||
77 | + */ | ||
78 | + public static final long MILLIS_PER_SECOND = 1000; | ||
79 | + | ||
80 | + /** | ||
81 | + * 标准年月格式 | ||
82 | + */ | ||
83 | + public final static String MONTH_PATTERN = "yyyy-MM"; | ||
84 | + | ||
85 | + private final static String[] WEEK_NAMES = {"星期一", "星期二", "星期三", "星期四", "星期五", "星期六", "星期天"}; | ||
86 | + | ||
87 | + /** | ||
88 | + * 在指定日期增加指定天数 | ||
89 | + * | ||
90 | + * @param date 指定日期 | ||
91 | + * @param days 指定天数 | ||
92 | + * @return | ||
93 | + */ | ||
94 | + public static Date addDay(Date date, int days) { | ||
95 | + if (days == 0) { | ||
96 | + return date; | ||
97 | + } | ||
98 | + Calendar c = Calendar.getInstance(); | ||
99 | + c.setTime(date); | ||
100 | + c.add(Calendar.DAY_OF_YEAR, days); | ||
101 | + return c.getTime(); | ||
102 | + } | ||
103 | + | ||
104 | + /** | ||
105 | + * 在指定日期增加指定天数 | ||
106 | + * | ||
107 | + * @param date 指定日期 | ||
108 | + * @param days 指定天数 | ||
109 | + * @return | ||
110 | + */ | ||
111 | + public static Date addDay(String date, int days) { | ||
112 | + return DateUtils.addDay(DateUtils.convertDate(date), days); | ||
113 | + } | ||
114 | + | ||
115 | + public static Date addMinute(Date date, int minute) { | ||
116 | + Calendar c = Calendar.getInstance(); | ||
117 | + c.setTime(date); | ||
118 | + c.add(Calendar.MINUTE, minute); | ||
119 | + return c.getTime(); | ||
120 | + } | ||
121 | + | ||
122 | + /** | ||
123 | + * 当前日期之后 | ||
124 | + * | ||
125 | + * @param date | ||
126 | + * @return | ||
127 | + */ | ||
128 | + public static boolean afterToday(Object date) { | ||
129 | + Date currentDate = new Date(); | ||
130 | + return DateUtils.compareDate(date, currentDate) == 1; | ||
131 | + } | ||
132 | + | ||
133 | + /** | ||
134 | + * 当前时间之后 | ||
135 | + * | ||
136 | + * @param date | ||
137 | + * @return | ||
138 | + */ | ||
139 | + public static boolean afterTodayDate(Date date) { | ||
140 | + Date currentDate = new Date(); | ||
141 | + return currentDate.compareTo(date) == -1; | ||
142 | + } | ||
143 | + | ||
144 | + /** | ||
145 | + * 当前日期之前 | ||
146 | + * | ||
147 | + * @param date | ||
148 | + * @return | ||
149 | + */ | ||
150 | + public static boolean beforeToday(Object date) { | ||
151 | + Date currentDate = new Date(); | ||
152 | + return DateUtils.compareDate(date, currentDate) == -1; | ||
153 | + } | ||
154 | + | ||
155 | + /** | ||
156 | + * 当前时间之前 | ||
157 | + * | ||
158 | + * @param date | ||
159 | + * @return | ||
160 | + */ | ||
161 | + public static boolean beforeTodayDate(Date date) { | ||
162 | + Date currentDate = new Date(); | ||
163 | + return currentDate.compareTo(date) == 1; | ||
164 | + } | ||
165 | + | ||
166 | + /** | ||
167 | + * 比较两个日期date1大于date1 返回1 等于返回0 小于返回-1 | ||
168 | + * | ||
169 | + * @param date1 | ||
170 | + * @param date2 | ||
171 | + * @return | ||
172 | + */ | ||
173 | + public static int compareDate(Object date1, Object date2) { | ||
174 | + if (date1 == null || date2 == null) { | ||
175 | + String msg = "illegal arguments,date1 and date2 must be not null."; | ||
176 | + throw new IllegalArgumentException(msg); | ||
177 | + } | ||
178 | + Date d1 = (Date) (date1 instanceof String ? DateUtils.convertDate((String) date1) : date1); | ||
179 | + Date d2 = (Date) (date2 instanceof String ? DateUtils.convertDate((String) date2) : date2); | ||
180 | + return DateUtils.round(d1, Calendar.DATE).compareTo(DateUtils.round(d2, Calendar.DATE)); | ||
181 | + } | ||
182 | + | ||
183 | + public static Date convertDate(Date date, String pattern) { | ||
184 | + if (StringUtils.isEmpty(pattern)) { | ||
185 | + String msg = "the date or pattern is empty."; | ||
186 | + throw new IllegalArgumentException(msg); | ||
187 | + } | ||
188 | + String dateForPattern = DateUtils.formatDate(date, pattern); | ||
189 | + return DateUtils.convertDate(dateForPattern, pattern); | ||
190 | + } | ||
191 | + | ||
192 | + /** | ||
193 | + * 将long型整数转化为时间。 | ||
194 | + * | ||
195 | + * @param date 时间对应的long值 | ||
196 | + * @return 时间对象 | ||
197 | + */ | ||
198 | + public static Date convertDate(Long date) { | ||
199 | + return new Date(date); | ||
200 | + } | ||
201 | + | ||
202 | + /** | ||
203 | + * 将日期或者时间戳转化为日期对象 | ||
204 | + * | ||
205 | + * @param date yyyy-MM-dd or yyyy-MM-dd HH:mm:ss or yyyy-MM-dd HH:mm:ss.SSS | ||
206 | + * @return | ||
207 | + */ | ||
208 | + public static Date convertDate(String date) { | ||
209 | + if (StringUtils.isBlank(date)) { | ||
210 | + return null; | ||
211 | + } | ||
212 | + if (date.indexOf(":") > 0) { | ||
213 | + return DateUtils.convertDate(date, DateUtils.DATETIME_PATTERN); | ||
214 | + } else if (date.indexOf(".") > 0) { | ||
215 | + return DateUtils.convertDate(date, DateUtils.DATETIME_MILL_SECOND); | ||
216 | + } else { | ||
217 | + return DateUtils.convertDate(date, DateUtils.DATE_PATTERN); | ||
218 | + } | ||
219 | + } | ||
220 | + | ||
221 | + /** | ||
222 | + * 将日期或者时间字符串转化为日期对象 | ||
223 | + * | ||
224 | + * @param date 日期字符串 | ||
225 | + * @param pattern 格式字符串</br> yyyy-MM-DD, yyyy/MM/DD, yyyyMMdd</br> yyyy-MM-dd-HH:mm:ss, yyyy-MM-dd HH:mm:ss | ||
226 | + * 格式字符串可选字符:"GyMdkHmsSEDFwWahKzZ" | ||
227 | + * @return Date | ||
228 | + * @see java.text.DateFormatSymbols.patternChars</br> | ||
229 | + */ | ||
230 | + public static Date convertDate(String date, String pattern) { | ||
231 | + try { | ||
232 | + if (StringUtils.isEmpty(pattern) || StringUtils.isEmpty(date)) { | ||
233 | + String msg = "the date or pattern is empty."; | ||
234 | + throw new IllegalArgumentException(msg); | ||
235 | + } | ||
236 | + SimpleDateFormat df = new SimpleDateFormat(pattern.trim()); | ||
237 | + return df.parse(date.trim()); | ||
238 | + } catch (Exception e) { | ||
239 | + DateUtils.logger.error("Method===DateUtils.convertDate error!", e); | ||
240 | + return null; | ||
241 | + } | ||
242 | + } | ||
243 | + | ||
244 | + /** | ||
245 | + * 将时间字符串转化为时间对象Time | ||
246 | + * | ||
247 | + * @param time 时间字符串 | ||
248 | + * @param pattern 格式字符串 yyyy-MM-dd HH:mm:ss or yyyy-MM-dd HH:mm:ss.SSS | ||
249 | + * @return | ||
250 | + */ | ||
251 | + public static Time convertTime(String time, String pattern) { | ||
252 | + Date d = DateUtils.convertDate(time, pattern); | ||
253 | + return new Time(d.getTime()); | ||
254 | + } | ||
255 | + | ||
256 | + /** | ||
257 | + * 获得日期相差天数 | ||
258 | + * | ||
259 | + * @param date1 日期 | ||
260 | + * @param date2 日期 | ||
261 | + * @return | ||
262 | + */ | ||
263 | + public static int diffDate(Date date1, Date date2) { | ||
264 | + return (int) ((date1.getTime() - date2.getTime()) / DateUtils.MILLIS_PER_DAY); | ||
265 | + } | ||
266 | + | ||
267 | + /** | ||
268 | + * 获取两个日期相差的分钟数 | ||
269 | + * | ||
270 | + * @param date1 | ||
271 | + * @param date2 | ||
272 | + * @return | ||
273 | + */ | ||
274 | + public static int diffMinute(Date date1, Date date2) { | ||
275 | + return (int) ((date1.getTime() - date2.getTime()) / DateUtils.MILLIS_PER_MINUTE); | ||
276 | + } | ||
277 | + | ||
278 | + /** | ||
279 | + * 格式为时间字符串 | ||
280 | + * | ||
281 | + * @param date 日期 | ||
282 | + * @return yyyy-MM-dd Date | ||
283 | + */ | ||
284 | + public static String formatDate(Date date) { | ||
285 | + try { | ||
286 | + return DateUtils.formatDate(date, DateUtils.DATE_PATTERN); | ||
287 | + } catch (Exception e) { | ||
288 | + return null; | ||
289 | + } | ||
290 | + } | ||
291 | + | ||
292 | + /** | ||
293 | + * 按指定格式字符串格式时间 | ||
294 | + * | ||
295 | + * @param date 日期或者时间 | ||
296 | + * @param pattern 格式化字符串 yyyy-MM-dd, yyyy-MM-dd HH:mm:ss, yyyy年MM月dd日 etc.</br> | ||
297 | + * @return | ||
298 | + */ | ||
299 | + public static String formatDate(Date date, String pattern) { | ||
300 | + SimpleDateFormat format = new SimpleDateFormat(pattern.trim()); | ||
301 | + return format.format(date); | ||
302 | + } | ||
303 | + | ||
304 | + /** | ||
305 | + * 格式为时间戳字符串 | ||
306 | + * | ||
307 | + * @param date 时间 | ||
308 | + * @return yyyy-MM-dd HH:mm:ss Date | ||
309 | + */ | ||
310 | + public static String formatDateTime(Date date) { | ||
311 | + try { | ||
312 | + return DateUtils.formatDate(date, DateUtils.DATETIME_PATTERN); | ||
313 | + } catch (Exception e) { | ||
314 | + return null; | ||
315 | + } | ||
316 | + } | ||
317 | + | ||
318 | + /** | ||
319 | + * 将制定时间格式为字符串'yyyyMMddHHmmss'. | ||
320 | + * | ||
321 | + * @return | ||
322 | + */ | ||
323 | + public static String formatDateToYMDHMS(Date date) { | ||
324 | + return DateUtils.formatDate(date, DateUtils.DATETIME_SHORT_PATTERN); | ||
325 | + } | ||
326 | + | ||
327 | + public static String formatMonth(Date date) { | ||
328 | + return DateUtils.formatDate(date, DateUtils.MONTH_PATTERN); | ||
329 | + } | ||
330 | + | ||
331 | + /** | ||
332 | + * 将当前时间格式为字符串'yyyyMMddHHmmss'. | ||
333 | + * | ||
334 | + * @return | ||
335 | + */ | ||
336 | + public static String formatNowToYMDHMS() { | ||
337 | + return DateUtils.formatDateToYMDHMS(new Date()); | ||
338 | + } | ||
339 | + | ||
340 | + public static Timestamp getCurrentTimestamp() { | ||
341 | + return new Timestamp(new Date().getTime()); | ||
342 | + } | ||
343 | + | ||
344 | + public static Date getDateFromShortString(String str) { | ||
345 | + SimpleDateFormat simpleDF = new SimpleDateFormat("yyyy-MM-dd"); | ||
346 | + try { | ||
347 | + return simpleDF.parse(str); | ||
348 | + } catch (ParseException e) { | ||
349 | + DateUtils.logger.warn("parse date error", e); | ||
350 | + } | ||
351 | + return null; | ||
352 | + } | ||
353 | + | ||
354 | + /** | ||
355 | + * 获得本周第一天 | ||
356 | + * | ||
357 | + * @param date | ||
358 | + * @return | ||
359 | + */ | ||
360 | + public static Date getFirstDayOfThisWeek(Date date) { | ||
361 | + Calendar cal = Calendar.getInstance(); | ||
362 | + cal.setTime(date); | ||
363 | + cal.setFirstDayOfWeek(Calendar.MONDAY); | ||
364 | + cal.set(Calendar.DAY_OF_WEEK, Calendar.MONDAY); | ||
365 | + return cal.getTime(); | ||
366 | + } | ||
367 | + | ||
368 | + /** | ||
369 | + * 获得小时 | ||
370 | + * | ||
371 | + * @param date | ||
372 | + * @return | ||
373 | + */ | ||
374 | + public static int getHourOfDay(Date date) { | ||
375 | + Calendar c = Calendar.getInstance(); | ||
376 | + c.setTime(date); | ||
377 | + return c.get(Calendar.HOUR_OF_DAY); | ||
378 | + } | ||
379 | + | ||
380 | + public static Date getLastMonth() { | ||
381 | + Calendar c = Calendar.getInstance(); | ||
382 | + int month = c.get(Calendar.MONTH); | ||
383 | + c.set(Calendar.MONTH, month - 1); | ||
384 | + return c.getTime(); | ||
385 | + } | ||
386 | + | ||
387 | + /** | ||
388 | + * 获得分钟数 | ||
389 | + * | ||
390 | + * @param date | ||
391 | + * @return | ||
392 | + */ | ||
393 | + public static int getMinute(Date date) { | ||
394 | + Calendar c = Calendar.getInstance(); | ||
395 | + c.setTime(date); | ||
396 | + return c.get(Calendar.MINUTE); | ||
397 | + } | ||
398 | + | ||
399 | + /** | ||
400 | + * 获取后续第n天日期 | ||
401 | + * | ||
402 | + * @param date | ||
403 | + * @param n 第n天 | ||
404 | + * @return | ||
405 | + */ | ||
406 | + public static Date getNextNDay(Date date, int n) { | ||
407 | + Calendar cal = Calendar.getInstance(); | ||
408 | + cal.setTime(date); | ||
409 | + cal.add(Calendar.DATE, n); | ||
410 | + return cal.getTime(); | ||
411 | + } | ||
412 | + | ||
413 | + /** | ||
414 | + * 获得星期数 | ||
415 | + * | ||
416 | + * @param date 日期 | ||
417 | + * @return | ||
418 | + */ | ||
419 | + public static int getWeekNumber(Date date) { | ||
420 | + Calendar c = Calendar.getInstance(); | ||
421 | + c.setTime(date); | ||
422 | + int number = c.get(Calendar.DAY_OF_WEEK) - 1; | ||
423 | + if (number == 0) { | ||
424 | + number = 7; | ||
425 | + } | ||
426 | + return number; | ||
427 | + } | ||
428 | + | ||
429 | + /** | ||
430 | + * 获得星期名称 | ||
431 | + * | ||
432 | + * @param date | ||
433 | + * @return | ||
434 | + */ | ||
435 | + public static String getWeekNumberString(Date date) { | ||
436 | + int dayNum = DateUtils.getWeekNumber(date); | ||
437 | + return DateUtils.WEEK_NAMES[dayNum - 1]; | ||
438 | + } | ||
439 | + | ||
440 | + /** | ||
441 | + * 是否同一天 | ||
442 | + * | ||
443 | + * @param date1 | ||
444 | + * @param date2 | ||
445 | + * @return | ||
446 | + */ | ||
447 | + public static boolean isSameDay(Object date1, Object date2) { | ||
448 | + return DateUtils.compareDate(date1, date2) == 0; | ||
449 | + } | ||
450 | + | ||
451 | + /** | ||
452 | + * 检查时间或者字符串是否合法 | ||
453 | + * | ||
454 | + * @param date 时间 | ||
455 | + * @param pattern 格式串 | ||
456 | + * @return | ||
457 | + */ | ||
458 | + public static boolean isValidDate(String date, String pattern) { | ||
459 | + try { | ||
460 | + DateUtils.convertDate(pattern, date); | ||
461 | + return true; | ||
462 | + } catch (Exception e) { | ||
463 | + DateUtils.logger.error("Method===DateUtils.isValidDate error!", e); | ||
464 | + return false; | ||
465 | + } | ||
466 | + } | ||
467 | + | ||
468 | + /** | ||
469 | + * 获得当前时间戳 | ||
470 | + * | ||
471 | + * @return Timestamp | ||
472 | + */ | ||
473 | + public static Timestamp now() { | ||
474 | + return new Timestamp(new Date().getTime()); | ||
475 | + } | ||
476 | + | ||
477 | + /** | ||
478 | + * 获得当前时间字符串,格式为:yyyy-MM-dd HH:mm:ss | ||
479 | + * | ||
480 | + * @return | ||
481 | + */ | ||
482 | + public static String nowDateTime() { | ||
483 | + return DateUtils.formatDate(new Date(), DateUtils.DATETIME_PATTERN); | ||
484 | + } | ||
485 | + | ||
486 | + /** | ||
487 | + * 按指定roundType格式化日期。 | ||
488 | + * | ||
489 | + * @param date 日期 | ||
490 | + * @param roundType | ||
491 | + * @return Date | ||
492 | + * @see Calendar.MONTH, java.util.Calendar.DATE, java.util.Calendar.HOUR, java.util.Calendar.MINUTE, java.util.Calendar.SECOND | ||
493 | + */ | ||
494 | + public static Date round(Date date, int roundType) { | ||
495 | + Calendar c = Calendar.getInstance(); | ||
496 | + c.setTimeInMillis(date.getTime()); | ||
497 | + switch (roundType) { | ||
498 | + case Calendar.MONTH: | ||
499 | + c.set(Calendar.DAY_OF_MONTH, 1); | ||
500 | + case Calendar.DATE: | ||
501 | + c.set(Calendar.HOUR_OF_DAY, 0); | ||
502 | + case Calendar.HOUR: | ||
503 | + c.set(Calendar.MINUTE, 0); | ||
504 | + case Calendar.MINUTE: | ||
505 | + c.set(Calendar.SECOND, 0); | ||
506 | + case Calendar.SECOND: | ||
507 | + c.set(Calendar.MILLISECOND, 0); | ||
508 | + return c.getTime(); | ||
509 | + default: | ||
510 | + throw new IllegalArgumentException("invalid round roundType."); | ||
511 | + } | ||
512 | + } | ||
513 | + | ||
514 | + /** | ||
515 | + * 获得当前日期对象 | ||
516 | + * | ||
517 | + * @return | ||
518 | + */ | ||
519 | + public static Date today() { | ||
520 | + return DateUtils.convertDate(DateUtils.formatDate(new Date()), DateUtils.DATE_PATTERN); | ||
521 | + } | ||
522 | + | ||
523 | + /** | ||
524 | + * 获得当前日期字符串,格式为:yyyy-MM-dd | ||
525 | + * | ||
526 | + * @return | ||
527 | + */ | ||
528 | + public static String todayDate() { | ||
529 | + return DateUtils.formatDate(new Date()); | ||
530 | + } | ||
531 | + | ||
532 | + /** | ||
533 | + * 将日期或者时间字符串转化为Timestamp对象 | ||
534 | + * | ||
535 | + * @param date 日期字符串 | ||
536 | + * @param pattern 格式字符串</br> yyyy-MM-DD, yyyy/MM/DD, yyyyMMdd</br> yyyy-MM-dd-HH:mm:ss, yyyy-MM-dd HH:mm:ss | ||
537 | + * @return Timestamp | ||
538 | + * @author reeboo | ||
539 | + */ | ||
540 | + public static Timestamp toTimestamp(String date, String pattern) { | ||
541 | + SimpleDateFormat format = new SimpleDateFormat(pattern.trim()); | ||
542 | + try { | ||
543 | + return new Timestamp(format.parse(date).getTime()); | ||
544 | + } catch (ParseException e) { | ||
545 | + } | ||
546 | + return null; | ||
547 | + } | ||
548 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/utils/EncryptUtil.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/EncryptUtil.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +import org.apache.commons.codec.binary.Base64; | ||
4 | +import sun.misc.BASE64Decoder; | ||
5 | +import sun.misc.BASE64Encoder; | ||
6 | + | ||
7 | +import javax.crypto.*; | ||
8 | +import javax.crypto.spec.DESedeKeySpec; | ||
9 | +import java.io.UnsupportedEncodingException; | ||
10 | +import java.security.InvalidKeyException; | ||
11 | +import java.security.MessageDigest; | ||
12 | +import java.security.NoSuchAlgorithmException; | ||
13 | +import java.security.SecureRandom; | ||
14 | +import java.security.spec.InvalidKeySpecException; | ||
15 | + | ||
16 | + | ||
17 | +/** | ||
18 | + * 基础加密算法类?当前支持des,md5码? | ||
19 | + * | ||
20 | + * @author huhaopeng | ||
21 | + */ | ||
22 | +public class EncryptUtil { | ||
23 | + | ||
24 | + /** | ||
25 | + * MD5值计码?p> | ||
26 | + * MD5的算法在RFC1321 中定码? | ||
27 | + * 在RFC 1321中,给出了Test suite用来码?码码你的实现是否正确码? | ||
28 | + * MD5 ("") = d41d8cd98f00b204e9800998ecf8427e | ||
29 | + * MD5 ("a") = 0cc175b9c0f1b6a831c399e269772661 | ||
30 | + * MD5 ("abc") = 900150983cd24fb0d6963f7d28e17f72 | ||
31 | + * MD5 ("message digest") = f96b697d7cb7938d525a2f31aaf161d0 | ||
32 | + * MD5 ("abcdefghijklmnopqrstuvwxyz") = c3fcd3d76192e4007dfb496cca67e13b | ||
33 | + * | ||
34 | + * @param str 源字符串 | ||
35 | + * @return md5码? | ||
36 | + */ | ||
37 | + public final static byte[] md5(String str) { | ||
38 | + try { | ||
39 | + byte[] res = str.getBytes("UTF-8"); | ||
40 | + MessageDigest mdTemp = MessageDigest.getInstance("MD5".toUpperCase()); | ||
41 | + mdTemp.update(res); | ||
42 | + byte[] hash = mdTemp.digest(); | ||
43 | + return hash; | ||
44 | + } catch (Exception e) { | ||
45 | + e.printStackTrace(); | ||
46 | + return null; | ||
47 | + } | ||
48 | + } | ||
49 | + | ||
50 | + //hex repr. of md5 | ||
51 | + public final static String MD5Hex(String input) { | ||
52 | + String s = null; | ||
53 | + char hexDigits[] = { // 用来将字节转换成 16 进制表示的字码? | ||
54 | + '0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'a', 'b', 'c', 'd', | ||
55 | + 'e', 'f'}; | ||
56 | + try { | ||
57 | + MessageDigest md = MessageDigest | ||
58 | + .getInstance("MD5"); | ||
59 | + md.update(input.getBytes("utf-8")); | ||
60 | + byte tmp[] = md.digest(); | ||
61 | + | ||
62 | + char str[] = new char[16 * 2]; | ||
63 | + | ||
64 | + int k = 0; | ||
65 | + for (int i = 0; i < 16; i++) { | ||
66 | + | ||
67 | + byte byte0 = tmp[i]; | ||
68 | + str[k++] = hexDigits[byte0 >>> 4 & 0xf]; | ||
69 | + str[k++] = hexDigits[byte0 & 0xf]; | ||
70 | + } | ||
71 | + s = new String(str); | ||
72 | + } catch (Exception e) { | ||
73 | + e.printStackTrace(); | ||
74 | + } | ||
75 | + return s; | ||
76 | + } | ||
77 | + | ||
78 | + // 加密后解码? | ||
79 | + public static String JM(byte[] inStr) { | ||
80 | + String newStr = new String(inStr); | ||
81 | + char[] a = newStr.toCharArray(); | ||
82 | + for (int i = 0; i < a.length; i++) { | ||
83 | + a[i] = (char) (a[i] ^ 't'); | ||
84 | + } | ||
85 | + String k = new String(a); | ||
86 | + return k; | ||
87 | + } | ||
88 | + | ||
89 | + | ||
90 | + /** | ||
91 | + * BASE64加密 | ||
92 | + * | ||
93 | + * @param key | ||
94 | + * @return | ||
95 | + * @throws Exception | ||
96 | + */ | ||
97 | + public static String BASE64Encrypt(byte[] key) { | ||
98 | + String edata = null; | ||
99 | + try { | ||
100 | + edata = (new BASE64Encoder()).encodeBuffer(key).trim(); | ||
101 | + } catch (Exception e) { | ||
102 | + e.printStackTrace(); | ||
103 | + } | ||
104 | + return edata; | ||
105 | + } | ||
106 | + | ||
107 | + | ||
108 | + /** | ||
109 | + * BASE64解密 | ||
110 | + * | ||
111 | + * @param data | ||
112 | + * @return | ||
113 | + * @throws Exception | ||
114 | + */ | ||
115 | + public static byte[] BASE64Decrypt(String data) { | ||
116 | + if (data == null) return null; | ||
117 | + byte[] edata = null; | ||
118 | + try { | ||
119 | + edata = (new BASE64Decoder()).decodeBuffer(data); | ||
120 | + return edata; | ||
121 | + } catch (Exception e) { | ||
122 | + e.printStackTrace(); | ||
123 | + } | ||
124 | + return null; | ||
125 | + } | ||
126 | + | ||
127 | + /** | ||
128 | + * @param key 24位密码? | ||
129 | + * @param str 源字符串 | ||
130 | + * @return | ||
131 | + * @throws NoSuchAlgorithmException | ||
132 | + * @throws NoSuchPaddingException | ||
133 | + * @throws InvalidKeyException | ||
134 | + * @throws UnsupportedEncodingException | ||
135 | + * @throws InvalidKeySpecException | ||
136 | + * @throws IllegalBlockSizeException | ||
137 | + * @throws BadPaddingException | ||
138 | + */ | ||
139 | + public static byte[] des3Encrypt(String key, String str) throws NoSuchAlgorithmException, NoSuchPaddingException, InvalidKeyException, UnsupportedEncodingException, InvalidKeySpecException, IllegalBlockSizeException, BadPaddingException { | ||
140 | + | ||
141 | + byte[] newkey = key.getBytes(); | ||
142 | + | ||
143 | + SecureRandom sr = new SecureRandom(); | ||
144 | + | ||
145 | + DESedeKeySpec dks = new DESedeKeySpec(newkey); | ||
146 | + | ||
147 | + SecretKeyFactory keyFactory = SecretKeyFactory.getInstance("DESede"); | ||
148 | + | ||
149 | + SecretKey securekey = keyFactory.generateSecret(dks); | ||
150 | + | ||
151 | + Cipher cipher = Cipher.getInstance("DESede/ECB/PKCS5Padding"); | ||
152 | + | ||
153 | + cipher.init(Cipher.ENCRYPT_MODE, securekey, sr); | ||
154 | + | ||
155 | + byte[] bt = cipher.doFinal(str.getBytes("utf-8")); | ||
156 | + | ||
157 | + return bt; | ||
158 | + } | ||
159 | + | ||
160 | + public static String des3EncryptWithString(String key, String str) { | ||
161 | + try { | ||
162 | + return Base64.encodeBase64String(des3Encrypt(key, str)); | ||
163 | + } catch (Exception e) { | ||
164 | + e.printStackTrace(); | ||
165 | + } | ||
166 | + return null; | ||
167 | + } | ||
168 | + | ||
169 | + public static String des3DecryptWithString(byte[] edata, String key) { | ||
170 | + try { | ||
171 | + byte[] bytes = Base64.decodeBase64(edata); | ||
172 | + return des3Decrypt(bytes, key); | ||
173 | + } catch (Exception e) { | ||
174 | + e.printStackTrace(); | ||
175 | + } | ||
176 | + return null; | ||
177 | + } | ||
178 | + | ||
179 | + | ||
180 | + /** | ||
181 | + * 解密 | ||
182 | + * | ||
183 | + * @param edata | ||
184 | + * @param key | ||
185 | + * @return | ||
186 | + * @throws Exception | ||
187 | + */ | ||
188 | + public static String des3Decrypt(byte[] edata, String key) { | ||
189 | + String data = ""; | ||
190 | + try { | ||
191 | + if (edata != null) { | ||
192 | + byte[] newkey = key.getBytes(); | ||
193 | + DESedeKeySpec dks = new DESedeKeySpec(newkey); | ||
194 | + SecretKeyFactory keyFactory = SecretKeyFactory.getInstance("DESede"); | ||
195 | + SecretKey securekey = keyFactory.generateSecret(dks); | ||
196 | + Cipher cipher = Cipher.getInstance("DESede/ECB/PKCS5Padding"); | ||
197 | + cipher.init(Cipher.DECRYPT_MODE, securekey, new SecureRandom()); | ||
198 | + byte[] bb = cipher.doFinal(edata); | ||
199 | + data = new String(bb, "UTF-8"); | ||
200 | + } | ||
201 | + } catch (Exception e) { | ||
202 | + e.printStackTrace(); | ||
203 | + } | ||
204 | + return data; | ||
205 | + } | ||
206 | + | ||
207 | + public final static String taoBaoMD5(String s) { | ||
208 | + char hexDigits[] = {'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', | ||
209 | + 'a', 'b', 'c', 'd', 'e', 'f'}; | ||
210 | + try { | ||
211 | + byte[] strTemp = s.getBytes("GBK"); | ||
212 | + MessageDigest mdTemp = MessageDigest.getInstance("MD5"); | ||
213 | + mdTemp.update(strTemp); | ||
214 | + byte[] md = mdTemp.digest(); | ||
215 | + int j = md.length; | ||
216 | + char str[] = new char[j * 2]; | ||
217 | + int k = 0; | ||
218 | + for (int i = 0; i < j; i++) { | ||
219 | + byte byte0 = md[i]; | ||
220 | + str[k++] = hexDigits[byte0 >>> 4 & 0xf]; | ||
221 | + str[k++] = hexDigits[byte0 & 0xf]; | ||
222 | + } | ||
223 | + return new String(str); | ||
224 | + } catch (Exception e) { | ||
225 | + e.printStackTrace(); | ||
226 | + return null; | ||
227 | + } | ||
228 | + } | ||
229 | +} | ||
230 | + |
zhyx-api/src/main/java/com/ectrip/cyt/utils/OrderStatusUtils.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/OrderStatusUtils.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +/** | ||
4 | + * PMS订单状态工具 | ||
5 | + * @author wenqiang.luo date:15-9-30 | ||
6 | + */ | ||
7 | +public class OrderStatusUtils { | ||
8 | + | ||
9 | + /** | ||
10 | + * 私有构造方法 | ||
11 | + */ | ||
12 | + private OrderStatusUtils() { | ||
13 | + | ||
14 | + } | ||
15 | + | ||
16 | + /** | ||
17 | + * 预付:初始订单 | ||
18 | + */ | ||
19 | + public static final String PREPAY_ORDER_INIT = "PREPAY_ORDER_INIT"; | ||
20 | + /** | ||
21 | + * 预付:预付失败 | ||
22 | + */ | ||
23 | + public static final String PREPAY_ORDER_BOOK_FAILED = "PREPAY_ORDER_BOOK_FAILED"; | ||
24 | + /** | ||
25 | + * 预付成功:待支付 | ||
26 | + */ | ||
27 | + public static final String PREPAY_ORDER_NOT_PAYED = "PREPAY_ORDER_NOT_PAYED"; | ||
28 | + /** | ||
29 | + * 预付:订单已取消 | ||
30 | + */ | ||
31 | + public static final String PREPAY_ORDER_CANCEL = "PREPAY_ORDER_CANCEL"; | ||
32 | + /** | ||
33 | + * 预付:已付款,出票中 | ||
34 | + */ | ||
35 | + public static final String PREPAY_ORDER_PRINTING = "PREPAY_ORDER_PRINTING"; | ||
36 | + /** | ||
37 | + * 预付:出票失败 | ||
38 | + */ | ||
39 | + public static final String PREPAY_ORDER_PRINT_FAILED = "PREPAY_ORDER_PRINT_FAILED"; | ||
40 | + /** | ||
41 | + * 预付:出票成功 | ||
42 | + */ | ||
43 | + public static final String PREPAY_ORDER_PRINT_SUCCESS = "PREPAY_ORDER_PRINT_SUCCESS"; | ||
44 | + | ||
45 | + /** | ||
46 | + * 预付:退订失败 | ||
47 | + */ | ||
48 | + public static final String PREPAY_ORDER_REFUNDFAIL = "PREPAY_ORDER_REFUNDFAIL"; | ||
49 | + /** | ||
50 | + * 预付:已退订 | ||
51 | + */ | ||
52 | + public static final String PREPAY_ORDER_REFUNDED = "PREPAY_ORDER_REFUNDED"; | ||
53 | + /** | ||
54 | + * 预付:已消费 | ||
55 | + */ | ||
56 | + public static final String PREPAY_ORDER_CONSUMED = "PREPAY_ORDER_CONSUMED"; | ||
57 | + /** | ||
58 | + * 现付:初始订单 | ||
59 | + */ | ||
60 | + public static final String CASHPAY_ORDER_INIT = "CASHPAY_ORDER_INIT"; | ||
61 | + /** | ||
62 | + * 现付:出票失败 | ||
63 | + */ | ||
64 | + public static final String CASHPAY_ORDER_PRINT_FAILED = "CASHPAY_ORDER_PRINT_FAILED"; | ||
65 | + /** | ||
66 | + * 现付:出票成功 | ||
67 | + */ | ||
68 | + public static final String CASHPAY_ORDER_PRINT_SUCCESS = "CASHPAY_ORDER_PRINT_SUCCESS"; | ||
69 | + /** | ||
70 | + * 现付:已退订 | ||
71 | + */ | ||
72 | + public static final String CASHPAY_ORDER_REFUNDED = "CASHPAY_ORDER_REFUNDED"; | ||
73 | + /** | ||
74 | + * 现付:已消费 | ||
75 | + */ | ||
76 | + public static final String CASHPAY_ORDER_CONSUMED = "CASHPAY_ORDER_CONSUMED"; | ||
77 | + | ||
78 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/utils/OtaUtils.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/OtaUtils.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +import com.ectrip.cyt.model.enums.CredentialsType; | ||
4 | +import com.ectrip.cyt.model.enums.OrderStatusType; | ||
5 | + | ||
6 | +import java.util.HashMap; | ||
7 | +import java.util.Map; | ||
8 | + | ||
9 | +/** | ||
10 | + * @author wenqiang.luo date:15-10-6 | ||
11 | + */ | ||
12 | +public class OtaUtils { | ||
13 | + | ||
14 | + /** | ||
15 | + * 私有构造方法 | ||
16 | + */ | ||
17 | + private OtaUtils() { | ||
18 | + | ||
19 | + } | ||
20 | + | ||
21 | + public static final String ENCODE_UTF8 = "UTF-8"; | ||
22 | + | ||
23 | + // | ||
24 | + public static final String VERSION2 = "2.0.0"; | ||
25 | + public static final String VERSION3 = "3.0.0"; | ||
26 | + | ||
27 | + //交互代码 | ||
28 | + public static final String SUCCESS_CODE = "1000";/** 交互成功标识 */ | ||
29 | + | ||
30 | + public static final String SUCCESS_DESCRIPTION = "SUCCESS";/** 交互成功描述 */ | ||
31 | + | ||
32 | + //加密算法 | ||
33 | + public static final String SECURITY_MD5 = "MD5"; | ||
34 | + public static final String SECURITY_AES_CBC = "AES/CBC"; | ||
35 | + public static final String SECURITY_SM4_CBC = "SM4/CBC"; | ||
36 | + | ||
37 | + public static final String JSON_DATA = "data"; | ||
38 | + public static final String JSON_SIGNED = "signed"; | ||
39 | + public static final String JSON_IV = "iv"; | ||
40 | + public static final String JSON_CREATEUSER = "createUser"; | ||
41 | + public static final String JSON_SECURITY_TYPE = "securityType"; | ||
42 | + public static final String REQUEST_XML = "requestXml"; | ||
43 | + public static final String RESPONSE_XML = "responseXml"; | ||
44 | + public static final String REQUEST_JSON_OBJECT = "requestJsonObject"; | ||
45 | + public static final String RESPONSE_JSON_OBJECT = "responseJsonObject"; | ||
46 | + public static final String KEY = "key"; | ||
47 | + public static final String SECURITY_TYPE = "securityType"; | ||
48 | + public static final String DISTRIBUTOR_NAME = "distributorName"; | ||
49 | + public static final String SUPPLIER_IDENTITY = "supplierIdentity"; | ||
50 | + public static final String ECTRIP = "ectrip"; | ||
51 | + public static final String DOM_HEADER = "header"; | ||
52 | + public static final String DOM_BODY = "body"; | ||
53 | + | ||
54 | + //接口方法 | ||
55 | + public final static String HEART_BEAT = "heartBeat"; | ||
56 | + public static final String GET_BALANCE = "getBalance"; | ||
57 | + public final static String PUSH_ORDER = "pushOrder"; | ||
58 | + public final static String CHECK_ORDER = "checkOrder"; | ||
59 | + public final static String GET_ORDER_BY_OTA = "getOrderByOTA"; | ||
60 | + public final static String APPLY_ORDER_REFUND_BY_USER = "applyOrderRefundByUser"; | ||
61 | + public final static String CREATE_ORDER ="createOrder"; | ||
62 | + public final static String CREATE_PAY_ORDER ="createPaymentOrder"; | ||
63 | + public final static String PAY_ORDER ="payOrder"; | ||
64 | + public final static String CANCEL_ORDER ="cancelOrder"; | ||
65 | + public final static String GET_PRODUCT_BY_OTA="getProductByOTA"; | ||
66 | + public final static String GET_AVAILABLE_PRODUCT="getAvailableProduct"; | ||
67 | + public static final String GET_STOCK_PRODUCT_INFO = "getStockProductInfo"; | ||
68 | + public static final String GET_SEAT_INFO = "getSeatInfo"; | ||
69 | + public static final String SEND_ORDER_ETICKET = "sendOrderEticket"; | ||
70 | + | ||
71 | + /** | ||
72 | + * 订单状态映射 | ||
73 | + */ | ||
74 | + public static Map<OrderStatusType, String> prepayOrderStatusTypeStringMap = new HashMap<OrderStatusType, String>() { | ||
75 | + { | ||
76 | + /** 未付款 */ | ||
77 | + put(OrderStatusType.ORDER_NOT_PAYED_YET, "PREPAY_ORDER_INIT"); | ||
78 | + | ||
79 | + /** 已取消 */ | ||
80 | + put(OrderStatusType.ORDER_CANCELED, "PREPAY_ORDER_CANCEL"); | ||
81 | + | ||
82 | + /** 预订成功 */ | ||
83 | + put(OrderStatusType.ORDER_RESERVE_SUCCESSFUL, "PREPAY_ORDER_PRINTING"); | ||
84 | + | ||
85 | + /** 预订失败 */ | ||
86 | + put(OrderStatusType.ORDER_RESERVE_FAILED, "PREPAY_ORDER_PRINT_FAILED"); | ||
87 | + | ||
88 | + /** 已消费 */ | ||
89 | + put(OrderStatusType.ORDER_CONSUMED, "PREPAY_ORDER_CONSUMED"); | ||
90 | + | ||
91 | + /** 已退款 */ | ||
92 | + put(OrderStatusType.ORDER_REFUNDED, "PREPAY_ORDER_REFUNDED"); | ||
93 | + } | ||
94 | + | ||
95 | + private static final long serialVersionUID = -6074224384596465754L; | ||
96 | + }; | ||
97 | + | ||
98 | + /** | ||
99 | + * 证件类型 - String 映射 | ||
100 | + */ | ||
101 | + public static Map<CredentialsType, String> credentialsTypeStringMap = new HashMap<CredentialsType, String>() { | ||
102 | + { | ||
103 | + put(CredentialsType.ID_CARD, "ID_CARD"); | ||
104 | + put(CredentialsType.HUZHAO, "HUZHAO"); | ||
105 | + put(CredentialsType.TAIBAO, "TAIBAO"); | ||
106 | + put(CredentialsType.GANGAO, "GANGAO"); | ||
107 | + put(CredentialsType.OFFICER, "OTHER"); | ||
108 | + put(CredentialsType.OTHER, "OTHER"); | ||
109 | + put(CredentialsType.GUIYI, "GUIYI"); | ||
110 | + put(CredentialsType.STUDENT, "OTHER"); | ||
111 | + } | ||
112 | + | ||
113 | + private static final long serialVersionUID = -4521723122855266147L; | ||
114 | + }; | ||
115 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/utils/SM4Tools.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/SM4Tools.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +import com.ectrip.cyt.exception.BusinessException; | ||
4 | +import org.apache.commons.codec.binary.Base64; | ||
5 | +import org.bouncycastle.jce.provider.BouncyCastleProvider; | ||
6 | +import org.bouncycastle.pqc.math.linearalgebra.ByteUtils; | ||
7 | +import org.bouncycastle.util.encoders.Hex; | ||
8 | + | ||
9 | +import javax.crypto.*; | ||
10 | +import javax.crypto.spec.IvParameterSpec; | ||
11 | +import javax.crypto.spec.SecretKeySpec; | ||
12 | +import java.security.*; | ||
13 | + | ||
14 | +/** | ||
15 | + * @Author zhoumengjun | ||
16 | + * @Description sm4加密算法工具类 | ||
17 | + * @Date 2023/7/12 10:47 | ||
18 | + */ | ||
19 | +public class SM4Tools { | ||
20 | + | ||
21 | + static { | ||
22 | + Security.addProvider(new BouncyCastleProvider()); | ||
23 | + } | ||
24 | + | ||
25 | + public static final String ALGORITHM = "SM4"; | ||
26 | + | ||
27 | + // 加密算法/分组加密模式/分组填充方式 | ||
28 | + // PKCS5Padding-以8个字节为一组进行分组加密 | ||
29 | + // 定义分组加密模式使用:PKCS5Padding | ||
30 | + public static final String SM4_CBC_PCK_ALG = "SM4/CBC/PKCS5Padding"; | ||
31 | + | ||
32 | + // 128-32位16进制;256-64位16进制 | ||
33 | + public static final int DEFAULT_KEY_SIZE = 128; | ||
34 | + | ||
35 | + | ||
36 | + public static String encryptCBC(String content, String key,String ivBase64){ | ||
37 | + try { | ||
38 | + String cipherText = ""; | ||
39 | + // 16进制字符串-->byte[] | ||
40 | + byte[] keyData = ByteUtils.fromHexString(key); | ||
41 | + // String-->byte[] | ||
42 | + byte[] srcData = content.getBytes(OtaUtils.ENCODE_UTF8); | ||
43 | + // 加密后的数组 | ||
44 | + Cipher cipher = generateCBCCipher(SM4_CBC_PCK_ALG, Cipher.ENCRYPT_MODE, keyData,SecurityTools.decodeIv(ivBase64)); | ||
45 | + byte[] cipherArray = cipher.doFinal(srcData); | ||
46 | + // byte[]-->hexString | ||
47 | + cipherText = ByteUtils.toHexString(cipherArray); | ||
48 | + return cipherText; | ||
49 | + }catch (Exception e){ | ||
50 | + throw new BusinessException("SM4加密失败"); | ||
51 | + } | ||
52 | + } | ||
53 | + | ||
54 | + public static String decryptCBC(String content, String key,String ivBase64){ | ||
55 | + try { | ||
56 | + // 用于接收解密后的字符串 | ||
57 | + String decryptStr = ""; | ||
58 | + // hexString-->byte[] | ||
59 | + byte[] keyData = ByteUtils.fromHexString(key); | ||
60 | + // hexString-->byte[] | ||
61 | + byte[] cipherData = ByteUtils.fromHexString(content); | ||
62 | + // 解密 | ||
63 | + Cipher cipher = generateCBCCipher(SM4_CBC_PCK_ALG, Cipher.DECRYPT_MODE, keyData,SecurityTools.decodeIv(ivBase64)); | ||
64 | + byte[] srcData = cipher.doFinal(cipherData); | ||
65 | + // byte[]-->String | ||
66 | + decryptStr = new String(srcData, OtaUtils.ENCODE_UTF8); | ||
67 | + return decryptStr; | ||
68 | + }catch (Exception e){ | ||
69 | + throw new BusinessException("SM4解密失败"); | ||
70 | + } | ||
71 | + } | ||
72 | + | ||
73 | + /** | ||
74 | + * 生成ECB暗号 | ||
75 | + * | ||
76 | + * @param algorithmName 算法名称 | ||
77 | + * @param mode 模式 | ||
78 | + * @param key | ||
79 | + * @return | ||
80 | + * @throws Exception | ||
81 | + * @explain ECB模式(电子密码本模式:Electronic codebook) | ||
82 | + */ | ||
83 | + private static Cipher generateCBCCipher(String algorithmName, int mode, byte[] key,byte[] iv) throws NoSuchPaddingException, NoSuchAlgorithmException, NoSuchProviderException, InvalidAlgorithmParameterException, InvalidKeyException { | ||
84 | + Cipher cipher = Cipher.getInstance(algorithmName, BouncyCastleProvider.PROVIDER_NAME); | ||
85 | + Key sm4Key = new SecretKeySpec(key, ALGORITHM); | ||
86 | + IvParameterSpec ivParameterSpec = new IvParameterSpec(iv); | ||
87 | + cipher.init(mode, sm4Key,ivParameterSpec); | ||
88 | + return cipher; | ||
89 | + } | ||
90 | + | ||
91 | + public static void main(String[] args) { | ||
92 | + try { | ||
93 | + String key = SecurityTools.generateKey(OtaUtils.SECURITY_AES_CBC); | ||
94 | + System.out.println(key); | ||
95 | + String iv = SecurityTools.generatorIv(); | ||
96 | + System.out.println(iv); | ||
97 | + String data ="<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\"?>\n" + | ||
98 | + "<request xmlns=\"http://tour.ectrip.com/2014/QMRequestDataSchema\">\n" + | ||
99 | + " <header>\n" + | ||
100 | + " <application>tour.ectrip.com</application>\n" + | ||
101 | + " <processor>DataExchangeProcessor</processor>\n" + | ||
102 | + " <version>v1.0.0</version>\n" + | ||
103 | + " <bodyType>GetOrderByOTARequestBody</bodyType>\n" + | ||
104 | + " <createUser>wllvmama</createUser>\n" + | ||
105 | + " <createTime>2020-11-18 11:36:09</createTime>\n" + | ||
106 | + " </header>\n" + | ||
107 | + " <body xsi:type=\"GetOrderByOTARequestBody\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\">\n" + | ||
108 | + " <partnerOrderId>91201118999003835</partnerOrderId>\n" + | ||
109 | + " </body>\n" + | ||
110 | + "</request>\n" + | ||
111 | + "\n"; | ||
112 | + //加密 | ||
113 | + String cipher = AesTools.encryptCBC(data, key,iv); | ||
114 | + System.out.println("加密后:"+cipher); | ||
115 | + //解密 | ||
116 | + String res = AesTools.decryptCBC(cipher, key,iv); | ||
117 | + System.out.println("解密后:"+res); | ||
118 | + } catch (Exception e) { | ||
119 | + e.printStackTrace(); | ||
120 | + } | ||
121 | + } | ||
122 | + | ||
123 | + /** | ||
124 | + * 根据位数 自动生成密钥 | ||
125 | + * | ||
126 | + * @return | ||
127 | + * @explain | ||
128 | + */ | ||
129 | + public static String generateKey() throws Exception { | ||
130 | + KeyGenerator kg = KeyGenerator.getInstance(ALGORITHM, BouncyCastleProvider.PROVIDER_NAME); | ||
131 | + kg.init(DEFAULT_KEY_SIZE, new SecureRandom()); | ||
132 | + byte[] bytes = kg.generateKey().getEncoded(); | ||
133 | + return new String(Hex.encode(bytes)); | ||
134 | + } | ||
135 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/utils/SecurityTools.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/SecurityTools.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +import org.apache.commons.codec.binary.Base64; | ||
4 | +import org.apache.commons.lang3.StringUtils; | ||
5 | +import org.bouncycastle.jce.provider.BouncyCastleProvider; | ||
6 | +import org.bouncycastle.util.encoders.Hex; | ||
7 | + | ||
8 | +import javax.crypto.KeyGenerator; | ||
9 | +import java.security.SecureRandom; | ||
10 | + | ||
11 | +public class SecurityTools { | ||
12 | + /** | ||
13 | + * 根据位数 自动生成密钥 | ||
14 | + * | ||
15 | + * @return | ||
16 | + * @explain | ||
17 | + */ | ||
18 | + public static String generateKey(String securityType) throws Exception { | ||
19 | + if(StringUtils.isBlank(securityType)){ | ||
20 | + return ""; | ||
21 | + }else if(securityType.equals(OtaUtils.SECURITY_AES_CBC)){ | ||
22 | + return AesTools.generateKey(); | ||
23 | + }else if(securityType.equals(OtaUtils.SECURITY_SM4_CBC)){ | ||
24 | + return SM4Tools.generateKey(); | ||
25 | + } | ||
26 | + return ""; | ||
27 | + } | ||
28 | + | ||
29 | + public static String generatorIv(){ | ||
30 | + // Generate a random IV | ||
31 | + SecureRandom random = new SecureRandom(); | ||
32 | + byte[] iv = new byte[16]; // AES/CBC/PKCS5Padding requires 16-byte IV | ||
33 | + random.nextBytes(iv); | ||
34 | + // Convert the IV to Base64 for easier handling | ||
35 | + String ivBase64 = Base64.encodeBase64String(iv); | ||
36 | + return ivBase64; | ||
37 | + } | ||
38 | + | ||
39 | + public static byte[] decodeIv(String ivBase64){ | ||
40 | + return Base64.decodeBase64(ivBase64); | ||
41 | + } | ||
42 | + | ||
43 | + public static void main(String[] args) throws Exception { | ||
44 | + System.out.println(generateKey(OtaUtils.SECURITY_SM4_CBC)); | ||
45 | + } | ||
46 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/utils/TestOrderUtils.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/TestOrderUtils.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +import java.text.SimpleDateFormat; | ||
4 | +import java.util.Date; | ||
5 | +import java.util.Random; | ||
6 | +import java.util.UUID; | ||
7 | + | ||
8 | +public class TestOrderUtils { | ||
9 | + public static String get16UUID() { | ||
10 | + int machineId = 1; | ||
11 | + int hashCodeV = UUID.randomUUID().toString().hashCode(); | ||
12 | + if (hashCodeV < 0) { | ||
13 | + hashCodeV = -hashCodeV; | ||
14 | + } | ||
15 | + return machineId + String.format("%015d", hashCodeV); | ||
16 | + } | ||
17 | + static final int cities [] = { | ||
18 | + 350602, 370782, 513431, 532624, 530426, 370203, 350128, 421002, 350624, 430225, 360300, 350203, 220211, 420822, 530625, 653126, 420203, 220182, 230603, 533323, 430121, 621225, 652827, 511500, 450205, 652824, 411402, 440781, 469022, 370214, 542521, 433101, 460100, 530381, 411722, 533400, 110229, 640300, 210700, 450127, 440105, 530828, 120000, 420000, 211402, 341823, 220402, 330500, 371324, 150500, 150927, 321284, 230231, 150926, 630123, 341700, 441400, 542330, 370684, 370828, 654326, 610831, 140300, 350581, 421182, 421200, 341124, 371423, 445302, 513225, 532522, 469026, 450102, 433130, 222406, 511325, 410328, 210422, 430405, 341100, 140212, 445222, 350403, 430521, 520111, 652924, 522201, 542327, 110103, 530826, 630122, 610527, 330481, 522424, 820000, 231081, 410103, 431223, 230524, 441284, 500226, 152524, 211382, 530300, 411102, 410727, 152223, 451200, 610203, 230805, 500116, 341222, 420324, 610500, 141128, 371202, 140426, 510181, 341021, 340421, 130623, 152529, 130626, 530902, 220102, 532801, 220183, 632122, 371622, 140721, 340121, 420503, 632524, 610327, 130500, 152923, 150422, 420528, 140221, 430502, 610921, 422822, 130627, 430105, 410926, 340603, 510321, 211202, 522729, 653100, 421123, 310104, 341282, 410602, 510304, 230712, 320481, 532627, 610800, 610522, 360829, 410105, 410106, 431126, 330127, 131126, 350428, 130930, 430621, 130724, 450681, 411381, 130208, 411200, 522327, 640105, 321282, 632323, 371481, 420800, 621124, 341825, 340300, 450923, 530500, 411423, 150302, 530821, 140802, 310115, 410203, 420116, 371724, 430922, 130800, 150502, 210711, 230207, 511529, 530325, 320402, 542300, 140723, 542221, 511800, 150430, 440700, 220421, 350181, 520329, 350784, 440115, 330304, 411221, 510107, 360803, 520221, 350603, 421003, 411522, 150205, 220503, 620421, 370303, 451031, 150525, 360700, 340711, 620403, 610924, 500117, 542626, 511922, 620800, 450123, 533123, 320900, 410423, 330902, 451002, 623027, 620923, 220204, 420923, 210922, 150429, 150929, 420684, 610427, 150624, 340702, 360313, 320300, 320600, 431228, 621000, 370323, 530421, 640104, 370503, 533421, 420102, 371428, 220105, 350981, 370113, 230503, 130925, 231025, 620300, 341524, 130127, 231200, 130224, 420606, 652922, 371426, 130402, 140826, 511304, 610724, 511823, 542100, 510303, 440113, 500114, 542337, 451381, 513336, 441427, 450311, 630105, 361122, 610829, 360425, 130128, 350105, 511525, 220202, 632724, 350205, 310112, 640303, 623023, 140726, 513229, 330103, 420204, 140725, 350500, 511826, 211322, 630102, 230822, 653022, 130426, 371121, 632200, 640521, 621100, 511524, 130803, 130982, 451202, 350600, 450324, 130424, 510800, 640324, 131028, 450305, 340828, 140423, 654028, 110114, 340503, 653128, 610823, 510184, 310105, 542622, 610821, 511602, 522730, 331000, 360100, 410421, 450107, 150826, 610525, 140922, 140107, 632522, 130283, 130121, 130431, 632523, 430223, 530112, 361023, 361181, 411421, 340302, 654325, 360733, 370322, 450126, 632721, 320924, 430321, 532625, 652927, 440523, 230302, 511702, 361025, 150725, 360731, 321183, 451024, 440404, 320205, 321302, 370306, 371322, 510311, 360102, 431124, 410883, 500238, 230110, 522422, 331123, 411403, 522229, 520424, 510682, 320000, 231102, 652101, 371000, 130107, 420527, 542121, 500112, 150425, 140225, 341623, 331100, 430522, 540123, 500000, 652923, 130726, 150223, 420529, 440783, 530921, 211003, 320281, 513223, 530700, 450400, 331004, 410303, 511681, 640205, 640424, 620821, 441424, 530522, 630000, 370634, 360726, 230604, 150523, 371302, 340323, 141023, 220581, 610431, 610524, 220724, 150922, 410600, 211103, 440800, 632222, 230505, 330211, 360721, 130406, 522627, 422826, 220122, 210882, 230826, 530102, 130921, 469002, 360424, 340123, 220502, 120112, 450422, 370830, 152201, 320107, 361028, 510104, 440923, 654000, 330621, 141034, 450803, 510727, 621222, 530000, 610825, 610302, 510400, 450109, 441202, 429021, 654201, 211300, 140624, 360302, 511528, 130108, 532527, 652826, 520303, 530825, 330322, 511600, 430281, 340406, 230624, 522223, 500235, 220281, 411503, 610322, 411330, 533100, 210122, 411726, 341102, 220181, 530626, 130826, 411622, 232722, 340825, 230102, 441500, 360826, 420111, 141082, 141182, 231281, 620200, 441581, 431129, 440183, 130604, 220800, 532329, 620321, 610526, 510000, 411224, 621022, 130428, 340521, 130205, 421087, 532621, 130628, 310118, 440902, 510502, 321000, 420583, 130804, 542522, 360103, 410800, 420113, 530829, 532524, 421125, 542301, 513424, 460107, 320830, 421000, 513230, 331024, 360222, 220303, 530602, 511522, 130823, 441802, 420881, 330200, 330727, 361124, 530113, 330803, 440114, 210211, 430726, 152526, 533321, 460000, 510600, 411282, 420281, 500118, 522625, 350426, 150522, 330382, 530424, 611023, 130532, 231084, 469031, 150300, 210600, 341302, 130185, 320400, 450330, 445102, 150404, 420506, 410311, 411623, 522401, 440803, 421022, 320114, 451226, 211421, 611024, 360200, 410700, 150222, 371203, 360123, 320703, 210282, 320322, 211221, 433100, 623025, 350505, 330108, 230803, 360732, 510124, 510302, 420106, 430211, 330183, 420205, 640323, 140224, 653226, 321102, 420984, 330424, 441882, 210800, 340500, 140932, 510703, 522631, 230127, 420582, 211302, 330503, 500242, 652302, 371626, 433123, 520321, 210900, 652900, 410184, 654221, 330881, 371081, 410104, 370829, 150104, 450521, 441223, 420600, 460106, 433125, 130630, 370211, 520114, 451423, 230381, 231085, 360321, 340223, 430412, 410811, 130303, 542127, 632621, 220103, 610830, 211121, 650106, 451324, 654322, 430224, 610626, 341821, 150981, 421023, 430203, 441827, 653201, 411000, 211081, 632127, 610624, 370321, 130638, 532530, 210204, 451321, 510525, 140924, 330326, 230203, 520328, 321081, 330782, 350583, 510623, 621025, 622926, 450222, 610404, 431322, 350123, 611021, 371400, 360900, 131023, 360111, 370902, 440281, 131081, 150421, 330329, 340104, 140200, 520200, 610822, 370700, 411600, 341721, 210811, 230705, 341502, 522623, 220622, 130184, 152200, 542424, 130200, 130730, 130400, 430721, 431026, 230902, 140729, 152502, 130522, 652925, 450303, 632626, 350504, 230100, 211011, 530428, 451030, 610422, 450405, 532327, 310108, 371327, 210100, 500113, 371102, 410221, 511821, 542122, 360122, 610828, 350721, 450502, 445321, 511825, 140108, 320504, 513432, 371325, 610623, 431202, 330825, 511725, 150621, 511129, 350623, 430682, 511133, 150103, 110116, 152202, 350481, 451425, 420504, 440300, 522425, 360823, 510403, 620103, 320382, 632722, 421024, 410326, 450421, 220882, 350724, 542329, 370900, 610304, 230500, 341800, 341000, 230882, 610622, 522626, 653124, 230700, 431123, 450122, 620402, 370523, 532628, 451227, 620422, 320721, 210681, 451302, 230707, 130525, 210727, 341421, 420922, 110109, 410402, 350925, 640400, 371122, 450100, 513430, 231224, 433122, 230208, 610727, 610303, 140226, 140429, 330102, 653225, 632726, 522230, 542125, 230703, 341723, 130207, 532502, 620724, 530321, 469028, 131128, 320115, 610402, 320723, 610328, 231002, 140702, 330683, 371312, 230421, 411121, 211303, 410922, 441624, 220700, 370405, 420300, 220282, 370784, 632625, 430529, 510524, 141123, 650200, 140430, 361123, 110000, 370283, 430124, 141181, 420105, 330122, 150100, 511521, 431122, 440308, 222424, 330903, 130625, 210102, 610423, 632624, 513200, 513231, 610521, 440229, 130727, 230230, 210202, 511621, 130404, 520422, 430681, 510521, 532532, 410204, 532323, 130126, 411625, 511100, 320623, 530822, 420381, 350423, 654202, 512022, 220702, 361030, 230711, 210111, 530128, 431302, 341321, 532328, 542334, 140121, 542523, 320507, 620902, 450221, 370612, 410724, 520122, 131182, 431002, 321300, 610502, 522222, 621121, 210403, 370284, 522300, 210423, 420302, 450602, 530326, 350902, 530722, 350781, 330109, 310230, 522723, 610326, 320111, 620822, 350525, 510823, 450981, 630100, 500240, 320305, 361128, 361024, 232700, 341023, 350782, 650202, 532926, 610103, 610923, 350200, 141028, 450512, 513332, 411721, 441481, 431381, 511000, 440205, 430703, 522325, 361129, 130132, 350924, 610632, 131121, 350211, 140421, 421100, 410803, 510626, 321181, 150428, 530624, 361027, 450902, 331082, 360921, 222403, 340881, 231182, 431025, 610926, 511400, 420625, 140322, 370786, 710000, 522328, 370304, 620121, 371523, 420683, 450702, 540124, 360428, 420505, 140105, 411323, 430921, 450921, 320206, 140223, 320506, 620623, 370212, 441200, 360983, 310120, 410400, 430423, 371723, 530422, 320724, 513325, 441324, 530600, 370400, 230722, 610728, 513335, 620982, 110107, 350429, 623021, 230708, 371328, 131082, 441825, 370783, 610400, 140781, 421122, 430300, 513429, 522634, 350825, 500115, 210504, 130722, 430923, 370686, 422827, 141030, 420802, 140603, 422828, 140923, 131026, 542200, 220623, 141027, 360203, 222402, 350824, 513331, 632801, 430603, 140823, 440513, 110102, 120225, 610429, 610826, 350430, 542231, 532531, 420100, 441881, 450200, 532525, 621002, 440606, 511822, 370681, 500101, 371326, 430100, 410900, 532822, 130824, 441226, 410482, 370831, 210321, 513427, 340404, 420104, 610621, 371700, 530622, 511421, 140500, 140829, 371103, 650100, 460108, 360600, 370881, 361021, 371082, 522732, 542226, 150800, 210323, 532301, 430722, 441625, 622901, 371425, 513333, 411321, 440811, 130721, 533325, 530111, 410782, 430624, 210702, 130130, 421222, 411327, 130624, 230108, 231222, 610582, 430981, 410224, 610700, 360830, 130705, 530802, 361125, 220106, 542427, 320411, 652926, 210903, 120223, 330682, 140600, 430700, 411602, 430702, 371726, 440282, 440982, 540122, 360827, 653121, 230715, 530323, 620721, 141031, 610112, 140902, 130183, 622923, 371625, 210603, 532325, 532500, 321100, 320113, 411023, 652122, 513434, 320321, 510105, 430304, 330104, 361127, 440608, 230123, 520112, 542129, 350122, 632128, 654300, 130635, 410381, 650105, 370205, 410181, 511181, 211321, 130733, 542128, 445323, 450821, 621221, 361000, 450329, 360622, 340207, 522428, 530827, 141130, 610631, 620111, 410000, 210522, 220104, 130631, 610102, 140825, 230710, 341702, 650103, 150727, 320802, 542126, 445122, 532528, 522722, 130433, 140921, 522725, 320684, 522200, 440605, 370685, 510903, 652825, 441521, 310103, 320103, 220221, 410711, 623026, 370124, 532600, 130421, 230111, 445100, 320505, 350104, 542422, 230621, 520421, 220323, 130302, 520302, 320405, 331021, 411624, 130203, 469027, 152523, 130133, 542338, 441323, 620500, 420981, 150221, 360782, 150802, 411082, 141100, 610323, 130923, 430611, 360423, 620722, 330206, 640381, 620700, 150921, 370406, 654002, 540127, 410222, 330411, 130629, 510802, 511025, 130322, 450000, 451402, 420321, 150124, 610723, 120110, 371100, 370000, 522601, 150823, 230206, 361026, 610000, 310114, 130223, 530924, 141021, 360802, 420902, 542623, 430725, 451300, 130125, 450332, 632700, 469033, 411329, 530721, 430406, 130637, 331023, 420114, 622921, 150822, 530630, 632725, 421221, 610104, 320705, 370481, 440400, 621126, 530328, 513437, 220723, 450105, 140728, 510812, 230605, 350722, 441623, 520121, 410325, 500236, 140727, 131181, 610116, 370403, 210000, 410411, 469023, 130100, 410122, 410523, 411681, 140122, 360730, 330324, 510421, 320700, 350527, 371500, 440402, 640302, 411024, 500107, 320124, 370921, 370682, 230225, 530900, 530124, 532523, 810000, 371422, 511527, 620823, 411081, 411724, 430822, 340403, 330802, 421083, 421281, 130928, 430811, 210802, 522624, 445281, 520102, 140927, 150625, 511523, 420325, 513330, 140623, 410324, 440825, 431221, 654003, 445300, 341004, 130521, 340208, 410802, 440000, 410183, 422823, 542222, 522426, 621200, 150928, 210803, 650203, 654301, 320903, 341422, 430202, 632121, 650204, 430524, 130481, 542430, 130981, 320324, 210400, 330381, 230183, 431128, 653130, 130929, 321088, 431127, 320921, 330824, 420322, 640181, 530126, 120111, 320804, 371321, 140621, 530628, 150304, 230300, 510114, 542331, 370826, 230704, 610426, 430511, 341622, 430602, 350821, 445202, 371323, 451229, 652829, 533423, 210283, 450600, 230321, 130523, 620100, 530400, 321322, 610824, 451027, 321011, 654223, 410725, 441300, 620522, 411729, 370882, 370785, 520113, 360430, 440233, 542524, 610329, 520325, 110112, 520203, 640122, 659001, 331126, 632822, 361126, 610222, 371524, 231004, 140181, 370305, 350926, 330282, 469006, 610114, 150303, 420624, 340321, 350400, 430421, 430781, 610204, 130534, 451400, 450500, 440785, 340405, 450300, 231000, 410200, 511111, 131003, 620922, 659004, 611000, 610100, 321111, 410825, 542333, 340811, 410225, 532324, 420804, 650205, 640100, 411324, 230804, 140425, 150627, 341802, 130530, 469007, 321023, 652300, 360426, 370213, 411525, 370704, 371424, 542124, 542133, 150200, 542527, 130634, 110104, 230184, 150423, 370102, 421121, 511028, 652328, 130123, 440604, 130535, 210726, 130432, 130706, 232723, 130229, 621228, 320323, 632622, 640121, 230304, 430424, 621224, 610702, 450223, 513224, 330783, 320800, 231202, 510723, 530621, 211422, 530129, 451026, 341221, 152531, 330600, 441900, 340803, 451102, 210213, 622922, 150700, 152221, 320482, 141033, 230900, 230124, 530103, 440222, 451025, 320582, 511902, 210604, 230422, 341822, 410108, 431027, 451225, 130723, 370200, 442000, 652123, 410526, 152530, 520402, 140424, 430381, 500225, 610902, 410302, 440983, 500232, 130225, 440512, 440232, 621026, 410182, 330900, 230221, 361022, 513401, 130300, 411727, 360429, 440802, 610929, 650121, 532927, 230523, 421102, 530925, 360727, 513300, 610722, 654023, 210505, 411122, 321324, 441423, 140123, 469000, 141122, 152900, 371525, 140830, 500233, 211102, 220881, 140722, 150821, 130527, 150207, 620981, 441203, 360728, 653224, 532331, 450503, 330212, 532823, 611002, 620702, 542332, 130429, 130430, 350723, 632600, 542624, 542526, 450226, 130632, 510725, 650107, 230903, 350402, 411100, 360403, 512081, 542132, 152921, 340400, 420500, 450721, 450722, 370112, 530823, 340602, 650104, 340700, 370125, 542232, 530423, 430103, 420700, 540121, 610481, 350305, 330602, 469029, 440882, 220822, 341225, 371721, 130822, 610802, 522726, 511722, 210300, 533124, 653123, 150924, 341003, 532322, 420525, 340800, 370285, 640200, 513433, 350923, 410702, 620621, 130529, 371600, 510724, 610625, 310116, 510122, 410306, 130984, 230904, 130321, 420117, 430426, 542225, 310109, 152522, 411104, 500231, 632802, 340122, 150902, 513328, 410425, 632221, 520330, 532526, 542425, 652100, 532932, 431300, 230702, 420682, 152222, 441426, 320502, 350503, 370687, 510106, 440600, 120115, 652800, 130304, 152525, 451222, 330182, 610126, 340304, 659003, 320200, 430382, 340504, 350425, 640422, 130000, 130423, 522633, 150923, 410928, 320811, 330681, 350900, 130204, 330784, 441602, 360322, 360502, 430581, 440305, 632300, 510704, 610428, 652928, 230128, 220721, 430723, 652929, 210411, 411723, 330110, 140106, 350783, 220722, 410422, 340823, 220300, 632800, 320105, 330522, 230223, 510683, 542123, 360781, 110106, 513322, 360923, 640106, 441823, 542400, 411502, 370602, 610122, 451023, 451481, 320923, 654200, 371502, 532922, 130202, 150526, 542336, 411425, 131002, 371623, 530502, 220582, 370703, 210112, 530922, 653122, 654021, 654022, 500109, 330303, 320585, 450403, 150723, 411728, 341125, 441700, 420581, 420626, 532623, 411500, 620924, 210224, 623022, 421224, 513221, 321323, 632123, 430821, 340621, 371522, 511102, 440306, 500111, 450881, 140900, 611025, 632525, 440511, 622924, 140400, 411103, 141081, 421181, 510811, 441303, 230306, 371402, 230303, 440224, 320826, 410923, 431081, 360724, 411002, 410102, 630104, 522622, 211282, 152528, 654024, 510108, 532326, 429006, 150125, 530181, 211481, 510182, 610528, 650109, 210781, 330300, 370404, 230716, 340822, 220100, 211005, 421126, 350100, 411481, 350524, 542627, 469021, 152224, 320621, 330502, 410527, 420112, 430481, 513323, 652200, 130636, 230407, 130582, 140321, 620600, 360800, 420921, 140100, 411422, 340802, 220284, 350921, 341024, 469003, 410726, 110117, 230307, 510921, 341522, 510132, 440903, 420526, 150900, 130633, 230281, 654025, 231024, 522224, 620400, 510411, 542335, 320211, 410500, 610730, 510300, 510681, 410223, 620104, 150400, 530402, 340000, 141125, 341402, 542421, 350700, 150782, 654321, 420222, 420821, 500241, 410505, 513329, 222400, 522632, 360725, 371200, 310117, 140800, 320503, 371728, 320381, 331122, 230600, 321182, 450302, 360926, 621021, 231005, 141002, 513428, 422801, 220521, 341503, 130903, 621024, 210113, 320202, 640202, 110113, 654027, 650000, 421124, 320304, 340102, 350303, 360602, 140929, 340311, 520327, 421202, 533122, 621102, 620000, 623001, 420107, 610726, 440106, 440100, 451000, 431028, 430400, 610430, 653125, 530723, 653200, 141121, 230200, 532925, 542233, 131100, 410581, 530322, 130926, 320682, 141102, 130181, 130621, 320611, 130983, 131025, 230781, 371482, 533324, 512000, 210503, 430221, 650201, 520181, 441781, 230400, 410404, 371526, 321202, 152527, 371521, 341181, 330921, 340604, 370923, 410704, 510522, 620824, 120105, 510900, 140622, 621023, 130227, 513334, 340200, 370302, 230125, 130182, 540125, 422825, 431230, 441302, 410822, 220681, 130324, 620826, 210181, 511781, 522728, 650102, 522600, 321112, 411281, 150602, 210203, 320829, 330726, 411725, 411523, 130703, 530425, 430122, 411527, 652722, 410728, 440804, 500106, 440900, 513233, 211404, 540000, 370725, 130425, 231121, 500103, 510781, 350111, 130683, 341400, 431022, 441702, 420103, 510504, 211122, 321084, 522727, 610324, 431003, 150206, 450922, 431102, 450224, 360922, 469005, 341521, 429004, 510700, 150783, 410211, 231100, 130524, 130528, 522225, 350213, 230713, 640221, 512002, 511402, 150724, 451224, 141022, 522226, 361100, 370521, 450423, 530324, 360824, 360500, 420702, 130732, 140928, 131022, 451228, 330402, 341203, 350625, 341002, 654225, 410403, 510821, 130827, 522629, 630103, 411325, 370832, 360734, 340111, 542600, 320584, 542328, 500102, 430407, 371727, 410506, 520323, 430302, 450481, 653127, 230714, 140222, 610725, 433126, 150600, 330100, 222404, 141026, 110101, 469030, 350103, 360681, 522322, 510129, 341200, 220322, 441225, 522630, 610827, 640423, 542223, 211004, 131127, 210281, 140428, 341722, 341103, 632821, 500243, 469001, 231123, 360481, 430500, 640522, 440184, 110111, 361002, 653131, 340703, 360729, 370983, 431121, 511123, 320100, 211223, 141025, 522423, 130434, 441422, 532928, 210402, 410781, 513400, 150825, 610331, 441821, 441502, 360825, 440500, 331003, 371624, 370126, 130922, 140211, 350702, 542228, 652901, 410304, 652723, 440104, 150121, 360521, 430104, 450321, 610424, 522702, 320412, 411303, 450124, 510322, 654226, 440103, 451323, 520123, 340303, 520322, 140881, 429005, 411700, 140581, 451021, 620523, 530926, 140981, 451028, 360202, 370300, 411025, 140602, 140524, 150781, 230706, 500237, 610900, 130581, 653101, 320925, 331102, 360881, 542429, 610928, 330203, 450700, 652700, 450802, 210602, 211381, 220602, 451424, 330483, 430528, 441402, 511622, 430111, 420602, 220400, 231221, 360281, 441800, 510402, 130700, 430800, 530627, 652327, 621227, 210421, 330723, 610425, 431224, 120103, 522636, 450804, 230202, 511126, 220422, 150626, 220802, 230305, 441224, 430408, 231083, 371427, 350822, 610628, 500200, 350212, 350000, 210304, 130825, 430626, 231003, 371311, 140110, 230227, 410927, 450621, 230229, 430802, 411626, 440307, 361029, 210804, 621122, 320203, 410603, 130900, 130681, 320583, 411426, 140822, 220605, 320982, 370100, 321003, 441322, 211281, 652223, 371621, 341600, 511300, 610630, 371083, 350124, 230204, 320102, 350521, 542525, 654224, 360735, 450103, 511425, 210911, 513426, 510100, 211403, 150424, 120114, 510121, 532800, 450326, 140522, 210624, 150721, 431100, 330800, 510115, 150123, 450703, 445224, 330105, 330328, 141029, 230406, 350725, 320922, 150403, 360925, 230623, 513326, 513338, 340824, 513232, 430600, 341423, 341424, 150521, 370282, 441283, 320282, 370827, 341324, 420900, 361102, 511424, 330000, 350626, 370281, 511721, 530121, 340203, 321200, 210124, 360121, 532622, 411322, 653024, 140521, 341202, 441600, 522326, 530125, 330226, 511422, 520425, 140427, 210404, 420303, 632521, 150581, 500108, 533300, 230205, 140824, 640402, 511302, 211224, 450924, 451123, 610922, 620524, 530824, 430482, 542426, 422800, 141126, 350622, 320404, 433124, 210104, 430527, 230521, 371300, 231124, 350182, 120221, 431321, 321203, 330283, 440112, 430204, 410202, 430724, 331181, 130927, 542621, 232721, 130924, 130129, 152500, 520100, 341323, 131000, 330523, 331125, 542625, 511024, 513327, 610925, 410300, 220600, 450203, 441721, 431200, 530523, 350982, 411702, 441622, 653000, 370781, 421300, 610581, 522700, 440304, 341122, 410503, 110228, 230800, 640502, 220524, 150785, 511323, 511423, 371581, 320116, 320681, 222405, 341525, 542428, 440116, 430503, 510922, 632100, 130725, 360981, 320104, 450108, 310106, 130728, 330624, 420323, 511923, 522635, 520326, 330400, 340502, 532300, 433127, 421381, 511303, 130702, 500222, 610927, 231223, 130403, 141024, 640000, 431225, 430422, 141129, 630121, 350628, 513436, 620122, 341824, 511124, 460105, 431281, 511322, 530927, 530427, 431024, 653223, 131124, 231283, 640425, 451223, 110108, 140000, 513222, 632321, 340827, 140926, 130435, 320125, 611026, 621123, 220621, 231225, 130427, 230828, 150524, 610111, 610403, 500234, 140525, 520103, 410882, 110115, 540100, 530800, 511526, 230104, 210682, 360821, 410185, 370982, 330482, 361121, 451221, 350424, 340402, 610202, 131122, 211100, 321281, 510503, 370522, 623024, 421081, 210782, 431103, 653023, 130821, 532930, 652823, 510722, 620725, 632224, 410323, 141127, 222426, 469032, 440981, 120113, 513226, 511011, 230709, 320902, 370500, 360124, 532900, 350322, 340202, 532501, 231282, 640500, 341204, 350526, 140930, 411400, 420607, 440784, 520381, 530629, 220500, 542325, 659000, 211400, 440203, 542322, 321002, 411627, 230502, 350800, 620302, 130828, 451121, 411628, 652325, 431226, 520400, 510112, 610721, 150925, 210521, 450603, 140109, 331002, 450800, 522400, 621223, 220000, 340322, 370105, 130729, 210114, 350206, 533422, 371722, 511381, 511724, 542423, 341621, 542229, 230403, 330204, 620825, 350302, 211002, 152501, 320303, 230109, 370800, 340721, 431000, 150702, 211324, 522323, 130682, 419001, 360000, 450331, 140724, 530524, 130684, 360828, 532626, 130533, 140481, 220200, 230833, 522731, 530127, 360402, 441826, 411521, 222401, 140827, 540126, 330521, 532929, 500119, 610602, 340221, 330185, 360421, 610729, 211021, 130531, 411202, 150000, 445121, 410327, 230382, 610330, 510904, 341523, 611022, 620105, 130731, 411528, 150426, 513337, 445221, 350427, 230000, 310101, 410305, 511132, 420703, 360723, 513324, 210502, 360105, 451122, 341226, 500223, 430525, 130230, 330822, 620503, 451281, 220203, 320803, 370502, 610627, 510603, 511502, 610124, 654026, 621226, 321283, 632623, 652222, 131125, 411621, 410322, 440507, 430623, 652301, 513435, 652201, 450900, 420502, 370181, 370705, 371329, 360104, 140931, 410100, 341602, 330702, 410502, 150105, 150623, 451322, 230129, 445200, 510500, 441523, 410821, 211000, 532931, 140821, 450328, 331022, 542323, 140227, 532901, 610113, 512021, 420704, 220821, 140431, 440883, 130526, 610115, 340103, 532923, 410329, 410522, 350823, 430102, 120104, 652801, 620423, 522228, 130600, 654323, 210881, 310000, 620521, 331124, 210200, 130131, 330703, 511112, 622925, 431382, 513321, 632324, 220382, 360400, 320706, 632322, 341022, 610600, 150722, 620622, 360924, 532529, 510726, 431227, 500110, 510113, 320831, 511900, 510923, 371421, 530923, 140828, 430902, 652828, 451421, 450225, 210381, 210905, 620123, 420200, 360427, 431222, 500229, 511321, 520324, 131123, 360902, 440204, 542224, 230405, 141124, 410611, 430903, 210921, 653001, 622900, 440607, 511827, 341322, 350681, 410721, 510824, 530521, 150622, 620900, 370683, 652323, 230606, 450325, 421127, 659002, 530623, 370811, 411424, 410823, 220302, 430523, 511802, 511921, 430200, 231226, 620802, 350582, 445381, 511700, 511623, 230103, 513422, 141000, 411526, 610523, 370613, 210904, 450322, 210703, 632723, 331127, 150726, 350629, 620525, 371725, 530100, 230602, 520382, 510822, 511824, 130281, 430900, 341500, 150784, 310110, 210123, 371602, 542227, 411300, 440515, 220381, 361130, 410902, 520201, 451422, 130603, 500105, 500230, 440703, 230182, 440303, 330421, 450304, 522324, 441723, 653221, 350802, 431229, 220112, 370600, 230921, 210500, 450327, 469025, 341300, 411302, 632823, 513227, 440823, 511723, 653129, 410621, 430000, 620602, 350922, 513423, 131102, 632126, 140925, 410703, 440705, 411328, 130622, 621125, 341182, 410804, 120106, 500104, 520423, 653222, 430181, 445322, 450204, 350502, 230224, 620921, 370202, 370883, 330700, 410205, 320981, 350300, 370724, 320311, 450404, 130124, 150203, 140700, 331121, 530724, 622927, 542324, 230126, 511113, 620502, 653227, 140303, 230622, 360323, 610125, 230881, 610629, 350627, 510183, 150122, 210103, 341881, 371702, 340222, 360702, 230522, 520222, 330225, 520000, 320581, 530122, 140882, 511324, 371002, 370611, 440514, 513425, 620723, 533103, 441621, 411326, 522227, 500224, 141032, 331081, 320722, 360982, 220283, 130323, 231181, 421223, 522628, 450125, 350421, 370911, 350125, 440403, 652324, 469024, 411222, 533102, 422802, 210212, 510422, 150402, 152922, 431023, 522427, 610300, 340826, 360722, 370104, 530302, 654324, 330281, 421303, 623000, 632500, 210311, 460200, 441421, 500227, 150824, 510131, 410481, 310113, 321311, 150202, 131024, 340600, 652701, 420982, 431125, 652822, 370702, 330302, 330327, 431021, 330922, 522301, 532924, 211200, 350881, 542326, 360822, 620102, 542500, 621202, 621027, 450323, 440200, 420202, 500228, 520300, 340100, 220523, 440704, 320500, 320204, 210105, 330781, 451022, 451029, 632223, 513228, 411524, 341126, 451100, 530702, 440881, 410622, 350121, 420115, 610200, 350304, 320602, 522701 | ||
19 | + }; | ||
20 | + | ||
21 | + public static String getIdNo(boolean male){ | ||
22 | + //随机生成生日 1~99岁 | ||
23 | + long begin = System.currentTimeMillis() - 3153600000000L;//100年内 | ||
24 | + long end = System.currentTimeMillis() - 31536000000L; //1年内 | ||
25 | + long rtn = begin + (long) (Math.random() * (end - begin)); | ||
26 | + Date date = new Date(rtn); | ||
27 | + SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyyMMdd"); | ||
28 | + String birth = simpleDateFormat.format(date); | ||
29 | + return getIdNo(birth,male); | ||
30 | + } | ||
31 | + | ||
32 | + public static String getIdNo(String birth,boolean male){ | ||
33 | + StringBuilder sb = new StringBuilder(); | ||
34 | + Random random = new Random(); | ||
35 | + int value = random.nextInt(cities.length); | ||
36 | + sb.append(cities[value]); | ||
37 | + sb.append(birth); | ||
38 | + value = random.nextInt(999) + 1; | ||
39 | + if(male && value % 2 == 0){ | ||
40 | + value++; | ||
41 | + } | ||
42 | + if(!male && value % 2 == 1){ | ||
43 | + value++; | ||
44 | + } | ||
45 | + if(value >= 100){ | ||
46 | + sb.append(value); | ||
47 | + }else if(value >= 10){ | ||
48 | + sb.append('0').append(value); | ||
49 | + }else{ | ||
50 | + sb.append("00").append(value); | ||
51 | + } | ||
52 | + sb.append(calcTrailingNumber(sb)); | ||
53 | + return sb.toString(); | ||
54 | + } | ||
55 | + private static final int[] calcC = { 7, 9, 10, 5, 8, 4, 2, 1, 6, 3, 7, 9, 10, 5, 8, 4, 2 }; | ||
56 | + private static final char[] calcR = { '1', '0', 'X', '9', '8', '7', '6', '5', '4', '3', '2' }; | ||
57 | + private static char calcTrailingNumber(StringBuilder sb) { | ||
58 | + int[] n = new int[17]; | ||
59 | + int result = 0; | ||
60 | + for (int i = 0; i < n.length; i++) { | ||
61 | + n[i] = Integer.parseInt(String.valueOf(sb.charAt(i))); | ||
62 | + } | ||
63 | + for (int i = 0; i < n.length; i++) { | ||
64 | + result += calcC[i] * n[i]; | ||
65 | + } | ||
66 | + return calcR[result % 11]; | ||
67 | + } | ||
68 | + //中国移动 | ||
69 | + public static final String[] CHINA_MOBILE = { | ||
70 | + "134", "135", "136", "137", "138", "139", | ||
71 | + "150", "151", "152", "157", "158", "159", | ||
72 | + "182", "183", "184", "187", "188", "178", "147", "172", "198" | ||
73 | + }; | ||
74 | + //中国联通 | ||
75 | + public static final String[] CHINA_UNICOM = { | ||
76 | + "130", "131", "132", "145", "155", "156", "166", "171", "175", "176", "185", "186", "166" | ||
77 | + }; | ||
78 | + //中国电信 | ||
79 | + public static final String[] CHINA_TELECOME = { | ||
80 | + "133", "149", "153", "173", "177", "180", "181", "189", "199" | ||
81 | + }; | ||
82 | + public static String createMobile(int op) { | ||
83 | + StringBuilder sb = new StringBuilder(); | ||
84 | + Random random = new Random(); | ||
85 | + String mobile01;//手机号前三位 | ||
86 | + int temp; | ||
87 | + switch (op) { | ||
88 | + case 0: | ||
89 | + mobile01 = CHINA_MOBILE[random.nextInt(CHINA_MOBILE.length)]; | ||
90 | + break; | ||
91 | + case 1: | ||
92 | + mobile01 = CHINA_UNICOM[random.nextInt(CHINA_UNICOM.length)]; | ||
93 | + break; | ||
94 | + case 2: | ||
95 | + mobile01 = CHINA_TELECOME[random.nextInt(CHINA_TELECOME.length)]; | ||
96 | + break; | ||
97 | + default: | ||
98 | + mobile01 = "op标志位有误!"; | ||
99 | + break; | ||
100 | + } | ||
101 | + if (mobile01.length() > 3) { | ||
102 | + return mobile01; | ||
103 | + | ||
104 | + } | ||
105 | + sb.append(mobile01); | ||
106 | + //生成手机号后8位 | ||
107 | + for (int i = 0; i < 8; i++) { | ||
108 | + temp = random.nextInt(10); | ||
109 | + | ||
110 | + sb.append(temp); | ||
111 | + | ||
112 | + } | ||
113 | + return sb.toString(); | ||
114 | + } | ||
115 | + | ||
116 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/utils/UTF8PostMethod.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/UTF8PostMethod.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +import org.apache.commons.httpclient.Header; | ||
4 | +import org.apache.commons.httpclient.methods.PostMethod; | ||
5 | + | ||
6 | +public class UTF8PostMethod extends PostMethod { | ||
7 | + | ||
8 | + /** | ||
9 | + * Creates a new instance of UTF8PostMethod | ||
10 | + */ | ||
11 | + public UTF8PostMethod(String string) { | ||
12 | + super(string); | ||
13 | + } | ||
14 | + | ||
15 | + protected String getContentCharSet(Header contentheader) { | ||
16 | + return "UTF-8"; | ||
17 | + } | ||
18 | +} | ||
19 | + |
zhyx-api/src/main/java/com/ectrip/cyt/utils/UUIDTools.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/UUIDTools.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +import java.util.UUID; | ||
4 | + | ||
5 | +public class UUIDTools { | ||
6 | + public static String get16UUID() { | ||
7 | + int machineId = 1;//最大支持1-9个集群机器部署 | ||
8 | + int hashCodeV = UUID.randomUUID().toString().hashCode(); | ||
9 | + if(hashCodeV < 0) {//有可能是负数 | ||
10 | + hashCodeV = - hashCodeV; | ||
11 | + } | ||
12 | + return machineId + String.format("%015d", hashCodeV); | ||
13 | + } | ||
14 | +} |
zhyx-api/src/main/java/com/ectrip/cyt/utils/XmlHeaderParam.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/XmlHeaderParam.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +/** | ||
4 | + * 用作XML转换的头信息参数传递(区分于OTA) | ||
5 | + * | ||
6 | + * @author huhaopeng | ||
7 | + */ | ||
8 | +public class XmlHeaderParam { | ||
9 | + private String namespaceRequest; | ||
10 | + private String namespaceResponse; | ||
11 | + private String attributeXsi; | ||
12 | + private String attributeXmlns; | ||
13 | + | ||
14 | + public XmlHeaderParam() { | ||
15 | + | ||
16 | + } | ||
17 | + | ||
18 | + public XmlHeaderParam(String namespaceRequest, String namespaceResponse, | ||
19 | + String attributeXsi, String attributeXmlns) { | ||
20 | + super(); | ||
21 | + this.namespaceRequest = namespaceRequest; | ||
22 | + this.namespaceResponse = namespaceResponse; | ||
23 | + this.attributeXsi = attributeXsi; | ||
24 | + this.attributeXmlns = attributeXmlns; | ||
25 | + } | ||
26 | + | ||
27 | + | ||
28 | + public String getNamespaceRequest() { | ||
29 | + return namespaceRequest; | ||
30 | + } | ||
31 | + | ||
32 | + public void setNamespaceRequest(String namespaceRequest) { | ||
33 | + this.namespaceRequest = namespaceRequest; | ||
34 | + } | ||
35 | + | ||
36 | + public String getNamespaceResponse() { | ||
37 | + return namespaceResponse; | ||
38 | + } | ||
39 | + | ||
40 | + public void setNamespaceResponse(String namespaceResponse) { | ||
41 | + this.namespaceResponse = namespaceResponse; | ||
42 | + } | ||
43 | + | ||
44 | + public String getAttributeXsi() { | ||
45 | + return attributeXsi; | ||
46 | + } | ||
47 | + | ||
48 | + public void setAttributeXsi(String attributeXsi) { | ||
49 | + this.attributeXsi = attributeXsi; | ||
50 | + } | ||
51 | + | ||
52 | + public String getAttributeXmlns() { | ||
53 | + return attributeXmlns; | ||
54 | + } | ||
55 | + | ||
56 | + public void setAttributeXmlns(String attributeXmlns) { | ||
57 | + this.attributeXmlns = attributeXmlns; | ||
58 | + } | ||
59 | + | ||
60 | +} | ||
61 | + |
zhyx-api/src/main/java/com/ectrip/cyt/utils/XmlParseUtil.java
0 → 100644
1 | +++ a/zhyx-api/src/main/java/com/ectrip/cyt/utils/XmlParseUtil.java | ||
1 | +package com.ectrip.cyt.utils; | ||
2 | + | ||
3 | +import org.dom4j.Document; | ||
4 | +import org.dom4j.DocumentHelper; | ||
5 | +import org.dom4j.Element; | ||
6 | +import org.dom4j.io.OutputFormat; | ||
7 | +import org.dom4j.io.XMLWriter; | ||
8 | + | ||
9 | +import java.beans.PropertyDescriptor; | ||
10 | +import java.io.IOException; | ||
11 | +import java.io.StringWriter; | ||
12 | +import java.lang.reflect.Field; | ||
13 | +import java.lang.reflect.Method; | ||
14 | +import java.util.*; | ||
15 | + | ||
16 | +/** | ||
17 | + * 解析XML公用类:支持多重内部类解析 dom4j 支持 | ||
18 | + * | ||
19 | + * @author huhaopeng | ||
20 | + */ | ||
21 | +public class XmlParseUtil { | ||
22 | + | ||
23 | + /** | ||
24 | + * JAVA Bean 转换 XML 字符串 Describe: | ||
25 | + * | ||
26 | + * @param obj Object 传入 Body | ||
27 | + * @param header Object 传入 Header | ||
28 | + * @param paramName String OTA区分标识 ( qunar, ectrip ) | ||
29 | + * @author:huhaopeng | ||
30 | + * @注: header 需要传入 application, processor, createUser return:void | ||
31 | + * Date:2014-2-21 | ||
32 | + */ | ||
33 | + @SuppressWarnings({"finally", "deprecation"}) | ||
34 | + public static String beanToXML(final Object obj, final Object header, | ||
35 | + String paramName) throws Exception { | ||
36 | + // 获取头信息 | ||
37 | + XmlHeaderParam param = getXmlHeaderParam(paramName); | ||
38 | + | ||
39 | + // className:类全名 | ||
40 | + String clsName = obj.getClass().getName(); | ||
41 | + // 去掉类全名前面不需要的:例如 cn.xml.Context -> Context | ||
42 | + clsName = clsName.substring(clsName.lastIndexOf(".") + 1, clsName | ||
43 | + .length()); | ||
44 | + | ||
45 | + // 根据类名生成root | ||
46 | + Document doc = DocumentHelper.createDocument(); | ||
47 | + // doc.addComment("Sample XML file generated by XMLSpy v2013 (http://www.altova.com)"); | ||
48 | + // 添加根节点: | ||
49 | + Element root = null; | ||
50 | + if (clsName.indexOf("Request") != -1) { | ||
51 | + root = doc.addElement("qm:request"); | ||
52 | + root.addNamespace("qm", param.getNamespaceRequest()); | ||
53 | + root.addAttribute("xsi:schemaLocation", param.getAttributeXsi()); | ||
54 | + root.addAttribute("xmlns:xsi", param.getAttributeXmlns()); | ||
55 | + } else if (clsName.indexOf("Response") != -1) { | ||
56 | + root = doc.addElement("qm:response"); | ||
57 | + root.addNamespace("qm", param.getNamespaceResponse()); | ||
58 | + root.addAttribute("xsi:schemaLocation", param.getAttributeXsi()); | ||
59 | + root.addAttribute("xmlns:xsi", param.getAttributeXmlns()); | ||
60 | + } | ||
61 | + | ||
62 | + // 添加Header | ||
63 | + Element head = root.addElement("qm:header"); | ||
64 | + | ||
65 | + complexTypeRecursive(header, head); | ||
66 | + | ||
67 | + Element body = root.addElement("qm:body"); | ||
68 | + | ||
69 | + body.setAttributeValue("xsi:type", "qm:" + clsName); | ||
70 | + // bean属性 | ||
71 | + complexTypeRecursive(obj, body); | ||
72 | + | ||
73 | + // 生成xml:String | ||
74 | + XMLWriter xw; | ||
75 | + StringWriter sw = new StringWriter(); | ||
76 | + OutputFormat opf; | ||
77 | + String result = null; | ||
78 | + try { | ||
79 | + opf = OutputFormat.createCompactFormat(); | ||
80 | + opf.setEncoding("UTF-8"); | ||
81 | + xw = new XMLWriter(sw); | ||
82 | + xw.write(doc); | ||
83 | + result = sw.toString(); | ||
84 | + xw.close(); | ||
85 | + sw.close(); | ||
86 | + | ||
87 | + } catch (IOException e1) { | ||
88 | + e1.printStackTrace(); | ||
89 | + } catch (Exception e) { | ||
90 | + e.printStackTrace(); | ||
91 | + } finally { | ||
92 | + return result; | ||
93 | + } | ||
94 | + | ||
95 | + } | ||
96 | + | ||
97 | + /** | ||
98 | + * 递归: 获取 复杂类型 树结构方法。 Describe: objectToXML() use | ||
99 | + * | ||
100 | + * @param obj : Object(此节点对应对象) | ||
101 | + * @param element : Element(此节点) return:void Date:2014-2-21 | ||
102 | + * @author:huhaopeng | ||
103 | + */ | ||
104 | + @SuppressWarnings("unchecked") | ||
105 | + public static void complexTypeRecursive(Object obj, Element element) { | ||
106 | + Class cls = obj.getClass(); | ||
107 | + String objName = cls.getSimpleName(); | ||
108 | + | ||
109 | + // getDeclaredFields:获取bean中所有属性 | ||
110 | + Field[] fields = cls.getDeclaredFields(); | ||
111 | + String fieldName = ""; | ||
112 | + if ("String".equals(objName)) { | ||
113 | + element.setText(obj.toString()); | ||
114 | + } else { | ||
115 | + for (Field f : fields) { | ||
116 | + f.setAccessible(true); | ||
117 | + fieldName = f.getName(); | ||
118 | + | ||
119 | + try { | ||
120 | + | ||
121 | + PropertyDescriptor pd = new PropertyDescriptor(fieldName, cls); | ||
122 | + Method getMethod = pd.getReadMethod();// 获得get方法 | ||
123 | + // 当前对象:o | ||
124 | + Object o = getMethod.invoke(obj);// 执行get方法返回一个Object | ||
125 | + | ||
126 | + // 判断是否为list属性 | ||
127 | + if ((".List").equals(f.getType().toString().substring( | ||
128 | + f.getType().toString().lastIndexOf(".")))) { | ||
129 | + List list = (ArrayList) o; | ||
130 | + for (Object ob : list) { | ||
131 | + Element emt = element.addElement("qm:" + fieldName); | ||
132 | + complexTypeRecursive(ob, emt); | ||
133 | + } | ||
134 | + } else { | ||
135 | + Element emt = element.addElement("qm:" + fieldName); | ||
136 | + // 判断下个节点是否需要:为null说明不用加入xml中 | ||
137 | + if (null != o) { | ||
138 | + // 判断节点o是否为基础类型:if(基础类型)else(非基础类型) | ||
139 | + if ("java".equals(o.getClass().getName() | ||
140 | + .substring(0, 4))) { | ||
141 | + emt.setText(o.toString()); | ||
142 | + } else { | ||
143 | + // 递归调用 | ||
144 | + complexTypeRecursive(o, emt); | ||
145 | + } | ||
146 | + } | ||
147 | + } | ||
148 | + } catch (Exception e) { | ||
149 | + e.printStackTrace(); | ||
150 | + } | ||
151 | + } | ||
152 | + } | ||
153 | + } | ||
154 | + | ||
155 | + /** | ||
156 | + * XML 转换 为 JACA BEAN Describe: bodyInfo 对应类中所有属性必须已经实例化,不能为NULL | ||
157 | + * | ||
158 | + * @param xml String | ||
159 | + * @param bodyInfo Object | ||
160 | + * @return return:Map Date:2014-2-22 | ||
161 | + * @author:huhaopeng | ||
162 | + */ | ||
163 | + public static Map xmlToBean(String xml, Object header, Object bodyInfo) | ||
164 | + throws Exception { | ||
165 | + Map<String, Object> map = new HashMap<String, Object>(); | ||
166 | + Document doc; | ||
167 | + try { | ||
168 | + doc = DocumentHelper.parseText(xml); // 将字符串转为XML | ||
169 | + Element root = doc.getRootElement(); // 获取根节点 | ||
170 | + Iterator rootIter = root.elementIterator();// 获取根节点下的子节点head | ||
171 | + | ||
172 | + Iterator headerIter = ((Element) rootIter.next()).elementIterator(); | ||
173 | + Iterator bodyIter = ((Element) rootIter.next()).elementIterator(); | ||
174 | + | ||
175 | + // Header: 递归塞值 | ||
176 | + complexTypeRecursiveXmlToBean(header, headerIter); | ||
177 | + map.put("header", header);// map.put("header", rqstHeader); | ||
178 | + | ||
179 | + // Body: 递归塞值 | ||
180 | + complexTypeRecursiveXmlToBean(bodyInfo, bodyIter); | ||
181 | + map.put("body", bodyInfo); | ||
182 | + | ||
183 | + } catch (Exception e) { | ||
184 | + e.printStackTrace(); | ||
185 | + throw e; | ||
186 | + } | ||
187 | + return map; | ||
188 | + } | ||
189 | + | ||
190 | + /** | ||
191 | + * 请求的 Header xml 转 bean | ||
192 | + * Describe: | ||
193 | + * | ||
194 | + * @param xml Header xml字符串 | ||
195 | + * @param header header格式 | ||
196 | + * @return return:String | ||
197 | + * Date:2014-5-9 | ||
198 | + * @author:huhaopeng | ||
199 | + */ | ||
200 | + public static Object requestHeaderXmlTobean(String xml, Object header) { | ||
201 | + Document doc = null; | ||
202 | + | ||
203 | + try { | ||
204 | + doc = DocumentHelper.parseText(xml); // 将字符串转为XML | ||
205 | + | ||
206 | + Element root = doc.getRootElement(); // 获取根节点 | ||
207 | + Iterator rootIter = root.elementIterator(); | ||
208 | + // 获取根节点下的子节点head | ||
209 | + Iterator headerIter = ((Element) rootIter.next()).elementIterator(); | ||
210 | + //Iterator bodyIter = ((Element) rootIter.next()).elementIterator(); | ||
211 | + | ||
212 | + // Header: 递归塞值 | ||
213 | + complexTypeRecursiveXmlToBean(header, headerIter); | ||
214 | + | ||
215 | + return header; | ||
216 | + | ||
217 | + // getDeclaredFields:获取为引用类型数 | ||
218 | + } catch (Exception e) { | ||
219 | + e.printStackTrace(); | ||
220 | + } | ||
221 | + | ||
222 | + | ||
223 | + return null; | ||
224 | + } | ||
225 | + | ||
226 | + /** | ||
227 | + * 递归:将xml中对应结构的值塞入对象中 Describe: | ||
228 | + * | ||
229 | + * @param obj Object 对象结构模型 | ||
230 | + * @param iterss 获取的XML文件:body中的所有子节点 return:void Date:2014-2-22 | ||
231 | + * @author:huhaopeng | ||
232 | + */ | ||
233 | + @SuppressWarnings("unchecked") | ||
234 | + public static void complexTypeRecursiveXmlToBean(Object obj, Iterator iterss) { | ||
235 | + Class cls = obj.getClass(); | ||
236 | + Field[] fields = cls.getDeclaredFields(); | ||
237 | + String upName; | ||
238 | + | ||
239 | + // 获取(Iterator iterss)所有对象的值。 | ||
240 | + List<Element> eList = new ArrayList<Element>(); | ||
241 | + while (iterss.hasNext()) { | ||
242 | + Element e = (Element) iterss.next(); | ||
243 | + eList.add(e); | ||
244 | + } | ||
245 | + | ||
246 | + for (Field field : fields) { | ||
247 | + field.setAccessible(true); | ||
248 | + // 当前 Node | ||
249 | + Element emt = null; | ||
250 | + // 判断obj此属性 在xml中是否存在(如果不是必须的,有可能不会传值.) | ||
251 | + boolean isContinue = true; | ||
252 | + for (Element e : eList) { | ||
253 | + if (e.getName().equals(field.getName())) { | ||
254 | + isContinue = false; | ||
255 | + emt = e; | ||
256 | + } else { | ||
257 | + | ||
258 | + } | ||
259 | + } | ||
260 | + if (isContinue == true) { | ||
261 | + continue; | ||
262 | + }// class | ||
263 | + | ||
264 | + String text = emt.getText(); | ||
265 | + try { | ||
266 | + // PropertyDescriptor:用来连接 <类当前属性> <get>和<set>方法 | ||
267 | + PropertyDescriptor pd = new PropertyDescriptor(field.getName(), | ||
268 | + cls); | ||
269 | + Method getMethod = pd.getReadMethod();// 获得get方法 | ||
270 | + // 当前对象:o | ||
271 | + Object o = getMethod.invoke(obj);// 执行get方法返回一个Object | ||
272 | + // 判断是否为list属性 | ||
273 | + if ((".List").equals(field.getType().toString().substring( | ||
274 | + field.getType().toString().lastIndexOf(".")))) { | ||
275 | + List list = (ArrayList) o; | ||
276 | + | ||
277 | + // 判断是否有对象:有就添加到list对象中 | ||
278 | + for (Element element : eList) {// while (iterss.hasNext()) | ||
279 | + // {//iterss 这时候 里面存的已经是 | ||
280 | + // List中的所有对象了 | ||
281 | + | ||
282 | + String classForName = field.getGenericType().toString() | ||
283 | + .substring( | ||
284 | + field.getGenericType().toString() | ||
285 | + .indexOf("<") + 1, | ||
286 | + field.getGenericType().toString() | ||
287 | + .lastIndexOf(">")); | ||
288 | + Object ob = Class.forName(classForName).newInstance(); | ||
289 | + // 将对象塞入list | ||
290 | + list.add(ob); | ||
291 | + // 获取节点下所有属性 | ||
292 | + Iterator ite = element.elementIterator(); | ||
293 | + // 给塞入list的对象赋值 | ||
294 | + complexTypeRecursiveXmlToBean(ob, ite); | ||
295 | + } | ||
296 | + } else { | ||
297 | + upName = field.getName().substring(0, 1).toUpperCase() | ||
298 | + + field.getName().substring(1); | ||
299 | + | ||
300 | + if ("java".equals(o.getClass().getName().substring(0, 4))) { | ||
301 | + // 基础类型:给对象塞值 | ||
302 | + obj.getClass().getMethod("set" + upName, String.class) | ||
303 | + .invoke(obj, text); | ||
304 | + } else { | ||
305 | + // 复杂类型:递归 | ||
306 | + Iterator eIter = emt.elementIterator(); | ||
307 | + complexTypeRecursiveXmlToBean(o, eIter); | ||
308 | + } | ||
309 | + } | ||
310 | + } catch (Exception e) { | ||
311 | + e.printStackTrace(); | ||
312 | + } | ||
313 | + } | ||
314 | + } | ||
315 | + | ||
316 | + /** | ||
317 | + * 获取xmlHeader参数 | ||
318 | + * @param paramName | ||
319 | + * @return | ||
320 | + */ | ||
321 | + public static XmlHeaderParam getXmlHeaderParam(String paramName){ | ||
322 | + XmlHeaderParam headerParam = null; | ||
323 | + | ||
324 | + if("qunar".equals(paramName)){ | ||
325 | + headerParam = new XmlHeaderParam( | ||
326 | + "http://piao.qunar.com/2013/QMenpiaoRequestSchema", | ||
327 | + "http://piao.qunar.com/2013/QMenpiaoResponseSchema", | ||
328 | + "http://piao.qunar.com/2013/QMenpiaoRequestSchema QMRequestDataSchema-2.0.0.xsd", | ||
329 | + "http://www.w3.org/2001/XMLSchema-instance"); | ||
330 | + }else if("ectrip".equals(paramName)){ | ||
331 | + headerParam = new XmlHeaderParam( | ||
332 | + "http://tour.ectrip.com/2014/QMRequestDataSchema", | ||
333 | + "http://tour.ectrip.com/2014/QMResponseSchema", | ||
334 | + "http://tour.ectrip.com/2014/QMResponseSchema QMRequestDataSchema-1.1.0.xsd", | ||
335 | + "http://www.w3.org/2001/XMLSchema-instance"); | ||
336 | + } | ||
337 | + | ||
338 | + return headerParam; | ||
339 | + } | ||
340 | +} |
zhyx-api/src/main/resources/application.yml
0 → 100644
zhyx-api/src/main/resources/logback.xml
0 → 100644
1 | +++ a/zhyx-api/src/main/resources/logback.xml | ||
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<configuration> | ||
3 | + <appender name="console" class="ch.qos.logback.core.ConsoleAppender"> | ||
4 | + <encoder charset="UTF-8"> | ||
5 | + <pattern>[%d{yyyy-MM-dd HH:mm:ss} %5p %c:%L] %m%n</pattern> | ||
6 | + </encoder> | ||
7 | + </appender> | ||
8 | + | ||
9 | + <appender name="file" class="ch.qos.logback.core.rolling.RollingFileAppender"> | ||
10 | + | ||
11 | + <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> | ||
12 | + <fileNamePattern>/home/q/springboot-demo/log/logFile.%d{yyyy-MM-dd}.log</fileNamePattern> | ||
13 | + <maxHistory>90</maxHistory> | ||
14 | + </rollingPolicy> | ||
15 | + | ||
16 | + <encoder charset="UTF-8"> | ||
17 | + <pattern>[%d{yyyy-MM-dd HH:mm:ss} %5p %c:%L] %m%n</pattern> | ||
18 | + </encoder> | ||
19 | + </appender> | ||
20 | + | ||
21 | + | ||
22 | + <root level="info"> | ||
23 | + <appender-ref ref="console"/> | ||
24 | + <appender-ref ref="file"/> | ||
25 | + </root> | ||
26 | +</configuration> | ||
0 | \ No newline at end of file | 27 | \ No newline at end of file |
zhyx-api/target/classes/application.yml
0 → 100644
zhyx-api/target/classes/com/ectrip/cyt/CytApplication.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/common/Parameter.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/common/Transient.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/Base64Util.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/OtaBase.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/ApplyOrderRefundByUserRequestBody$OrderInfo$VisitPerson$Person.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/ApplyOrderRefundByUserRequestBody$OrderInfo$VisitPerson.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/ApplyOrderRefundByUserRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/ApplyOrderRefundByUserRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CancelOrderRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CancelOrderRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CheckOrderRequestBody$OrderInfo$ContactPerson.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CheckOrderRequestBody$OrderInfo$Product.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CheckOrderRequestBody$OrderInfo$VisitPerson$Person.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CheckOrderRequestBody$OrderInfo$VisitPerson.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CheckOrderRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CheckOrderRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreateOrderRequestBody$OrderInfo$ContactPerson.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreateOrderRequestBody$OrderInfo$Product.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreateOrderRequestBody$OrderInfo$VisitPerson$Person.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreateOrderRequestBody$OrderInfo$VisitPerson.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreateOrderRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreateOrderRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreatePaymentOrderRequestBody$OrderInfo$ContactPerson.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreatePaymentOrderRequestBody$OrderInfo$Product.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreatePaymentOrderRequestBody$OrderInfo$VisitPerson$Person.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreatePaymentOrderRequestBody$OrderInfo$VisitPerson.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreatePaymentOrderRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/CreatePaymentOrderRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/GetOrderByOTARequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/GetProductByOTARequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/GetStockProductInfoRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderConsumedRequestBody$OrderInfo$Vouchers$Voucher.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderConsumedRequestBody$OrderInfo$Vouchers.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderConsumedRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderConsumedRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderEticketSendedRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderEticketSendedRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderModifyRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderModifyRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderPrintSuccessRequestBody$OrderInfo$Vouchers$Voucher.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderPrintSuccessRequestBody$OrderInfo$Vouchers.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderPrintSuccessRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderPrintSuccessRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundApproveResultRequestBody$OrderInfo$Vouchers$Voucher.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundApproveResultRequestBody$OrderInfo$Vouchers.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundApproveResultRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundApproveResultRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundRequestBody$OrderInfo$Vouchers$Voucher.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundRequestBody$OrderInfo$Vouchers.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundedByOTARequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderRefundedByOTARequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderReserveRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeOrderReserveRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/NoticeProductChangeRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/PayOrderRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/PayOrderRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/PostFaceInfoRequestBody$FaceInfos$FaceInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/PostFaceInfoRequestBody$FaceInfos.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/PostFaceInfoRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/PushOrderRequestBody$OrderInfo$ContactPerson.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/PushOrderRequestBody$OrderInfo$VisitPerson$Person.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/PushOrderRequestBody$OrderInfo$VisitPerson.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/PushOrderRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/PushOrderRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/QueryOtaOrderRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/QueryOtaOrderRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/Request.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/RequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/RequestHeader.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/SendOrderEticketRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/SendOrderEticketRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/VerifyConsumeRequestBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/request/VerifyConsumeRequestBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/ApplyOrderRefundByUserResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/CancelOrderResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/CheckOrderResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/CreateOrderResponseBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/CreateOrderResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/CreatePaymentOrderResponseBody$OrderInfo$Vouchers$Voucher.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/CreatePaymentOrderResponseBody$OrderInfo$Vouchers.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/CreatePaymentOrderResponseBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/CreatePaymentOrderResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetAvailableProductResponseBody$Pois$Poi$Products$Product.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetAvailableProductResponseBody$Pois$Poi$Products.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetAvailableProductResponseBody$Pois$Poi.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetAvailableProductResponseBody$Pois.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetAvailableProductResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetBalanceResponseBody$SupplierBalances$SupplierBalance.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetBalanceResponseBody$SupplierBalances.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetBalanceResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetOrderByOTAResponseBody$OrderInfo$Vouchers$Voucher.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetOrderByOTAResponseBody$OrderInfo$Vouchers.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetOrderByOTAResponseBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetOrderByOTAResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$BaseInfo$Sights$Sight.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$BaseInfo$Sights.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$BaseInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$BookConfig$AdvanceOption.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$BookConfig.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$OtherConfig.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$PriceConfig$CalendarPrices$CalendarPrice.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$PriceConfig$CalendarPrices.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$PriceConfig.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$ProductDescription$RefundOption.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$ProductDescription.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$TimeOfBooks$TimeOfBook.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo$TimeOfBooks.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos$ProductInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody$ProductInfos.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetProductByOTAResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetStockProductInfoResponseBody$StockInfos$StockInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetStockProductInfoResponseBody$StockInfos.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetStockProductInfoResponseBody$TimeOfBooks$TimeOfBook.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetStockProductInfoResponseBody$TimeOfBooks.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/GetStockProductInfoResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderConsumedResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderEticketSendedResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderPrintSuccessResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderRefundApproveResultResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderRefundResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderRefundedByOTAResponseBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeOrderRefundedByOTAResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/NoticeProductChangedResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/PayOrderResponseBody$OrderInfo$Vouchers$Voucher.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/PayOrderResponseBody$OrderInfo$Vouchers.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/PayOrderResponseBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/PayOrderResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/PostFaceInfoResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/PushOrderResponseBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/PushOrderResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/QueryOtaOrderResponseBody$OrderInfo.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/QueryOtaOrderResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/Response.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/ResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/ResponseHeader.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/SendOrderEticketResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/model/cytOrder/response/VerifyConsumeResponseBody.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/client/cyt/service/TdosApiClient.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/config/DruidConfig.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/config/Swagger2.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/controller/TdosApiController.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/exception/BusinessException.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/CancelOrderRequest.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/CreateOrderRequest.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/GetProductRequest.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/GetSeatRequset.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/GetStockRequest.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/PayOrderRequest.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/QueryOrderRequest.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/RefundOrderRequest.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/Request.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/SendOrderEticketRequest.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/enums/ApiMethodType.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/enums/CredentialsType.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/enums/OrderStatusType.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/enums/PaymentWay.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/param/AccountParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/param/CancelOrderParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/param/CreateOrderParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/param/GetProductParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/param/GetSeatParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/param/GetStockParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/param/PayOrderParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/param/ProductParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/param/PushOrderParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/param/QueryOrderParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/param/RefundOrderParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/param/SendOrderEticketParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/pojo/EditPerson.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/pojo/Person.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/result/AjaxResult.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/result/Result.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/result/ResultStatus.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/rt/CommonReturn.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/model/rt/PushOrderRequest.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/AesTools.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/Base64Utils.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/BigDecimalUtils.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/DateUtils.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/EncryptUtil.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/OrderStatusUtils.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/OtaUtils$1.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/OtaUtils$2.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/OtaUtils.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/SM4Tools.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/SecurityTools.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/TestOrderUtils.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/UTF8PostMethod.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/UUIDTools.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/XmlHeaderParam.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/com/ectrip/cyt/utils/XmlParseUtil.class
0 → 100644
No preview for this file type
zhyx-api/target/classes/logback.xml
0 → 100644
1 | +++ a/zhyx-api/target/classes/logback.xml | ||
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<configuration> | ||
3 | + <appender name="console" class="ch.qos.logback.core.ConsoleAppender"> | ||
4 | + <encoder charset="UTF-8"> | ||
5 | + <pattern>[%d{yyyy-MM-dd HH:mm:ss} %5p %c:%L] %m%n</pattern> | ||
6 | + </encoder> | ||
7 | + </appender> | ||
8 | + | ||
9 | + <appender name="file" class="ch.qos.logback.core.rolling.RollingFileAppender"> | ||
10 | + | ||
11 | + <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy"> | ||
12 | + <fileNamePattern>/home/q/springboot-demo/log/logFile.%d{yyyy-MM-dd}.log</fileNamePattern> | ||
13 | + <maxHistory>90</maxHistory> | ||
14 | + </rollingPolicy> | ||
15 | + | ||
16 | + <encoder charset="UTF-8"> | ||
17 | + <pattern>[%d{yyyy-MM-dd HH:mm:ss} %5p %c:%L] %m%n</pattern> | ||
18 | + </encoder> | ||
19 | + </appender> | ||
20 | + | ||
21 | + | ||
22 | + <root level="info"> | ||
23 | + <appender-ref ref="console"/> | ||
24 | + <appender-ref ref="file"/> | ||
25 | + </root> | ||
26 | +</configuration> | ||
0 | \ No newline at end of file | 27 | \ No newline at end of file |
zhyx-api/zhyx-api.iml
0 → 100644