From d9179a9edf1f49a2fc8eaeab19fb2b8651c629d7 Mon Sep 17 00:00:00 2001 From: taoshihan1991 <630892807@qq.com> Date: Tue, 30 Mar 2021 09:59:16 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B8=AE=E5=8A=A9=E9=A1=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- static/html/index_new.html | 54 +++++++++++++++++++++++++++++++------- 1 file changed, 45 insertions(+), 9 deletions(-) diff --git a/static/html/index_new.html b/static/html/index_new.html index 725dc2f..e00cb00 100644 --- a/static/html/index_new.html +++ b/static/html/index_new.html @@ -64,31 +64,67 @@

1.引入js并且修改为自己的域名

-<!--对接客服代码,安装完成后更改成自己的域名或IP,下面js文件路径以及GOFLY_URL都要改-->
-<script src="https://gofly.sopans.com/static/js/gofly-front.js?v=1"></script>
-<script>
+    script标签引入这段js https://gofly.sopans.com/static/js/gofly-front.js
     GOFLY.init({
         GOFLY_URL:"https://gofly.sopans.com",
         GOFLY_KEFU_ID: "kefu2",//对接的客服name
     })
-</script>
-<!--//对接客服代码-->
                 

2.隐藏默认按钮使用自己的按钮

-<script>
+
     GOFLY.init({
         GOFLY_URL:"https://gofly.sopans.com",
         GOFLY_KEFU_ID: "kefu2",//对接的客服name
         GOFLY_WITHOUT_BTN:true,
     })
-</script>
-<a  href="javascript:GOFLY.showPanel();">联系客服</a>
+    在你的按钮点击事件上,调用这个方法 GOFLY.showPanel() [新版添加]
                 
+

配置数据库

+
+

在mysql命令行下或者网页管理面板里 , 创建好空数据库.

+
+    mysql命令行下的建库语句如下:
+    create database gofly charset utf8;
+                
+

编辑config/mysql.json , 更换为自己的数据库host/用户名/密码/数据库名

+

服务端安装

-

参考readme.md

+

1. linux系统

+

下载zip压缩包,并且解压缩的详细命令如下.

+
+    mkdir go-fly
+    cd go-fly
+    wget xxxxxxxxxxx.zip
+    unzip xxxx.zip
+    chmod 0777 -R ./
+    导入数据库( 注意:会删除表并且清空数据 )
+    linux: ./go-fly install
+                
+

2. windows系统

+

在cmd命令行下进入解压的目录

+
+    导入数据库( 注意:会删除表并且清空数据 )
+    windows: go-fly.exe install
+                
+

3. 运行项目

+
+    linux:   ./go-fly server [可选 -p 8082 -d]
+    windows: go-fly.exe server [可选 -p 8082 -d]
+    参数说明
+    -p 指定端口
+    -d linux下是否以daemon守护进程运行
+    -h 查看帮助
+                
+

4. 关闭程序

+
+    linux下使用ps命令结合kill命令杀掉进程,windows下使用任务管理器结束进程
+    ps -ef|grep go-fly 看到父子进程id
+    kill 进程父进程id ; kill 进程子进程id
+                
+

详细请参考readme.md