# day12_16_shop **Repository Path**: bwdb/day12_16_shop ## Basic Information - **Project Name**: day12_16_shop - **Description**: No description available - **Primary Language**: Go - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2024-12-16 - **Last Updated**: 2024-12-16 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # 1专高3第一周周考 # ### 构建gin框架下载包 ### go get github.com/gin-gonic/gin go get gorm.io/gorm go get gorm.io/driver/mysql go get github.com/sfp13/viper go get github.com/go-redis/redis/v8 go get github.com/golang-jwt/jwt/v4 1.用户注册功能 1.使用模型绑定验证参数格式 2.使用md5加密密码 3.将信息存入数据库 2.用户登录功能 1.判断用户是否存在 2.判断用户密码输入是否正确 3.通过登录后返回的id生成token 3.闲置商品发布功能 1.使用模型绑定验证参数 2.发布成功返回id 4.闲置商品展示功能 1.可以通过品牌,容量,或者新旧成功进行筛选 2.限制每页条数实现分页 3.判断商品状态 4.不展示售罄的商品 5.闲置商品购买功能 1.发布者不能购买自己发布的商品 2.商品购买后改变状态为售罄 备注:项目目录实现工程化目录,使用go版本为1.23.3