实现同时重启MpAPP 和运维APP

hdrplus
Matthew 11 months ago
parent 8a77bb6ab6
commit a4b509a819

@ -83,6 +83,10 @@ public class SimUtil {
ifmessageCorrect = true;
sendtype = SmsTypeEnum.RESTART_MPMST.value();
sendmessage = getSendString(content, ifmessageCorrect);
} else if (content.contains(SmsTypeEnum.RESTART_BOTH_APPS.value()) || content.contains(SmsTypeEnum.RESTART_BOTH_APPS2.value())) {
ifmessageCorrect = true;
sendtype = SmsTypeEnum.RESTART_BOTH_APPS.value();
sendmessage = getSendString(content, ifmessageCorrect);
} else if (content.contains(SmsTypeEnum.SET_YW_SCHEDULE.value())) {
ifmessageCorrect = true;
String[] split1 = StringUtils.splitString1(content);

@ -64,6 +64,9 @@ public class SmsSendReceiver extends BroadcastReceiver {
UpdateSysConfigUtil.restartApp(context);
} else if (type.contains(SmsTypeEnum.RESTART_MPMST.value())) {
UpdateSysConfigUtil.restartMasterApp(context);
} else if (type.contains(SmsTypeEnum.RESTART_BOTH_APPS.value())) {
UpdateSysConfigUtil.restartApp(context);
UpdateSysConfigUtil.restartMasterApp(context);
} else if (type.contains(SmsTypeEnum.SET_YW_SCHEDULE.value())) {
UpdateSysConfigUtil.restartMasterApp(context);
} else if (type.contains(SmsTypeEnum.SET_OPERATE.value())) {

@ -7,6 +7,8 @@ public enum SmsTypeEnum {
RESTART_MP2("at-restart=mpapp"),
RESTART_MPMST("at+restart=mpmaster"),
RESTART_MPMST2("at-restart=mpmaster"),
RESTART_BOTH_APPS("at+restart=both"),
RESTART_BOTH_APPS2("at-restart=both"),
SET_YW_SCHEDULE("yw+at+stw51"), //拍照时间表设置
GET_YW_SCHEDULE("yw+at+str51"), //查询拍照时间表
SET_OPERATE("yw+at+stw52"), //设置运维开关

Loading…
Cancel
Save