下载地址:Node.js+MySQL开发的B2C商城系统源码+数据库(微信小程序端+服务端)
本项目需要配合微信小程序端使用,nideshop-mini-program
克隆项目到本地
创建数据库nideshop并导入项目根目录下的nideshop.sql
CREATE SCHEMA `nideshop` DEFAULT CHARACTER SET utf8mb4 ;
注意数据库字符编码为utf8mb4
const mysql = require('think-model-mysql');module.exports = {handle: mysql,database: 'nideshop',prefix: 'nideshop_',encoding: 'utf8mb4',host: '127.0.0.1',port: '3306',user: 'root',password: '你的密码',dateStrings: true
};
// default config
module.exports = {default_module: 'api',weixin: {appid: '', // 小程序 appidsecret: '', // 小程序密钥mch_id: '', // 商户帐号IDpartner_key: '', // 微信支付密钥notify_url: '' // 微信异步通知,例:https://www.nideshop.com/api/pay/notify}
};
npm install
npm start
访问http://127.0.0.1:8360/
├─config
├─lib
│ └─wxParse
├─pages
│ ├─auth
│ │ ├─login
│ │ ├─register
│ │ └─reset
│ ├─brand
│ ├─brandDetail
│ ├─cart
│ ├─catalog
│ ├─category
│ ├─comment
│ ├─goods
│ ├─hotGoods
│ ├─index
│ ├─logs
│ ├─newGoods
│ ├─pay
│ ├─search
│ ├─shopping
│ │ ├─address
│ │ ├─addressAdd
│ │ └─checkout
│ ├─topic
│ ├─topicDetail
│ └─ucenter
│ ├─address
│ ├─addressAdd
│ ├─collect
│ ├─coupon
│ ├─feedback
│ ├─footprint
│ ├─index
│ ├─order
│ └─orderDetail
├─static
│ └─images
└─utils
下载地址:Node.js+MySQL开发的B2C商城系统源码+数据库(微信小程序端+服务端)