Commit ec090b08 by 罗志长

doc

parent 4149da67
This diff could not be displayed because it is too large.
INSERT INTO `saas_user`(`id`, `username`, `account`, `password`, `mobile`, `status`, `remark`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`) VALUES ('1', 'root', 'root', 'c7f8527fa84730686fa82f861ac389d705d1018c7dc4e5721b5b7655', '1', '1', NULL, '2022-05-17 14:50:24', '2022-05-17 14:50:28', '0', '', '');
INSERT INTO `plat_alarm_config`(`id`, `alarm_type`, `status`, `org_id`, `city_org_id`, `district_org_id`, `street_org_id`, `org_path`, `rule_config`, `content`, `notify_channel`, `notify_relation`, `notify_way`, `notify_user`, `description`, `create_by`, `create_date`, `update_by`, `update_date`, `del_flag`, `tenant_id`, `content_audit`) VALUES ('1699667670087065604', '1', '1', '1701542574740770817', NULL, NULL, NULL, NULL, '{}', '[#长者姓名]在[#房间名]跌倒,请及时处理!', '', '1', '1', NULL, NULL, 'platAdmin02', '2023-09-07 14:15:26', '测试clt', '2023-09-12 17:09:17', '0', '0', NULL);
INSERT INTO `plat_alarm_config`(`id`, `alarm_type`, `status`, `org_id`, `city_org_id`, `district_org_id`, `street_org_id`, `org_path`, `rule_config`, `content`, `notify_channel`, `notify_relation`, `notify_way`, `notify_user`, `description`, `create_by`, `create_date`, `update_by`, `update_date`, `del_flag`, `tenant_id`, `content_audit`) VALUES ('16996678722776842251', '2', '1', '1701542574740770817', NULL, NULL, NULL, NULL, '{\"respiratoryRateStart\":\"10\",\"respiratoryRateEnd\":\"120\",\"duration\":\"5\"}', '[#长者姓名][#呼吸状态],请及时处理!', '', '1', '1', NULL, NULL, 'platAdmin02', '2023-09-07 14:16:14', 'platAdmin02', '2023-09-07 14:16:14', '0', '0', NULL);
INSERT INTO `plat_alarm_config`(`id`, `alarm_type`, `status`, `org_id`, `city_org_id`, `district_org_id`, `street_org_id`, `org_path`, `rule_config`, `content`, `notify_channel`, `notify_relation`, `notify_way`, `notify_user`, `description`, `create_by`, `create_date`, `update_by`, `update_date`, `del_flag`, `tenant_id`, `content_audit`) VALUES ('16996680489417687051', '3', '1', '1701542574740770817', NULL, NULL, NULL, NULL, '{\"heartRateStart\":\"60\",\"heartRateEnd\":\"90\",\"duration\":\"5\"}', '[#长者姓名][#心率状态],请及时处理!', '', '1', '1', NULL, NULL, 'platAdmin02', '2023-09-07 14:16:56', 'platAdmin02', '2023-09-07 14:16:56', '0', '0', NULL);
INSERT INTO `plat_alarm_config`(`id`, `alarm_type`, `status`, `org_id`, `city_org_id`, `district_org_id`, `street_org_id`, `org_path`, `rule_config`, `content`, `notify_channel`, `notify_relation`, `notify_way`, `notify_user`, `description`, `create_by`, `create_date`, `update_by`, `update_date`, `del_flag`, `tenant_id`, `content_audit`) VALUES ('16996682046846648331', '4', '1', '1701542574740770817', NULL, NULL, NULL, NULL, '{\"averageDuration\":\"5\"}', '[#长者姓名]在[#上级空间名-房间名]内存在行为异常,请及时处理!', '', '1', '1', NULL, NULL, 'platAdmin02', '2023-09-07 14:17:33', 'platAdmin02', '2023-09-07 14:17:33', '0', '0', NULL);
INSERT INTO `sys_config_category`(`id`, `tenant_id`, `code`, `name`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('2', '0', 'elder.blood', '长者血型', '2023-07-11 10:55:06', '2023-07-11 10:55:08', '0', NULL, NULL, NULL);
INSERT INTO `sys_config_category`(`id`, `tenant_id`, `code`, `name`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('3', '0', 'elder.socialRelation', '长者社会关系', '2023-07-11 10:55:06', '2023-07-11 10:55:08', '0', NULL, NULL, NULL);
INSERT INTO `sys_config_category`(`id`, `tenant_id`, `code`, `name`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('4', '0', 'elder.elderType', '长者老人类型', '2023-07-11 10:55:06', '2023-07-11 10:55:08', '0', NULL, NULL, NULL);
INSERT INTO `sys_config_category`(`id`, `tenant_id`, `code`, `name`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('5', '0', 'elder.illness', '长者疾病状况', '2023-07-11 10:55:06', '2023-07-11 10:55:08', '0', NULL, NULL, NULL);
INSERT INTO `sys_config_category`(`id`, `tenant_id`, `code`, `name`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('6', '0', 'elder.foodProhibition', '长者饮食禁忌', '2023-07-11 10:55:06', '2023-07-11 10:55:08', '0', NULL, NULL, NULL);
INSERT INTO `sys_config_category`(`id`, `tenant_id`, `code`, `name`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('7', '0', 'elder.hobbies', '长者兴趣爱好', '2023-07-11 10:55:06', '2023-07-11 10:55:08', '0', NULL, NULL, NULL);
INSERT INTO `sys_config_category`(`id`, `tenant_id`, `code`, `name`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('8', '0', 'elder.education', '长者文化程度', '2023-07-11 10:55:06', '2023-07-11 10:55:08', '0', NULL, NULL, NULL);
INSERT INTO `sys_config_category`(`id`, `tenant_id`, `code`, `name`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('9', '0', 'elder.belief', '长者宗教信仰', '2023-07-11 10:55:06', '2023-07-11 10:55:08', '0', NULL, NULL, NULL);
INSERT INTO `sys_config`(`id`, `tenant_id`, `code`, `name`, `value`, `sort`, `description`, `category_id`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('1', '0', 'elder.certificateType.idCard', '身份证', '1', 0, '', '1', '2023-07-11 10:57:57', '2023-07-11 10:58:02', '0', NULL, NULL, NULL);
INSERT INTO `sys_config`(`id`, `tenant_id`, `code`, `name`, `value`, `sort`, `description`, `category_id`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('10', '0', 'elder.income.low', '低收入', '1', 0, '', '10', '2023-07-11 10:57:57', '2023-07-11 10:58:02', '0', NULL, NULL, NULL);
INSERT INTO `sys_config`(`id`, `tenant_id`, `code`, `name`, `value`, `sort`, `description`, `category_id`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('2', '0', 'elder.blood.a', 'A', '1', 0, '', '2', '2023-07-11 10:57:57', '2023-07-11 10:58:02', '0', NULL, NULL, NULL);
INSERT INTO `sys_config`(`id`, `tenant_id`, `code`, `name`, `value`, `sort`, `description`, `category_id`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('20', '0', 'elder.marriage.no', '未婚', '0', 0, '', '11', '2023-07-11 10:57:57', '2023-07-11 10:58:02', '0', NULL, NULL, NULL);
INSERT INTO `sys_config`(`id`, `tenant_id`, `code`, `name`, `value`, `sort`, `description`, `category_id`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('21', '0', 'elder.marriage.yes', '已婚', '1', 0, '', '11', '2023-07-11 10:57:57', '2023-07-11 10:58:02', '0', NULL, NULL, NULL);
INSERT INTO `sys_config`(`id`, `tenant_id`, `code`, `name`, `value`, `sort`, `description`, `category_id`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('3', '0', 'elder.socialRelation.children', '子女', '1', 0, '', '3', '2023-07-11 10:57:57', '2023-07-11 10:58:02', '0', NULL, NULL, NULL);
INSERT INTO `sys_config`(`id`, `tenant_id`, `code`, `name`, `value`, `sort`, `description`, `category_id`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('4', '0', 'elder.elderType.single', '失独老人', '1', 0, '', '4', '2023-07-11 10:57:57', '2023-07-11 10:58:02', '0', NULL, NULL, NULL);
INSERT INTO `sys_config`(`id`, `tenant_id`, `code`, `name`, `value`, `sort`, `description`, `category_id`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('5', '0', 'elder.illness.heartDisease', '心脏病', '1', 0, '', '5', '2023-07-11 10:57:57', '2023-07-11 10:58:02', '0', NULL, NULL, NULL);
INSERT INTO `sys_config`(`id`, `tenant_id`, `code`, `name`, `value`, `sort`, `description`, `category_id`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('6', '0', 'elder.foodProhibition.avoidSpiciness', '忌辛辣', '1', 0, '', '6', '2023-07-11 10:57:57', '2023-07-11 10:58:02', '0', NULL, NULL, NULL);
INSERT INTO `sys_config`(`id`, `tenant_id`, `code`, `name`, `value`, `sort`, `description`, `category_id`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('7', '0', 'elder.hobbies.growFlowers', '养花', '1', 0, '', '7', '2023-07-11 10:57:57', '2023-07-11 10:58:02', '0', NULL, NULL, NULL);
INSERT INTO `sys_config`(`id`, `tenant_id`, `code`, `name`, `value`, `sort`, `description`, `category_id`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('8', '0', 'elder.education.seniorMiddleSchool', '高中', '1', 0, '', '8', '2023-07-11 10:57:57', '2023-07-11 10:58:02', '0', NULL, NULL, NULL);
INSERT INTO `sys_config`(`id`, `tenant_id`, `code`, `name`, `value`, `sort`, `description`, `category_id`, `create_date`, `update_date`, `del_flag`, `create_by`, `update_by`, `eng_name`) VALUES ('9', '0', 'elder.belief.none', '无', '1', 0, '', '9', '2023-07-11 10:57:57', '2023-07-11 10:58:02', '0', NULL, NULL, NULL);
This diff could not be displayed because it is too large.
# 平台端
## 服务器环境准备
- JDK(版本号1.8.0_202)
- Redis
- MySql 初始化脚本db/init/init.sql
## 项目打包
- 拉取源码http://git.xmmakeit.com/huangjiay/iot-platform-server.git
- 切换分支(master生产环境,dev测试环境)
- 在项目根目录下执行mvn clean package进行打包
## 部署
- 在服务器上创建目录/opt/iot-platform-server
- 将jar包上传至服务器/opt/iot-platform-server目录下
- 正式环境在/opt/iot-platform-server/config目录下新建application.yaml文件,请注意修改对应配置信息!!!
- application.yaml
```yaml
server:
port: 10005
servlet:
encoding:
charset: UTF-8
force: true
enabled: true
spring:
application:
name: iot-server
datasource:
url: jdbc:mysql://127.0.0.1:3306/kanyang_app?allowMultiQueries=true&useUnicode=true&characterEncoding=UTF-8&useSSL=false&serverTimezone=GMT%2B8&autoReconnect=true
username: kuangshi
password: ks@kjb#Ds@1010&
driver-class-name: com.mysql.cj.jdbc.Driver
#type: com.alibaba.druid.pool.DruidDataSource
redis:
address: redis://localhost:6379
password: iot@2023
#超时时间
timeout: 10000
#连接等待超时
connectTimeout: 10000
#redis库
database: 1
mail:
host: smtp.qq.com
username: 994997968@qq.com
password: jctyarhjddstbfef
protocol: smtps
default-encoding: UTF-8
properties:
default-encoding: utf-8
mail:
smtp:
port: 587
auth: true
starttls:
enable: true
required: true
sign:
flag: false
mybatis-plus:
configuration:
log-impl: org.apache.ibatis.logging.nologging.NoLoggingImpl
file:
filePath: file
file: /opt/iot-platform-server/file/${file.filePath}
log: logs
storage:
location: ${file.file}
type: local
url: https://saas.quanthium.com.cn/api/${file.filePath}
logging:
level:
root: info
config: classpath:logback-spring-prod.xml
swagger:
prefix:
maven:
profile:
redis:
prefix:
libreOffice: /home/group1_lzy/iot-server/LibreOffice/program/soffice
iot:
url: https://iot.quanthium.com.cn/api/
uploadUrl: https://saas.qa.quanthium.com.cn/api/saas/device/devicePushLog
clientId: SGtXMT3nXNjDrexH
secureKey: SK48ztMZDMEs8FmaPHjGQGmQBA4CjrPt
sync:
enable: true
mqtt:
username: kuangshi-tumble|1704772011077
password: 9918b498632f64d7de9537c663a50427
hostUrl: tcp://47.106.157.175:11883
clientId:
defaultTopic: /device/*/*/**
timeout: 10
keepalive: 60
msgSwitch: true
wx:
miniapp:
config:
appid: wx454f0dbc28a6529a #微信小程序的appid
secret: fb20da3064d6b7ac90d5c15cf407df46 #微信小程序的Secret
token: #微信小程序消息服务器配置的token
aesKey: #微信小程序消息服务器配置的EncodingAESKey
msgDataFormat: JSON
sms:
send:
url: http://www.aozoneyun.com/message/message/send
uid: 357
pwd: xmks123456
voice-sms:
send:
url: http://www.aozoneyun.com/Message/Message/video_send
uid: 362
pwd: xmksyy123456
shengwang:
appId: 883078934ecd4193aa7a62a3cdacd810
appCertificate: b29be69c9c034120a68f1d5c199d2e74
channelName: 1
uid: 0
tokenExpirationInSeconds: 3600
privilegeExpirationInSeconds: 3600
customerKey: b3b5f44e536a4fc191358926c6716b7b
customerSecret: bd81828a133140a58dfb04e9d80eba43
pid: C567D6F40C6E48E293AA4F9B7AE9BA30
aliyun:
oss:
accessKey: LTAI5tMjaFCiaYYLmtCLiuMj
secretKey: Oq1925mQ8663nxaf83MyoOGAbVM71H
endpoint: oss-cn-shenzhen.aliyuncs.com
bucket: kangyang-oss
baseDir: kangyang
elasticsearch:
host: 47.106.229.44
port: 9200
user:
password:
scheme: http
```
- 启动项目
- 测试环境
```sh
nohup java -jar server-web.jar --spring.profiles.active=test &
```
- 正式环境
```sh
nohup java -jar server-web.jar &
```
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment