From eda4ec88d55900e5092e01792f48ec49e16f8cfa Mon Sep 17 00:00:00 2001 From: Pererinha Date: Mon, 6 Apr 2015 16:00:48 -0300 Subject: [PATCH] Share with SMS contacts as only customer referral option on mobile #5092 --- .../default/crunchbutton/api/giftcard/index.php | 2 +- .../views/default/crunchbutton/frontend/free-food.phtml | 2 +- include/views/default/crunchbutton/frontend/giftcard.phtml | 2 +- include/views/default/crunchbutton/frontend/orders.phtml | 2 +- include/views/default/seven/frontend/free-food.phtml | 2 +- include/views/default/seven/frontend/giftcard.phtml | 7 ++++++- include/views/default/seven/frontend/order.phtml | 6 +++--- include/views/default/seven/frontend/orders.phtml | 4 ++-- www/assets/js/services.referral.js | 6 +++--- 9 files changed, 19 insertions(+), 14 deletions(-) diff --git a/include/controllers/default/crunchbutton/api/giftcard/index.php b/include/controllers/default/crunchbutton/api/giftcard/index.php index 92bcdb57a..e29f54779 100644 --- a/include/controllers/default/crunchbutton/api/giftcard/index.php +++ b/include/controllers/default/crunchbutton/api/giftcard/index.php @@ -392,7 +392,7 @@ class Controller_api_Giftcard extends Crunchbutton_Controller_Rest { if( $reward->checkIfItIsEligibleForFirstTimeOrder() && $valid ){ $value = $reward->getReferredDiscountAmount(); if( $value ){ - echo json_encode( [ 'success' => [ 'value' => $value, 'giftcard' => $code, 'message' => 'You have a $' . $value . ' gift card towards your first order.' ] ] ); + echo json_encode( [ 'success' => [ 'value' => $value, 'giftcard' => $code, 'message' => 'You have a $' . $value . ' gift card for a free delivery.' ] ] ); exit; } } diff --git a/include/views/default/crunchbutton/frontend/free-food.phtml b/include/views/default/crunchbutton/frontend/free-food.phtml index 22811163f..95102c396 100644 --- a/include/views/default/crunchbutton/frontend/free-food.phtml +++ b/include/views/default/crunchbutton/frontend/free-food.phtml @@ -28,7 +28,7 @@
-
+

You are {{account.user.points.away_free_delivery}} points away from a free delivery!

diff --git a/include/views/default/crunchbutton/frontend/giftcard.phtml b/include/views/default/crunchbutton/frontend/giftcard.phtml index a51923708..df75868ec 100644 --- a/include/views/default/crunchbutton/frontend/giftcard.phtml +++ b/include/views/default/crunchbutton/frontend/giftcard.phtml @@ -45,7 +45,7 @@ Congrats, you just got a ${{giftcard.value}} gift card.

- Go ahead and order something delicious! + Go ahead and order some food!
@@ -77,7 +77,7 @@ - + @@ -111,7 +111,7 @@ - +
diff --git a/include/views/default/seven/frontend/orders.phtml b/include/views/default/seven/frontend/orders.phtml index b2dce9fb7..26cef3968 100644 --- a/include/views/default/seven/frontend/orders.phtml +++ b/include/views/default/seven/frontend/orders.phtml @@ -7,7 +7,7 @@
-

You are {{account.user.points.away_free_delivery || 0}} points away

from a free delivery. Earn points by ordering food, sharing your order, or referring friends.


+

You are {{account.user.points.away_free_delivery || 0}} points away from a free delivery. Earn points by ordering food, sharing your order, or referring friends.


You have {{account.user.points.free_delivery}} points!

The next delivery fee is on us.

@@ -19,7 +19,7 @@

- Get your friends to enter your referal code in the Notes section of their first order, and they will get $3 off and you a delivery free ;) + Get your friends to enter your referral code in the Notes section of their first order, and they will get $3 off and you a delivery free ;)



diff --git a/www/assets/js/services.referral.js b/www/assets/js/services.referral.js index 2dfd574bf..8b6373cd9 100644 --- a/www/assets/js/services.referral.js +++ b/www/assets/js/services.referral.js @@ -28,12 +28,12 @@ NGApp.factory( 'ReferralService', function( $http, $rootScope, $location, Accoun } service.sms = function(){ - var text = 'i love crunchbutton delivery :) use my code ' + service.invite_code + ' in the Notes section and get $3 off your 1st order!'; + var text = 'I love crunchbutton delivery :) use my code ' + service.invite_code + ' in the Notes section and get your first order delivered for free!'; if( App.iOS() ){ - return 'sms:&body=' + text + ' ' + service.invite_url; + return 'sms:body=' + text + ' ' + service.invite_url; } else { // this appears to be the standard and should work for other non droid phones - return 'sms:?body=' + text + ' ' + service.invite_url; + return 'sms:body=' + text + ' ' + service.invite_url; } }