Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

这是一个关于交易记录的web项目,使用Spring+Springmcv框架 银泰网机试题 2.程序设计与解释 2.1程序设计思路: 1) … #13

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

WendellZhou
Copy link

…为了保证能够与IDE无关,我的解决是把工程完成后,打包成war包。war包的web工程遵守了JavaEE规范。可以直接放到Tomcat中运行。 2)为了把数据放到程序中。我的持久化方案是把数据存储在XML文件中。使用Dom4J+XPath解析项目xml文件,得到xml文件中交易记录。 3)因为Springmvc本身具备发布Rest风格服务。我使用Spring+Springnvc框架,发布Rest服务。 4)用户调用接口,得到JSON格式数据。

3.测试 3.1添加交易记录 地址: http://localhost:8090/deal2/makeDeal.jsp

3.2查询交易记录 //state值为“0”代表交易成功。值为:“1”为交易失败。

1)查询交易成功的记录 地址:http://localhost:8090/deal2/rest/getDeals/0

2)查询交易失败的记录 地址:http://localhost:8090/deal2/rest/getDeals/1

===================周文中================

…为了保证能够与IDE无关,我的解决是把工程完成后,打包成war包。war包的web工程遵守了JavaEE规范。可以直接放到Tomcat中运行。 2)为了把数据放到程序中。我的持久化方案是把数据存储在XML文件中。使用Dom4J+XPath解析项目xml文件,得到xml文件中交易记录。 3)因为Springmvc本身具备发布Rest风格服务。我使用Spring+Springnvc框架,发布Rest服务。 4)用户调用接口,得到JSON格式数据。

3.测试 3.1添加交易记录 地址: http://localhost:8090/deal2/makeDeal.jsp

3.2查询交易记录 //state值为“0”代表交易成功。值为:“1”为交易失败。

1)查询交易成功的记录 地址:http://localhost:8090/deal2/rest/getDeals/0

2)查询交易失败的记录 地址:http://localhost:8090/deal2/rest/getDeals/1

===================周文中================
@mengqiang81
Copy link
Contributor

已收到, 正在 review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants