Get the App
SLTechnology News&Howtos  ›  Development  › 

How to realize the Health Management Mini Program based on Java SSM

Shulou Source: shulou.com Published: 2022-06-02 13:30:07 09月23日 Update

This article mainly shows you "how to achieve Java SSM-based health management Mini Program", the content is easy to understand, clear, hope to help you solve your doubts, now let the editor lead you to study and learn "how to achieve Java SSM-based health management Mini Program" this article.

A brief introduction to the system

Development language: Java

Frame: ssm

JDK version: JDK1.8

Server: tomcat7

Database: mysql 5.7 (must be version 5.7)

Database tool: Navicat11

Development software: eclipse/myeclipse/idea

Maven package: Maven3.3.9

Browser: Google browser

Second, the main functions of the system

(1) user management. It mainly realizes the user management function of health management Mini Program.

(2) sign in. The mini program side can log in and register.

(3) Health goal. Complete the setting of health goals

(4) Mall. Buy health-related goods online.

(5) check personal information. View all kinds of information.

(6) background management. Manage all kinds of information on Mini Program.

III. Interface demonstration of the system

Fourth, the core code shows @ RestController@RequestMapping ("/ address") public class AddressController {@ Autowired private AddressService addressService / * backend list * / @ RequestMapping ("/ page") public R page (@ RequestParam Map params,AddressEntity address, HttpServletRequest request) {if (! request.getSession () .getAttribute ("role") .toString () .equals ("administrator") {address.setUserid ((Long) request.getSession (). GetAttribute ("userId"));} EntityWrapper ew = new EntityWrapper () PageUtils page = addressService.queryPage (params, MPUtil.sort (MPUtil.between (MPUtil.likeOrEq (ew, address), params), params); return R.ok () .put ("data", page) } / * Front end list * / @ RequestMapping ("/ list") public R list (@ RequestParam Map params,AddressEntity address, HttpServletRequest request) {if (! request.getSession (). GetAttribute ("role"). ToString (). Equals ("administrator") {address.setUserid ((Long) request.getSession (). GetAttribute ("userId"));} EntityWrapper ew = new EntityWrapper () PageUtils page = addressService.queryPage (params, MPUtil.sort (MPUtil.between (MPUtil.likeOrEq (ew, address), params), params); return R.ok (). Put ("data", page);} / * list * / @ RequestMapping ("/ lists") public R list (AddressEntity address) {EntityWrapper ew = new EntityWrapper (); ew.allEq (MPUtil.allEQMapPre (address, "address")) Return R.ok () .put ("data", addressService.selectListView (ew));} / * query * / @ RequestMapping ("/ query") public R query (AddressEntity address) {EntityWrapper

< AddressEntity>

Ew = new EntityWrapper

< AddressEntity>

< OrdersEntity>

Ew = new EntityWrapper

< OrdersEntity>

(); ew.allEq (MPUtil.allEQMapPre (orders, "orders")); OrdersView ordersView = ordersService.selectView (ew); return R.ok ("query order success"). Put ("data", ordersView);} / * * backend details * / @ RequestMapping ("/ info/ {id}") public R info (@ PathVariable ("id") Long id) {OrdersEntity orders = ordersService.selectById (id) Return R.ok () .put ("data", orders);} / * * frontend details * / @ RequestMapping ("/ detail/ {id}") public R detail (@ PathVariable ("id") Long id) {OrdersEntity orders = ordersService.selectById (id); return R.ok () .put ("data", orders) } / * the backend saves * / @ RequestMapping ("/ save") public R save (@ RequestBody OrdersEntity orders, HttpServletRequest request) {orders.setId (new Date (). GetTime () + new Double (Math.floor (Math.random () * 1000). LongValue ()); / / ValidatorUtils.validateEntity (orders); orders.setUserid ((Long) request.getSession (). GetAttribute ("userId")); ordersService.insert (orders) Return R.ok ();} these are all the contents of the article "how to implement Java SSM-based Health Management Mini Program". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!

Tags: Management Health Program Information Front end Health Management query content Administrator Article system details Login success function address data Database browser version Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno MySQL Linux Xiaomi Docker macOS