From 113665da1ee91c5c1538793075ae147646eefaf4 Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Sun, 11 May 2014 21:24:30 +0300 Subject: [PATCH] Updating texts --- app/controllers/AccountController.php | 2 +- app/lang/de/texts.php | 3 +++ app/lang/es/texts.php | 3 +++ app/lang/fr/texts.php | 3 +++ app/lang/it/texts.php | 3 +++ app/lang/nl/texts.php | 3 +++ app/lang/pt_BR/texts.php | 3 +++ app/views/accounts/payments.blade.php | 7 ++++++- app/views/header.blade.php | 1 + app/views/master.blade.php | 23 +++++++++++++++-------- app/views/public/header.blade.php | 9 ++------- public/built.js | 9 ++------- public/js/script.js | 9 ++------- 13 files changed, 47 insertions(+), 31 deletions(-) diff --git a/app/controllers/AccountController.php b/app/controllers/AccountController.php index 5adac2baa1bb..db2627cd1469 100755 --- a/app/controllers/AccountController.php +++ b/app/controllers/AccountController.php @@ -50,7 +50,7 @@ class AccountController extends \BaseController { Auth::login($user, true); Event::fire('user.login'); - return Redirect::to('invoices/create'); + return Redirect::to('invoices/create'); } public function enableProPlan() diff --git a/app/lang/de/texts.php b/app/lang/de/texts.php index b8a05f5564f7..80994e330da9 100644 --- a/app/lang/de/texts.php +++ b/app/lang/de/texts.php @@ -334,5 +334,8 @@ return array( 'archived_product' => 'Produkt erfolgreich archiviert', 'product_library' => 'Produktbibliothek', + 'chart_builder' => 'Chart Builder', + 'ninja_email_footer' => 'Use :site to invoice your clients and get paid online for free!', + ); diff --git a/app/lang/es/texts.php b/app/lang/es/texts.php index b79e23eeb930..b03704badd13 100644 --- a/app/lang/es/texts.php +++ b/app/lang/es/texts.php @@ -332,5 +332,8 @@ return array( 'updated_product' => 'Successfully updated product', 'created_product' => 'Successfully created product', 'archived_product' => 'Successfully archived product', + + 'chart_builder' => 'Chart Builder', + 'ninja_email_footer' => 'Use :site to invoice your clients and get paid online for free!', ); diff --git a/app/lang/fr/texts.php b/app/lang/fr/texts.php index 55549733eea6..d3f677279d08 100644 --- a/app/lang/fr/texts.php +++ b/app/lang/fr/texts.php @@ -333,5 +333,8 @@ return array( 'updated_product' => 'Successfully updated product', 'created_product' => 'Successfully created product', 'archived_product' => 'Successfully archived product', + + 'chart_builder' => 'Chart Builder', + 'ninja_email_footer' => 'Use :site to invoice your clients and get paid online for free!', ); diff --git a/app/lang/it/texts.php b/app/lang/it/texts.php index c7bc93202d53..bba41f289c46 100644 --- a/app/lang/it/texts.php +++ b/app/lang/it/texts.php @@ -334,4 +334,7 @@ return array( 'created_product' => 'Successfully created product', 'archived_product' => 'Successfully archived product', + 'chart_builder' => 'Chart Builder', + 'ninja_email_footer' => 'Use :site to invoice your clients and get paid online for free!', + ); diff --git a/app/lang/nl/texts.php b/app/lang/nl/texts.php index 3696b00543db..fa4deda05369 100644 --- a/app/lang/nl/texts.php +++ b/app/lang/nl/texts.php @@ -334,5 +334,8 @@ return array( 'updated_product' => 'Successfully updated product', 'created_product' => 'Successfully created product', 'archived_product' => 'Successfully archived product', + + 'chart_builder' => 'Chart Builder', + 'ninja_email_footer' => 'Use :site to invoice your clients and get paid online for free!', ); diff --git a/app/lang/pt_BR/texts.php b/app/lang/pt_BR/texts.php index e6a0fb30f69c..c7597a53c2b6 100644 --- a/app/lang/pt_BR/texts.php +++ b/app/lang/pt_BR/texts.php @@ -323,5 +323,8 @@ return array( 'created_product' => 'Successfully created product', 'archived_product' => 'Successfully archived product', + 'chart_builder' => 'Chart Builder', + 'ninja_email_footer' => 'Use :site to invoice your clients and get paid online for free!', + ); diff --git a/app/views/accounts/payments.blade.php b/app/views/accounts/payments.blade.php index dad6767e3673..7150a5549388 100755 --- a/app/views/accounts/payments.blade.php +++ b/app/views/accounts/payments.blade.php @@ -73,6 +73,11 @@ } } + function gatewayLink(url) { + //if (url.match('authorize')) + openUrl(url, '/affiliate/' + new URL(url).hostname); + } + $(document).ready(function() { $('.recommended-gateway').change( function(){ @@ -95,7 +100,7 @@ var contents = $(this).parent().contents(); contents[contents.length - 1].nodeValue = ''; $(this).after('
'); - $(this).parent().children().last().after('Create an account'); + $(this).parent().children().last().after('Create an account'); }); diff --git a/app/views/header.blade.php b/app/views/header.blade.php index 76aa74764d21..5d95f8b7e830 100755 --- a/app/views/header.blade.php +++ b/app/views/header.blade.php @@ -492,6 +492,7 @@ Want something changed? We're {{ link_to('https://github.com/hillelcoren/invoice trackUrl('/signed_up'); if (result) { localStorage.setItem('guest_key', ''); + trackUrl('/user/sign_up'); NINJA.isRegistered = true; $('#signUpButton').hide(); $('#myAccountButton').html(result); diff --git a/app/views/master.blade.php b/app/views/master.blade.php index 58ae3b71fc3c..d14fb94801e8 100755 --- a/app/views/master.blade.php +++ b/app/views/master.blade.php @@ -51,17 +51,24 @@ + + ga('create', '{{ $_ENV['ANALYTICS_KEY'] }}'); + ga('send', 'pageview'); + + function trackUrl(url) { + url = '/track' + url.replace('http:/', ''); + ga('send', 'pageview', url); + } + @else + function trackUrl(url) {} @endif + @yield('body') diff --git a/app/views/public/header.blade.php b/app/views/public/header.blade.php index 73b86889017e..e32148382e15 100644 --- a/app/views/public/header.blade.php +++ b/app/views/public/header.blade.php @@ -181,15 +181,10 @@ jQuery(document).ready(function($) { }); - - - - @stop \ No newline at end of file diff --git a/public/built.js b/public/built.js index 9f6679517922..c3a5772f898f 100644 --- a/public/built.js +++ b/public/built.js @@ -39444,12 +39444,7 @@ function setDocHexDraw(doc, hex) { return doc.setDrawColor(r, g, b); } -function openUrl(url) { - trackUrl(url); +function openUrl(url, track) { + trackUrl(track ? track : url); window.open(url, '_blank'); -} - -function trackUrl(url) { - url = '/track' + url.replace('http:/', ''); - ga('send', 'pageview', url); } \ No newline at end of file diff --git a/public/js/script.js b/public/js/script.js index ab16787cc0b7..9632d71cc4c8 100644 --- a/public/js/script.js +++ b/public/js/script.js @@ -1728,12 +1728,7 @@ function setDocHexDraw(doc, hex) { return doc.setDrawColor(r, g, b); } -function openUrl(url) { - trackUrl(url); +function openUrl(url, track) { + trackUrl(track ? track : url); window.open(url, '_blank'); -} - -function trackUrl(url) { - url = '/track' + url.replace('http:/', ''); - ga('send', 'pageview', url); } \ No newline at end of file