新架构开发
1、 码云将我添加进入开发者名单;
2、 通过IDEA克隆DeviceManageSystem的branch分支,地址:https://gitee.com/lx_ytw/DeviceManageSystem.git
- DeviceManageSystem的branch分支内含有3个包:backend->moleculer-base(后端,后面简称moleculer-base)、dmsWeb(前端)、my-code-generation(代码生成器-表单)。但此时看不见。解决方法:
- 输入git checkout –b branch ,然后pull。。。。。。结果失败;
- 通过Version Control—log 查看最新的版本,点击右键选择Reset Current Branch here…
(在此处重置当前分支),选择HARD,成功。
3、 由于网速较慢,分别cd(进入)各个包中输入npm config set registry https://registry.npm.taobao.org (从淘宝获取node_modules)。然后npm install。
4、 将各个包的node_modules点击右键选Mark Directory as(标记),先标记为not exclude ,再改回exclued(作用:搜索时,IntelliJ IDEA不会查找排除的文件夹等, 使排除内容“不太重要”的文件夹可以提高IDE性能----不卡)。
5、 在moleculer-base包中新建public文件夹,然则在此文件夹下新建codes和uploads文件夹。
6、 将my-code-generation文件夹下package.Json文件中“start”:”ng start”改"start": “ng serve --port=4201”。
7、 moleculer-base(后端)运行npm run dev ;dmsWeb(前端)和my-code-generation(代码生成器-表单)运行npm run start .