From c3a0c2a465ed6ea5a4a97901050097348b2f25ba Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Thu, 12 Mar 2020 09:42:31 +0200 Subject: [PATCH] UI tweaks and hide on hosted --- app/Models/User.php | 5 +++++ resources/lang/en/texts.php | 4 +++- resources/views/accounts/management.blade.php | 15 +++++---------- resources/views/migration/auth.blade.php | 4 ++-- resources/views/migration/endpoint.blade.php | 4 ++-- resources/views/migration/start.blade.php | 4 ++-- 6 files changed, 19 insertions(+), 17 deletions(-) diff --git a/app/Models/User.php b/app/Models/User.php index b7255d721b86..9c0550d05ae1 100644 --- a/app/Models/User.php +++ b/app/Models/User.php @@ -496,6 +496,11 @@ class User extends Authenticatable public function eligibleForMigration() { + // Not ready to show to hosted users + if (Utils::isNinjaProd()) { + return false; + } + return is_null($this->public_id) || $this->public_id == 0; } } diff --git a/resources/lang/en/texts.php b/resources/lang/en/texts.php index 595963dc9a9f..9abac0545db6 100644 --- a/resources/lang/en/texts.php +++ b/resources/lang/en/texts.php @@ -3270,7 +3270,9 @@ $LANG = array( 'long_press_multiselect' => 'Long-press Multiselect', 'migrate_to_next_version' => 'Migrate to the next version of Invoice Ninja', 'migrate_intro_text' => 'We\'ve been working on next version of Invoice Ninja. Click the button bellow to start the migration.', - 'start_the_migration' => 'Start the migration', + 'start_migration' => 'Start Migration', + 'auth' => 'Auth', + 'endpoint' => 'Endpont', 'migration' => 'Migration', 'welcome_to_the_new_version' => 'Welcome to the new version of Invoice Ninja', 'download_data' => 'Press button below to download the data.', diff --git a/resources/views/accounts/management.blade.php b/resources/views/accounts/management.blade.php index 7ccfd6852a9b..97e174501d49 100644 --- a/resources/views/accounts/management.blade.php +++ b/resources/views/accounts/management.blade.php @@ -244,17 +244,12 @@

{!! trans('texts.migrate_to_next_version') !!}

- -
-
- {!! trans('texts.migrate_intro_text') !!} -
-
- -
-
+
+ +
+
{{ trans('texts.migrate_intro_text')}}

{!! trans('texts.start_the_migration') !!} + href="/migration/start">{!! trans('texts.start_migration') !!}
diff --git a/resources/views/migration/auth.blade.php b/resources/views/migration/auth.blade.php index c68281caad6f..281f5717a1a6 100644 --- a/resources/views/migration/auth.blade.php +++ b/resources/views/migration/auth.blade.php @@ -11,7 +11,7 @@

{!! trans('texts.welcome_to_the_new_version') !!}

-

Let's continue with authentication.

+

Let's continue with authentication.


{{ csrf_field() }}
@@ -29,4 +29,4 @@
-@stop \ No newline at end of file +@stop diff --git a/resources/views/migration/endpoint.blade.php b/resources/views/migration/endpoint.blade.php index bbf8da64485a..3ff3162a4702 100644 --- a/resources/views/migration/endpoint.blade.php +++ b/resources/views/migration/endpoint.blade.php @@ -9,7 +9,7 @@

{!! trans('texts.welcome_to_the_new_version') !!}

-

We need to know the link of your application.

+

We need to know the link of your application.


{{ csrf_field() }}
@@ -25,4 +25,4 @@
-@stop \ No newline at end of file +@stop diff --git a/resources/views/migration/start.blade.php b/resources/views/migration/start.blade.php index 0137061b7b12..40f7017964d4 100644 --- a/resources/views/migration/start.blade.php +++ b/resources/views/migration/start.blade.php @@ -9,7 +9,7 @@

{!! trans('texts.welcome_to_the_new_version') !!}

-

In order to start the migration, we need to know where do you want to migrate.

+

In order to start the migration, we need to know where do you want to migrate.


{{ csrf_field() }}
@@ -34,4 +34,4 @@
-@stop \ No newline at end of file +@stop