patch update

make settings form individual to reduce conflicts
This commit is contained in:
Focuslinkstech 2024-10-23 08:28:00 +01:00
parent 6ffa396b05
commit eb1d804a4d
2 changed files with 57 additions and 5 deletions

View File

@ -145,7 +145,7 @@ switch ($action) {
r2(U . 'settings/app', 'e', 'PHP GD is not installed'); r2(U . 'settings/app', 'e', 'PHP GD is not installed');
} }
} }
if ($company == '') { if ($_POST['general'] && $company == '') {
r2(U . 'settings/app', 'e', Lang::T('All field is required')); r2(U . 'settings/app', 'e', Lang::T('All field is required'));
} else { } else {
if ($radius_enable) { if ($radius_enable) {

View File

@ -120,12 +120,17 @@
<span class="help-block col-md-4">{Lang::T('Income will reset every this <span class="help-block col-md-4">{Lang::T('Income will reset every this
day')}</span> day')}</span>
</div> </div>
<button class="btn btn-success btn-block" type="submit"> <button class="btn btn-success btn-block" name="general" type="submit">
{Lang::T('Save Changes')} {Lang::T('Save Changes')}
</button> </button>
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="HideDashboardContent"> <div class="panel-heading" role="tab" id="HideDashboardContent">
<h4 class="panel-title"> <h4 class="panel-title">
@ -161,6 +166,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="Registration"> <div class="panel-heading" role="tab" id="Registration">
<h4 class="panel-title"> <h4 class="panel-title">
@ -230,9 +239,9 @@
<div class="col-md-6"> <div class="col-md-6">
<select name="phone_otp_type" id="phone_otp_type" class="form-control"> <select name="phone_otp_type" id="phone_otp_type" class="form-control">
<option value="sms" {if $_c['phone_otp_type']=='sms' }selected="selected" {/if}> <option value="sms" {if $_c['phone_otp_type']=='sms' }selected="selected" {/if}>
{Lang::T('By SMS')} {Lang::T('By SMS')}</option>
<option value="whatsapp" {if $_c['phone_otp_type']=='whatsapp' }selected="selected" {/if}> <option value="whatsapp" {if $_c['phone_otp_type']=='whatsapp' }selected="selected" {/if}>
{Lang::T('by WhatsApp')} {Lang::T('by WhatsApp')}</option>
<option value="both" {if $_c['phone_otp_type']=='both' }selected="selected" {/if}> <option value="both" {if $_c['phone_otp_type']=='both' }selected="selected" {/if}>
{Lang::T('By WhatsApp and SMS')} {Lang::T('By WhatsApp and SMS')}
</option> </option>
@ -247,6 +256,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="Voucher"> <div class="panel-heading" role="tab" id="Voucher">
<h4 class="panel-title"> <h4 class="panel-title">
@ -310,7 +323,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="FreeRadius"> <div class="panel-heading" role="tab" id="FreeRadius">
<h4 class="panel-title"> <h4 class="panel-title">
@ -341,7 +357,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="ExtendPostpaidExpiration"> <div class="panel-heading" role="tab" id="ExtendPostpaidExpiration">
<h4 class="panel-title"> <h4 class="panel-title">
@ -385,7 +404,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="CustomerBalanceSystem"> <div class="panel-heading" role="tab" id="CustomerBalanceSystem">
<h4 class="panel-title"> <h4 class="panel-title">
@ -437,7 +459,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="TelegramNotification"> <div class="panel-heading" role="tab" id="TelegramNotification">
<h4 class="panel-title"> <h4 class="panel-title">
@ -477,7 +502,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="SMSNotification"> <div class="panel-heading" role="tab" id="SMSNotification">
<h4 class="panel-title"> <h4 class="panel-title">
@ -529,7 +557,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="WhatsappNotification"> <div class="panel-heading" role="tab" id="WhatsappNotification">
<h4 class="panel-title"> <h4 class="panel-title">
@ -552,7 +583,7 @@
placeholder="https://domain/?param_number=[number]&param_text=[text]&secret="> placeholder="https://domain/?param_number=[number]&param_text=[text]&secret=">
</div> </div>
<p class="help-block col-md-4">{Lang::T('Must include')} <b>[text]</b> &amp; <b>[number]</b>, <p class="help-block col-md-4">{Lang::T('Must include')} <b>[text]</b> &amp; <b>[number]</b>,
{Lang::T('it will be replaced.')} {Lang::T('it will be replaced.')}</p>
</div> </div>
<small id="emailHelp" class="form-text text-muted">{Lang::T('You can use')} WhatsApp <small id="emailHelp" class="form-text text-muted">{Lang::T('You can use')} WhatsApp
{Lang::T('in here too.')} <a href="https://wa.nux.my.id/login" target="_blank">{Lang::T('Free {Lang::T('in here too.')} <a href="https://wa.nux.my.id/login" target="_blank">{Lang::T('Free
@ -563,7 +594,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="EmailNotification"> <div class="panel-heading" role="tab" id="EmailNotification">
<h4 class="panel-title"> <h4 class="panel-title">
@ -645,7 +679,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="UserNotification"> <div class="panel-heading" role="tab" id="UserNotification">
<h4 class="panel-title"> <h4 class="panel-title">
@ -708,7 +745,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="TawkToChatWidget"> <div class="panel-heading" role="tab" id="TawkToChatWidget">
<h4 class="panel-title"> <h4 class="panel-title">
@ -738,7 +778,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="APIKey"> <div class="panel-heading" role="tab" id="APIKey">
<h4 class="panel-title"> <h4 class="panel-title">
@ -765,7 +808,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="Proxy"> <div class="panel-heading" role="tab" id="Proxy">
<h4 class="panel-title"> <h4 class="panel-title">
@ -798,7 +844,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="TaxSystem"> <div class="panel-heading" role="tab" id="TaxSystem">
<h4 class="panel-title"> <h4 class="panel-title">
@ -869,7 +918,10 @@
</div> </div>
</div> </div>
</div> </div>
</form>
<form class="form-horizontal" method="post" role="form" action="{$_url}settings/app-post" enctype="multipart/form-data">
<input type="hidden" name="csrf_token" value="{$csrf_token}">
<div class="panel"> <div class="panel">
<div class="panel-heading" role="tab" id="GithubAuthentication"> <div class="panel-heading" role="tab" id="GithubAuthentication">
<h4 class="panel-title"> <h4 class="panel-title">