├── README.md ├── assets ├── Snipaste_2025-04-19_18-26-00.png ├── image-20250310020708632.png ├── image-20250310020907964.png ├── pinjie.jpeg ├── pintu-fulicat.com-1741612540853.png └── pintu-fulicat.com-1741612663611.png ├── doc ├── tju_elm_project_report_latex │ ├── .gitignore │ ├── README.md │ ├── TJUThesis.bst │ ├── body │ │ ├── achievement.tex │ │ ├── background.tex │ │ ├── characteristic.tex │ │ ├── conclusion.tex │ │ ├── deploy.tex │ │ ├── devise.tex │ │ ├── divisionOfLabor.tex │ │ ├── equations.tex │ │ ├── figures.tex │ │ ├── instruction.tex │ │ ├── intros.tex │ │ ├── others.tex │ │ ├── process.tex │ │ ├── summarize.tex │ │ ├── summary.tex │ │ ├── tables.tex │ │ └── test.tex │ ├── figures │ │ ├── Pictur6.png │ │ ├── Pictur9.png │ │ ├── Picture1.png │ │ ├── Picture10.png │ │ ├── Picture11.png │ │ ├── Picture12.png │ │ ├── Picture13.png │ │ ├── Picture14.png │ │ ├── Picture15.png │ │ ├── Picture2.png │ │ ├── Picture20.png │ │ ├── Picture3.png │ │ ├── Picture30.png │ │ ├── Picture31.png │ │ ├── Picture32.png │ │ ├── Picture33.png │ │ ├── Picture34png.png │ │ ├── Picture35.png │ │ ├── Picture36.png │ │ ├── Picture37.png │ │ ├── Picture38.png │ │ ├── Picture39.png │ │ ├── Picture4.png │ │ ├── Picture5.png │ │ ├── Picture7.png │ │ ├── Picture8.png │ │ ├── Tjulogo.png │ │ ├── eps │ │ │ ├── Tjulogo.eps │ │ │ ├── XML.eps │ │ │ ├── dataDimensions.eps │ │ │ ├── dataSize.eps │ │ │ ├── latex.eps │ │ │ ├── list.eps │ │ │ ├── pdf.eps │ │ │ ├── tju.eps │ │ │ └── word.eps │ │ └── image.png │ ├── setup │ │ ├── format.tex │ │ ├── info.tex │ │ ├── package.tex │ │ └── toc.tex │ ├── tjumain.run.xml │ ├── tjumain.tex │ └── tjumain.xdv └── 第47组实验报告.pdf ├── other ├── doc │ ├── Elm_PlantUML.docx │ ├── Image │ │ ├── Picture1.png │ │ ├── Picture10.png │ │ ├── Picture11.png │ │ ├── Picture12.png │ │ ├── Picture13.png │ │ ├── Picture14.png │ │ ├── Picture15.png │ │ ├── Picture2.png │ │ ├── Picture20.png │ │ ├── Picture3.png │ │ ├── Picture4.png │ │ ├── Picture5.png │ │ ├── Picture6.png │ │ ├── Picture7.png │ │ ├── Picture8.png │ │ ├── Picture9.png │ │ └── 启动页面.pptx │ ├── 饿了吧V2.0 所有接口及数据库设计.docx │ └── 饿了吧V2.0 所有接口汇总.docx └── docker_deploy │ ├── Dockerfile │ ├── deploy.sh │ ├── docker-build-image.txt │ ├── docker-compose.yaml │ ├── docker构建镜像.txt │ └── elmboot-0.0.1-SNAPSHOT.jar └── src ├── elm_admin ├── elm_admin.iml ├── lib ├── mysql-connector-j-8.4.0.jar └── src │ ├── Main.java │ └── com │ └── neusoft │ └── elm │ ├── ElmAdminEntry.java │ ├── ElmBusinessEntry.java │ ├── dao │ ├── AdminDao.java │ ├── BusinessDao.java │ ├── FoodDao.java │ └── impl │ │ ├── AdminDaoImpl.java │ │ ├── BusinessDaoImpl.java │ │ └── FoodDaoImpl.java │ ├── po │ ├── Admin.java │ ├── Business.java │ └── Food.java │ ├── util │ └── DBUtil.java │ └── view │ ├── AdminView.java │ ├── BusinessView.java │ ├── FoodView.java │ └── impl │ ├── AdminViewImpl.java │ ├── BusinessViewImpl.java │ └── FoodViewImpl.java ├── elm_demo ├── businessInfo.html ├── businessList.html ├── css │ ├── businessInfo.css │ ├── businessList.css │ ├── index.css │ ├── login.css │ ├── order.css │ ├── orderList.css │ ├── payment.css │ └── register.css ├── framework │ ├── font-awesome-4.7.0 │ │ └── font-awesome-4.7.0 │ │ │ ├── HELP-US-OUT.txt │ │ │ ├── css │ │ │ ├── font-awesome.css │ │ │ └── font-awesome.min.css │ │ │ ├── fonts │ │ │ ├── FontAwesome.otf │ │ │ ├── fontawesome-webfont.eot │ │ │ ├── fontawesome-webfont.svg │ │ │ ├── fontawesome-webfont.ttf │ │ │ ├── fontawesome-webfont.woff │ │ │ └── fontawesome-webfont.woff2 │ │ │ ├── less │ │ │ ├── animated.less │ │ │ ├── bordered-pulled.less │ │ │ ├── core.less │ │ │ ├── fixed-width.less │ │ │ ├── font-awesome.less │ │ │ ├── icons.less │ │ │ ├── larger.less │ │ │ ├── list.less │ │ │ ├── mixins.less │ │ │ ├── path.less │ │ │ ├── rotated-flipped.less │ │ │ ├── screen-reader.less │ │ │ ├── stacked.less │ │ │ └── variables.less │ │ │ └── scss │ │ │ ├── _animated.scss │ │ │ ├── _bordered-pulled.scss │ │ │ ├── _core.scss │ │ │ ├── _fixed-width.scss │ │ │ ├── _icons.scss │ │ │ ├── _larger.scss │ │ │ ├── _list.scss │ │ │ ├── _mixins.scss │ │ │ ├── _path.scss │ │ │ ├── _rotated-flipped.scss │ │ │ ├── _screen-reader.scss │ │ │ ├── _stacked.scss │ │ │ ├── _variables.scss │ │ │ └── font-awesome.scss │ ├── icon.css │ └── reset.css ├── img │ ├── alipay.png │ ├── dcfl01.png │ ├── dcfl02.png │ ├── dcfl03.png │ ├── dcfl04.png │ ├── dcfl05.png │ ├── dcfl06.png │ ├── dcfl07.png │ ├── dcfl08.png │ ├── dcfl09.png │ ├── dcfl10.png │ ├── index_banner.png │ ├── sj01.png │ ├── sj02.png │ ├── sj03.png │ ├── sj04.png │ ├── sj05.png │ ├── sj06.png │ ├── sj07.png │ ├── sj08.png │ ├── sj09.png │ ├── sp01.png │ ├── sp02.png │ ├── sp03.png │ ├── sp04.png │ ├── sp05.png │ ├── sp06.png │ ├── sp07.png │ ├── sp08.png │ ├── sp09.png │ ├── sp10.png │ ├── sp11.png │ ├── sp12.png │ ├── super_member.png │ ├── userImg │ │ ├── userImg.png │ │ ├── yhtx01.png │ │ ├── yhtx02.png │ │ ├── yhtx03.png │ │ ├── yhtx04.png │ │ ├── yhtx05.png │ │ ├── yhtx06.png │ │ ├── yhtx07.png │ │ ├── yhtx08.png │ │ └── yhtx09.png │ └── wechat.png ├── index.html ├── login.html ├── order.html ├── orderList.html ├── payment.html └── register.html ├── elmboot-sql └── elm.sql ├── elmboot ├── pom.xml └── src │ ├── main │ ├── java │ │ └── com │ │ │ └── neusoft │ │ │ └── elmboot │ │ │ ├── ElmbootApplication.java │ │ │ ├── config │ │ │ ├── MyBatisConfig.java │ │ │ ├── WebConfig.java │ │ │ ├── WebMvcConfig.java │ │ │ └── WenXinProperties.java │ │ │ ├── constants │ │ │ └── TransactionStatus.java │ │ │ ├── controller │ │ │ ├── BusinessController.java │ │ │ ├── CartController.java │ │ │ ├── ChatsController.java │ │ │ ├── DeliveryAddressController.java │ │ │ ├── DiscoverSearchHistoryController.java │ │ │ ├── FavoriteController.java │ │ │ ├── FoodController.java │ │ │ ├── GeoCodingService.java │ │ │ ├── LikesController.java │ │ │ ├── OrdersController.java │ │ │ ├── RemarkController.java │ │ │ ├── SearchController.java │ │ │ ├── SmartSearchController.java │ │ │ ├── UserController.java │ │ │ └── wenxincontroller.java │ │ │ ├── intercept │ │ │ └── SqlInjectInterceptor.java │ │ │ ├── interceptor │ │ │ └── JwtAuthInterceptor.java │ │ │ ├── mapper │ │ │ ├── BusinessMapper.java │ │ │ ├── CartMapper.java │ │ │ ├── ChatsMapper.java │ │ │ ├── DeliveryAddressMapper.java │ │ │ ├── DiscoverSearchHistoryMapper.java │ │ │ ├── FavoriteMapper.java │ │ │ ├── FoodMapper.java │ │ │ ├── HistoryMapper.java │ │ │ ├── LikesMapper.java │ │ │ ├── OrderDetailetMapper.java │ │ │ ├── OrderDetailet_FoodMapper.java │ │ │ ├── OrdersMapper.java │ │ │ ├── RemarkMapper.java │ │ │ └── UserMapper.java │ │ │ ├── po │ │ │ ├── Business.java │ │ │ ├── Cart.java │ │ │ ├── Chats.java │ │ │ ├── DeliveryAddress.java │ │ │ ├── DiscoverSearchHistory.java │ │ │ ├── Favorite.java │ │ │ ├── Food.java │ │ │ ├── History.java │ │ │ ├── InsufficientBalanceException.java │ │ │ ├── InvalidAmountException.java │ │ │ ├── Likes.java │ │ │ ├── OrderDetailet.java │ │ │ ├── OrderDetailet_Food.java │ │ │ ├── Orders.java │ │ │ ├── Remark.java │ │ │ ├── SearchResult.java │ │ │ ├── User.java │ │ │ ├── UserAvatar.java │ │ │ ├── UserPsd.java │ │ │ └── image.java │ │ │ ├── service │ │ │ ├── BusinessService.java │ │ │ ├── CartService.java │ │ │ ├── ChatsService.java │ │ │ ├── DeliveryAddressService.java │ │ │ ├── DiscoverSearchHistoryService.java │ │ │ ├── FavoriteService.java │ │ │ ├── FoodService.java │ │ │ ├── HistoryService.java │ │ │ ├── LikesService.java │ │ │ ├── OrdersService.java │ │ │ ├── RemarkService.java │ │ │ ├── SmartSearchService.java │ │ │ ├── UserService.java │ │ │ ├── WenXinService.java │ │ │ └── impl │ │ │ │ ├── BusinessServiceImpl.java │ │ │ │ ├── CartServiceImpl.java │ │ │ │ ├── ChatsServiceImpl.java │ │ │ │ ├── DeliveryAddressServiceImpl.java │ │ │ │ ├── DiscoverSearchHistoryServiceImpl.java │ │ │ │ ├── FavoriteServiceImpl.java │ │ │ │ ├── FoodServiceImpl.java │ │ │ │ ├── HistoryServiceImpl.java │ │ │ │ ├── LikesServiceImpl.java │ │ │ │ ├── OrdersServiceImpl.java │ │ │ │ ├── RemarkServiceImpl.java │ │ │ │ ├── SmartSearchServiceImpl.java │ │ │ │ ├── UserServiceImpl.java │ │ │ │ └── WenXinServiceImpl.java │ │ │ └── util │ │ │ ├── CommonUtil.java │ │ │ ├── HttpClientUtil.java │ │ │ └── JwtUtil.java │ └── resources │ │ ├── application.yml │ │ └── mapper │ │ ├── CartMapper.xml │ │ ├── OrderDetailetMapper.xml │ │ └── OrdersMapper.xml │ └── test │ └── java │ └── com │ └── neusoft │ └── elmboot │ └── ElmbootApplicationTests.java └── elmclient ├── .gitignore ├── README.md ├── babel.config.js ├── jsconfig.json ├── package-lock.json ├── package.json ├── public ├── R-C.png ├── baozi.jpg ├── chicken.jpg ├── duck.jpg ├── favicon.ico ├── index.html ├── jiaozi.jpg ├── meat.jpg ├── paigu.jpg ├── shumai.jpg ├── tofu.jpg ├── yu.jpg └── 下载.jpg ├── src ├── App.vue ├── assets │ ├── R-C.png │ ├── alipay.png │ ├── dcfl01.png │ ├── dcfl02.png │ ├── dcfl03.png │ ├── dcfl04.png │ ├── dcfl05.png │ ├── dcfl06.png │ ├── dcfl07.png │ ├── dcfl08.png │ ├── dcfl09.png │ ├── dcfl10.png │ ├── index_banner.png │ ├── logo.png │ ├── readme.txt │ ├── sj01.png │ ├── sj02.png │ ├── sj03.png │ ├── sj04.png │ ├── sj05.png │ ├── sj06.png │ ├── sj07.png │ ├── sj08.png │ ├── sj09.png │ ├── sp01.png │ ├── sp02.png │ ├── sp03.png │ ├── sp04.png │ ├── sp05.png │ ├── sp06.png │ ├── sp07.png │ ├── sp08.png │ ├── sp09.png │ ├── sp10.png │ ├── sp11.png │ ├── sp12.png │ ├── super_member.png │ └── wechat.png ├── common.js ├── components │ ├── BackButton.vue │ ├── BusinessFooter.vue │ ├── Footer.vue │ ├── HelloWorld.vue │ └── Toast.vue ├── main.js ├── router │ └── index.js ├── utils │ └── toast.js └── views │ ├── AboutView.vue │ ├── AddUserAddress.vue │ ├── BusinessInfo.vue │ ├── BusinessInformation.vue │ ├── BusinessList.vue │ ├── BusinessLogin.vue │ ├── BusinessRegister.vue │ ├── BusinessView.vue │ ├── Cart.vue │ ├── CommentBusiness.vue │ ├── CommentsList.vue │ ├── Discover.vue │ ├── EditUserAddress.vue │ ├── HomeView.vue │ ├── Index.vue │ ├── LChoose.vue │ ├── LikesList.vue │ ├── Login.vue │ ├── MyInformation.vue │ ├── Myfavorite.vue │ ├── OrderList.vue │ ├── Orders.vue │ ├── Payment.vue │ ├── PersonalInfo.vue │ ├── RChoose.vue │ ├── Register.vue │ ├── Search.vue │ ├── SubmitItems.vue │ ├── SuccessfulPayment.vue │ └── UserAddress.vue └── vue.config.js /assets/Snipaste_2025-04-19_18-26-00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/assets/Snipaste_2025-04-19_18-26-00.png -------------------------------------------------------------------------------- /assets/image-20250310020708632.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/assets/image-20250310020708632.png -------------------------------------------------------------------------------- /assets/image-20250310020907964.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/assets/image-20250310020907964.png -------------------------------------------------------------------------------- /assets/pinjie.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/assets/pinjie.jpeg -------------------------------------------------------------------------------- /assets/pintu-fulicat.com-1741612540853.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/assets/pintu-fulicat.com-1741612540853.png -------------------------------------------------------------------------------- /assets/pintu-fulicat.com-1741612663611.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/assets/pintu-fulicat.com-1741612663611.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/.gitignore: -------------------------------------------------------------------------------- 1 | *.pdf 2 | *.bat 3 | *.fls 4 | *.fdb_latexmk 5 | *.aux 6 | *.bbl 7 | *.blg 8 | *.log 9 | *.out 10 | *.thm 11 | *.toc 12 | *.gz 13 | -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/README.md: -------------------------------------------------------------------------------- 1 | # tju_course_design_report_template 2 | 3 | #### 项目介绍 4 | 天津大学软件学院专业课程设计2结课报告模板 5 | 6 | #### 环境配置 7 | 8 | 推荐使用 VS Code + Latex Workshop(VsCode插件) + Texlive进行撰写。 9 | 10 | #### 使用说明 11 | 12 | tjumain.tex 主模板文件 13 | 14 | body/ 在此文件夹下编写论文各章节内容 15 | 16 | body文件夹下的文件需要在tjumain.tex的相应位置添加引用 17 | ``` 18 | \include{body/intros} 19 | \include{body/figures} 20 | \include{body/tables} 21 | \include{body/equations} 22 | \include{body/others} 23 | \include{body/conclusion} 24 | ``` 25 | 26 | figure/* 文中所使用的图片 27 | 28 | setup/info.tex 封面和页眉的基本信息 29 | 30 | #### 如何参与贡献 31 | 32 | 1. Fork 本项目 33 | 2. 新建分支 34 | 3. 提交代码 35 | 4. 创建 Pull Request -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/body/achievement.tex: -------------------------------------------------------------------------------- 1 | % !Mode:: "TeX:UTF-8" 2 | 3 | \chapter{实践成果} 4 | 5 | 6 | -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/body/conclusion.tex: -------------------------------------------------------------------------------- 1 | % !Mode:: "TeX:UTF-8" 2 | 3 | \chapter{结论} 4 | 5 | 学位论文的结论作为论文正文的最后一章单独排写,但不加章标题序号。 结论应是作者在学位论文研究过程中所取得的创新性成果的概要总结,不能与摘要混为一谈。 6 | 学位论文结论应包括论文的主要结果、创新点、展望三部分,在结论中应概括论文的核心观点, 7 | 明确、客观地指出本研究内容的创新性成果(含新见解、新观点、方法创新、技术创新、理论创新), 8 | 并指出今后进一步在本研究方向进行研究工作的展望与设想。 9 | 对所取得的创新性成果应注意从定性和定量两方面给出科学、准确的评价,分(1)、(2)、(3)…条列出,宜用“提出了”、“建立了”等词叙述。 -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/body/divisionOfLabor.tex: -------------------------------------------------------------------------------- 1 | % !Mode:: "TeX:UTF-8" 2 | 3 | \chapter{人员分工及项目进度} 4 | 5 | \begin{itemize} 6 | \item \textbf{人员分工:} 7 | \begin{itemize} 8 | \item 杨宇鑫:负责后端与部署 9 | \item 谢帛洋:负责前端与测试 10 | \end{itemize} 11 | \end{itemize} 12 | 13 | \begin{itemize} 14 | \item \textbf{项目进度:} 15 | \begin{itemize} 16 | \item 第一周:学习了项目一的内容,复盘了项目一的代码; 17 | \item 第二周:学习了项目二到项目四的内容,复盘了项目二到项目四的代码,饿了吧V1.0项目复盘完成; 18 | \item 第三周:创新了原项目,饿了吧V2.0项目完成。 19 | \end{itemize} 20 | \end{itemize} 21 | -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/body/summarize.tex: -------------------------------------------------------------------------------- 1 | \chapter{问题,解决对策及反思} 2 | 3 | \section{浮点数精度} 4 | 问题:如果出现3个0.1相加的情况,得到的结果就是0.3000004 5 | 6 | 解决方案:用字符串表示小数,然后通过字符串相加的算法,得到最终结果 7 | 8 | \section{页面显示不全} 9 | 问题:有些机型在页面下拉的时候,由于底部有遮挡,没有办法下拉到最下边 10 | 11 | 解决方案:底部适当留白 12 | 13 | 反思:站在用户的角度,完善页面布局,给用户最好的体验 14 | 15 | \section{历史订单的价格不能随着新的商品价格变化而变化} 16 | 问题:当改变数据库一个商品价格的时候,之前已经购买的商品的价格也会变化 17 | 18 | 解决方案:在原有的订单明细表中,增加一个属性;商品的priceAtThatTime,记住商品在购买时的价格 19 | ,当展示订单明细的时候,不用在数据库中去找现在的商品,而是直接在订单明细表中拿到当时的商品价格 20 | 21 | 反思:当想要保留一个数据的时候,可以直接在数据库中增加属性,在创建的时候,可以直接将值保留进数据库, 22 | 在想用的时候直接从数据库中拿到想要的值就可以了 23 | 24 | 25 | \section{商品详情页的图片不能显示} 26 | 问题:商品详情页的图片不能显示,因为图片的url是相对路径,需要将图片的url改为绝对路径 27 | 28 | 解决方案:在数据库中,将图片的url改为绝对路径,在商品详情页中,通过绝对路径来获取图片 29 | 30 | 反思:在数据库中,将图片的url改为绝对路径,在商品详情页中,通过绝对路径来获取图片, 31 | 这样,在商品详情页中,图片的url就无需再通过服务器来获取了 32 | 33 | \section{搜索} 34 | 问题:搜索功能,只能搜索到商家,无法搜索到想要的商品 35 | 36 | 解决方案:强化搜索的sql语句:先将商家与商品按照商家的id进行左连接,并筛选出带有关键词的 37 | 商家or商品,将筛选出满足条件的所有商家的id,再显示所有的商家id在(in)刚才筛选出的id中的商家即可 38 | 39 | 反思:优化sql语句,可以实现更强大的功能 40 | 41 | \section{手机号和密码的强度检验} 42 | 问题:如果没有检验,用户使用的手机号和密码将会泛滥,失去控制 43 | 44 | 解决方案:使用正则表达式进行手机号与密码的强度判断 45 | 46 | \section{点赞,收藏,评论的存储} 47 | 48 | 问题:用户的点赞,收藏,评论如何永久保留 49 | 50 | 解决方案:在数据库中新建点赞,收藏,评论的表结构,并约束好主键外键,设计索引以便更方便的查询数据库中的数据 51 | 52 | \section{文心一言的接口} 53 | 54 | 问题:在javaweb工程中,如何调用文心一言的接口 55 | 56 | 解决方案:通过查询文心一言api的官网,根据教程与代码,在javaweb工程中,通过HttpClient调用文心一言的接口,并获取返回结果 57 | 58 | \section{部署到云端} 59 | 60 | 问题:如何将本地的javaweb工程部署到云端,并让云端能访问到前端后端以及数据库 61 | 62 | 解决方案:注册腾讯云账号,开通一个云服务器,因为云服务器上的操作系统是linux, 63 | 不方便操作,所以安装宝塔面板,通过数据库部署,html前端部署,java后端部署以及一些配置 64 | 完成云端部署,并可以通过公网ip访问到云端的项目 -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/body/summary.tex: -------------------------------------------------------------------------------- 1 | \chapter{成果与展望} 2 | 3 | 经过团队成员共同努力,“饿了吧”项目不仅按期完成了既定目标,还超预期地实现了多项创新功能。未来我们将继续关注,不断迭代优化产品,力求提供更加优质的服务。同时,我们也将积极探索新技术的应用,如AI推荐算法等,以期进一步提升平台智能化水平 4 | 5 | “饿了吧”项目的成功离不开每一位参与者的辛勤付出与智慧贡献。它不仅是对我们现有技术水平的一次检验,更为重要的是它代表了我们对未来发展方向的一种探索。希望以此为契机,能够激励更多人投身于技术创新之中,共同推动行业进步。 -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Pictur6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Pictur6.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Pictur9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Pictur9.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture1.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture10.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture11.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture12.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture13.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture14.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture14.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture15.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture15.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture2.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture20.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture3.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture30.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture30.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture31.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture31.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture32.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture33.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture33.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture34png.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture34png.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture35.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture35.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture36.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture36.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture37.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture37.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture38.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture38.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture39.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture39.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture4.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture5.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture7.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Picture8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Picture8.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/Tjulogo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/Tjulogo.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/eps/Tjulogo.eps: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/eps/Tjulogo.eps -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/figures/image.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/figures/image.png -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/setup/info.tex: -------------------------------------------------------------------------------- 1 | % !Mode:: "TeX:UTF-8" 2 | 3 | 4 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 5 | %% 可通过对 setup/format.tex中 %% 6 | %% 第243行 \setlength{\@title@width}{5cm}中 5cm 这个参数来 %% 7 | %% 控制封面中下划线的长度。 %% 8 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 9 | 10 | \cheading{天津大学软件学院~\the\year~年《专业课程设计2》结课报告} % 正文页眉 11 | \ccovertitle{《软件工程综合实践》结课报告} % 封面标题 12 | 13 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 14 | %%%%%%%%%% 以下为论文的基本信息,需要由作者进行修改 %%%%%%%%%%%% 15 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 16 | \ctitle{饿了吧项目实践报告} % 封面用论文标题,自己可手动断行 17 | \caffil{软件工程学院} % 学院名称 18 | \csubject{软件工程} % 专业名称 19 | \cgrade{2022级} % 年级 20 | \cauthor{杨宇鑫~谢帛洋} % 学生姓名 21 | \cstuid{~~~~3022207128~3022206049} % 学号 22 | 23 | \cdate{\the\year~年~\the\month~月~\the\day~日} % 论文完成日期,不需要修改,自动生成 24 | -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/setup/toc.tex: -------------------------------------------------------------------------------- 1 | % !Mode:: "TeX:UTF-8" 2 | 3 | % 目录 4 | \defaultfont 5 | \clearpage{ 6 | \pagestyle{empty} 7 | \cleardoublepage 8 | \setcounter{page}{1} % 单独从 1 开始编页码 9 | \pagenumbering{arabic} 10 | \titleformat{\chapter}{\centering\sanhao\hei}{\chaptername}{2em}{} % 设置目录两字的格式 11 | \pdfbookmark[0]{目~~录}{mulu} 12 | \tableofcontents % 中文目录 13 | \thispagestyle{plain} 14 | } -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/tjumain.tex: -------------------------------------------------------------------------------- 1 | % !Mode:: "TeX:UTF-8" 2 | 3 | \def\usewhat{pdflatex} % 定义编译方式 dvipdfmx 或者 pdflatex,默认为 dvipdfmx 4 | % 方式编译,如果需要修改,只需改变花括号中的内容即可。 5 | \documentclass[12pt,openany,oneside,ctexartutf8]{book} 6 | % 本科生毕业论文通常采用单页排版 7 | \input{setup/package} % 定义本文所使用宏包 8 | \graphicspath{{figures/}} % 定义所有的 .eps 文件在 figures 子目录下 9 | \begin{document} % 开始全文 10 | \begin{CJK*}{UTF8}{song} % 开始中文字体使用 11 | \input{setup/format} % 完成对论文各个部分格式的设置 12 | \input{setup/info} 13 | \frontmatter % 以下是论文导言部分,包括论文的封面,中英文摘要和中文目录 14 | \fancypagestyle{plain}{ % 正文前均无页眉 15 | \fancyhf{} 16 | \renewcommand{\headrulewidth}{0 pt} 17 | \fancyfoot[C]{\song\xiaowu~\thepage~} 18 | } 19 | 20 | \makecover % 封面 21 | 22 | \include{setup/toc} % 目录 23 | 24 | \mainmatter\defaultfont\sloppy\raggedbottom 25 | \makeatletter 26 | \fancypagestyle{plain}{ % 设置正文眉页脚风格 27 | \fancyhf{} 28 | \fancyhead[C]{\song\wuhao \@cheading} % 页眉格式 29 | \fancyfoot[C]{\song\xiaowu ~\thepage~} % 页脚格式 30 | \renewcommand{\headrulewidth}{0.5pt} 31 | \renewcommand{\footrulewidth}{0pt} 32 | } 33 | \makeatother 34 | \setcounter{page}{1} % 单独从 1 开始编页码 35 | \titleformat{\chapter}{\centering\xiaosan\hei}{\chaptername}{2em}{} % 恢复chapter标题格式要求 36 | 37 | %%%%%% 这里是正文,每个文件对应正文中的一章 %%%%%% 38 | 39 | \include{body/instruction} 40 | \include{body/devise} 41 | \include{body/test} 42 | \include{body/deploy} 43 | \include{body/divisionOfLabor} 44 | \include{body/process} 45 | \include{body/characteristic} 46 | \include{body/summarize} 47 | \include{body/summary} 48 | 49 | 50 | % \include{body/background} 51 | % \include{body/process} 52 | % \include{body/achievement} 53 | 54 | \end{CJK*} % 结束中文字体使用 55 | \end{document} % 结束全文 56 | -------------------------------------------------------------------------------- /doc/tju_elm_project_report_latex/tjumain.xdv: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/tju_elm_project_report_latex/tjumain.xdv -------------------------------------------------------------------------------- /doc/第47组实验报告.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/doc/第47组实验报告.pdf -------------------------------------------------------------------------------- /other/doc/Elm_PlantUML.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Elm_PlantUML.docx -------------------------------------------------------------------------------- /other/doc/Image/Picture1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture1.png -------------------------------------------------------------------------------- /other/doc/Image/Picture10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture10.png -------------------------------------------------------------------------------- /other/doc/Image/Picture11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture11.png -------------------------------------------------------------------------------- /other/doc/Image/Picture12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture12.png -------------------------------------------------------------------------------- /other/doc/Image/Picture13.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture13.png -------------------------------------------------------------------------------- /other/doc/Image/Picture14.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture14.png -------------------------------------------------------------------------------- /other/doc/Image/Picture15.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture15.png -------------------------------------------------------------------------------- /other/doc/Image/Picture2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture2.png -------------------------------------------------------------------------------- /other/doc/Image/Picture20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture20.png -------------------------------------------------------------------------------- /other/doc/Image/Picture3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture3.png -------------------------------------------------------------------------------- /other/doc/Image/Picture4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture4.png -------------------------------------------------------------------------------- /other/doc/Image/Picture5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture5.png -------------------------------------------------------------------------------- /other/doc/Image/Picture6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture6.png -------------------------------------------------------------------------------- /other/doc/Image/Picture7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture7.png -------------------------------------------------------------------------------- /other/doc/Image/Picture8.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture8.png -------------------------------------------------------------------------------- /other/doc/Image/Picture9.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/Picture9.png -------------------------------------------------------------------------------- /other/doc/Image/启动页面.pptx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/Image/启动页面.pptx -------------------------------------------------------------------------------- /other/doc/饿了吧V2.0 所有接口及数据库设计.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/饿了吧V2.0 所有接口及数据库设计.docx -------------------------------------------------------------------------------- /other/doc/饿了吧V2.0 所有接口汇总.docx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/doc/饿了吧V2.0 所有接口汇总.docx -------------------------------------------------------------------------------- /other/docker_deploy/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM openjdk:17 2 | 3 | LABEL author=yangyuxin 4 | 5 | COPY elmboot-0.0.1-SNAPSHOT.jar /app.jar 6 | 7 | EXPOSE 8080 8 | 9 | ENTRYPOINT ["java","-jar","/app.jar"] 10 | -------------------------------------------------------------------------------- /other/docker_deploy/docker-build-image.txt: -------------------------------------------------------------------------------- 1 | docker build -f Dockerfile -t elmboot-app:latest . 2 | docker tag elmboot-app:latest jhm2004/tju-springboot-elm:latest 3 | docker login (接着复制生成的one-time code, 点击链接输入code, 登录成功,注意复制code的时候不要将命令行打断,不行的话就手动输入code) 4 | docker push jhm2004/tju-springboot-elm:latest 5 | 6 | 7 | 8 | 9 | VM_IP=$(curl -s https://api.ipify.org) docker compose -f compose.yaml up -d 10 | 11 | 12 | # 单独run elmboot-app 13 | docker run --name elmboot-app -p 8888:8080 --env VITE_API_BASE_URL=http://${VM_IP}:8888/ --network springboot-elm_elmboot elmboot-app:latest -------------------------------------------------------------------------------- /other/docker_deploy/docker-compose.yaml: -------------------------------------------------------------------------------- 1 | name: springboot-elm 2 | services: 3 | mysql: 4 | container_name: elmboot-mysql 5 | image: mysql:latest 6 | ports: 7 | - "11000:3306" 8 | environment: 9 | - MYSQL_ROOT_PASSWORD=123456 10 | - MYSQL_DATABASE=elm 11 | volumes: 12 | - mysql-data:/var/lib/mysql 13 | - /app/myconf:/etc/mysql/conf.d 14 | restart: always 15 | networks: 16 | - elmboot 17 | tju-springboot-elm: 18 | container_name: elmboot-app 19 | image: jhm2004/tju-springboot-elm:latest 20 | ports: 21 | - "10000:8080" 22 | environment: 23 | - VITE_API_BASE_URL=http://${VM_IP}:10000/ 24 | restart: always 25 | networks: 26 | - elmboot 27 | depends_on: 28 | - mysql 29 | 30 | volumes: 31 | mysql-data: 32 | 33 | networks: 34 | elmboot: -------------------------------------------------------------------------------- /other/docker_deploy/docker构建镜像.txt: -------------------------------------------------------------------------------- 1 | # 构建ELM镜像 2 | docker build -f Dockerfile -t elmboot-app:latest . 3 | # 为ELM镜像打tag,为了上传到DockerHub 4 | docker tag elmboot-app:latest jhm2004/tju-springboot-elm:latest 5 | # 推送到DockerHub,在此之前需要docker login登录 6 | docker push jhm2004/tju-springboot-elm:latest 7 | 8 | 9 | # ------------------ 其他 -------------------- 10 | 11 | VM_IP=$(curl -s https://api.ipify.org) docker compose -f compose.yaml up -d 12 | 13 | # 单独run elmboot-app 14 | docker run --name elmboot-app -p 8888:8080 --env VITE_API_BASE_URL=http://${VM_IP}:8888/ --network springboot-elm_elmboot elmboot-app:latest 15 | 16 | # 一键部署命令 17 | sudo curl -fsSL -o ~/deploy.sh https://www.yangyuxin.cn/elm/boot/deploy.sh && sudo curl -fsSL -o ~/elm.sql https://www.yangyuxin.cn/elm/boot/elm.sql && sudo curl -fsSL -o ~/docker-compose.yaml https://www.yangyuxin.cn/elm/boot/docker-compose.yaml && sudo chmod +x ~/deploy.sh && sudo bash ~/deploy.sh 18 | # 端口 19 | mysql 11000 20 | elmboot-app 10000 21 | 22 | -------------------------------------------------------------------------------- /other/docker_deploy/elmboot-0.0.1-SNAPSHOT.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/other/docker_deploy/elmboot-0.0.1-SNAPSHOT.jar -------------------------------------------------------------------------------- /src/elm_admin/elm_admin.iml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /src/elm_admin/lib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_admin/lib -------------------------------------------------------------------------------- /src/elm_admin/mysql-connector-j-8.4.0.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_admin/mysql-connector-j-8.4.0.jar -------------------------------------------------------------------------------- /src/elm_admin/src/Main.java: -------------------------------------------------------------------------------- 1 | public class Main { 2 | public static void main(String[] args) { 3 | System.out.println("Hello world!"); 4 | } 5 | } -------------------------------------------------------------------------------- /src/elm_admin/src/com/neusoft/elm/dao/AdminDao.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elm.dao; 2 | 3 | import com.neusoft.elm.po.Admin; 4 | 5 | public interface AdminDao { 6 | 7 | public Admin getAdminByNameByPass(String adminName,String password); 8 | } 9 | -------------------------------------------------------------------------------- /src/elm_admin/src/com/neusoft/elm/dao/BusinessDao.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elm.dao; 2 | 3 | import com.neusoft.elm.po.Business; 4 | 5 | import java.util.List; 6 | 7 | public interface BusinessDao { 8 | //参数方便之后做模糊查询 9 | public List listBusiness(String businessName,String businessAddress); 10 | //返回值是新建商家的编号(主键) 11 | public int saveBusiness(String businessName); 12 | //按主键删除商家 13 | public int removeBusiness(int businessId); 14 | //获取商家 15 | public Business getBusinessByIdByPass(Integer businessId,String password); 16 | //查看商家信息 17 | public Business getBusinessById(Integer businessId); 18 | //修改商家信息(增,删,改 的返回值都是int) 19 | public int updateBusiness(Business business); 20 | //修改商家密码 21 | public int updateBusinessPassword(Integer businessId,String password); 22 | 23 | } 24 | -------------------------------------------------------------------------------- /src/elm_admin/src/com/neusoft/elm/dao/FoodDao.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elm.dao; 2 | 3 | import com.neusoft.elm.po.Food; 4 | 5 | import java.util.List; 6 | 7 | public interface FoodDao { 8 | public List listFoodByBusinessId(Integer businessId); 9 | 10 | public int saveFood(Food food); 11 | 12 | public Food getFoodById(Integer foodId); 13 | 14 | public int updateFood(Food food); 15 | 16 | public int removeFood(Integer foodId); 17 | 18 | 19 | } 20 | -------------------------------------------------------------------------------- /src/elm_admin/src/com/neusoft/elm/dao/impl/AdminDaoImpl.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elm.dao.impl; 2 | 3 | //实现类 4 | 5 | import java.sql.Connection; 6 | import java.sql.PreparedStatement; 7 | import java.sql.ResultSet; 8 | import java.sql.SQLException; 9 | 10 | import com.neusoft.elm.dao.AdminDao; 11 | import com.neusoft.elm.po.Admin; 12 | import com.neusoft.elm.util.DBUtil; 13 | 14 | public class AdminDaoImpl implements AdminDao { 15 | 16 | private Connection con=null; 17 | private PreparedStatement pst=null; 18 | private ResultSet rs=null; 19 | 20 | @Override 21 | public Admin getAdminByNameByPass(String adminName, String password) { 22 | Admin admin=null; 23 | String sql="select * from admin where adminName=? and password=?"; 24 | try { 25 | con = DBUtil.getConnection(); 26 | pst=con.prepareStatement(sql); 27 | pst.setString(1,adminName); 28 | pst.setString(2,password); 29 | rs = pst.executeQuery(); 30 | 31 | //其实只能查到一个admin 32 | while(rs.next()){ 33 | //将表结构数据转换成java的对象数据的过程 34 | admin=new Admin(); 35 | admin.setAdminId(rs.getInt("adminId")); 36 | admin.setAdminName(rs.getString("adminName")); 37 | admin.setPassword(rs.getString("password")); 38 | 39 | } 40 | } catch (Exception e) { 41 | e.printStackTrace(); 42 | }finally{ 43 | //释放资源 44 | DBUtil.close(rs,pst,con); 45 | } 46 | return admin; 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /src/elm_admin/src/com/neusoft/elm/po/Admin.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elm.po; 2 | 3 | //持久化数据库的表1 4 | //表1 5 | 6 | public class Admin { 7 | //属性 8 | private Integer adminId; 9 | private String adminName; 10 | private String password; 11 | 12 | //get set 方法 13 | 14 | public Integer getAdminId() { 15 | return adminId; 16 | } 17 | 18 | public void setAdminId(Integer adminId) { 19 | this.adminId = adminId; 20 | } 21 | 22 | public String getAdminName() { 23 | return adminName; 24 | } 25 | 26 | public void setAdminName(String adminName) { 27 | this.adminName = adminName; 28 | } 29 | 30 | public String getPassword() { 31 | return password; 32 | } 33 | 34 | public void setPassword(String password) { 35 | this.password = password; 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /src/elm_admin/src/com/neusoft/elm/po/Business.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elm.po; 2 | 3 | public class Business { 4 | private Integer businessId; 5 | private String password; 6 | private String businessName; 7 | private String businessAddress; 8 | private String businessExplain; 9 | private Double starPrice; 10 | private Double deliverPrice; 11 | 12 | //输出对象(重写toString方法) 13 | @Override 14 | public String toString(){ 15 | return "\n商家编号:"+this.businessId+ 16 | "\n商家名称"+this.businessName+ 17 | "\n商家地址"+this.businessAddress+ 18 | "\n商家介绍"+this.businessExplain+ 19 | "\n起送费"+this.starPrice+ 20 | "\n配送费"+this.deliverPrice; 21 | } 22 | 23 | 24 | 25 | 26 | public Integer getBusinessId() { 27 | return businessId; 28 | } 29 | 30 | public void setBusinessId(Integer businessId) { 31 | this.businessId = businessId; 32 | } 33 | 34 | public String getPassword() { 35 | return password; 36 | } 37 | 38 | public void setPassword(String password) { 39 | this.password = password; 40 | } 41 | 42 | public String getBusinessName() { 43 | return businessName; 44 | } 45 | 46 | public void setBusinessName(String businessName) { 47 | this.businessName = businessName; 48 | } 49 | 50 | public String getBusinessAddress() { 51 | return businessAddress; 52 | } 53 | 54 | public void setBusinessAddress(String businessAddress) { 55 | this.businessAddress = businessAddress; 56 | } 57 | 58 | public String getBusinessExplain() { 59 | return businessExplain; 60 | } 61 | 62 | public void setBusinessExplain(String businessExplain) { 63 | this.businessExplain = businessExplain; 64 | } 65 | 66 | public Double getStarPrice() { 67 | return starPrice; 68 | } 69 | 70 | public void setStarPrice(Double starPrice) { 71 | this.starPrice = starPrice; 72 | } 73 | 74 | public Double getDeliverPrice() { 75 | return deliverPrice; 76 | } 77 | 78 | public void setDeliverPrice(Double deliverPrice) { 79 | this.deliverPrice = deliverPrice; 80 | } 81 | } 82 | -------------------------------------------------------------------------------- /src/elm_admin/src/com/neusoft/elm/po/Food.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elm.po; 2 | 3 | //表3 食品表 4 | public class Food { 5 | private Integer foodId; 6 | private String foodName; 7 | private String foodExplain; 8 | private Double foodPrice; 9 | private Integer businessId; 10 | 11 | @Override 12 | public String toString(){ 13 | return "\n食品编号:"+this.foodId+ 14 | "\n食品名称"+this.foodName+ 15 | "\n食品介绍"+this.foodExplain+ 16 | "\n食品价格"+this.foodPrice+ 17 | "\n所属商家"+this.businessId; 18 | } 19 | 20 | public Integer getFoodId() { 21 | return foodId; 22 | } 23 | 24 | public void setFoodId(Integer foodId) { 25 | this.foodId = foodId; 26 | } 27 | 28 | public String getFoodName() { 29 | return foodName; 30 | } 31 | 32 | public void setFoodName(String foodName) { 33 | this.foodName = foodName; 34 | } 35 | 36 | public String getFoodExplain() { 37 | return foodExplain; 38 | } 39 | 40 | public void setFoodExplain(String foodExplain) { 41 | this.foodExplain = foodExplain; 42 | } 43 | 44 | public Double getFoodPrice() { 45 | return foodPrice; 46 | } 47 | 48 | public void setFoodPrice(Double foodPrice) { 49 | this.foodPrice = foodPrice; 50 | } 51 | 52 | public Integer getBusinessId() { 53 | return businessId; 54 | } 55 | 56 | public void setBusinessId(Integer businessId) { 57 | this.businessId = businessId; 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /src/elm_admin/src/com/neusoft/elm/util/DBUtil.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elm.util; 2 | 3 | import java.sql.*; 4 | 5 | //数据库工具类 6 | 7 | public class DBUtil { 8 | // 这个数据库工具类需要干两件事情 9 | // 1.获取一个connection数据库连接 10 | // 2.关闭对数据库操作后的资源 11 | 12 | //常量 数据库连接字符串 协议 本机服务器 端口 数据库名 字符集 13 | private static final String URL="jdbc:mysql://localhost:3306/elm_admin?characterEncoding=utf-8"; 14 | //常量 驱动架包的路径 15 | private static final String DRIVER="com.mysql.cj.jdbc.Driver";//相对路径 16 | 17 | //常量 数据库的用户名和密码 18 | private static final String USERNAME="root";//相对路径 19 | private static final String PASSWORD="123456";//相对路径 20 | 21 | //获取connection 22 | //静态变量,使用方便,用的时候直接类名.方法名,不用创建对象了 23 | public static Connection getConnection(){ 24 | Connection con=null; 25 | try { 26 | //加载驱动路径,就能加载mysql驱动了 27 | Class.forName(DRIVER); 28 | con=DriverManager.getConnection(URL,USERNAME,PASSWORD); 29 | } catch (Exception e) { 30 | e.printStackTrace(); 31 | } 32 | return con; 33 | } 34 | 35 | 36 | //关闭所有资源 通用的,声明成静态 37 | public static void close(ResultSet rs, PreparedStatement pst,Connection con) { 38 | //判断空指针 39 | if(rs!=null){ 40 | try { 41 | rs.close(); 42 | } catch (Exception e) { 43 | e.printStackTrace(); 44 | } 45 | } 46 | //释放资源 47 | rs=null; 48 | 49 | //判断空指针 50 | if(pst!=null){ 51 | try { 52 | pst.close(); 53 | } catch (Exception e) { 54 | e.printStackTrace(); 55 | } 56 | } 57 | //释放资源 58 | pst=null; 59 | 60 | //判断空指针 61 | if(con!=null){ 62 | try { 63 | con.close(); 64 | } catch (Exception e) { 65 | e.printStackTrace(); 66 | } 67 | } 68 | //释放资源 69 | con=null; 70 | 71 | } 72 | 73 | } 74 | -------------------------------------------------------------------------------- /src/elm_admin/src/com/neusoft/elm/view/AdminView.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elm.view; 2 | 3 | import com.neusoft.elm.po.Admin; 4 | 5 | public interface AdminView { 6 | public Admin login(); 7 | } 8 | -------------------------------------------------------------------------------- /src/elm_admin/src/com/neusoft/elm/view/BusinessView.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elm.view; 2 | 3 | import com.neusoft.elm.po.Business; 4 | 5 | public interface BusinessView { 6 | public void listBusinessAll(); 7 | //模糊匹配查询 8 | public void listBusiness(); 9 | 10 | public void saveBusiness(); 11 | 12 | public void removeBusiness(); 13 | 14 | public Business login(); 15 | 16 | public void showBusiness(Integer businessId); 17 | 18 | //更新商家信息的View层 19 | public void editBusiness(Integer businessId); 20 | 21 | //更新密码的View层 22 | public void updateBusinessByPassword(Integer businessId); 23 | } 24 | -------------------------------------------------------------------------------- /src/elm_admin/src/com/neusoft/elm/view/FoodView.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elm.view; 2 | 3 | import com.neusoft.elm.po.Food; 4 | 5 | import java.util.List; 6 | 7 | public interface FoodView { 8 | public List showFoodList(Integer businessId); 9 | public void saveFood(Integer businessId); 10 | public void updateFood(Integer businessId); 11 | public void removeFood(Integer businessId); 12 | } 13 | -------------------------------------------------------------------------------- /src/elm_admin/src/com/neusoft/elm/view/impl/AdminViewImpl.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elm.view.impl; 2 | 3 | import com.neusoft.elm.dao.AdminDao; 4 | import com.neusoft.elm.dao.impl.AdminDaoImpl; 5 | import com.neusoft.elm.po.Admin; 6 | import com.neusoft.elm.view.AdminView; 7 | 8 | import java.util.Scanner; 9 | 10 | public class AdminViewImpl implements AdminView { 11 | 12 | //视图层需要画界面,我们用输出语句操作 13 | //获取用户在控制台输入的数据 14 | //拿这些数据在数据库中操作数据 15 | //根据数据层返回的结果显示在界面上 16 | 17 | private Scanner input=new Scanner(System.in); 18 | 19 | @Override 20 | public Admin login() { 21 | 22 | System.out.println("请输入管理员名称:"); 23 | String adminName=input.next(); 24 | System.out.println("请输入密码:"); 25 | String password=input.next(); 26 | 27 | AdminDao dao=new AdminDaoImpl(); 28 | Admin admin=dao.getAdminByNameByPass(adminName,password); 29 | return admin; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/HELP-US-OUT.txt: -------------------------------------------------------------------------------- 1 | I hope you love Font Awesome. If you've found it useful, please do me a favor and check out my latest project, 2 | Fort Awesome (https://fortawesome.com). It makes it easy to put the perfect icons on your website. Choose from our awesome, 3 | comprehensive icon sets or copy and paste your own. 4 | 5 | Please. Check it out. 6 | 7 | -Dave Gandy 8 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/fonts/FontAwesome.otf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/fonts/FontAwesome.otf -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/fonts/fontawesome-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/fonts/fontawesome-webfont.woff2 -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/less/animated.less: -------------------------------------------------------------------------------- 1 | // Animated Icons 2 | // -------------------------- 3 | 4 | .@{fa-css-prefix}-spin { 5 | -webkit-animation: fa-spin 2s infinite linear; 6 | animation: fa-spin 2s infinite linear; 7 | } 8 | 9 | .@{fa-css-prefix}-pulse { 10 | -webkit-animation: fa-spin 1s infinite steps(8); 11 | animation: fa-spin 1s infinite steps(8); 12 | } 13 | 14 | @-webkit-keyframes fa-spin { 15 | 0% { 16 | -webkit-transform: rotate(0deg); 17 | transform: rotate(0deg); 18 | } 19 | 100% { 20 | -webkit-transform: rotate(359deg); 21 | transform: rotate(359deg); 22 | } 23 | } 24 | 25 | @keyframes fa-spin { 26 | 0% { 27 | -webkit-transform: rotate(0deg); 28 | transform: rotate(0deg); 29 | } 30 | 100% { 31 | -webkit-transform: rotate(359deg); 32 | transform: rotate(359deg); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/less/bordered-pulled.less: -------------------------------------------------------------------------------- 1 | // Bordered & Pulled 2 | // ------------------------- 3 | 4 | .@{fa-css-prefix}-border { 5 | padding: .2em .25em .15em; 6 | border: solid .08em @fa-border-color; 7 | border-radius: .1em; 8 | } 9 | 10 | .@{fa-css-prefix}-pull-left { float: left; } 11 | .@{fa-css-prefix}-pull-right { float: right; } 12 | 13 | .@{fa-css-prefix} { 14 | &.@{fa-css-prefix}-pull-left { margin-right: .3em; } 15 | &.@{fa-css-prefix}-pull-right { margin-left: .3em; } 16 | } 17 | 18 | /* Deprecated as of 4.4.0 */ 19 | .pull-right { float: right; } 20 | .pull-left { float: left; } 21 | 22 | .@{fa-css-prefix} { 23 | &.pull-left { margin-right: .3em; } 24 | &.pull-right { margin-left: .3em; } 25 | } 26 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/less/core.less: -------------------------------------------------------------------------------- 1 | // Base Class Definition 2 | // ------------------------- 3 | 4 | .@{fa-css-prefix} { 5 | display: inline-block; 6 | font: normal normal normal @fa-font-size-base/@fa-line-height-base FontAwesome; // shortening font declaration 7 | font-size: inherit; // can't have font-size inherit on line above, so need to override 8 | text-rendering: auto; // optimizelegibility throws things off #1094 9 | -webkit-font-smoothing: antialiased; 10 | -moz-osx-font-smoothing: grayscale; 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/less/fixed-width.less: -------------------------------------------------------------------------------- 1 | // Fixed Width Icons 2 | // ------------------------- 3 | .@{fa-css-prefix}-fw { 4 | width: (18em / 14); 5 | text-align: center; 6 | } 7 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/less/font-awesome.less: -------------------------------------------------------------------------------- 1 | /*! 2 | * Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome 3 | * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) 4 | */ 5 | 6 | @import "variables.less"; 7 | @import "mixins.less"; 8 | @import "path.less"; 9 | @import "core.less"; 10 | @import "larger.less"; 11 | @import "fixed-width.less"; 12 | @import "list.less"; 13 | @import "bordered-pulled.less"; 14 | @import "animated.less"; 15 | @import "rotated-flipped.less"; 16 | @import "stacked.less"; 17 | @import "icons.less"; 18 | @import "screen-reader.less"; 19 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/less/larger.less: -------------------------------------------------------------------------------- 1 | // Icon Sizes 2 | // ------------------------- 3 | 4 | /* makes the font 33% larger relative to the icon container */ 5 | .@{fa-css-prefix}-lg { 6 | font-size: (4em / 3); 7 | line-height: (3em / 4); 8 | vertical-align: -15%; 9 | } 10 | .@{fa-css-prefix}-2x { font-size: 2em; } 11 | .@{fa-css-prefix}-3x { font-size: 3em; } 12 | .@{fa-css-prefix}-4x { font-size: 4em; } 13 | .@{fa-css-prefix}-5x { font-size: 5em; } 14 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/less/list.less: -------------------------------------------------------------------------------- 1 | // List Icons 2 | // ------------------------- 3 | 4 | .@{fa-css-prefix}-ul { 5 | padding-left: 0; 6 | margin-left: @fa-li-width; 7 | list-style-type: none; 8 | > li { position: relative; } 9 | } 10 | .@{fa-css-prefix}-li { 11 | position: absolute; 12 | left: -@fa-li-width; 13 | width: @fa-li-width; 14 | top: (2em / 14); 15 | text-align: center; 16 | &.@{fa-css-prefix}-lg { 17 | left: (-@fa-li-width + (4em / 14)); 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/less/mixins.less: -------------------------------------------------------------------------------- 1 | // Mixins 2 | // -------------------------- 3 | 4 | .fa-icon() { 5 | display: inline-block; 6 | font: normal normal normal @fa-font-size-base/@fa-line-height-base FontAwesome; // shortening font declaration 7 | font-size: inherit; // can't have font-size inherit on line above, so need to override 8 | text-rendering: auto; // optimizelegibility throws things off #1094 9 | -webkit-font-smoothing: antialiased; 10 | -moz-osx-font-smoothing: grayscale; 11 | 12 | } 13 | 14 | .fa-icon-rotate(@degrees, @rotation) { 15 | -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=@{rotation})"; 16 | -webkit-transform: rotate(@degrees); 17 | -ms-transform: rotate(@degrees); 18 | transform: rotate(@degrees); 19 | } 20 | 21 | .fa-icon-flip(@horiz, @vert, @rotation) { 22 | -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=@{rotation}, mirror=1)"; 23 | -webkit-transform: scale(@horiz, @vert); 24 | -ms-transform: scale(@horiz, @vert); 25 | transform: scale(@horiz, @vert); 26 | } 27 | 28 | 29 | // Only display content to screen readers. A la Bootstrap 4. 30 | // 31 | // See: http://a11yproject.com/posts/how-to-hide-content/ 32 | 33 | .sr-only() { 34 | position: absolute; 35 | width: 1px; 36 | height: 1px; 37 | padding: 0; 38 | margin: -1px; 39 | overflow: hidden; 40 | clip: rect(0,0,0,0); 41 | border: 0; 42 | } 43 | 44 | // Use in conjunction with .sr-only to only display content when it's focused. 45 | // 46 | // Useful for "Skip to main content" links; see http://www.w3.org/TR/2013/NOTE-WCAG20-TECHS-20130905/G1 47 | // 48 | // Credit: HTML5 Boilerplate 49 | 50 | .sr-only-focusable() { 51 | &:active, 52 | &:focus { 53 | position: static; 54 | width: auto; 55 | height: auto; 56 | margin: 0; 57 | overflow: visible; 58 | clip: auto; 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/less/path.less: -------------------------------------------------------------------------------- 1 | /* FONT PATH 2 | * -------------------------- */ 3 | 4 | @font-face { 5 | font-family: 'FontAwesome'; 6 | src: url('@{fa-font-path}/fontawesome-webfont.eot?v=@{fa-version}'); 7 | src: url('@{fa-font-path}/fontawesome-webfont.eot?#iefix&v=@{fa-version}') format('embedded-opentype'), 8 | url('@{fa-font-path}/fontawesome-webfont.woff2?v=@{fa-version}') format('woff2'), 9 | url('@{fa-font-path}/fontawesome-webfont.woff?v=@{fa-version}') format('woff'), 10 | url('@{fa-font-path}/fontawesome-webfont.ttf?v=@{fa-version}') format('truetype'), 11 | url('@{fa-font-path}/fontawesome-webfont.svg?v=@{fa-version}#fontawesomeregular') format('svg'); 12 | // src: url('@{fa-font-path}/FontAwesome.otf') format('opentype'); // used when developing fonts 13 | font-weight: normal; 14 | font-style: normal; 15 | } 16 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/less/rotated-flipped.less: -------------------------------------------------------------------------------- 1 | // Rotated & Flipped Icons 2 | // ------------------------- 3 | 4 | .@{fa-css-prefix}-rotate-90 { .fa-icon-rotate(90deg, 1); } 5 | .@{fa-css-prefix}-rotate-180 { .fa-icon-rotate(180deg, 2); } 6 | .@{fa-css-prefix}-rotate-270 { .fa-icon-rotate(270deg, 3); } 7 | 8 | .@{fa-css-prefix}-flip-horizontal { .fa-icon-flip(-1, 1, 0); } 9 | .@{fa-css-prefix}-flip-vertical { .fa-icon-flip(1, -1, 2); } 10 | 11 | // Hook for IE8-9 12 | // ------------------------- 13 | 14 | :root .@{fa-css-prefix}-rotate-90, 15 | :root .@{fa-css-prefix}-rotate-180, 16 | :root .@{fa-css-prefix}-rotate-270, 17 | :root .@{fa-css-prefix}-flip-horizontal, 18 | :root .@{fa-css-prefix}-flip-vertical { 19 | filter: none; 20 | } 21 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/less/screen-reader.less: -------------------------------------------------------------------------------- 1 | // Screen Readers 2 | // ------------------------- 3 | 4 | .sr-only { .sr-only(); } 5 | .sr-only-focusable { .sr-only-focusable(); } 6 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/less/stacked.less: -------------------------------------------------------------------------------- 1 | // Stacked Icons 2 | // ------------------------- 3 | 4 | .@{fa-css-prefix}-stack { 5 | position: relative; 6 | display: inline-block; 7 | width: 2em; 8 | height: 2em; 9 | line-height: 2em; 10 | vertical-align: middle; 11 | } 12 | .@{fa-css-prefix}-stack-1x, .@{fa-css-prefix}-stack-2x { 13 | position: absolute; 14 | left: 0; 15 | width: 100%; 16 | text-align: center; 17 | } 18 | .@{fa-css-prefix}-stack-1x { line-height: inherit; } 19 | .@{fa-css-prefix}-stack-2x { font-size: 2em; } 20 | .@{fa-css-prefix}-inverse { color: @fa-inverse; } 21 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/scss/_animated.scss: -------------------------------------------------------------------------------- 1 | // Spinning Icons 2 | // -------------------------- 3 | 4 | .#{$fa-css-prefix}-spin { 5 | -webkit-animation: fa-spin 2s infinite linear; 6 | animation: fa-spin 2s infinite linear; 7 | } 8 | 9 | .#{$fa-css-prefix}-pulse { 10 | -webkit-animation: fa-spin 1s infinite steps(8); 11 | animation: fa-spin 1s infinite steps(8); 12 | } 13 | 14 | @-webkit-keyframes fa-spin { 15 | 0% { 16 | -webkit-transform: rotate(0deg); 17 | transform: rotate(0deg); 18 | } 19 | 100% { 20 | -webkit-transform: rotate(359deg); 21 | transform: rotate(359deg); 22 | } 23 | } 24 | 25 | @keyframes fa-spin { 26 | 0% { 27 | -webkit-transform: rotate(0deg); 28 | transform: rotate(0deg); 29 | } 30 | 100% { 31 | -webkit-transform: rotate(359deg); 32 | transform: rotate(359deg); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/scss/_bordered-pulled.scss: -------------------------------------------------------------------------------- 1 | // Bordered & Pulled 2 | // ------------------------- 3 | 4 | .#{$fa-css-prefix}-border { 5 | padding: .2em .25em .15em; 6 | border: solid .08em $fa-border-color; 7 | border-radius: .1em; 8 | } 9 | 10 | .#{$fa-css-prefix}-pull-left { float: left; } 11 | .#{$fa-css-prefix}-pull-right { float: right; } 12 | 13 | .#{$fa-css-prefix} { 14 | &.#{$fa-css-prefix}-pull-left { margin-right: .3em; } 15 | &.#{$fa-css-prefix}-pull-right { margin-left: .3em; } 16 | } 17 | 18 | /* Deprecated as of 4.4.0 */ 19 | .pull-right { float: right; } 20 | .pull-left { float: left; } 21 | 22 | .#{$fa-css-prefix} { 23 | &.pull-left { margin-right: .3em; } 24 | &.pull-right { margin-left: .3em; } 25 | } 26 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/scss/_core.scss: -------------------------------------------------------------------------------- 1 | // Base Class Definition 2 | // ------------------------- 3 | 4 | .#{$fa-css-prefix} { 5 | display: inline-block; 6 | font: normal normal normal #{$fa-font-size-base}/#{$fa-line-height-base} FontAwesome; // shortening font declaration 7 | font-size: inherit; // can't have font-size inherit on line above, so need to override 8 | text-rendering: auto; // optimizelegibility throws things off #1094 9 | -webkit-font-smoothing: antialiased; 10 | -moz-osx-font-smoothing: grayscale; 11 | 12 | } 13 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/scss/_fixed-width.scss: -------------------------------------------------------------------------------- 1 | // Fixed Width Icons 2 | // ------------------------- 3 | .#{$fa-css-prefix}-fw { 4 | width: (18em / 14); 5 | text-align: center; 6 | } 7 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/scss/_larger.scss: -------------------------------------------------------------------------------- 1 | // Icon Sizes 2 | // ------------------------- 3 | 4 | /* makes the font 33% larger relative to the icon container */ 5 | .#{$fa-css-prefix}-lg { 6 | font-size: (4em / 3); 7 | line-height: (3em / 4); 8 | vertical-align: -15%; 9 | } 10 | .#{$fa-css-prefix}-2x { font-size: 2em; } 11 | .#{$fa-css-prefix}-3x { font-size: 3em; } 12 | .#{$fa-css-prefix}-4x { font-size: 4em; } 13 | .#{$fa-css-prefix}-5x { font-size: 5em; } 14 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/scss/_list.scss: -------------------------------------------------------------------------------- 1 | // List Icons 2 | // ------------------------- 3 | 4 | .#{$fa-css-prefix}-ul { 5 | padding-left: 0; 6 | margin-left: $fa-li-width; 7 | list-style-type: none; 8 | > li { position: relative; } 9 | } 10 | .#{$fa-css-prefix}-li { 11 | position: absolute; 12 | left: -$fa-li-width; 13 | width: $fa-li-width; 14 | top: (2em / 14); 15 | text-align: center; 16 | &.#{$fa-css-prefix}-lg { 17 | left: -$fa-li-width + (4em / 14); 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/scss/_mixins.scss: -------------------------------------------------------------------------------- 1 | // Mixins 2 | // -------------------------- 3 | 4 | @mixin fa-icon() { 5 | display: inline-block; 6 | font: normal normal normal #{$fa-font-size-base}/#{$fa-line-height-base} FontAwesome; // shortening font declaration 7 | font-size: inherit; // can't have font-size inherit on line above, so need to override 8 | text-rendering: auto; // optimizelegibility throws things off #1094 9 | -webkit-font-smoothing: antialiased; 10 | -moz-osx-font-smoothing: grayscale; 11 | 12 | } 13 | 14 | @mixin fa-icon-rotate($degrees, $rotation) { 15 | -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=#{$rotation})"; 16 | -webkit-transform: rotate($degrees); 17 | -ms-transform: rotate($degrees); 18 | transform: rotate($degrees); 19 | } 20 | 21 | @mixin fa-icon-flip($horiz, $vert, $rotation) { 22 | -ms-filter: "progid:DXImageTransform.Microsoft.BasicImage(rotation=#{$rotation}, mirror=1)"; 23 | -webkit-transform: scale($horiz, $vert); 24 | -ms-transform: scale($horiz, $vert); 25 | transform: scale($horiz, $vert); 26 | } 27 | 28 | 29 | // Only display content to screen readers. A la Bootstrap 4. 30 | // 31 | // See: http://a11yproject.com/posts/how-to-hide-content/ 32 | 33 | @mixin sr-only { 34 | position: absolute; 35 | width: 1px; 36 | height: 1px; 37 | padding: 0; 38 | margin: -1px; 39 | overflow: hidden; 40 | clip: rect(0,0,0,0); 41 | border: 0; 42 | } 43 | 44 | // Use in conjunction with .sr-only to only display content when it's focused. 45 | // 46 | // Useful for "Skip to main content" links; see http://www.w3.org/TR/2013/NOTE-WCAG20-TECHS-20130905/G1 47 | // 48 | // Credit: HTML5 Boilerplate 49 | 50 | @mixin sr-only-focusable { 51 | &:active, 52 | &:focus { 53 | position: static; 54 | width: auto; 55 | height: auto; 56 | margin: 0; 57 | overflow: visible; 58 | clip: auto; 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/scss/_path.scss: -------------------------------------------------------------------------------- 1 | /* FONT PATH 2 | * -------------------------- */ 3 | 4 | @font-face { 5 | font-family: 'FontAwesome'; 6 | src: url('#{$fa-font-path}/fontawesome-webfont.eot?v=#{$fa-version}'); 7 | src: url('#{$fa-font-path}/fontawesome-webfont.eot?#iefix&v=#{$fa-version}') format('embedded-opentype'), 8 | url('#{$fa-font-path}/fontawesome-webfont.woff2?v=#{$fa-version}') format('woff2'), 9 | url('#{$fa-font-path}/fontawesome-webfont.woff?v=#{$fa-version}') format('woff'), 10 | url('#{$fa-font-path}/fontawesome-webfont.ttf?v=#{$fa-version}') format('truetype'), 11 | url('#{$fa-font-path}/fontawesome-webfont.svg?v=#{$fa-version}#fontawesomeregular') format('svg'); 12 | // src: url('#{$fa-font-path}/FontAwesome.otf') format('opentype'); // used when developing fonts 13 | font-weight: normal; 14 | font-style: normal; 15 | } 16 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/scss/_rotated-flipped.scss: -------------------------------------------------------------------------------- 1 | // Rotated & Flipped Icons 2 | // ------------------------- 3 | 4 | .#{$fa-css-prefix}-rotate-90 { @include fa-icon-rotate(90deg, 1); } 5 | .#{$fa-css-prefix}-rotate-180 { @include fa-icon-rotate(180deg, 2); } 6 | .#{$fa-css-prefix}-rotate-270 { @include fa-icon-rotate(270deg, 3); } 7 | 8 | .#{$fa-css-prefix}-flip-horizontal { @include fa-icon-flip(-1, 1, 0); } 9 | .#{$fa-css-prefix}-flip-vertical { @include fa-icon-flip(1, -1, 2); } 10 | 11 | // Hook for IE8-9 12 | // ------------------------- 13 | 14 | :root .#{$fa-css-prefix}-rotate-90, 15 | :root .#{$fa-css-prefix}-rotate-180, 16 | :root .#{$fa-css-prefix}-rotate-270, 17 | :root .#{$fa-css-prefix}-flip-horizontal, 18 | :root .#{$fa-css-prefix}-flip-vertical { 19 | filter: none; 20 | } 21 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/scss/_screen-reader.scss: -------------------------------------------------------------------------------- 1 | // Screen Readers 2 | // ------------------------- 3 | 4 | .sr-only { @include sr-only(); } 5 | .sr-only-focusable { @include sr-only-focusable(); } 6 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/scss/_stacked.scss: -------------------------------------------------------------------------------- 1 | // Stacked Icons 2 | // ------------------------- 3 | 4 | .#{$fa-css-prefix}-stack { 5 | position: relative; 6 | display: inline-block; 7 | width: 2em; 8 | height: 2em; 9 | line-height: 2em; 10 | vertical-align: middle; 11 | } 12 | .#{$fa-css-prefix}-stack-1x, .#{$fa-css-prefix}-stack-2x { 13 | position: absolute; 14 | left: 0; 15 | width: 100%; 16 | text-align: center; 17 | } 18 | .#{$fa-css-prefix}-stack-1x { line-height: inherit; } 19 | .#{$fa-css-prefix}-stack-2x { font-size: 2em; } 20 | .#{$fa-css-prefix}-inverse { color: $fa-inverse; } 21 | -------------------------------------------------------------------------------- /src/elm_demo/framework/font-awesome-4.7.0/font-awesome-4.7.0/scss/font-awesome.scss: -------------------------------------------------------------------------------- 1 | /*! 2 | * Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome 3 | * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) 4 | */ 5 | 6 | @import "variables"; 7 | @import "mixins"; 8 | @import "path"; 9 | @import "core"; 10 | @import "larger"; 11 | @import "fixed-width"; 12 | @import "list"; 13 | @import "bordered-pulled"; 14 | @import "animated"; 15 | @import "rotated-flipped"; 16 | @import "stacked"; 17 | @import "icons"; 18 | @import "screen-reader"; 19 | -------------------------------------------------------------------------------- /src/elm_demo/framework/icon.css: -------------------------------------------------------------------------------- 1 | .icon-location{ 2 | position:relative; 3 | width: 100%; 4 | height: 100%; 5 | border-radius: 50% 50% 50% 0; 6 | background: #fff; 7 | transform: rotate(-45deg); 8 | } 9 | 10 | .icon-location:after{ 11 | content: ''; 12 | width: 40%; 13 | height: 40%; 14 | margin: 30% 0 0 29%; 15 | background-color: #0097FF; 16 | position: absolute; 17 | border-radius: 50%; 18 | } -------------------------------------------------------------------------------- /src/elm_demo/framework/reset.css: -------------------------------------------------------------------------------- 1 | /**************css重置**********/ 2 | html,body,div,span,h1,h2,h3,h4,h5,h6,ul,ol,li,p{ 3 | margin: 0; 4 | paddig: 0; 5 | } 6 | html,body{ 7 | width: 100%; 8 | height: 100%; 9 | font-family: "微软雅黑"; 10 | } 11 | ul,ol{ 12 | list-style: none; 13 | margin: 0; 14 | padding: 0; 15 | } 16 | a{ 17 | text-decoration: none; 18 | } -------------------------------------------------------------------------------- /src/elm_demo/img/alipay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/alipay.png -------------------------------------------------------------------------------- /src/elm_demo/img/dcfl01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/dcfl01.png -------------------------------------------------------------------------------- /src/elm_demo/img/dcfl02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/dcfl02.png -------------------------------------------------------------------------------- /src/elm_demo/img/dcfl03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/dcfl03.png -------------------------------------------------------------------------------- /src/elm_demo/img/dcfl04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/dcfl04.png -------------------------------------------------------------------------------- /src/elm_demo/img/dcfl05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/dcfl05.png -------------------------------------------------------------------------------- /src/elm_demo/img/dcfl06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/dcfl06.png -------------------------------------------------------------------------------- /src/elm_demo/img/dcfl07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/dcfl07.png -------------------------------------------------------------------------------- /src/elm_demo/img/dcfl08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/dcfl08.png -------------------------------------------------------------------------------- /src/elm_demo/img/dcfl09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/dcfl09.png -------------------------------------------------------------------------------- /src/elm_demo/img/dcfl10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/dcfl10.png -------------------------------------------------------------------------------- /src/elm_demo/img/index_banner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/index_banner.png -------------------------------------------------------------------------------- /src/elm_demo/img/sj01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sj01.png -------------------------------------------------------------------------------- /src/elm_demo/img/sj02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sj02.png -------------------------------------------------------------------------------- /src/elm_demo/img/sj03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sj03.png -------------------------------------------------------------------------------- /src/elm_demo/img/sj04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sj04.png -------------------------------------------------------------------------------- /src/elm_demo/img/sj05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sj05.png -------------------------------------------------------------------------------- /src/elm_demo/img/sj06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sj06.png -------------------------------------------------------------------------------- /src/elm_demo/img/sj07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sj07.png -------------------------------------------------------------------------------- /src/elm_demo/img/sj08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sj08.png -------------------------------------------------------------------------------- /src/elm_demo/img/sj09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sj09.png -------------------------------------------------------------------------------- /src/elm_demo/img/sp01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sp01.png -------------------------------------------------------------------------------- /src/elm_demo/img/sp02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sp02.png -------------------------------------------------------------------------------- /src/elm_demo/img/sp03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sp03.png -------------------------------------------------------------------------------- /src/elm_demo/img/sp04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sp04.png -------------------------------------------------------------------------------- /src/elm_demo/img/sp05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sp05.png -------------------------------------------------------------------------------- /src/elm_demo/img/sp06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sp06.png -------------------------------------------------------------------------------- /src/elm_demo/img/sp07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sp07.png -------------------------------------------------------------------------------- /src/elm_demo/img/sp08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sp08.png -------------------------------------------------------------------------------- /src/elm_demo/img/sp09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sp09.png -------------------------------------------------------------------------------- /src/elm_demo/img/sp10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sp10.png -------------------------------------------------------------------------------- /src/elm_demo/img/sp11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sp11.png -------------------------------------------------------------------------------- /src/elm_demo/img/sp12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/sp12.png -------------------------------------------------------------------------------- /src/elm_demo/img/super_member.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/super_member.png -------------------------------------------------------------------------------- /src/elm_demo/img/userImg/userImg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/userImg/userImg.png -------------------------------------------------------------------------------- /src/elm_demo/img/userImg/yhtx01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/userImg/yhtx01.png -------------------------------------------------------------------------------- /src/elm_demo/img/userImg/yhtx02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/userImg/yhtx02.png -------------------------------------------------------------------------------- /src/elm_demo/img/userImg/yhtx03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/userImg/yhtx03.png -------------------------------------------------------------------------------- /src/elm_demo/img/userImg/yhtx04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/userImg/yhtx04.png -------------------------------------------------------------------------------- /src/elm_demo/img/userImg/yhtx05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/userImg/yhtx05.png -------------------------------------------------------------------------------- /src/elm_demo/img/userImg/yhtx06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/userImg/yhtx06.png -------------------------------------------------------------------------------- /src/elm_demo/img/userImg/yhtx07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/userImg/yhtx07.png -------------------------------------------------------------------------------- /src/elm_demo/img/userImg/yhtx08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/userImg/yhtx08.png -------------------------------------------------------------------------------- /src/elm_demo/img/userImg/yhtx09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/userImg/yhtx09.png -------------------------------------------------------------------------------- /src/elm_demo/img/wechat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elm_demo/img/wechat.png -------------------------------------------------------------------------------- /src/elm_demo/login.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 饿了么 用户登陆 10 | 11 | 12 |
13 | 14 | 15 |
16 |

用户登陆

17 |
18 | 19 | 20 |
    21 |
  • 22 |
    23 | 手机号码: 24 |
    25 |
    26 | 27 |
    28 |
  • 29 |
  • 30 |
    31 | 密码: 32 |
    33 |
    34 | 35 |
    36 |
  • 37 |
38 | 39 | 42 |
43 | 44 |
45 | 46 | 47 | 65 |
66 | 67 | -------------------------------------------------------------------------------- /src/elm_demo/order.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 饿了么 确认订单 10 | 11 | 12 |
13 | 14 |
15 |

确认订单

16 |
17 | 18 |
19 |
订单配送至:
20 |
21 |

沈阳市浑南区智慧四街1-121号

22 | 23 |
24 |

习近平先生 13656785432

25 |
26 |

万家饺子(软件园E18店)

27 | 28 |
    29 |
  • 30 |
    31 | 32 |

    纯肉鲜肉(水饺) x 2

    33 |
    34 |

    ¥15

    35 |
  • 36 |
  • 37 |
    38 | 39 |

    玉米鲜肉(水饺) x 1

    40 |
    41 |

    ¥16

    42 |
  • 43 |
44 |
45 |

配送费

46 |

¥3

47 |
48 | 49 |
50 |
51 | ¥49 52 |
53 |
54 | 去支付 55 |
56 |
57 |
58 | 59 | -------------------------------------------------------------------------------- /src/elm_demo/payment.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 饿了么 在线支付 11 | 12 | 13 |
14 | 15 |
16 |

在线支付

17 |
18 | 19 |

订单信息:

20 |
21 |

22 | 万家饺子(软件园E18店) 23 | 24 |

25 |

¥49

26 |
27 | 28 | 29 |
    30 |
  • 31 |

    纯肉鲜肉(水饺) x 2

    32 |

    ¥15

    33 |
  • 34 |
  • 35 |

    玉米鲜肉(水饺) x 1

    36 |

    ¥16

    37 |
  • 38 |
  • 39 |

    配送费

    40 |

    ¥3

    41 |
  • 42 |
43 | 44 | 45 |
    46 |
  • 47 | 48 | 49 |
  • 50 |
  • 51 | 52 |
  • 53 |
54 |
55 | 56 |
57 | 58 | 59 | 77 |
78 | 79 | -------------------------------------------------------------------------------- /src/elm_demo/register.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 饿了么 用户注册 10 | 11 | 12 |
13 | 14 |
15 |

用户注册

16 |
17 | 18 | 19 |
    20 |
  • 21 |
    22 | 手机号码: 23 |
    24 |
    25 | 26 |
    27 |
  • 28 |
  • 29 |
    30 | 密码: 31 |
    32 |
    33 | 34 |
    35 |
  • 36 |
  • 37 |
    38 | 确认密码: 39 |
    40 |
    41 | 42 |
    43 |
  • 44 |
  • 45 |
    46 | 性别: 47 |
    48 |
    49 | 50 | 男 51 | 女 52 |
    53 |
  • 54 |
55 | 56 | 59 | 60 | 61 | 79 |
80 | 81 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/ElmbootApplication.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.boot.autoconfigure.SpringBootApplication; 5 | 6 | @SpringBootApplication 7 | public class ElmbootApplication { 8 | 9 | public static void main(String[] args) { 10 | SpringApplication.run(ElmbootApplication.class, args); 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/config/WebConfig.java: -------------------------------------------------------------------------------- 1 | //package com.neusoft.elmboot.config; 2 | // 3 | //import com.neusoft.elmboot.interceptor.JwtAuthInterceptor; 4 | //import org.springframework.beans.factory.annotation.Autowired; 5 | //import org.springframework.context.annotation.Configuration; 6 | //import org.springframework.web.servlet.config.annotation.InterceptorRegistry; 7 | //import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; 8 | // 9 | //@Configuration 10 | //public class WebConfig implements WebMvcConfigurer { 11 | // 12 | // @Autowired 13 | // private JwtAuthInterceptor jwtAuthInterceptor; 14 | // 15 | // @Override 16 | // public void addInterceptors(InterceptorRegistry registry) { 17 | // registry.addInterceptor(jwtAuthInterceptor) 18 | // .addPathPatterns("/**") 19 | // .excludePathPatterns("/user/login", "/user/register"); 20 | // } 21 | //} -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/config/WebMvcConfig.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.config; 2 | 3 | import org.springframework.context.annotation.Bean; 4 | import org.springframework.context.annotation.Configuration; 5 | import org.springframework.web.servlet.config.annotation.CorsRegistry; 6 | import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; 7 | 8 | @Configuration 9 | public class WebMvcConfig { 10 | @Bean 11 | public WebMvcConfigurer corsConfigurer() { 12 | return new WebMvcConfigurer() { 13 | @Override 14 | public void addCorsMappings(CorsRegistry registry) { 15 | registry.addMapping("/**") 16 | .allowedOrigins("*") 17 | .allowedMethods("GET", "POST", "DELETE", "PUT", "PATCH", "OPTIONS") 18 | .allowedHeaders("Origin", "Content-Type", "Accept", "Authorization", 19 | "X-Requested-With", "Access-Control-Request-Method", 20 | "Access-Control-Request-Headers") 21 | .exposedHeaders("Access-Control-Allow-Origin", "Access-Control-Allow-Credentials") 22 | .maxAge(3600); 23 | } 24 | }; 25 | } 26 | } 27 | 28 | 29 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/config/WenXinProperties.java: -------------------------------------------------------------------------------- 1 | //package com.neusoft.elmboot.config; 2 | //import org.springframework.boot.context.properties.ConfigurationProperties; 3 | //import org.springframework.stereotype.Component; 4 | // 5 | //import lombok.Data; 6 | // 7 | //@Component 8 | //@ConfigurationProperties(prefix = "elm.wenxincontroller") 9 | //@Data 10 | //public class WenXinProperties { 11 | // private String apiKey; 12 | // private String secretKey; 13 | // private String tokenUrl; 14 | // private String chatUrl; 15 | // 16 | // public String getApiKey() { 17 | // return "LzHLae3ch9isirMsCDnfO4gV"; 18 | // } 19 | // public void setApiKey(String apiKey) { 20 | // this.apiKey = apiKey; 21 | // } 22 | // public String getSecretKey() { 23 | // return "qEaqABpUPU4bQX2tuXK6efOeATaxA0jP"; 24 | // } 25 | // public void setSecretKey(String secretKey) { 26 | // this.secretKey = secretKey; 27 | // } 28 | // public String getChatUrl() { 29 | // return "https://aip.baidubce.com/rpc/2.0/ai_custom/v1/wenxinworkshop/chat/ernie-tiny-8k"; 30 | // } 31 | // public void setTokenUrl(String tokenUrl) { 32 | // this.tokenUrl = tokenUrl; 33 | // } 34 | // public String getTokenUrl() { 35 | // return "https://aip.baidubce.com/oauth/2.0/token"; 36 | // } 37 | // public void setChatUrl(String chatUrl) { 38 | // this.chatUrl = chatUrl; 39 | // } 40 | // 41 | //} 42 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/constants/TransactionStatus.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.constants; 2 | 3 | public class TransactionStatus { 4 | public static final String DEBIT = "提现" ; 5 | public static final String CREDIT = "充值" ; 6 | public static final String TRANSFER = "支付" ; 7 | 8 | 9 | 10 | } 11 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/controller/CartController.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.controller; 2 | import java.util.List; 3 | import org.springframework.beans.factory.annotation.Autowired; 4 | import org.springframework.web.bind.annotation.RequestBody; 5 | import org.springframework.web.bind.annotation.RequestMapping; 6 | import org.springframework.web.bind.annotation.RestController; 7 | import com.neusoft.elmboot.po.Cart; 8 | import com.neusoft.elmboot.service.CartService; 9 | @RestController 10 | @RequestMapping("/CartController") 11 | public class CartController { 12 | @Autowired 13 | private CartService cartService; 14 | 15 | @RequestMapping("/listCart") 16 | public List listCart(@RequestBody Cart cart) throws Exception{ 17 | return cartService.listCart(cart); 18 | } 19 | 20 | @RequestMapping("/saveCart") 21 | public int saveCart(@RequestBody Cart cart) throws Exception{ 22 | return cartService.saveCart(cart); 23 | } 24 | 25 | @RequestMapping("/updateCart") 26 | public int updateCart(@RequestBody Cart cart) throws Exception{ 27 | return cartService.updateCart(cart); 28 | } 29 | 30 | @RequestMapping("/removeCart") 31 | public int removeCart(@RequestBody Cart cart) throws Exception{ 32 | return cartService.removeCart(cart); 33 | } 34 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/controller/ChatsController.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.controller; 2 | 3 | import java.util.List; 4 | 5 | import org.springframework.beans.factory.annotation.Autowired; 6 | import org.springframework.web.bind.annotation.RequestBody; 7 | import org.springframework.web.bind.annotation.RequestMapping; 8 | import org.springframework.web.bind.annotation.RestController; 9 | 10 | import com.neusoft.elmboot.po.Chats; 11 | import com.neusoft.elmboot.service.ChatsService; 12 | 13 | @RestController 14 | @RequestMapping("/ChatsController") 15 | public class ChatsController { 16 | @Autowired 17 | private ChatsService chatsService; 18 | 19 | @RequestMapping("/getChatsByUserId") 20 | public List getChatsByUserId(@RequestBody Chats chats){ 21 | return chatsService.getChatsByUserId(chats.getCurrentUserId()); 22 | } 23 | 24 | @RequestMapping("/saveChats") 25 | public int saveChats(@RequestBody Chats chats) { 26 | return chatsService.saveChats(chats); 27 | } 28 | 29 | @RequestMapping("/removeChatsAllByCurrentUserId") 30 | public int removeChatsAllByCurrentUserId(@RequestBody Chats chats) { 31 | return chatsService.removeChatsAllByCurrentUserId(chats); 32 | } 33 | 34 | @RequestMapping("/removeChatsByTwoUserIdByMessage") 35 | public int removeChatsByTwoUserIdByMessage(@RequestBody Chats chats) { 36 | return chatsService.removeChatsByTwoUserIdByMessage(chats); 37 | } 38 | 39 | @RequestMapping("/recallChatsByTwoUserIdByMessage") 40 | public int recallChatsByTwoUserIdByMessage(@RequestBody Chats chats) { 41 | return chatsService.recallChatsByTwoUserIdByMessage(chats); 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/controller/DeliveryAddressController.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.controller; 2 | import java.util.List; 3 | 4 | import org.springframework.beans.factory.annotation.Autowired; 5 | import org.springframework.web.bind.annotation.RequestBody; 6 | import org.springframework.web.bind.annotation.RequestMapping; 7 | import org.springframework.web.bind.annotation.RestController; 8 | import com.neusoft.elmboot.po.DeliveryAddress; 9 | import com.neusoft.elmboot.service.DeliveryAddressService; 10 | 11 | @RestController 12 | @RequestMapping("/DeliveryAddressController") 13 | public class DeliveryAddressController { 14 | 15 | @Autowired 16 | private DeliveryAddressService deliveryAddressService; 17 | 18 | @RequestMapping("/listDeliveryAddressByUserId") 19 | public List listDeliveryAddressByUserId(@RequestBody DeliveryAddress deliveryAddress) 20 | throws Exception{ 21 | return deliveryAddressService.listDeliveryAddressByUserId(deliveryAddress.getUserId()); 22 | } 23 | 24 | @RequestMapping("/getDeliveryAddressById") 25 | public DeliveryAddress getDeliveryAddressById(@RequestBody DeliveryAddress deliveryAddress) throws 26 | Exception{ 27 | return deliveryAddressService.getDeliveryAddressById(deliveryAddress.getDaId()); 28 | } 29 | 30 | @RequestMapping("/saveDeliveryAddress") 31 | public int saveDeliveryAddress(@RequestBody DeliveryAddress deliveryAddress) throws Exception{ 32 | return deliveryAddressService.saveDeliveryAddress(deliveryAddress); 33 | } 34 | 35 | @RequestMapping("/updateDeliveryAddress") 36 | public int updateDeliveryAddress(@RequestBody DeliveryAddress deliveryAddress) throws Exception{ 37 | return deliveryAddressService.updateDeliveryAddress(deliveryAddress); 38 | } 39 | 40 | @RequestMapping("/removeDeliveryAddress") 41 | public int removeDeliveryAddress(@RequestBody DeliveryAddress deliveryAddress) throws Exception{ 42 | return deliveryAddressService.removeDeliveryAddress(deliveryAddress.getDaId()); 43 | } 44 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/controller/DiscoverSearchHistoryController.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.controller; 2 | 3 | import java.util.HashMap; 4 | import java.util.List; 5 | import java.util.Map; 6 | 7 | import org.springframework.beans.factory.annotation.Autowired; 8 | import org.springframework.web.bind.annotation.RequestBody; 9 | import org.springframework.web.bind.annotation.RequestMapping; 10 | import org.springframework.web.bind.annotation.RestController; 11 | 12 | import com.neusoft.elmboot.po.DiscoverSearchHistory; 13 | import com.neusoft.elmboot.service.DiscoverSearchHistoryService; 14 | 15 | @RestController 16 | @RequestMapping("/DiscoverSearchController") 17 | public class DiscoverSearchHistoryController { 18 | 19 | @Autowired 20 | private DiscoverSearchHistoryService discoverSearchHistoryService; 21 | 22 | @RequestMapping("/saveSearchHistory") 23 | public Map saveSearchHistory(@RequestBody DiscoverSearchHistory history) { 24 | Map result = new HashMap<>(); 25 | int success = discoverSearchHistoryService.saveSearchHistory(history); 26 | result.put("success", success > 0); 27 | result.put("id", history.getId()); 28 | return result; 29 | } 30 | 31 | @RequestMapping("/getSearchHistoryByUserId") 32 | public List getSearchHistoryByUserId(@RequestBody Map params) { 33 | String userId = params.get("userId"); 34 | return discoverSearchHistoryService.getSearchHistoryByUserId(userId); 35 | } 36 | 37 | @RequestMapping("/updateCurrentPage") 38 | public Map updateCurrentPage(@RequestBody DiscoverSearchHistory history) { 39 | Map result = new HashMap<>(); 40 | int success = discoverSearchHistoryService.updateCurrentPage(history); 41 | result.put("success", success > 0); 42 | return result; 43 | } 44 | 45 | @RequestMapping("/deleteSearchHistoryByUserId") 46 | public Map deleteSearchHistoryByUserId(@RequestBody Map params) { 47 | Map result = new HashMap<>(); 48 | String userId = params.get("userId"); 49 | int success = discoverSearchHistoryService.deleteSearchHistoryByUserId(userId); 50 | result.put("success", success > 0); 51 | return result; 52 | } 53 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/controller/FavoriteController.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.controller; 2 | 3 | import java.util.List; 4 | 5 | import org.springframework.beans.factory.annotation.Autowired; 6 | import org.springframework.web.bind.annotation.RequestBody; 7 | import org.springframework.web.bind.annotation.RequestMapping; 8 | import org.springframework.web.bind.annotation.RestController; 9 | 10 | import com.neusoft.elmboot.po.Favorite; 11 | import com.neusoft.elmboot.service.FavoriteService; 12 | 13 | 14 | @RestController 15 | @RequestMapping("/FavoriteController") 16 | public class FavoriteController { 17 | 18 | @Autowired 19 | private FavoriteService favoriteService; 20 | 21 | @RequestMapping("/saveFavoriteBusinessId") 22 | public int saveFavoriteBusinessId(@RequestBody Favorite favorite) { 23 | return favoriteService.saveFavoriteBusinessId(favorite); 24 | } 25 | 26 | @RequestMapping("/listFavoriteByUserId") 27 | public List listFavoriteByUserId(@RequestBody Favorite favorite) { 28 | return favoriteService.listFavoriteByUserId(favorite); 29 | } 30 | 31 | @RequestMapping("/removeFavoriteBusinessId") 32 | public int removeFavoriteBusinessId(@RequestBody Favorite favorite) { 33 | return favoriteService.removeFavoriteBusinessId(favorite); 34 | } 35 | 36 | @RequestMapping("/getFavoriteCountByBusinessId") 37 | public int getFavoriteCountByBusinessId(@RequestBody Favorite favorite) { 38 | return favoriteService.getFavoriteCountByBusinessId(favorite); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/controller/FoodController.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.controller; 2 | import java.util.List; 3 | import org.springframework.beans.factory.annotation.Autowired; 4 | import org.springframework.web.bind.annotation.RequestBody; 5 | import org.springframework.web.bind.annotation.RequestMapping; 6 | import org.springframework.web.bind.annotation.RestController; 7 | import com.neusoft.elmboot.po.Food; 8 | import com.neusoft.elmboot.service.FoodService; 9 | @RestController 10 | @RequestMapping("/FoodController") 11 | public class FoodController { 12 | 13 | @Autowired 14 | private FoodService foodService; 15 | 16 | 17 | @RequestMapping("/listFoodByBusinessId") 18 | public List listFoodByBusinessId(@RequestBody Food food) throws Exception{ 19 | return foodService.listFoodByBusinessId(food.getBusinessId()); 20 | } 21 | 22 | @RequestMapping("/addFood") 23 | public int addFood(@RequestBody Food food) throws Exception{ 24 | return foodService.addFood(food); 25 | } 26 | 27 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/controller/LikesController.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.controller; 2 | 3 | import java.util.List; 4 | import java.util.Map; 5 | 6 | import org.springframework.beans.factory.annotation.Autowired; 7 | import org.springframework.web.bind.annotation.RequestBody; 8 | import org.springframework.web.bind.annotation.RequestMapping; 9 | import org.springframework.web.bind.annotation.RestController; 10 | 11 | import com.neusoft.elmboot.po.Likes; 12 | import com.neusoft.elmboot.service.LikesService; 13 | 14 | @RestController 15 | @RequestMapping("/LikesController") 16 | public class LikesController { 17 | 18 | @Autowired 19 | private LikesService likesService; 20 | 21 | @RequestMapping("/getLikesBybusinessId") 22 | public int getLikesBybusinessId(@RequestBody Likes likes) { 23 | return likesService.getLikesBybusinessId(likes); 24 | } 25 | 26 | @RequestMapping("/saveLikes") 27 | public int saveLikes(@RequestBody Likes likes) { 28 | return likesService.saveLikes(likes); 29 | } 30 | 31 | @RequestMapping("/removeLikes") 32 | public int removeLikes(@RequestBody Likes likes) { 33 | return likesService.removeLikes(likes); 34 | } 35 | 36 | @RequestMapping("/getLikesByUserIdByBusinessId") 37 | public int getLikesByUserIdByBusinessId(@RequestBody Likes likes) { 38 | return likesService.getLikesByUserIdByBusinessId(likes); 39 | } 40 | 41 | @RequestMapping("/getLikesByUserId") 42 | public List> getLikesByUserId(@RequestBody Map param) { 43 | return likesService.getLikesByUserId(param.get("userId")); 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/controller/OrdersController.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.controller; 2 | import java.util.List; 3 | 4 | import org.apache.ibatis.annotations.Param; 5 | import org.springframework.beans.factory.annotation.Autowired; 6 | import org.springframework.web.bind.annotation.PathVariable; 7 | import org.springframework.web.bind.annotation.RequestBody; 8 | import org.springframework.web.bind.annotation.RequestMapping; 9 | import org.springframework.web.bind.annotation.RequestMethod; 10 | import org.springframework.web.bind.annotation.RestController; 11 | 12 | import com.neusoft.elmboot.po.OrderDetailet; 13 | import com.neusoft.elmboot.po.Orders; 14 | import com.neusoft.elmboot.service.OrdersService; 15 | import com.neusoft.elmboot.util.CommonUtil; 16 | @RestController 17 | @RequestMapping("/OrdersController") 18 | public class OrdersController { 19 | @Autowired 20 | private OrdersService ordersService; 21 | 22 | @RequestMapping(value = "/createOrders", method = RequestMethod.POST) 23 | public int createOrders(@RequestBody Orders orders) throws Exception{ 24 | return ordersService.createOrders(orders); 25 | } 26 | 27 | @RequestMapping("/getOrdersById") 28 | public Orders getOrdersById(@RequestBody Orders orders) throws Exception{ 29 | return ordersService.getOrdersById(orders.getOrderId()); 30 | } 31 | 32 | @RequestMapping("/listOrdersByUserId") 33 | public List listOrdersByUserId(@RequestBody Orders orders) throws Exception{ 34 | return ordersService.listOrdersByUserId(orders.getUserId()); 35 | } 36 | 37 | @RequestMapping("/payOk") 38 | public int payOk(@RequestBody Orders orders) throws Exception{ 39 | return ordersService.payOk(orders); 40 | } 41 | 42 | @RequestMapping("/listOrderDetailetByOrderId") 43 | public List listOrderDetailetByOrderId(@RequestBody Orders orders){ 44 | return ordersService.listOrderDetailetByOrderId(orders); 45 | } 46 | 47 | @RequestMapping("/listOdIdByOrderId") 48 | public List listOdIdByOrderId(@RequestBody Orders orders){ 49 | return ordersService.listOdIdByOrderId(orders); 50 | } 51 | 52 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/controller/RemarkController.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.controller; 2 | 3 | import java.util.List; 4 | import java.util.Map; 5 | 6 | import org.springframework.beans.factory.annotation.Autowired; 7 | import org.springframework.web.bind.annotation.RequestBody; 8 | import org.springframework.web.bind.annotation.RequestMapping; 9 | import org.springframework.web.bind.annotation.RestController; 10 | 11 | import com.neusoft.elmboot.po.Business; 12 | import com.neusoft.elmboot.po.Remark; 13 | import com.neusoft.elmboot.service.BusinessService; 14 | import com.neusoft.elmboot.service.RemarkService; 15 | 16 | @RestController 17 | @RequestMapping("/RemarkController") 18 | public class RemarkController { 19 | @Autowired 20 | private RemarkService remarkService; 21 | 22 | //需要businessId 23 | @RequestMapping("/listRemarksByBussinessId") 24 | public List listRemarksByBussinessId(@RequestBody Remark remark){ 25 | return remarkService.listRemarksByBusinessId(remark.getBusinessId()); 26 | } 27 | 28 | //需要userId,businessId,userName,remark 29 | @RequestMapping("/saveRemarks") 30 | public int saveRemarks(@RequestBody Remark remark) { 31 | return remarkService.saveRemarks(remark); 32 | } 33 | 34 | @RequestMapping("/removeOneRemark") 35 | public int removeOneRemark(@RequestBody Remark remark){ 36 | return remarkService.removeOneRemark(remark); 37 | } 38 | 39 | @RequestMapping("/removeAllRemarksByUserId") 40 | public List removeAllRemarksByUserId(String userId){ 41 | return remarkService.removeAllRemarksByUserId(userId); 42 | } 43 | 44 | @RequestMapping("/getRemarkCountByBusinessId") 45 | public int getRemarkCountByBusinessId(@RequestBody Remark remark) { 46 | if (remark == null || remark.getBusinessId() == null) { 47 | return 0; 48 | } 49 | return remarkService.getRemarkCountByBusinessId(remark.getBusinessId()); 50 | } 51 | 52 | @RequestMapping("/getCommentsByUserId") 53 | public List> getCommentsByUserId(@RequestBody Map param){ 54 | return remarkService.getCommentsByUserId(param.get("userId")); 55 | } 56 | } 57 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/controller/SearchController.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.controller; 2 | 3 | 4 | import java.util.ArrayList; 5 | import java.util.Collections; 6 | import java.util.HashSet; 7 | import java.util.List; 8 | import java.util.Set; 9 | 10 | import org.springframework.beans.factory.annotation.Autowired; 11 | import org.springframework.web.bind.annotation.RequestBody; 12 | import org.springframework.web.bind.annotation.RequestMapping; 13 | import org.springframework.web.bind.annotation.RestController; 14 | 15 | import com.neusoft.elmboot.po.Business; 16 | import com.neusoft.elmboot.po.History; 17 | import com.neusoft.elmboot.service.BusinessService; 18 | import com.neusoft.elmboot.service.HistoryService; 19 | 20 | 21 | @RestController 22 | @RequestMapping("/SearchController") 23 | public class SearchController { 24 | 25 | @Autowired 26 | private BusinessService businessService; 27 | @Autowired 28 | private HistoryService historyService; 29 | 30 | @RequestMapping("/listBusiness") 31 | public List listBusiness(@RequestBody History history) throws Exception { 32 | String userId = history.getUserId(); 33 | String searchContent = history.getSearchContent(); 34 | StringBuffer str=new StringBuffer(); 35 | List businessList = new ArrayList<>(); 36 | for(char ch:searchContent.toCharArray()) { 37 | str.append(ch); 38 | String nowContent = str.toString(); 39 | businessList.addAll(businessService.listBusinessByBusinessName(nowContent)); 40 | } 41 | 42 | //去重: 43 | Set set = new HashSet<>(); 44 | for (Business i : businessList) { 45 | set.add(i); 46 | } 47 | businessList.clear(); 48 | businessList.addAll(set); 49 | 50 | Collections.reverse(businessList); 51 | 52 | 53 | //将本次的搜索语句存到historysearch数据库表中,注:本次的搜索语句是searchContent 54 | historyService.saveHistory(history); 55 | 56 | return businessList; 57 | } 58 | 59 | @RequestMapping("/getHistoryByUserId") 60 | public String getHistoryByUserId(@RequestBody History history) throws Exception { 61 | return historyService.getHistoryByUserId(history); 62 | 63 | } 64 | } 65 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/controller/SmartSearchController.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.controller; 2 | 3 | import java.util.List; 4 | import java.util.Map; 5 | import java.util.HashMap; 6 | 7 | import org.springframework.beans.factory.annotation.Autowired; 8 | import org.springframework.web.bind.annotation.RequestBody; 9 | import org.springframework.web.bind.annotation.RequestMapping; 10 | import org.springframework.web.bind.annotation.RestController; 11 | 12 | import com.neusoft.elmboot.service.SmartSearchService; 13 | import com.neusoft.elmboot.po.SearchResult; 14 | 15 | @RestController 16 | @RequestMapping("/smartSearch") 17 | public class SmartSearchController { 18 | 19 | @Autowired 20 | private SmartSearchService smartSearchService; 21 | 22 | @RequestMapping("/smartSearch") 23 | public Map smartSearch(@RequestBody Map params) { 24 | String query = (String) params.get("query"); 25 | String category = (String) params.get("category"); 26 | 27 | Map result = new HashMap<>(); 28 | List searchResults = smartSearchService.search(query, category); 29 | result.put("results", searchResults); 30 | 31 | return result; 32 | } 33 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/controller/wenxincontroller.java: -------------------------------------------------------------------------------- 1 | //package com.neusoft.elmboot.controller; 2 | // 3 | //import org.springframework.beans.factory.annotation.Autowired; 4 | //import org.springframework.http.ResponseEntity; 5 | //import org.springframework.web.bind.annotation.PostMapping; 6 | //import org.springframework.web.bind.annotation.RequestBody; 7 | //import org.springframework.web.bind.annotation.RequestMapping; 8 | //import org.springframework.web.bind.annotation.RestController; 9 | // 10 | //import com.neusoft.elmboot.service.WenXinService; 11 | // 12 | //@RestController 13 | //@RequestMapping("/wenxincontroller") 14 | //public class wenxincontroller { 15 | // @Autowired 16 | // private WenXinService wenXinService; 17 | // 18 | // @PostMapping("/query") 19 | // public String query(@RequestBody String question){ 20 | // String answers = wenXinService.wenXinTest(question); 21 | // return answers; 22 | // } 23 | //} 24 | // 25 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/interceptor/JwtAuthInterceptor.java: -------------------------------------------------------------------------------- 1 | //package com.neusoft.elmboot.interceptor; 2 | // 3 | //import com.neusoft.elmboot.util.JwtUtil; 4 | //import jakarta.servlet.http.HttpServletRequest; 5 | //import jakarta.servlet.http.HttpServletResponse; 6 | //import org.springframework.beans.factory.annotation.Autowired; 7 | //import org.springframework.stereotype.Component; 8 | //import org.springframework.web.servlet.HandlerInterceptor; 9 | // 10 | //@Component 11 | //public class JwtAuthInterceptor implements HandlerInterceptor { 12 | // 13 | // @Autowired 14 | // private JwtUtil jwtUtil; 15 | // 16 | // @Override 17 | // public boolean preHandle(HttpServletRequest request, HttpServletResponse response, Object handler) throws Exception { 18 | // // 从请求头中获取token 19 | // String token = request.getHeader("Authorization"); 20 | // 21 | // // 如果是登录或注册接口,直接放行 22 | // if (request.getRequestURI().contains("/user/login") || 23 | // request.getRequestURI().contains("/user/register")) { 24 | // return true; 25 | // } 26 | // 27 | // // 验证token 28 | // if (token == null || !token.startsWith("Bearer ")) { 29 | // response.setStatus(HttpServletResponse.SC_UNAUTHORIZED); 30 | // return false; 31 | // } 32 | // 33 | // token = token.substring(7); 34 | // 35 | // if (!jwtUtil.validateToken(token)) { 36 | // response.setStatus(HttpServletResponse.SC_UNAUTHORIZED); 37 | // return false; 38 | // } 39 | // 40 | // // 将用户ID添加到请求属性中 41 | // request.setAttribute("userId", jwtUtil.getUserIdFromToken(token)); 42 | // return true; 43 | // } 44 | //} -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/CartMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | import java.util.List; 3 | import org.apache.ibatis.annotations.Insert; 4 | import org.apache.ibatis.annotations.Mapper; 5 | import org.apache.ibatis.annotations.Update; 6 | import com.neusoft.elmboot.po.Cart; 7 | @Mapper 8 | public interface CartMapper { 9 | 10 | public List listCart(Cart cart); 11 | 12 | @Insert("insert into cart values(null,#{foodId},#{businessId},#{userId},1)") 13 | public int saveCart(Cart cart); 14 | 15 | @Update("update cart set quantity=#{quantity} where foodId=#{foodId} and businessId=#{businessId} and userId=#{userId}") 16 | public int updateCart(Cart cart); 17 | 18 | public int removeCart(Cart cart); 19 | 20 | } 21 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/ChatsMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | 3 | import java.util.List; 4 | 5 | import org.apache.ibatis.annotations.Delete; 6 | import org.apache.ibatis.annotations.Insert; 7 | import org.apache.ibatis.annotations.Mapper; 8 | import org.apache.ibatis.annotations.Select; 9 | 10 | import com.neusoft.elmboot.po.Chats; 11 | 12 | @Mapper 13 | public interface ChatsMapper { 14 | @Select("select * from chats where currentUserId =#{currentUserId}") 15 | public List getChatsByUserId(String currentUserId); 16 | 17 | @Insert("insert into chats values(#{currentUserId},#{senderUserId},#{receiverUserId},#{message})") 18 | public int saveChats(Chats chats); 19 | 20 | @Delete("delete from chats where currentUserId=#{currentUserId}") 21 | public int removeChatsAllByCurrentUserId(Chats chats); 22 | 23 | @Delete("delete from chats where currentUserId=#{currentUserId} and senderUserId=#{senderUserId} and " 24 | + "receiverUserId=#{receiverUserId} and message=#{message}") 25 | public int removeChatsByTwoUserIdByMessage(Chats chats); 26 | 27 | @Delete("delete from chats where currentUserId=#{currentUserId} and receiverUserId=#{receiverUserId} and " 28 | + "message=#{message}") 29 | public int recallChatsByTwoUserIdByMessage(Chats chats); 30 | } 31 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/DeliveryAddressMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | import java.util.List; 3 | import org.apache.ibatis.annotations.Delete; 4 | import org.apache.ibatis.annotations.Insert; 5 | import org.apache.ibatis.annotations.Mapper; 6 | import org.apache.ibatis.annotations.Select; 7 | import org.apache.ibatis.annotations.Update; 8 | import com.neusoft.elmboot.po.DeliveryAddress; 9 | @Mapper 10 | public interface DeliveryAddressMapper { 11 | @Select("select * from deliveryaddress where userId=#{userId} order by daId") 12 | public List listDeliveryAddressByUserId(String userId); 13 | 14 | @Select("select * from deliveryaddress where daId=#{daId}") 15 | public DeliveryAddress getDeliveryAddressById(Integer daId); 16 | 17 | @Insert("insert into deliveryaddress(contactName,contactSex,contactTel,address,userId) values(#{contactName},#{contactSex},#{contactTel},#{address},#{userId})") 18 | public int saveDeliveryAddress(DeliveryAddress deliveryAddress); 19 | 20 | @Update("update deliveryaddress set contactName=#{contactName},contactSex=#{contactSex},contactTel=#{contactTel},address=#{address} where daId=#{daId}") 21 | public int updateDeliveryAddress(DeliveryAddress deliveryAddress); 22 | 23 | @Delete("delete from deliveryaddress where daId=#{daId}") 24 | public int removeDeliveryAddress(Integer daId); 25 | 26 | } 27 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/DiscoverSearchHistoryMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | 3 | import java.util.List; 4 | 5 | import org.apache.ibatis.annotations.Delete; 6 | import org.apache.ibatis.annotations.Insert; 7 | import org.apache.ibatis.annotations.Mapper; 8 | import org.apache.ibatis.annotations.Options; 9 | import org.apache.ibatis.annotations.Select; 10 | import org.apache.ibatis.annotations.Update; 11 | 12 | import com.neusoft.elmboot.po.DiscoverSearchHistory; 13 | 14 | @Mapper 15 | public interface DiscoverSearchHistoryMapper { 16 | 17 | @Insert("INSERT INTO discover_search_history (user_id, query, results, current_page) VALUES (#{userId}, #{query}, #{results}, #{currentPage})") 18 | @Options(useGeneratedKeys=true, keyProperty="id", keyColumn="id") 19 | public int saveSearchHistory(DiscoverSearchHistory history); 20 | 21 | @Select("SELECT * FROM discover_search_history WHERE user_id = #{userId} ORDER BY id ASC") 22 | public List getSearchHistoryByUserId(String userId); 23 | 24 | @Update("UPDATE discover_search_history SET current_page = #{currentPage} WHERE id = #{id}") 25 | public int updateCurrentPage(DiscoverSearchHistory history); 26 | 27 | @Delete("DELETE FROM discover_search_history WHERE user_id = #{userId}") 28 | public int deleteSearchHistoryByUserId(String userId); 29 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/FavoriteMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | 3 | import java.util.List; 4 | 5 | import org.apache.ibatis.annotations.Delete; 6 | import org.apache.ibatis.annotations.Insert; 7 | import org.apache.ibatis.annotations.Mapper; 8 | import org.apache.ibatis.annotations.Select; 9 | 10 | import com.neusoft.elmboot.po.Favorite; 11 | 12 | @Mapper 13 | public interface FavoriteMapper { 14 | 15 | @Insert("insert into favorite values(#{userId},#{businessId})") 16 | public int saveFavoriteBusinessId(Favorite favorite); 17 | 18 | @Select("select businessId from favorite where userId=#{userId}") 19 | public List listFavoriteByUserId(Favorite favorite); 20 | 21 | @Delete("delete from favorite where userId=#{userId} and businessId=#{businessId}") 22 | public int removeFavoriteBusinessId(Favorite favorite); 23 | 24 | @Select("select count(*) from favorite where businessId=#{businessId}") 25 | public int getFavoriteCountByBusinessId(Favorite favorite); 26 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/FoodMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | import java.util.List; 3 | 4 | import org.apache.ibatis.annotations.Insert; 5 | import org.apache.ibatis.annotations.Mapper; 6 | import org.apache.ibatis.annotations.Select; 7 | import com.neusoft.elmboot.po.Food; 8 | @Mapper 9 | public interface FoodMapper { 10 | 11 | @Select("select * from food where businessId=#{businessId}") 12 | public List listFoodByBusinessId(Integer businessId); 13 | 14 | @Select("select * from food where foodId=#{foodId}") 15 | public Food getFoodById(Integer foodId); 16 | 17 | @Insert("insert into food(foodName,foodExplain,foodImg,foodPrice,businessId) values(#{foodName},#{foodExplain},#{foodImg},#{foodPrice},#{businessId})") 18 | public int addFood(Food food); 19 | 20 | @Select("select * from food where foodName like CONCAT('%',#{foodName},'%')") 21 | public List listFoodBySearchName(String foodName); 22 | 23 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/HistoryMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | 3 | import org.apache.ibatis.annotations.Insert; 4 | import org.apache.ibatis.annotations.Mapper; 5 | import org.apache.ibatis.annotations.Select; 6 | import org.apache.ibatis.annotations.Update; 7 | 8 | import com.neusoft.elmboot.po.History; 9 | 10 | @Mapper 11 | public interface HistoryMapper { 12 | 13 | @Select("select s.searchContent from searchhistory s where s.userId=#{userId}") 14 | public String getHistoryByUserId(History history); 15 | 16 | @Select("select count(*) from searchhistory where userId=#{userId}") 17 | public int findHistoryByUserId(History history); 18 | 19 | @Select("select count(*) from searchhistory where userId=#{userId}") 20 | public int judgeExist(History history); 21 | 22 | @Insert("insert into searchhistory values(#{userId},#{searchContent})") 23 | public int saveHistory(History history); 24 | 25 | @Update("UPDATE searchhistory SET searchContent =#{searchContent} WHERE userId =#{userId}") 26 | public int updateHistory(History history); 27 | 28 | 29 | 30 | } 31 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/LikesMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | 3 | import java.util.List; 4 | import java.util.Map; 5 | 6 | import org.apache.ibatis.annotations.Delete; 7 | import org.apache.ibatis.annotations.Insert; 8 | import org.apache.ibatis.annotations.Mapper; 9 | import org.apache.ibatis.annotations.Select; 10 | 11 | import com.neusoft.elmboot.po.Likes; 12 | import com.neusoft.elmboot.po.User; 13 | 14 | @Mapper 15 | public interface LikesMapper { 16 | @Select("select count(*) from likes where businessId=#{businessId}") 17 | public int getLikesBybusinessId(Likes likes); 18 | 19 | @Insert("insert into likes values(#{userId},#{businessId})") 20 | public int saveLikes(Likes likes); 21 | 22 | @Delete("delete from likes where userId=#{userId} and businessId=#{businessId}") 23 | public int removeLikes(Likes likes); 24 | 25 | @Select("select count(*) from likes where userId=#{userId} and businessId=#{businessId}") 26 | public int getLikesByUserIdByBusinessId(Likes likes); 27 | 28 | @Select("SELECT l.*, b.businessName as name, b.businessImg as img, 'business' as type, NOW() as likeTime FROM likes l JOIN business b ON l.businessId = b.businessId WHERE l.userId = #{userId}") 29 | public List> getLikesByUserId(String userId); 30 | } 31 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/OrderDetailetMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | import java.util.List; 3 | import org.apache.ibatis.annotations.Mapper; 4 | import org.apache.ibatis.annotations.Param; 5 | import org.apache.ibatis.annotations.Select; 6 | 7 | import com.neusoft.elmboot.po.OrderDetailet; 8 | import com.neusoft.elmboot.po.OrderDetailet_Food; 9 | import com.neusoft.elmboot.po.Orders; 10 | @Mapper 11 | public interface OrderDetailetMapper { 12 | 13 | public int saveOrderDetailetBatch(@Param("list") List list); 14 | 15 | 16 | public List listOrderDetailetByOrderId(Integer orderId); 17 | 18 | @Select("select * from orderdetailet where orderId=#{orderId}") 19 | public List listorderDetailetByOrderId(Orders orders); 20 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/OrderDetailet_FoodMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | 3 | import org.apache.ibatis.annotations.Insert; 4 | 5 | import com.neusoft.elmboot.po.OrderDetailet_Food; 6 | 7 | public interface OrderDetailet_FoodMapper { 8 | @Insert("insert into orderdetailet_food values(" 9 | + "#{odId}," 10 | + "#{orderId}," 11 | + "#{foodId}," 12 | + "#{quantity}," 13 | + "#{priceAtThatTime}," 14 | + "#{foodExplain}," 15 | + "#{foodName}," 16 | + "#{foodImg}," 17 | + "#{businessId}," 18 | + "#{remarks})") 19 | public int saveOrderDetailet_Food(OrderDetailet_Food orderDetailet_Food); 20 | } 21 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/OrdersMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | import java.util.List; 3 | 4 | import org.apache.ibatis.annotations.Insert; 5 | import org.apache.ibatis.annotations.Mapper; 6 | import org.apache.ibatis.annotations.Options; 7 | import org.apache.ibatis.annotations.Param; 8 | import org.apache.ibatis.annotations.Select; 9 | 10 | import com.neusoft.elmboot.po.Orders; 11 | import org.apache.ibatis.annotations.Update; 12 | 13 | 14 | @Mapper 15 | public interface OrdersMapper { 16 | 17 | public Orders getOrdersById(Integer ordersId); 18 | 19 | @Insert("insert into orders (userId,businessId,orderDate,orderTotal,daId,orderState) values(#{userId},#{businessId},#{orderDate},#{orderTotal},#{daId},0)") 20 | @Options(useGeneratedKeys=true,keyProperty="orderId",keyColumn="orderId") 21 | public int saveOrders(Orders orders); 22 | 23 | public List listOrdersByUserId(String userId); 24 | 25 | @Update("update orders set orderState=1 where orderId=#{orderId}") 26 | public int updateOrderState(Integer orderId); 27 | 28 | @Update("update orders set orderState=1 where orderId=#{orderId}") 29 | public int payOk(Orders orders); 30 | 31 | //开发了,但是没有使用的功能接口,废除了 32 | @Update("update orders set orderState=1,useCredit = #{useCredit} where orderId=#{orderId}") 33 | public int updateOrderStateAndCredit(Integer orderId,Integer useCredit); 34 | 35 | 36 | @Select("select odId from orderdetailet where orderId=#{orderId}") 37 | public List listOdIdByOrderId(Orders orders); 38 | 39 | 40 | 41 | } 42 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/RemarkMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | 3 | import java.util.List; 4 | import java.util.Map; 5 | 6 | import org.apache.ibatis.annotations.Insert; 7 | import org.apache.ibatis.annotations.Mapper; 8 | import org.apache.ibatis.annotations.Options; 9 | import org.apache.ibatis.annotations.Select; 10 | 11 | import com.neusoft.elmboot.po.Remark; 12 | 13 | @Mapper 14 | public interface RemarkMapper { 15 | 16 | @Select("select * from remarks where businessId=#{businessId}") 17 | public List listRemarksByBusinessId(Integer businessId); 18 | 19 | @Insert("insert into remarks(remark,businessId,remarkDate,userId,userName) values(#{remark},#{businessId},#{remarkDate},#{userId},#{userName})") 20 | @Options(useGeneratedKeys = true, keyProperty = "remarkId", keyColumn = "remarkId") 21 | public int saveRemarks(Remark remark); 22 | 23 | //删除某用户某条评论 24 | @Select("delete from remarks where userId=#{userId} and businessId =#{businessId } and remark=#{remark}" ) 25 | public int removeOneRemark(Remark remark); 26 | 27 | 28 | //删除某用户所有评论 29 | @Select("delete from remark where userId=#{userId}") 30 | public List removeAllRemarksByUserId(String userId); 31 | 32 | @Select("select count(*) from remarks where businessId=#{businessId}") 33 | public int getRemarkCountByBusinessId(Integer businessId); 34 | 35 | @Select("SELECT r.*, b.businessName, b.businessImg, 5 as deliveryRating, r.remark as content, r.remarkDate as commentTime FROM remarks r JOIN business b ON r.businessId = b.businessId WHERE r.userId = #{userId} ORDER BY r.remarkId DESC") 36 | public List> getCommentsByUserId(String userId); 37 | } 38 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/mapper/UserMapper.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.mapper; 2 | 3 | import com.neusoft.elmboot.po.User; 4 | import com.neusoft.elmboot.po.UserAvatar; 5 | import com.neusoft.elmboot.po.UserPsd; 6 | import org.apache.ibatis.annotations.*; 7 | 8 | @Mapper 9 | public interface UserMapper { 10 | 11 | @Select("SELECT * FROM user WHERE userId = #{userId} AND password=#{password} AND delTag = 1") 12 | public User getUserByIdByPass(User user); 13 | 14 | @Insert("insert into user values(#{userId},#{password},#{userName},#{userSex},#{userImg},1)") 15 | public int saveUser(User user); 16 | 17 | @Update("UPDATE user u SET u.userImg =#{userImg} WHERE u.userId =#{userId}") 18 | public int changeUserAvatar(UserAvatar userAvatar); 19 | 20 | @Update("update user set password=#{newPassword} where userId=#{userId} and password=#{oldPassword}") 21 | public int changeUserPassword(UserPsd userPsd); 22 | 23 | @Update("UPDATE user SET userName=#{userName} WHERE userId=#{userId}") 24 | public int changeUserName(User user); 25 | 26 | @Select("select count(*) from user where userId=#{userId}") 27 | public int userIdExists(User user); 28 | 29 | @Select("SELECT * FROM user WHERE userId = #{userId} AND password = #{password} AND delTag = 1") 30 | public User getUserByIdAndPassword(@Param("userId") String userId, @Param("password") String password); 31 | 32 | @Select("SELECT * FROM user WHERE userId = #{userId} AND delTag = 1") 33 | public User getUserById(@Param("userId") String userId); 34 | 35 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/Cart.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | public class Cart { 3 | private Integer cartId; 4 | private Integer foodId; 5 | private Integer businessId; 6 | private String userId; 7 | private Integer quantity; 8 | 9 | //多对一:所属食品 10 | private Food food; 11 | //多对一:所属商家 12 | private Business business; 13 | 14 | public Integer getCartId() { 15 | return cartId; 16 | } 17 | public void setCartId(Integer cartId) { 18 | this.cartId = cartId; 19 | } 20 | public Integer getFoodId() { 21 | return foodId; 22 | } 23 | public void setFoodId(Integer foodId) { 24 | this.foodId = foodId; 25 | } 26 | public Integer getBusinessId() { 27 | return businessId; 28 | } 29 | public void setBusinessId(Integer businessId) { 30 | this.businessId = businessId; 31 | } 32 | public String getUserId() { 33 | return userId; 34 | } 35 | public void setUserId(String userId) { 36 | this.userId = userId; 37 | } 38 | public Integer getQuantity() { 39 | return quantity; 40 | } 41 | public void setQuantity(Integer quantity) { 42 | this.quantity = quantity; 43 | } 44 | public Food getFood() { 45 | return food; 46 | } 47 | public void setFood(Food food) { 48 | this.food = food; 49 | } 50 | public Business getBusiness() { 51 | return business; 52 | } 53 | public void setBusiness(Business business) { 54 | this.business = business; 55 | } 56 | 57 | } 58 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/Chats.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | public class Chats { 4 | private String currentUserId; 5 | private String senderUserId; 6 | private String receiverUserId; 7 | private String message; 8 | 9 | public String getCurrentUserId() { 10 | return currentUserId; 11 | } 12 | public void setCurrentUserId(String currentUserId) { 13 | this.currentUserId = currentUserId; 14 | } 15 | public String getMessage() { 16 | return message; 17 | } 18 | public void setMessage(String message) { 19 | this.message = message; 20 | } 21 | public String getSenderUserId() { 22 | return senderUserId; 23 | } 24 | public void setSenderUserId(String senderUserId) { 25 | this.senderUserId = senderUserId; 26 | } 27 | public String getReceiverUserId() { 28 | return receiverUserId; 29 | } 30 | public void setReceiverUserId(String receiverUserId) { 31 | this.receiverUserId = receiverUserId; 32 | } 33 | 34 | 35 | 36 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/DeliveryAddress.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | public class DeliveryAddress { 4 | private Integer daId; 5 | private String contactName; 6 | private Integer contactSex; 7 | private String contactTel; 8 | private String address; 9 | private String userId; 10 | 11 | public Integer getDaId() { 12 | return daId; 13 | } 14 | public void setDaId(Integer daId) { 15 | this.daId = daId; 16 | } 17 | public String getContactName() { 18 | return contactName; 19 | } 20 | public void setContactName(String contactName) { 21 | this.contactName = contactName; 22 | } 23 | public Integer getContactSex() { 24 | return contactSex; 25 | } 26 | public void setContactSex(Integer contactSex) { 27 | this.contactSex = contactSex; 28 | } 29 | public String getContactTel() { 30 | return contactTel; 31 | } 32 | public void setContactTel(String contactTel) { 33 | this.contactTel = contactTel; 34 | } 35 | public String getAddress() { 36 | return address; 37 | } 38 | public void setAddress(String address) { 39 | this.address = address; 40 | } 41 | public String getUserId() { 42 | return userId; 43 | } 44 | public void setUserId(String userId) { 45 | this.userId = userId; 46 | } 47 | 48 | //get、set ... ... 49 | 50 | } 51 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/DiscoverSearchHistory.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | import java.util.Date; 4 | 5 | public class DiscoverSearchHistory { 6 | private Integer id; 7 | private String userId; 8 | private String query; 9 | private String results; 10 | private Integer currentPage; 11 | private Date createdAt; 12 | 13 | public Integer getId() { 14 | return id; 15 | } 16 | 17 | public void setId(Integer id) { 18 | this.id = id; 19 | } 20 | 21 | public String getUserId() { 22 | return userId; 23 | } 24 | 25 | public void setUserId(String userId) { 26 | this.userId = userId; 27 | } 28 | 29 | public String getQuery() { 30 | return query; 31 | } 32 | 33 | public void setQuery(String query) { 34 | this.query = query; 35 | } 36 | 37 | public String getResults() { 38 | return results; 39 | } 40 | 41 | public void setResults(String results) { 42 | this.results = results; 43 | } 44 | 45 | public Integer getCurrentPage() { 46 | return currentPage; 47 | } 48 | 49 | public void setCurrentPage(Integer currentPage) { 50 | this.currentPage = currentPage; 51 | } 52 | 53 | public Date getCreatedAt() { 54 | return createdAt; 55 | } 56 | 57 | public void setCreatedAt(Date createdAt) { 58 | this.createdAt = createdAt; 59 | } 60 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/Favorite.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | public class Favorite { 4 | private String userId; 5 | private Integer businessId; 6 | 7 | public String getUserId() { 8 | return userId; 9 | } 10 | public void setUserId(String userId) { 11 | this.userId = userId; 12 | } 13 | public Integer getBusinessId() { 14 | return businessId; 15 | } 16 | public void setBusinessId(Integer businessId) { 17 | this.businessId = businessId; 18 | } 19 | 20 | 21 | } 22 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/Food.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | import java.math.BigDecimal; 4 | 5 | public class Food { 6 | private Integer foodId; 7 | private String foodName; 8 | private String foodExplain; 9 | private String foodImg; 10 | private BigDecimal foodPrice; 11 | private Integer businessId; 12 | private String remarks; 13 | public Integer getFoodId() { 14 | return foodId; 15 | } 16 | public void setFoodId(Integer foodId) { 17 | this.foodId = foodId; 18 | } 19 | public String getFoodName() { 20 | return foodName; 21 | } 22 | public void setFoodName(String foodName) { 23 | this.foodName = foodName; 24 | } 25 | public String getFoodExplain() { 26 | return foodExplain; 27 | } 28 | public void setFoodExplain(String foodExplain) { 29 | this.foodExplain = foodExplain; 30 | } 31 | public String getFoodImg() { 32 | return foodImg; 33 | } 34 | public void setFoodImg(String foodImg) { 35 | this.foodImg = foodImg; 36 | } 37 | public BigDecimal getFoodPrice() { 38 | return foodPrice; 39 | } 40 | public void setFoodPrice(BigDecimal foodPrice) { 41 | this.foodPrice = foodPrice; 42 | } 43 | public Integer getBusinessId() { 44 | return businessId; 45 | } 46 | public void setBusinessId(Integer businessId) { 47 | this.businessId = businessId; 48 | } 49 | public String getRemarks() { 50 | return remarks; 51 | } 52 | public void setRemarks(String remarks) { 53 | this.remarks = remarks; 54 | } 55 | 56 | //get、set ... ... 57 | 58 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/History.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | public class History { 4 | 5 | private String userId; 6 | private String searchContent; 7 | 8 | public String getUserId() { 9 | return userId; 10 | } 11 | public void setUserId(String userId) { 12 | this.userId = userId; 13 | } 14 | public String getSearchContent() { 15 | return searchContent; 16 | } 17 | public void setSearchContent(String searchContent) { 18 | this.searchContent = searchContent; 19 | } 20 | 21 | } 22 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/InsufficientBalanceException.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | public class InsufficientBalanceException extends Exception { 4 | public InsufficientBalanceException(String massage) { 5 | super(massage); 6 | } 7 | 8 | } 9 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/InvalidAmountException.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | public class InvalidAmountException extends Exception { 4 | public InvalidAmountException(String massage) { 5 | super(massage); 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/Likes.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | public class Likes { 4 | private String userId; 5 | private Integer businessId; 6 | 7 | public String getUserId() { 8 | return userId; 9 | } 10 | public void setUserId(String userId) { 11 | this.userId = userId; 12 | } 13 | public Integer getBusinessId() { 14 | return businessId; 15 | } 16 | public void setBusinessId(Integer businessId) { 17 | this.businessId = businessId; 18 | } 19 | 20 | } 21 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/OrderDetailet.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | import java.math.BigDecimal; 4 | 5 | public class OrderDetailet { 6 | 7 | private Integer odId; 8 | private Integer orderId; 9 | private Integer foodId; 10 | private Integer quantity; 11 | private BigDecimal priceAtThatTime; 12 | private String foodName; 13 | //多对一:所属食品 14 | private Food food; 15 | 16 | public String getFoodName() { 17 | return foodName; 18 | } 19 | 20 | public void setFoodName(String foodName) { 21 | this.foodName = foodName; 22 | } 23 | public BigDecimal getPriceAtThatTime() { 24 | return priceAtThatTime; 25 | } 26 | 27 | public void setPriceAtThatTime(BigDecimal priceAtThatTime) { 28 | this.priceAtThatTime = priceAtThatTime; 29 | } 30 | public Integer getOdId() { 31 | return odId; 32 | } 33 | 34 | public void setOdId(Integer odId) { 35 | this.odId = odId; 36 | } 37 | 38 | public Integer getOrderId() { 39 | return orderId; 40 | } 41 | 42 | public void setOrderId(Integer orderId) { 43 | this.orderId = orderId; 44 | } 45 | 46 | public Integer getFoodId() { 47 | return foodId; 48 | } 49 | 50 | public void setFoodId(Integer foodId) { 51 | this.foodId = foodId; 52 | } 53 | 54 | public Integer getQuantity() { 55 | return quantity; 56 | } 57 | 58 | public void setQuantity(Integer quantity) { 59 | this.quantity = quantity; 60 | } 61 | 62 | public Food getFood() { 63 | return food; 64 | } 65 | 66 | public void setFood(Food food) { 67 | this.food = food; 68 | } 69 | 70 | } 71 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/OrderDetailet_Food.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | import java.math.BigDecimal; 4 | 5 | public class OrderDetailet_Food { 6 | private Integer odId; 7 | private Integer orderId; 8 | private Integer foodId; 9 | private Integer quantity; 10 | private BigDecimal priceAtThatTime; 11 | 12 | private String foodName; 13 | private String foodExplain; 14 | private String foodImg; 15 | private Integer businessId; 16 | private String remarks; 17 | 18 | //多对一:所属食品 19 | private Food food; 20 | 21 | public Integer getOdId() { 22 | return odId; 23 | } 24 | public void setOdId(Integer odId) { 25 | this.odId = odId; 26 | } 27 | public Integer getOrderId() { 28 | return orderId; 29 | } 30 | public void setOrderId(Integer orderId) { 31 | this.orderId = orderId; 32 | } 33 | public Integer getFoodId() { 34 | return foodId; 35 | } 36 | public void setFoodId(Integer foodId) { 37 | this.foodId = foodId; 38 | } 39 | public Integer getQuantity() { 40 | return quantity; 41 | } 42 | public void setQuantity(Integer quantity) { 43 | this.quantity = quantity; 44 | } 45 | public BigDecimal getPriceAtThatTime() { 46 | return priceAtThatTime; 47 | } 48 | public void setPriceAtThatTime(BigDecimal priceAtThatTime) { 49 | this.priceAtThatTime = priceAtThatTime; 50 | } 51 | public Food getFood() { 52 | return food; 53 | } 54 | public void setFood(Food food) { 55 | this.food = food; 56 | } 57 | public String getFoodName() { 58 | return foodName; 59 | } 60 | public void setFoodName(String foodName) { 61 | this.foodName = foodName; 62 | } 63 | public String getFoodExplain() { 64 | return foodExplain; 65 | } 66 | public void setFoodExplain(String foodExplain) { 67 | this.foodExplain = foodExplain; 68 | } 69 | public String getFoodImg() { 70 | return foodImg; 71 | } 72 | public void setFoodImg(String foodImg) { 73 | this.foodImg = foodImg; 74 | } 75 | public Integer getBusinessId() { 76 | return businessId; 77 | } 78 | public void setBusinessId(Integer businessId) { 79 | this.businessId = businessId; 80 | } 81 | public String getRemarks() { 82 | return remarks; 83 | } 84 | public void setRemarks(String remarks) { 85 | this.remarks = remarks; 86 | } 87 | 88 | } 89 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/Orders.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | import java.math.BigDecimal; 4 | import java.util.List; 5 | 6 | public class Orders { 7 | 8 | private Integer orderId; 9 | private String userId; 10 | private Integer businessId; 11 | private String orderDate; 12 | private BigDecimal orderTotal; 13 | private Integer daId; //送货地址编号 14 | private Integer orderState; //订单状态(0:未支付; 1:已支付) 15 | //多对一:所属商家 16 | private Business business; 17 | //一对多:订单明细 18 | private List list; 19 | 20 | 21 | 22 | 23 | public Integer getOrderId() { 24 | return orderId; 25 | } 26 | public void setOrderId(Integer orderId) { 27 | this.orderId = orderId; 28 | } 29 | public String getUserId() { 30 | return userId; 31 | } 32 | public void setUserId(String userId) { 33 | this.userId = userId; 34 | } 35 | public Integer getBusinessId() { 36 | return businessId; 37 | } 38 | public void setBusinessId(Integer businessId) { 39 | this.businessId = businessId; 40 | } 41 | public String getOrderDate() { 42 | return orderDate; 43 | } 44 | public void setOrderDate(String orderDate) { 45 | this.orderDate = orderDate; 46 | } 47 | public BigDecimal getOrderTotal() { 48 | return orderTotal; 49 | } 50 | public void setOrderTotal(BigDecimal orderTotal) { 51 | this.orderTotal = orderTotal; 52 | } 53 | public Integer getDaId() { 54 | return daId; 55 | } 56 | public void setDaId(Integer daId) { 57 | this.daId = daId; 58 | } 59 | public Integer getOrderState() { 60 | return orderState; 61 | } 62 | public void setOrderState(Integer orderState) { 63 | this.orderState = orderState; 64 | } 65 | public Business getBusiness() { 66 | return business; 67 | } 68 | public void setBusiness(Business business) { 69 | this.business = business; 70 | } 71 | public List getList() { 72 | return list; 73 | } 74 | public void setList(List list) { 75 | this.list = list; 76 | } 77 | } 78 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/Remark.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | public class Remark { 4 | 5 | private String remark; 6 | private String userId; 7 | private String userName; 8 | private Integer businessId; 9 | private String remarkDate; 10 | private Integer remarkId; 11 | 12 | public String getRemark() { 13 | return remark; 14 | } 15 | public void setRemark(String remark) { 16 | this.remark = remark; 17 | } 18 | public Integer getBusinessId() { 19 | return businessId; 20 | } 21 | public void setBusinessId(Integer businessId) { 22 | this.businessId = businessId; 23 | } 24 | public String getUserName() { 25 | return userName; 26 | } 27 | public void setUserName(String userName) { 28 | this.userName = userName; 29 | } 30 | public String getRemarkDate() { 31 | return remarkDate; 32 | } 33 | public void setRemarkDate(String remarkDate) { 34 | this.remarkDate = remarkDate; 35 | } 36 | public String getUserId() { 37 | return userId; 38 | } 39 | public void setUserId(String userId) { 40 | this.userId = userId; 41 | } 42 | public Integer getRemarkId() { 43 | return remarkId; 44 | } 45 | public void setRemarkId(Integer remarkId) { 46 | this.remarkId = remarkId; 47 | } 48 | 49 | 50 | } 51 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/SearchResult.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | public class SearchResult { 4 | private String type; // "business" 或 "food" 5 | private Integer businessId; 6 | private Integer foodId; 7 | private String name; 8 | private String img; 9 | private Double starPrice; // 起送价 10 | private Double deliveryPrice; // 配送费 11 | private Double price; // 食品价格 12 | 13 | public String getType() { 14 | return type; 15 | } 16 | 17 | public void setType(String type) { 18 | this.type = type; 19 | } 20 | 21 | public Integer getBusinessId() { 22 | return businessId; 23 | } 24 | 25 | public void setBusinessId(Integer businessId) { 26 | this.businessId = businessId; 27 | } 28 | 29 | public Integer getFoodId() { 30 | return foodId; 31 | } 32 | 33 | public void setFoodId(Integer foodId) { 34 | this.foodId = foodId; 35 | } 36 | 37 | public String getName() { 38 | return name; 39 | } 40 | 41 | public void setName(String name) { 42 | this.name = name; 43 | } 44 | 45 | public String getImg() { 46 | return img; 47 | } 48 | 49 | public void setImg(String img) { 50 | this.img = img; 51 | } 52 | 53 | public Double getStarPrice() { 54 | return starPrice; 55 | } 56 | 57 | public void setStarPrice(Double starPrice) { 58 | this.starPrice = starPrice; 59 | } 60 | 61 | public Double getDeliveryPrice() { 62 | return deliveryPrice; 63 | } 64 | 65 | public void setDeliveryPrice(Double deliveryPrice) { 66 | this.deliveryPrice = deliveryPrice; 67 | } 68 | 69 | public Double getPrice() { 70 | return price; 71 | } 72 | 73 | public void setPrice(Double price) { 74 | this.price = price; 75 | } 76 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/User.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | public class User { 4 | 5 | private String userId; 6 | 7 | private String password; 8 | 9 | private String userName; 10 | 11 | private Integer userSex; 12 | 13 | private String userImg; 14 | 15 | private Integer delTag; 16 | 17 | public String getUserId() { 18 | return userId; 19 | } 20 | 21 | public void setUserId(String userId) { 22 | this.userId = userId; 23 | } 24 | 25 | public String getPassword() { 26 | return password; 27 | } 28 | 29 | public void setPassword(String password) { 30 | this.password = password; 31 | } 32 | 33 | public String getUserName() { 34 | return userName; 35 | } 36 | 37 | public void setUserName(String userName) { 38 | this.userName = userName; 39 | } 40 | 41 | public Integer getUserSex() { 42 | return userSex; 43 | } 44 | 45 | public void setUserSex(Integer userSex) { 46 | this.userSex = userSex; 47 | } 48 | 49 | public String getUserImg() { 50 | return userImg; 51 | } 52 | 53 | public void setUserImg(String userImg) { 54 | this.userImg = userImg; 55 | } 56 | 57 | public Integer getDelTag() { 58 | return delTag; 59 | } 60 | 61 | public void setDelTag(Integer delTag) { 62 | this.delTag = delTag; 63 | } 64 | 65 | 66 | } 67 | 68 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/UserAvatar.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | public class UserAvatar { 4 | 5 | private String userId; 6 | private String userImg; 7 | 8 | public String getUserId() { 9 | return userId; 10 | } 11 | 12 | public void setUserId(String userId) { 13 | this.userId = userId; 14 | } 15 | 16 | public String getUserImg() { 17 | return userImg; 18 | } 19 | 20 | public void setUserImg(String userImg) { 21 | this.userImg = userImg; 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/UserPsd.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | //import jakarta.validation.constraints.NotNull; 4 | 5 | public class UserPsd { 6 | public String getUserId() { 7 | return userId; 8 | } 9 | 10 | public void setUserId(String userId) { 11 | this.userId = userId; 12 | } 13 | 14 | public String getNewPassword() { 15 | return newPassword; 16 | } 17 | 18 | public void setNewPassword(String newPassword) { 19 | this.newPassword = newPassword; 20 | } 21 | 22 | public String getOldPassword() { 23 | return oldPassword; 24 | } 25 | 26 | public void setOldPassword(String oldPassword) { 27 | this.oldPassword = oldPassword; 28 | } 29 | 30 | private String userId; 31 | 32 | private String newPassword; 33 | 34 | private String oldPassword; 35 | 36 | } 37 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/po/image.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.po; 2 | 3 | public class image 4 | { 5 | 6 | private int id; 7 | private String name; 8 | private String data; // 这里用字符串来表示Base64编码的图片数据 9 | private String type; 10 | 11 | // 省略构造函数和其他方法 12 | 13 | // 省略其他字段 14 | 15 | public int getId() { 16 | return id; 17 | } 18 | 19 | public void setId(int id) { 20 | this.id = id; 21 | } 22 | 23 | public String getName() { 24 | return name; 25 | } 26 | 27 | public void setName(String name) { 28 | this.name = name; 29 | } 30 | 31 | public String getData() { 32 | return data; 33 | } 34 | 35 | public void setData(String data) { 36 | this.data = data; 37 | } 38 | 39 | public String getType() { 40 | return type; 41 | } 42 | 43 | public void setType(String type) { 44 | this.type = type; 45 | } 46 | 47 | 48 | } 49 | 50 | 51 | 52 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/BusinessService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | 3 | import com.neusoft.elmboot.po.Business; 4 | 5 | import java.util.List; 6 | 7 | import org.springframework.web.bind.annotation.RequestBody; 8 | 9 | public interface BusinessService { 10 | public List listBusinessByOrderTypeId(Integer orderTypeId); 11 | public Business getBusinessById(Integer businessId); 12 | public List listBusinessByBusinessName(String businessName); 13 | public int saveBusiness(Business business); 14 | public int updateBusiness(Business business); 15 | public Business getBusinessByIdByPass(Business business); 16 | public int checkBusiness (Business business); 17 | public int getBusinessIdByPhoneNumber(Business business); 18 | } 19 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/CartService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | import java.util.List; 3 | import com.neusoft.elmboot.po.Cart; 4 | public interface CartService { 5 | public List listCart(Cart cart); 6 | public int saveCart(Cart cart); 7 | public int updateCart(Cart cart); 8 | public int removeCart(Cart cart); 9 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/ChatsService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | 3 | import java.util.List; 4 | 5 | 6 | import com.neusoft.elmboot.po.Chats; 7 | 8 | public interface ChatsService { 9 | 10 | public List getChatsByUserId(String currentUserId); 11 | public int saveChats(Chats chats); 12 | public int removeChatsAllByCurrentUserId(Chats chats); 13 | public int removeChatsByTwoUserIdByMessage(Chats chats); 14 | public int recallChatsByTwoUserIdByMessage(Chats chats); 15 | } 16 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/DeliveryAddressService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | import java.util.List; 3 | import com.neusoft.elmboot.po.DeliveryAddress; 4 | public interface DeliveryAddressService { 5 | public List listDeliveryAddressByUserId(String userId); 6 | 7 | public DeliveryAddress getDeliveryAddressById(Integer daId); 8 | public int saveDeliveryAddress(DeliveryAddress deliveryAddress); 9 | public int updateDeliveryAddress(DeliveryAddress deliveryAddress); 10 | public int removeDeliveryAddress(Integer daId); 11 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/DiscoverSearchHistoryService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | 3 | import java.util.List; 4 | 5 | import com.neusoft.elmboot.po.DiscoverSearchHistory; 6 | 7 | public interface DiscoverSearchHistoryService { 8 | 9 | public int saveSearchHistory(DiscoverSearchHistory history); 10 | 11 | public List getSearchHistoryByUserId(String userId); 12 | 13 | public int updateCurrentPage(DiscoverSearchHistory history); 14 | 15 | public int deleteSearchHistoryByUserId(String userId); 16 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/FavoriteService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | 3 | import java.util.List; 4 | 5 | import com.neusoft.elmboot.po.Favorite; 6 | 7 | public interface FavoriteService { 8 | public int saveFavoriteBusinessId(Favorite favorite); 9 | public List listFavoriteByUserId(Favorite favorite); 10 | public int removeFavoriteBusinessId(Favorite favorite); 11 | public int getFavoriteCountByBusinessId(Favorite favorite); 12 | } 13 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/FoodService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | import java.util.List; 3 | 4 | import com.neusoft.elmboot.po.Food; 5 | public interface FoodService { 6 | 7 | public List listFoodByBusinessId(Integer businessId); 8 | 9 | public int addFood(Food food); 10 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/HistoryService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | 3 | import com.neusoft.elmboot.po.History; 4 | 5 | public interface HistoryService { 6 | public String getHistoryByUserId(History history); 7 | public int saveHistory(History history); 8 | } 9 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/LikesService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | 3 | import java.util.List; 4 | import java.util.Map; 5 | 6 | import com.neusoft.elmboot.po.Likes; 7 | 8 | public interface LikesService { 9 | public int getLikesBybusinessId(Likes likes); 10 | public int saveLikes(Likes likes); 11 | public int removeLikes(Likes likes); 12 | public int getLikesByUserIdByBusinessId(Likes likes); 13 | public List> getLikesByUserId(String userId); 14 | } 15 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/OrdersService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | import java.util.List; 3 | 4 | import com.neusoft.elmboot.po.OrderDetailet; 5 | import com.neusoft.elmboot.po.Orders; 6 | public interface OrdersService { 7 | public int createOrders(Orders orders); 8 | public Orders getOrdersById(Integer orderId); 9 | public List listOrdersByUserId(String userId); 10 | 11 | public int payOk(Orders orders); 12 | 13 | public List listOrderDetailetByOrderId(Orders orders); 14 | 15 | public List listOdIdByOrderId(Orders orders); 16 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/RemarkService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | 3 | import java.util.List; 4 | import java.util.Map; 5 | 6 | import com.neusoft.elmboot.po.Business; 7 | import com.neusoft.elmboot.po.Remark; 8 | 9 | public interface RemarkService { 10 | 11 | public List listRemarksByBusinessId(Integer businessId); 12 | public int saveRemarks(Remark remark); 13 | public int removeOneRemark(Remark remark); 14 | 15 | 16 | 17 | public List removeAllRemarksByUserId(String userId); 18 | 19 | public int getRemarkCountByBusinessId(Integer businessId); 20 | 21 | public List> getCommentsByUserId(String userId); 22 | } 23 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/SmartSearchService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | 3 | import com.neusoft.elmboot.po.SearchResult; 4 | 5 | import java.util.List; 6 | import java.util.Map; 7 | 8 | public interface SmartSearchService { 9 | List search(String query, String category); 10 | public Map search(String query, String type, String category, int page); 11 | } 12 | 13 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/UserService.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service; 2 | 3 | import com.neusoft.elmboot.po.User; 4 | import com.neusoft.elmboot.po.UserAvatar; 5 | import com.neusoft.elmboot.po.UserPsd; 6 | 7 | public interface UserService { 8 | 9 | public User getUserByIdByPass(User user); 10 | 11 | public User getUserById(String userId); 12 | 13 | public int saveUser(User user); 14 | 15 | public int changeUserPassword(UserPsd userPsd); 16 | 17 | public int changeUserAvatar(UserAvatar userAvatar); 18 | 19 | public int changeUserName(User user); 20 | 21 | public int userIdExists(User user); 22 | 23 | // 用户注册 24 | boolean register(User user); 25 | 26 | // 用户登录 27 | User login(String userId, String password); 28 | 29 | // 检查用户ID是否已存在 30 | boolean checkUserIdExists(String userId); 31 | 32 | public User createUser(String username, String password, String phone); 33 | 34 | } 35 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/WenXinService.java: -------------------------------------------------------------------------------- 1 | //package com.neusoft.elmboot.service; 2 | // 3 | //public interface WenXinService { 4 | // /** 5 | // * 向文心一言提问 6 | // * @param question 7 | // * @return 8 | // */ 9 | // String wenXinTest(String question); 10 | //} 11 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/impl/BusinessServiceImpl.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service.impl; 2 | 3 | import com.neusoft.elmboot.mapper.BusinessMapper; 4 | import com.neusoft.elmboot.po.Business; 5 | import com.neusoft.elmboot.service.BusinessService; 6 | 7 | import org.springframework.beans.factory.annotation.Autowired; 8 | import org.springframework.stereotype.Service; 9 | 10 | import java.util.List; 11 | 12 | @Service 13 | public class BusinessServiceImpl implements BusinessService { 14 | 15 | @Autowired 16 | private BusinessMapper businessMapper; 17 | 18 | @Override 19 | public List listBusinessByOrderTypeId(Integer orderTypeId) { 20 | return businessMapper.listBusinessByOrderTypeId(orderTypeId); 21 | } 22 | 23 | @Override 24 | public Business getBusinessById(Integer businessId) { 25 | return businessMapper.getBusinessById(businessId); 26 | } 27 | 28 | @Override 29 | public Business getBusinessByIdByPass(Business business) { 30 | return businessMapper.getBusinessByIdByPass(business); 31 | } 32 | 33 | @Override 34 | public List listBusinessByBusinessName(String businessName) { 35 | return businessMapper.listBusinessByBusinessName(businessName); 36 | } 37 | 38 | @Override 39 | public int saveBusiness(Business business){ 40 | return businessMapper.saveBusiness(business); 41 | } 42 | 43 | @Override 44 | public int updateBusiness(Business business) { 45 | return businessMapper.updateBusiness(business); 46 | } 47 | 48 | @Override 49 | public int checkBusiness(Business business) { 50 | return businessMapper.checkBusiness(business); 51 | } 52 | 53 | @Override 54 | public int getBusinessIdByPhoneNumber(Business business){ 55 | return businessMapper.getBusinessIdByPhoneNumber(business); 56 | } 57 | 58 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/impl/CartServiceImpl.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service.impl; 2 | import java.util.List; 3 | import org.springframework.beans.factory.annotation.Autowired; 4 | import org.springframework.stereotype.Service; 5 | import com.neusoft.elmboot.mapper.CartMapper; 6 | import com.neusoft.elmboot.po.Cart; 7 | import com.neusoft.elmboot.service.CartService; 8 | @Service 9 | public class CartServiceImpl implements CartService{ 10 | 11 | @Autowired 12 | private CartMapper cartMapper; 13 | @Override 14 | public List listCart(Cart cart) { 15 | return cartMapper.listCart(cart); 16 | } 17 | 18 | @Override 19 | public int saveCart(Cart cart) { 20 | return cartMapper.saveCart(cart); 21 | } 22 | 23 | @Override 24 | public int updateCart(Cart cart) { 25 | return cartMapper.updateCart(cart); 26 | } 27 | 28 | @Override 29 | public int removeCart(Cart cart) { 30 | return cartMapper.removeCart(cart); 31 | } 32 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/impl/ChatsServiceImpl.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service.impl; 2 | 3 | import java.util.List; 4 | 5 | import org.springframework.beans.factory.annotation.Autowired; 6 | import org.springframework.stereotype.Service; 7 | import org.springframework.web.bind.annotation.RequestBody; 8 | 9 | import com.neusoft.elmboot.mapper.ChatsMapper; 10 | import com.neusoft.elmboot.po.Chats; 11 | import com.neusoft.elmboot.service.ChatsService; 12 | 13 | @Service 14 | public class ChatsServiceImpl implements ChatsService{ 15 | 16 | @Autowired 17 | private ChatsMapper chatsMapper; 18 | 19 | @Override 20 | public List getChatsByUserId(String userId){ 21 | return chatsMapper.getChatsByUserId(userId); 22 | } 23 | @Override 24 | public int saveChats(Chats chats) { 25 | Chats chats2 = new Chats(); 26 | chats.setCurrentUserId(chats.getSenderUserId()); 27 | chats2.setCurrentUserId(chats.getReceiverUserId()); 28 | chats2.setSenderUserId(chats.getSenderUserId()); 29 | chats2.setReceiverUserId(chats.getReceiverUserId()); 30 | chats2.setMessage(chats.getMessage()); 31 | chatsMapper.saveChats(chats); 32 | chatsMapper.saveChats(chats2); 33 | return 2; 34 | } 35 | 36 | @Override 37 | public int removeChatsAllByCurrentUserId(Chats chats) { 38 | return chatsMapper.removeChatsAllByCurrentUserId(chats); 39 | } 40 | 41 | @Override 42 | public int removeChatsByTwoUserIdByMessage(Chats chats) { 43 | return chatsMapper.removeChatsByTwoUserIdByMessage(chats); 44 | } 45 | 46 | @Override 47 | public int recallChatsByTwoUserIdByMessage(Chats chats) { 48 | chats.setSenderUserId(chats.getCurrentUserId()); 49 | int count1=chatsMapper.recallChatsByTwoUserIdByMessage(chats); 50 | chats.setCurrentUserId(chats.getReceiverUserId()); 51 | int count2=chatsMapper.recallChatsByTwoUserIdByMessage(chats); 52 | return count1+count2; 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/impl/DeliveryAddressServiceImpl.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service.impl; 2 | import java.util.List; 3 | 4 | import org.springframework.beans.factory.annotation.Autowired; 5 | import org.springframework.stereotype.Service; 6 | import com.neusoft.elmboot.mapper.DeliveryAddressMapper; 7 | import com.neusoft.elmboot.po.DeliveryAddress; 8 | import com.neusoft.elmboot.service.DeliveryAddressService; 9 | 10 | @Service 11 | public class DeliveryAddressServiceImpl implements DeliveryAddressService{ 12 | 13 | @Autowired 14 | private DeliveryAddressMapper deliveryAddressMapper; 15 | 16 | @Override 17 | public List listDeliveryAddressByUserId(String userId) { 18 | return deliveryAddressMapper.listDeliveryAddressByUserId(userId); 19 | } 20 | 21 | @Override 22 | public DeliveryAddress getDeliveryAddressById(Integer daId) { 23 | return deliveryAddressMapper.getDeliveryAddressById(daId); 24 | } 25 | 26 | @Override 27 | public int saveDeliveryAddress(DeliveryAddress deliveryAddress) { 28 | return deliveryAddressMapper.saveDeliveryAddress(deliveryAddress); 29 | } 30 | @Override 31 | public int updateDeliveryAddress(DeliveryAddress deliveryAddress) { 32 | return deliveryAddressMapper.updateDeliveryAddress(deliveryAddress); 33 | } 34 | 35 | @Override 36 | public int removeDeliveryAddress(Integer daId) { 37 | return deliveryAddressMapper.removeDeliveryAddress(daId); 38 | } 39 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/impl/DiscoverSearchHistoryServiceImpl.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service.impl; 2 | 3 | import java.util.List; 4 | 5 | import org.springframework.beans.factory.annotation.Autowired; 6 | import org.springframework.stereotype.Service; 7 | 8 | import com.neusoft.elmboot.mapper.DiscoverSearchHistoryMapper; 9 | import com.neusoft.elmboot.po.DiscoverSearchHistory; 10 | import com.neusoft.elmboot.service.DiscoverSearchHistoryService; 11 | 12 | @Service 13 | public class DiscoverSearchHistoryServiceImpl implements DiscoverSearchHistoryService { 14 | 15 | @Autowired 16 | private DiscoverSearchHistoryMapper discoverSearchHistoryMapper; 17 | 18 | @Override 19 | public int saveSearchHistory(DiscoverSearchHistory history) { 20 | return discoverSearchHistoryMapper.saveSearchHistory(history); 21 | } 22 | 23 | @Override 24 | public List getSearchHistoryByUserId(String userId) { 25 | return discoverSearchHistoryMapper.getSearchHistoryByUserId(userId); 26 | } 27 | 28 | @Override 29 | public int updateCurrentPage(DiscoverSearchHistory history) { 30 | return discoverSearchHistoryMapper.updateCurrentPage(history); 31 | } 32 | 33 | @Override 34 | public int deleteSearchHistoryByUserId(String userId) { 35 | return discoverSearchHistoryMapper.deleteSearchHistoryByUserId(userId); 36 | } 37 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/impl/FavoriteServiceImpl.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service.impl; 2 | 3 | import java.util.List; 4 | 5 | import org.springframework.beans.factory.annotation.Autowired; 6 | import org.springframework.stereotype.Service; 7 | 8 | import com.neusoft.elmboot.mapper.FavoriteMapper; 9 | import com.neusoft.elmboot.po.Favorite; 10 | import com.neusoft.elmboot.service.FavoriteService; 11 | 12 | @Service 13 | public class FavoriteServiceImpl implements FavoriteService{ 14 | 15 | @Autowired 16 | private FavoriteMapper favoriteMapper; 17 | 18 | @Override 19 | public int saveFavoriteBusinessId(Favorite favorite) { 20 | return favoriteMapper.saveFavoriteBusinessId(favorite); 21 | } 22 | 23 | @Override 24 | public List listFavoriteByUserId(Favorite favorite) { 25 | return favoriteMapper.listFavoriteByUserId(favorite); 26 | } 27 | 28 | @Override 29 | public int removeFavoriteBusinessId(Favorite favorite) { 30 | return favoriteMapper.removeFavoriteBusinessId(favorite); 31 | } 32 | 33 | @Override 34 | public int getFavoriteCountByBusinessId(Favorite favorite) { 35 | return favoriteMapper.getFavoriteCountByBusinessId(favorite); 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/impl/FoodServiceImpl.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service.impl; 2 | import java.util.List; 3 | import org.springframework.beans.factory.annotation.Autowired; 4 | import org.springframework.stereotype.Service; 5 | import com.neusoft.elmboot.mapper.FoodMapper; 6 | import com.neusoft.elmboot.po.Food; 7 | import com.neusoft.elmboot.service.FoodService; 8 | @Service 9 | public class FoodServiceImpl implements FoodService{ 10 | 11 | @Autowired 12 | private FoodMapper foodMapper; 13 | 14 | @Override 15 | public List listFoodByBusinessId(Integer businessId) { 16 | return foodMapper.listFoodByBusinessId(businessId); 17 | } 18 | 19 | @Override 20 | public int addFood(Food food) { 21 | return foodMapper.addFood(food); 22 | } 23 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/impl/HistoryServiceImpl.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service.impl; 2 | 3 | import org.springframework.beans.factory.annotation.Autowired; 4 | import org.springframework.stereotype.Service; 5 | 6 | import com.neusoft.elmboot.mapper.HistoryMapper; 7 | import com.neusoft.elmboot.po.History; 8 | import com.neusoft.elmboot.service.HistoryService; 9 | 10 | @Service 11 | public class HistoryServiceImpl implements HistoryService{ 12 | 13 | @Autowired 14 | private HistoryMapper historyMapper; 15 | 16 | @Override 17 | public String getHistoryByUserId(History history) { 18 | String str=""; 19 | 20 | if(historyMapper.findHistoryByUserId(history)==0) { 21 | str+="无搜索历史"; 22 | } 23 | 24 | else { 25 | str+=historyMapper.getHistoryByUserId(history); 26 | } 27 | 28 | return str; 29 | } 30 | 31 | @Override 32 | public int saveHistory(History history) { 33 | //select这个用户之前有没有搜索记录 34 | //if有搜索记录,则update搜索记录 35 | //else没有搜索记录,则insert搜索记录 36 | if(historyMapper.judgeExist(history)==0) { 37 | historyMapper.saveHistory(history); 38 | } 39 | else { 40 | historyMapper.updateHistory(history); 41 | } 42 | 43 | return 1; 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/impl/LikesServiceImpl.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service.impl; 2 | 3 | import java.util.List; 4 | import java.util.Map; 5 | 6 | import org.springframework.beans.factory.annotation.Autowired; 7 | import org.springframework.stereotype.Service; 8 | 9 | import com.neusoft.elmboot.mapper.LikesMapper; 10 | import com.neusoft.elmboot.po.Likes; 11 | import com.neusoft.elmboot.service.LikesService; 12 | 13 | @Service 14 | public class LikesServiceImpl implements LikesService { 15 | 16 | @Autowired 17 | private LikesMapper likesMapper; 18 | 19 | @Override 20 | public int getLikesBybusinessId(Likes likes) { 21 | return likesMapper.getLikesBybusinessId(likes); 22 | } 23 | 24 | @Override 25 | public int saveLikes(Likes likes) { 26 | return likesMapper.saveLikes(likes); 27 | } 28 | 29 | @Override 30 | public int removeLikes(Likes likes) { 31 | return likesMapper.removeLikes(likes); 32 | } 33 | 34 | @Override 35 | public int getLikesByUserIdByBusinessId(Likes likes) { 36 | return likesMapper.getLikesByUserIdByBusinessId(likes); 37 | } 38 | 39 | @Override 40 | public List> getLikesByUserId(String userId) { 41 | return likesMapper.getLikesByUserId(userId); 42 | } 43 | } -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/service/impl/RemarkServiceImpl.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.service.impl; 2 | 3 | import java.util.List; 4 | import java.util.Map; 5 | 6 | import org.springframework.beans.factory.annotation.Autowired; 7 | import org.springframework.stereotype.Service; 8 | 9 | import com.neusoft.elmboot.mapper.RemarkMapper; 10 | import com.neusoft.elmboot.po.Remark; 11 | import com.neusoft.elmboot.service.RemarkService; 12 | import com.neusoft.elmboot.util.CommonUtil; 13 | 14 | @Service 15 | public class RemarkServiceImpl implements RemarkService{ 16 | 17 | @Autowired 18 | private RemarkMapper remarkMapper; 19 | 20 | @Override 21 | public List listRemarksByBusinessId(Integer businessId) { 22 | 23 | return remarkMapper.listRemarksByBusinessId(businessId); 24 | } 25 | 26 | @Override 27 | public int saveRemarks(Remark remark) { 28 | remark.setRemarkDate(CommonUtil.getCurrentDate()); 29 | //返回值是评论编号 30 | return remarkMapper.saveRemarks(remark); 31 | } 32 | 33 | @Override 34 | public int removeOneRemark(Remark remark) { 35 | return remarkMapper.removeOneRemark(remark); 36 | } 37 | 38 | 39 | @Override 40 | public List removeAllRemarksByUserId(String userId) { 41 | return remarkMapper.removeAllRemarksByUserId(userId); 42 | } 43 | 44 | @Override 45 | public int getRemarkCountByBusinessId(Integer businessId) { 46 | return remarkMapper.getRemarkCountByBusinessId(businessId); 47 | } 48 | 49 | @Override 50 | public List> getCommentsByUserId(String userId) { 51 | return remarkMapper.getCommentsByUserId(userId); 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/util/CommonUtil.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot.util; 2 | 3 | import java.text.SimpleDateFormat; 4 | import java.util.Calendar; 5 | 6 | public class CommonUtil { 7 | public static String getCurrentDate1() { 8 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); 9 | Calendar calendar = Calendar.getInstance(); 10 | return sdf.format(calendar.getTime()); 11 | } 12 | 13 | public static String getCurrentDate() { 14 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH-mm-ss"); 15 | Calendar calendar = Calendar.getInstance(); 16 | return sdf.format(calendar.getTime()); 17 | } 18 | 19 | public static String getCurrentDate2() { 20 | //获取下一周周末的时间 21 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); 22 | Calendar calendar = Calendar.getInstance(); 23 | calendar.add(Calendar.DATE, 7); 24 | //将时间近似到下一天0点 25 | calendar.set(Calendar.HOUR_OF_DAY, 23); 26 | calendar.set(Calendar.MINUTE, 59); 27 | calendar.set(Calendar.SECOND, 59); 28 | return sdf.format(calendar.getTime()); 29 | } 30 | 31 | public static int compareDate(String expiredTime, String currentDate) {//比较时间 32 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); 33 | try { 34 | if (sdf.parse(expiredTime).getTime() > sdf.parse(currentDate).getTime()) { 35 | return 1; 36 | } else if (sdf.parse(expiredTime).getTime() < sdf.parse(currentDate).getTime()) { 37 | return -1; 38 | } else { 39 | return 0; 40 | } 41 | } catch (Exception e) { 42 | e.printStackTrace(); 43 | } 44 | return 0; 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /src/elmboot/src/main/java/com/neusoft/elmboot/util/JwtUtil.java: -------------------------------------------------------------------------------- 1 | //package com.neusoft.elmboot.util; 2 | // 3 | //import io.jsonwebtoken.*; 4 | //import io.jsonwebtoken.security.Keys; 5 | //import org.springframework.beans.factory.annotation.Value; 6 | //import org.springframework.stereotype.Component; 7 | // 8 | //import javax.crypto.SecretKey; 9 | //import java.util.Date; 10 | // 11 | //@Component 12 | //public class JwtUtil { 13 | // 14 | // @Value("${jwt.secret:defaultSecretKey12345678901234567890}") 15 | // private String secret; 16 | // 17 | // @Value("${jwt.expiration:86400000}") // 24小时 18 | // private long expiration; 19 | // 20 | // private SecretKey getSigningKey() { 21 | // return Keys.hmacShaKeyFor(secret.getBytes()); 22 | // } 23 | // 24 | // public String generateToken(String userId) { 25 | // Date now = new Date(); 26 | // Date expiryDate = new Date(now.getTime() + expiration); 27 | // 28 | // return Jwts.builder() 29 | // .setSubject(userId) 30 | // .setIssuedAt(now) 31 | // .setExpiration(expiryDate) 32 | // .signWith(getSigningKey()) 33 | // .compact(); 34 | // } 35 | // 36 | // public String getUserIdFromToken(String token) { 37 | // Claims claims = Jwts.parserBuilder() 38 | // .setSigningKey(getSigningKey()) 39 | // .build() 40 | // .parseClaimsJws(token) 41 | // .getBody(); 42 | // 43 | // return claims.getSubject(); 44 | // } 45 | // 46 | // public boolean validateToken(String token) { 47 | // try { 48 | // Jwts.parserBuilder() 49 | // .setSigningKey(getSigningKey()) 50 | // .build() 51 | // .parseClaimsJws(token); 52 | // return true; 53 | // } catch (JwtException e) { 54 | // return false; 55 | // } 56 | // } 57 | //} -------------------------------------------------------------------------------- /src/elmboot/src/main/resources/application.yml: -------------------------------------------------------------------------------- 1 | server: 2 | port: 8080 #端口(默认也是8080) 3 | servlet: 4 | context-path: / 5 | 6 | logging: 7 | level: 8 | org: 9 | springframework: debug #输出的日志文件更详细,方便今后出问题了做调试 10 | com: 11 | neusoft: 12 | elmboot: 13 | mapper: debug #将mapper接口执行的所有类型的日志都以dubug的形式输出出来 14 | 15 | #数据库连接需要的东西 16 | spring: 17 | datasource: 18 | driver-class-name: com.mysql.cj.jdbc.Driver 19 | url: jdbc:mysql://localhost:3306/elm?characterEncoding=utf-8&serverTimezone=UTC&useSSL=false 20 | # url: jdbc:mysql://localhost:3306/elm?characterEncoding=utf-8&serverTimezone=UTC&useSSL=false 21 | username: root 22 | password: 123456 23 | 24 | #配置mybatis的一些文件 25 | mybatis: 26 | mapper-locations: classpath:mapper/*.xml 27 | type-aliases-package: com.neusoft.elmboot.po #扫描整个po包,给实体类设置别名 28 | configuration: 29 | map-underscore-to-camel-case: true 30 | -------------------------------------------------------------------------------- /src/elmboot/src/main/resources/mapper/CartMapper.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 13 | 16 | 17 | 18 | 28 | 29 | 30 | delete from cart 31 | 32 | userId=#{userId} 33 | 34 | and businessId=#{businessId} 35 | 36 | 37 | and foodId=#{foodId} 38 | 39 | 40 | 41 | -------------------------------------------------------------------------------- /src/elmboot/src/main/resources/mapper/OrderDetailetMapper.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | insert into orderDetailet(orderId,foodId,quantity,priceAtThatTime,foodName) values 7 | 8 | (#{od.orderId},#{od.foodId},#{od.quantity},#{od.priceAtThatTime},#{od.foodName}) 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 21 | 22 | 23 | 27 | -------------------------------------------------------------------------------- /src/elmboot/src/main/resources/mapper/OrdersMapper.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 16 | 19 | 20 | 23 | 24 | 27 | -------------------------------------------------------------------------------- /src/elmboot/src/test/java/com/neusoft/elmboot/ElmbootApplicationTests.java: -------------------------------------------------------------------------------- 1 | package com.neusoft.elmboot; 2 | 3 | import org.junit.jupiter.api.Test; 4 | import org.springframework.boot.test.context.SpringBootTest; 5 | 6 | @SpringBootTest 7 | class ElmbootApplicationTests { 8 | 9 | @Test 10 | void contextLoads() { 11 | } 12 | 13 | } 14 | -------------------------------------------------------------------------------- /src/elmclient/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules 3 | /dist 4 | 5 | 6 | # local env files 7 | .env.local 8 | .env.*.local 9 | 10 | # Log files 11 | npm-debug.log* 12 | yarn-debug.log* 13 | yarn-error.log* 14 | pnpm-debug.log* 15 | 16 | # Editor directories and files 17 | .idea 18 | .vscode 19 | *.suo 20 | *.ntvs* 21 | *.njsproj 22 | *.sln 23 | *.sw? 24 | -------------------------------------------------------------------------------- /src/elmclient/README.md: -------------------------------------------------------------------------------- 1 | # elmclient 2 | 3 | ## Project setup 4 | ``` 5 | npm install 6 | ``` 7 | 8 | ### Compiles and hot-reloads for development 9 | ``` 10 | npm run serve 11 | ``` 12 | 13 | ### Compiles and minifies for production 14 | ``` 15 | npm run build 16 | ``` 17 | 18 | ### Customize configuration 19 | See [Configuration Reference](https://cli.vuejs.org/config/). 20 | -------------------------------------------------------------------------------- /src/elmclient/babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [ 3 | '@vue/cli-plugin-babel/preset' 4 | ] 5 | } 6 | -------------------------------------------------------------------------------- /src/elmclient/jsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "es5", 4 | "module": "esnext", 5 | "baseUrl": "./", 6 | "moduleResolution": "node", 7 | "paths": { 8 | "@/*": [ 9 | "src/*" 10 | ] 11 | }, 12 | "lib": [ 13 | "esnext", 14 | "dom", 15 | "dom.iterable", 16 | "scripthost" 17 | ] 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /src/elmclient/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "elmclient", 3 | "version": "0.1.0", 4 | "private": true, 5 | "scripts": { 6 | "serve": "vue-cli-service serve", 7 | "build": "vue-cli-service build" 8 | }, 9 | "dependencies": { 10 | "@element-plus/icons-vue": "^2.3.1", 11 | "axios": "^1.7.7", 12 | "cnpm": "^9.4.0", 13 | "core-js": "^3.8.3", 14 | "element-plus": "^2.9.6", 15 | "font-awesome": "^4.7.0", 16 | "install": "^0.13.0", 17 | "qs": "^6.13.0", 18 | "vue": "^3.2.13", 19 | "vue-router": "^4.4.3" 20 | }, 21 | "devDependencies": { 22 | "@vue/cli-plugin-babel": "~5.0.0", 23 | "@vue/cli-plugin-router": "~5.0.0", 24 | "@vue/cli-service": "~5.0.0" 25 | }, 26 | "browserslist": [ 27 | "> 1%", 28 | "last 2 versions", 29 | "not dead", 30 | "not ie 11" 31 | ] 32 | } 33 | -------------------------------------------------------------------------------- /src/elmclient/public/R-C.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/public/R-C.png -------------------------------------------------------------------------------- /src/elmclient/public/baozi.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/public/baozi.jpg -------------------------------------------------------------------------------- /src/elmclient/public/chicken.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/public/chicken.jpg -------------------------------------------------------------------------------- /src/elmclient/public/duck.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/public/duck.jpg -------------------------------------------------------------------------------- /src/elmclient/public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/public/favicon.ico -------------------------------------------------------------------------------- /src/elmclient/public/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | <%= htmlWebpackPlugin.options.title %> 9 | 10 | 11 | 14 |
15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /src/elmclient/public/jiaozi.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/public/jiaozi.jpg -------------------------------------------------------------------------------- /src/elmclient/public/meat.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/public/meat.jpg -------------------------------------------------------------------------------- /src/elmclient/public/paigu.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/public/paigu.jpg -------------------------------------------------------------------------------- /src/elmclient/public/shumai.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/public/shumai.jpg -------------------------------------------------------------------------------- /src/elmclient/public/tofu.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/public/tofu.jpg -------------------------------------------------------------------------------- /src/elmclient/public/yu.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/public/yu.jpg -------------------------------------------------------------------------------- /src/elmclient/public/下载.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/public/下载.jpg -------------------------------------------------------------------------------- /src/elmclient/src/App.vue: -------------------------------------------------------------------------------- 1 | 12 | 45 | -------------------------------------------------------------------------------- /src/elmclient/src/assets/R-C.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/R-C.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/alipay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/alipay.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/dcfl01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/dcfl01.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/dcfl02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/dcfl02.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/dcfl03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/dcfl03.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/dcfl04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/dcfl04.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/dcfl05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/dcfl05.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/dcfl06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/dcfl06.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/dcfl07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/dcfl07.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/dcfl08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/dcfl08.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/dcfl09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/dcfl09.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/dcfl10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/dcfl10.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/index_banner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/index_banner.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/logo.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/readme.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/readme.txt -------------------------------------------------------------------------------- /src/elmclient/src/assets/sj01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sj01.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sj02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sj02.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sj03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sj03.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sj04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sj04.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sj05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sj05.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sj06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sj06.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sj07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sj07.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sj08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sj08.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sj09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sj09.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sp01.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sp01.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sp02.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sp02.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sp03.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sp03.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sp04.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sp04.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sp05.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sp05.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sp06.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sp06.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sp07.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sp07.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sp08.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sp08.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sp09.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sp09.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sp10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sp10.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sp11.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sp11.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/sp12.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/sp12.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/super_member.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/super_member.png -------------------------------------------------------------------------------- /src/elmclient/src/assets/wechat.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/JHM2004/tju_elm_project/ea1f0fb5474301294818c10c562fccac80e8a6ad/src/elmclient/src/assets/wechat.png -------------------------------------------------------------------------------- /src/elmclient/src/common.js: -------------------------------------------------------------------------------- 1 | //获取当前时间(XXXX-XX-XX) 2 | export function getCurDate() { 3 | var now = new Date(); 4 | var year = now.getFullYear(); 5 | var month = now.getMonth() + 1; 6 | var day = now.getDate(); 7 | month = month < 10 ? "0" + month : month; 8 | day = day < 10 ? "0" + day : day; 9 | return year + "-" + month + "-" + day; 10 | } 11 | 12 | //向sessionStorage中存储一个JSON对象 13 | export function setSessionStorage(keyStr, value) { 14 | sessionStorage.setItem(keyStr, JSON.stringify(value)); 15 | } 16 | 17 | //从sessionStorage中获取一个JSON对象(取不到时返回null) 18 | export function getSessionStorage(keyStr) { 19 | var str = sessionStorage.getItem(keyStr); 20 | if (str == '' || str == null || str == 'null' || str == undefined) { 21 | return null; 22 | } else { 23 | return JSON.parse(str); 24 | } 25 | } 26 | 27 | //从sessionStorage中移除一个JSON对象 28 | export function removeSessionStorage(keyStr) { 29 | sessionStorage.removeItem(keyStr); 30 | } 31 | 32 | //向localStorage中存储一个JSON对象 33 | export function setLocalStorage(keyStr, value) { 34 | localStorage.setItem(keyStr, JSON.stringify(value)); 35 | } 36 | 37 | //从localStorage中获取一个JSON对象(取不到时返回null) 38 | export function getLocalStorage(keyStr) { 39 | var str = localStorage.getItem(keyStr); 40 | if (str == '' || str == null || str == 'null' || str == undefined) { 41 | return null; 42 | } else { 43 | return JSON.parse(str); 44 | } 45 | } 46 | 47 | //从localStorage中移除一个JSON对象 48 | export function removeLocalStorage(keyStr) { 49 | localStorage.removeItem(keyStr); 50 | } 51 | -------------------------------------------------------------------------------- /src/elmclient/src/components/BackButton.vue: -------------------------------------------------------------------------------- 1 | 6 | 7 | 30 | 31 | 54 | -------------------------------------------------------------------------------- /src/elmclient/src/components/Footer.vue: -------------------------------------------------------------------------------- 1 | 21 | 22 | 51 | 52 | 88 | -------------------------------------------------------------------------------- /src/elmclient/src/components/HelloWorld.vue: -------------------------------------------------------------------------------- 1 | 32 | 33 | 41 | 42 | 43 | 59 | -------------------------------------------------------------------------------- /src/elmclient/src/utils/toast.js: -------------------------------------------------------------------------------- 1 | import { createVNode, render } from 'vue'; 2 | import Toast from '../components/Toast.vue'; 3 | 4 | let toastContainer = null; 5 | 6 | const createToast = (options) => { 7 | // 创建容器 8 | if (!toastContainer) { 9 | toastContainer = document.createElement('div'); 10 | toastContainer.className = 'toast-container'; 11 | document.body.appendChild(toastContainer); 12 | } 13 | 14 | // 创建 Toast 实例 15 | const vnode = createVNode(Toast, { 16 | ...options, 17 | onClose: () => { 18 | render(null, toastContainer); 19 | } 20 | }); 21 | 22 | // 渲染 Toast 23 | render(vnode, toastContainer); 24 | }; 25 | 26 | // 导出不同类型的提示方法 27 | export const toast = { 28 | info(message, duration = 2000) { 29 | createToast({ message, type: 'info', duration }); 30 | }, 31 | success(message, duration = 2000) { 32 | createToast({ message, type: 'success', duration }); 33 | }, 34 | error(message, duration = 2000) { 35 | createToast({ message, type: 'error', duration }); 36 | }, 37 | warning(message, duration = 2000) { 38 | createToast({ message, type: 'warning', duration }); 39 | } 40 | }; -------------------------------------------------------------------------------- /src/elmclient/src/views/AboutView.vue: -------------------------------------------------------------------------------- 1 | 6 | -------------------------------------------------------------------------------- /src/elmclient/src/views/HomeView.vue: -------------------------------------------------------------------------------- 1 | 7 | 8 | 19 | -------------------------------------------------------------------------------- /src/elmclient/src/views/LChoose.vue: -------------------------------------------------------------------------------- 1 | 13 | 14 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /src/elmclient/src/views/RChoose.vue: -------------------------------------------------------------------------------- 1 | 13 | 14 | 39 | 40 | 41 | 77 | -------------------------------------------------------------------------------- /src/elmclient/vue.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | devServer: { 3 | port: 8080 4 | } 5 | } 6 | --------------------------------------------------------------------------------