Commit 17b5cb20 by patpat

Merge branch 'develop' into uat

parents 550bfa34 ec0b4fe8
#### 打包流程 ### 分支管理
分支名|描述
-|-
develop|开发分支作为源分支,所有新功能开发和bug修复都在develop派生分支进行
test|测试环境,仅用作打包使用,打包前先从develop分支合并过来并递增版本号
uat|uat环境,仅用作打包使用,打包前先从develop分支合并过来并递增版本号
production|生产环境,仅用作打包使用,打包前先从develop分支合并过来并递增版本号
#### 特殊功能二维码 ### 特殊功能二维码
在线生成二维码:https://www.liantu.com 在线生成二维码:https://www.liantu.com
功能|二维码内容 功能|二维码内容
...@@ -10,13 +16,13 @@ ...@@ -10,13 +16,13 @@
软件更新|{"action":"CONFIG_UPDATE","data":{"url":"apk网络地址"}} 软件更新|{"action":"CONFIG_UPDATE","data":{"url":"apk网络地址"}}
清空离线支付记录|{"action":"CONFIG_CLEAR_OFFLINE_RECODE"} 清空离线支付记录|{"action":"CONFIG_CLEAR_OFFLINE_RECODE"}
#### 已知问题 ### 已知问题
- 现场反馈终端有偶发性卡死的情况,具体表现为界面右上角时间不走,接入鼠标键盘均没有响应。终端系统日志显示是因为某个App占用过多资源导致系统频繁GC,目前没有排除到是否我们App导致还是终端里其它App导致,建议与甲方沟通把多余无关的App卸载掉,并且把蓝牙关闭。 - 现场反馈终端有偶发性卡死的情况,具体表现为界面右上角时间不走,接入鼠标键盘均没有响应。终端系统日志显示是因为某个App占用过多资源导致系统频繁GC,目前没有排除到是否我们App导致还是终端里其它App导致,建议与甲方沟通把多余无关的App卸载掉,并且把蓝牙关闭。
#### 注意事项 ### 注意事项
- 优卡特p60s受厂家二维码sdk限制,targetSdkVersion必须为22,使用高版本将导致App**无法在设备上运行!!!切记!!!** - 优卡特p60s受厂家二维码sdk限制,targetSdkVersion必须为22,使用高版本将导致App**无法在设备上运行!!!切记!!!**
#### 机型历史 ### 机型历史
该项目到现在一共使用过3个机型,按时间顺序排列分别是: 该项目到现在一共使用过3个机型,按时间顺序排列分别是:
1. ~~深圳小兵Q6~~ 1. ~~深圳小兵Q6~~
2. ~~天波580C~~ 2. ~~天波580C~~
......
package com.bgycc.smartcanteen.action package com.bgycc.smartcanteen.action
import com.bgycc.smartcanteen.App import com.bgycc.smartcanteen.App
import com.bgycc.smartcanteen.BuildConfig
import com.bgycc.smartcanteen.server.http.MainHttpClient import com.bgycc.smartcanteen.server.http.MainHttpClient
import com.bgycc.smartcanteen.util.LogUtil
import com.blankj.utilcode.util.FileIOUtils
import com.blankj.utilcode.util.FileUtils import com.blankj.utilcode.util.FileUtils
import com.blankj.utilcode.util.PathUtils import com.blankj.utilcode.util.PathUtils
import com.blankj.utilcode.util.ZipUtils import com.blankj.utilcode.util.ZipUtils
...@@ -44,6 +41,7 @@ object LogAction : Action(ActionEnum.LOG_PULL.name) { ...@@ -44,6 +41,7 @@ object LogAction : Action(ActionEnum.LOG_PULL.name) {
} }
Thread { Thread {
try {
state = State.STARTED state = State.STARTED
val logZipFile = File(PathUtils.getExternalAppCachePath(), "upload/log.zip") val logZipFile = File(PathUtils.getExternalAppCachePath(), "upload/log.zip")
val logUploadDir = File(PathUtils.getExternalAppCachePath(), "upload/log") val logUploadDir = File(PathUtils.getExternalAppCachePath(), "upload/log")
...@@ -55,7 +53,7 @@ object LogAction : Action(ActionEnum.LOG_PULL.name) { ...@@ -55,7 +53,7 @@ object LogAction : Action(ActionEnum.LOG_PULL.name) {
"system" -> File(PathUtils.getExternalStoragePath(), "boot_log") "system" -> File(PathUtils.getExternalStoragePath(), "boot_log")
else -> File(PathUtils.getExternalAppCachePath(), "log") else -> File(PathUtils.getExternalAppCachePath(), "log")
} }
FileUtils.listFilesInDir(logDir).forEach { FileUtils.listFilesInDir(logDir)?.forEach {
val date = Date(it.lastModified()) val date = Date(it.lastModified())
if (date >= startTime && date <= endTime) { if (date >= startTime && date <= endTime) {
FileUtils.copyFile(it, File(logUploadDir, it.name)) FileUtils.copyFile(it, File(logUploadDir, it.name))
...@@ -64,6 +62,7 @@ object LogAction : Action(ActionEnum.LOG_PULL.name) { ...@@ -64,6 +62,7 @@ object LogAction : Action(ActionEnum.LOG_PULL.name) {
ZipUtils.zipFile(logUploadDir, logZipFile) ZipUtils.zipFile(logUploadDir, logZipFile)
FileUtils.deleteDir(logUploadDir) FileUtils.deleteDir(logUploadDir)
MainHttpClient.uploadLog(logZipFile, "$type${formatSrc.format(startTime)}${formatSrc.format(endTime)}${App.getDeviceSN()}.zip") MainHttpClient.uploadLog(logZipFile, "$type${formatSrc.format(startTime)}${formatSrc.format(endTime)}${App.getDeviceSN()}.zip")
} catch (e: Exception) {}
state = State.INITED state = State.INITED
}.start() }.start()
} catch (e: Exception) {} } catch (e: Exception) {}
......
...@@ -4,6 +4,7 @@ import com.bgycc.smartcanteen.App; ...@@ -4,6 +4,7 @@ import com.bgycc.smartcanteen.App;
import com.bgycc.smartcanteen.Storage.PayStorage; import com.bgycc.smartcanteen.Storage.PayStorage;
import com.bgycc.smartcanteen.event.PayStateEvent; import com.bgycc.smartcanteen.event.PayStateEvent;
import com.bgycc.smartcanteen.event.QRCodeRepeatEvent; import com.bgycc.smartcanteen.event.QRCodeRepeatEvent;
import com.bgycc.smartcanteen.helper.TTSHelper;
import com.bgycc.smartcanteen.helper.TimerHelper; import com.bgycc.smartcanteen.helper.TimerHelper;
import com.bgycc.smartcanteen.server.websocket.MainWebSocket; import com.bgycc.smartcanteen.server.websocket.MainWebSocket;
import com.bgycc.smartcanteen.task.QRCodeTask; import com.bgycc.smartcanteen.task.QRCodeTask;
...@@ -79,7 +80,7 @@ public class PayOfflineAction extends Action { ...@@ -79,7 +80,7 @@ public class PayOfflineAction extends Action {
setState(State.STARTED); setState(State.STARTED);
if (!QRCodeTask.TYPE_BHPAY.equals(payCodeType)) { if (!QRCodeTask.TYPE_BHPAY.equals(payCodeType)) {
setState(State.FAIL); setState(State.FAIL, "第三方支付异常");
return; return;
} }
if (checkRepeat && mPayCodeHistory.contains(payCode)) { if (checkRepeat && mPayCodeHistory.contains(payCode)) {
......
...@@ -66,9 +66,10 @@ object TTSHelper { ...@@ -66,9 +66,10 @@ object TTSHelper {
"您的就餐权限已失效" -> "pay-invalid-permission.mp3" "您的就餐权限已失效" -> "pay-invalid-permission.mp3"
"非本窗口营业时间" -> "pay-window-rest-time.mp3" "非本窗口营业时间" -> "pay-window-rest-time.mp3"
"非营业时间" -> "pay-canteen-rest-time.mp3" "非营业时间" -> "pay-canteen-rest-time.mp3"
"可用余额不足" -> "pay-balance-not-enough.mp3" "余额不足" -> "pay-balance-not-enough.mp3"
else -> null "第三方支付异常" -> "pay-other-platform-offline.mp3"
} ?: return else -> "pay-fail.mp3"
}
var id = mSoundIdMap[soundName] var id = mSoundIdMap[soundName]
if (id == null) { if (id == null) {
......
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