feat: hide first_install_token if is not required (#3795)
This commit is contained in:
@@ -1220,6 +1220,7 @@ class PublicSettings(BaseModel):
|
|||||||
lnbits_user_activation_by_invitation_code: bool = Field(
|
lnbits_user_activation_by_invitation_code: bool = Field(
|
||||||
alias="userActivationByInvitationCode"
|
alias="userActivationByInvitationCode"
|
||||||
)
|
)
|
||||||
|
has_first_install_token: bool = Field(alias="hasFirstInstallToken")
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def from_settings(cls, settings: Settings):
|
def from_settings(cls, settings: Settings):
|
||||||
@@ -1278,6 +1279,7 @@ class PublicSettings(BaseModel):
|
|||||||
userActivationByEmail=settings.lnbits_user_activation_by_email,
|
userActivationByEmail=settings.lnbits_user_activation_by_email,
|
||||||
userActivationByPayment=settings.lnbits_user_activation_by_payment,
|
userActivationByPayment=settings.lnbits_user_activation_by_payment,
|
||||||
userActivationByInvitationCode=settings.lnbits_user_activation_by_invitation_code,
|
userActivationByInvitationCode=settings.lnbits_user_activation_by_invitation_code,
|
||||||
|
hasFirstInstallToken=settings.first_install_token is not None,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Vendored
+1
-1
File diff suppressed because one or more lines are too long
@@ -529,7 +529,7 @@ window.localisation.en = {
|
|||||||
hash: 'Hash: ',
|
hash: 'Hash: ',
|
||||||
welcome_lnbits: 'Welcome to LNbits',
|
welcome_lnbits: 'Welcome to LNbits',
|
||||||
setup_su_account: 'Set up the Superuser account below.',
|
setup_su_account: 'Set up the Superuser account below.',
|
||||||
first_install_token: 'First Install Token (optional)',
|
first_install_token: 'First Install Token',
|
||||||
create_ticker_converter: 'Create Currency Ticker Converter',
|
create_ticker_converter: 'Create Currency Ticker Converter',
|
||||||
enable_audit: 'Enable Audit',
|
enable_audit: 'Enable Audit',
|
||||||
recommended: 'Recommended',
|
recommended: 'Recommended',
|
||||||
|
|||||||
@@ -55,6 +55,7 @@
|
|||||||
></q-input>
|
></q-input>
|
||||||
<q-input
|
<q-input
|
||||||
filled
|
filled
|
||||||
|
v-if="g.settings.hasFirstInstallToken"
|
||||||
v-model.trim="loginData.firstInstallToken"
|
v-model.trim="loginData.firstInstallToken"
|
||||||
:type="loginData.isPwd ? 'password' : 'text'"
|
:type="loginData.isPwd ? 'password' : 'text'"
|
||||||
:label="$t('first_install_token')"
|
:label="$t('first_install_token')"
|
||||||
|
|||||||
Reference in New Issue
Block a user