mirror of
https://github.com/srlabs/blue-merle.git
synced 2025-01-03 03:20:52 -05:00
removing v3 patches
The switch doesn't work yet but "uci get switch-button.@main[0].func" gets the currently active configured action for button. I guess that /etc/rc.button/switch is called on every press of the button.
This commit is contained in:
parent
843ddf9e7d
commit
4c29fe2732
@ -1,39 +0,0 @@
|
||||
--- orig/index.html
|
||||
+++ patch/index.html
|
||||
@@ -6,7 +6,7 @@
|
||||
<span class="circle active"></span>
|
||||
<span>{{t($lang.setting.btnSetting)}}</span>
|
||||
</h4>
|
||||
- <gl-btn type="purple" class="pull-right moblieBtnLate" @click="checkType" :disabled="btnStatus">{{t($lang.button.apply)}}</gl-btn>
|
||||
+ <gl-btn type="purple" class="pull-right moblieBtnLate" @click="checkType" :disabled="true">{{t($lang.button.apply)}}</gl-btn>
|
||||
</div>
|
||||
<div class="panel-body panel-status">
|
||||
<span class="setting-box clearfix list-group">
|
||||
@@ -64,6 +64,20 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
+
|
||||
+ <div v-show="parstatus=='sim'">
|
||||
+ <div style="width:47%; display:inline-block;vertical-align:top;">
|
||||
+ <div id="title_left" style=" font-weight:bold">SIM Change Start</div>
|
||||
+ <div id="content_left" class="content_switch">{{'SIM change will be initiated'}}.
|
||||
+ </div>
|
||||
+ </div>
|
||||
+ <div style="width:47%; display:inline-block;vertical-align:top">
|
||||
+ <div id="title_right" style="font-weight:bold">SIM Change Stop</div>
|
||||
+ <div id="content_right" class="content_switch">
|
||||
+ </div>
|
||||
+ </div>
|
||||
+ </div>
|
||||
+
|
||||
</div>
|
||||
<div style="display:none">
|
||||
<label class="div-help-title">{{t($lang.setting.diy)}}</label>
|
||||
@@ -84,4 +98,4 @@
|
||||
|
||||
</div>
|
||||
</div>
|
||||
-</div>
|
||||
\ No newline at end of file
|
||||
+</div>
|
@ -1,41 +0,0 @@
|
||||
--- orig/index.js
|
||||
+++ patch/index.js
|
||||
@@ -6,7 +6,7 @@
|
||||
data: function data() {
|
||||
return {
|
||||
isShow: false,
|
||||
- chooseState: ["No function (default)", "WireGuard® Client Toggle (On/Off)", "OpenVPN Client Toggle (On/Off)"],
|
||||
+ chooseState: ["No function (default)", "WireGuard® Client Toggle (On/Off)", "OpenVPN Client Toggle (On/Off)", "SIM Change (Start/Stop)"],
|
||||
// chooseState4G: ["No function (default)", "WireGuard® Client Toggle (On/Off)", "OpenVPN Client Toggle (On/Off)", ],
|
||||
param: "",
|
||||
btnStatus: true,
|
||||
@@ -79,6 +79,9 @@
|
||||
case "Tor Toggle (On/Off)":
|
||||
status = "tor";
|
||||
break;
|
||||
+ case "SIM Change (Start/Stop)":
|
||||
+ status="sim";
|
||||
+ break;
|
||||
}
|
||||
return status;
|
||||
},
|
||||
@@ -108,6 +111,9 @@
|
||||
case "tor":
|
||||
_this.param = "Tor Toggle (On/Off)";
|
||||
break;
|
||||
+ case "sim":
|
||||
+ _this.param = "SIM Change (Start/Stop)";
|
||||
+ break;
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -170,6 +176,9 @@
|
||||
case 'tor':
|
||||
_this.openSetting();
|
||||
break;
|
||||
+ case 'sim':
|
||||
+ _this.openSetting();
|
||||
+ break;
|
||||
}
|
||||
},
|
||||
openSetting: function openSetting() {
|
@ -1,23 +0,0 @@
|
||||
--- orig/switch_queue
|
||||
+++ patch/switch_queue
|
||||
@@ -81,6 +81,10 @@
|
||||
"tor")
|
||||
e750-mcu " Turning TOR ON"
|
||||
;;
|
||||
+ "sim")
|
||||
+# e750-mcu " Starting SIM swap"
|
||||
+ blue-merle-switch&
|
||||
+ ;;
|
||||
"*")
|
||||
;;
|
||||
esac
|
||||
@@ -98,6 +102,9 @@
|
||||
check_other_vpn tor
|
||||
e750-mcu " Turning TOR OFF"
|
||||
;;
|
||||
+ "sim")
|
||||
+# e750-mcu " Stopping SIM swap"
|
||||
+ ;;
|
||||
"*")
|
||||
;;
|
||||
esac
|
@ -1,38 +0,0 @@
|
||||
--- orig/switchaction
|
||||
+++ patch/switchaction
|
||||
@@ -10,6 +10,15 @@
|
||||
fi
|
||||
}
|
||||
|
||||
+toggle_sim(){
|
||||
+ local action=$1
|
||||
+ if [ "$action" = "OFF" ];then
|
||||
+ sim_switch off
|
||||
+ else
|
||||
+ sim_switch on
|
||||
+ fi
|
||||
+}
|
||||
+
|
||||
check_other_vpn(){
|
||||
wg_server=$(uci get wireguard_server.@servers[0].enable)
|
||||
ov_server=$(uci get vpn_service.global.enable)
|
||||
@@ -136,6 +145,9 @@
|
||||
check_other_vpn tor
|
||||
toggle_tor ON
|
||||
;;
|
||||
+ "sim")
|
||||
+ toggle_sim ON
|
||||
+ ;;
|
||||
"*")
|
||||
;;
|
||||
esac
|
||||
@@ -157,6 +169,9 @@
|
||||
"tor")
|
||||
toggle_tor OFF
|
||||
;;
|
||||
+ "sim")
|
||||
+ toggle_sim OFF
|
||||
+ ;;
|
||||
"*")
|
||||
;;
|
||||
esac
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user