水滴 后端服务
图片上传服务端文档 简单介绍:https://help.aliyun.com/document_detail/31926.html Nodejs 代码:https://help.aliyun.com/document_detail/322691.htm?spm=a2c4g.11186623.0.0.1607566aUI6l0V#task-2121074 发送短信的阿里云文档 https://dysms.console.aliyun.com/quickstart
接口规范 返回数据的接口规范:
{ code: 200, // 10001 10002 data: [], // {} message: 'error', page: { start: 0, length: 20, total: 100, }, debug: '', key: '', } 使用 JWT 保存登录状态 相关文档:https://docs.nestjs.com/security/authentication
pnpm i @nestjs/jwt @nestjs/passport passport-jwt passport -S 注册 JwtModule 添加自定义 JWT 策略 创建 Guard,引入 JWT 策略 修改登录接口 PC 端页面获取 JWT 使用 plop 生成模版代码 文档:https://plopjs.com/documentation/ hbs:https://handlebarsjs.com/guide/#what-is-handlebars
pnpm i plop -D 配置 plopfile.js 文件 npx plop 按照商品的门店距离做排序 createQueryBuilder 自定义 SQL 查询 ST_Distance 计算两个地理对象之间的最短距离 ST_GeomFromText 把文本表示形式转换为地理对象(如点、线、多边形等) getRawAndEntities 获取自定义的查询结果 距离计算的两个扩展问题 坐标转换问题: https://github.com/wandergis/coordtransform 性能优化的问题:(先缩小范围再去排序)geohash https://github.com/sunng87/node-geohash 微信公众号网页授权文档 网页授权:https://developers.weixin.qq.com/doc/offiaccount/OA_Web_Apps/Wechat_webpage_authorization.html 查看微信接口权限:https://mp.weixin.qq.com/advanced/advanced?action=table&token=360474277&lang=zh_CN 配置微信允许的域名:https://mp.weixin.qq.com/cgi-bin/settingpage?t=setting/function&action=function&token=360474277&lang=zh_CN 微信支付文档 接入文档:https://pay.weixin.qq.com/wiki/doc/apiv3/open/pay/chapter2_1.shtml API 文档: https://pay.weixin.qq.com/wiki/doc/apiv3/open/pay/chapter2_4.shtml 第三方微信支付 SDK:https://github.com/klover2/wechatpay-node-v3-ts 线上体验地址 http://water-drop.yondu.vip
Nest framework TypeScript starter repository.
$ npm install
# development
$ npm run start
# watch mode
$ npm run start:dev
# production mode
$ npm run start:prod
# unit tests
$ npm run test
# e2e tests
$ npm run test:e2e
# test coverage
$ npm run test:cov
Nest is an MIT-licensed open source project. It can grow thanks to the sponsors and support by the amazing backers. If you'd like to join them, please read more here.
Nest is MIT licensed.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。