diff --git a/.gitignore b/.gitignore
index e0d0d37db7..4f688793b4 100755
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1,4 @@
+/app/config/staging
/bootstrap/compiled.php
/vendor
composer.phar
diff --git a/app/config/app.php b/app/config/app.php
index 90d2aeec0f..962dd37a46 100755
--- a/app/config/app.php
+++ b/app/config/app.php
@@ -65,7 +65,7 @@ return array(
|
*/
- 'key' => 'Zwa83ZM8ZYjEAfHWXl7SvYwVdV9X*oU1',
+ 'key' => 'a2jfy6HtBEdNtJnRSOC7vIM3UVhxZ1BB',
/*
|--------------------------------------------------------------------------
diff --git a/app/controllers/AccountController.php b/app/controllers/AccountController.php
index b5be1a7548..ba3006cc5a 100755
--- a/app/controllers/AccountController.php
+++ b/app/controllers/AccountController.php
@@ -4,8 +4,12 @@ class AccountController extends \BaseController {
public function getStarted()
{
- $user = false;
+ if (Auth::check())
+ {
+ return Redirect::to('invoices/create');
+ }
+ $user = false;
$guestKey = Input::get('guest_key');
if ($guestKey)
@@ -128,7 +132,7 @@ class AccountController extends \BaseController {
$contacts = DB::table('contacts')->whereIn('client_id', function($query){
$query->select('client_id')->from('clients')->where('account_id','=',Auth::user()->account_id);
})->get();
- AccountController::exportData($output, toArray($contacts));
+ AccountController::exportData($output, Utils::toArray($contacts));
$invoices = Invoice::where('account_id','=',Auth::user()->account_id)->get();
AccountController::exportData($output, $invoices->toArray());
@@ -136,7 +140,7 @@ class AccountController extends \BaseController {
$invoiceItems = DB::table('invoice_items')->whereIn('invoice_id', function($query){
$query->select('invoice_id')->from('invoices')->where('account_id','=',Auth::user()->account_id);
})->get();
- AccountController::exportData($output, toArray($invoiceItems));
+ AccountController::exportData($output, Utils::toArray($invoiceItems));
$payments = Payment::where('account_id','=',Auth::user()->account_id)->get();
AccountController::exportData($output, $payments->toArray());
@@ -251,7 +255,7 @@ class AccountController extends \BaseController {
$client->contacts()->save($contact);
}
- $message = pluralize('Successfully created ? client', $count);
+ $message = Utils::pluralize('Successfully created ? client', $count);
Session::flash('message', $message);
return Redirect::to('clients');
}
diff --git a/app/controllers/ActivityController.php b/app/controllers/ActivityController.php
index 72daee516e..04713f2106 100755
--- a/app/controllers/ActivityController.php
+++ b/app/controllers/ActivityController.php
@@ -7,7 +7,7 @@ class ActivityController extends \BaseController {
$clientId = Client::getPrivateId($clientPublicId);
return Datatable::collection(Activity::scope()->where('client_id','=',$clientId)->get())
- ->addColumn('date', function($model) { return timestampToDateString($model->created_at); })
+ ->addColumn('date', function($model) { return Utils::timestampToDateString($model->created_at); })
->addColumn('message', function($model) { return $model->message; })
->addColumn('balance', function($model) { return '$' . $model->balance; })
->orderColumns('date')
diff --git a/app/controllers/ClientController.php b/app/controllers/ClientController.php
index 7cbab2cb45..5473ee8a53 100755
--- a/app/controllers/ClientController.php
+++ b/app/controllers/ClientController.php
@@ -26,17 +26,17 @@ class ClientController extends \BaseController {
->where('clients.account_id', '=', Auth::user()->account_id)
->where('clients.deleted_at', '=', null)
->where('contacts.is_primary', '=', true)
- ->select('clients.public_id','clients.name','contacts.first_name','contacts.last_name','clients.balance','clients.last_login','clients.created_at','contacts.phone','contacts.email');
+ ->select('clients.public_id','clients.name','contacts.first_name','contacts.last_name','clients.balance','clients.last_login','clients.created_at','clients.work_phone','contacts.email');
return Datatable::query($query)
->addColumn('checkbox', function($model) { return ''; })
->addColumn('name', function($model) { return link_to('clients/' . $model->public_id, $model->name); })
->addColumn('first_name', function($model) { return $model->first_name . ' ' . $model->last_name; })
->addColumn('balance', function($model) { return '$' . $model->balance; })
- ->addColumn('last_login', function($model) { return timestampToDateString($model->last_login); })
- ->addColumn('created_at', function($model) { return timestampToDateString($model->created_at); })
+ ->addColumn('last_login', function($model) { return Utils::timestampToDateString($model->last_login); })
+ ->addColumn('created_at', function($model) { return Utils::timestampToDateString($model->created_at); })
->addColumn('email', function($model) { return $model->email ? HTML::mailto($model->email, $model->email) : ''; })
- ->addColumn('phone', function($model) { return $model->phone; })
+ ->addColumn('work_phone', function($model) { return Utils::formatPhoneNumber($model->work_phone); })
->addColumn('dropdown', function($model)
{
return '
@@ -92,7 +92,7 @@ class ClientController extends \BaseController {
public function show($publicId)
{
$client = Client::scope($publicId)->with('contacts')->firstOrFail();
- trackViewed($client->name, ENTITY_CLIENT);
+ Utils::trackViewed($client->name, ENTITY_CLIENT);
$data = array(
'client' => $client,
@@ -216,7 +216,7 @@ class ClientController extends \BaseController {
}
}
- $message = pluralize('Successfully '.$action.'d ? client', count($ids));
+ $message = Utils::pluralize('Successfully '.$action.'d ? client', count($ids));
Session::flash('message', $message);
return Redirect::to('clients');
diff --git a/app/controllers/CreditController.php b/app/controllers/CreditController.php
index d121b01b49..9ac8255f26 100755
--- a/app/controllers/CreditController.php
+++ b/app/controllers/CreditController.php
@@ -36,7 +36,7 @@ class CreditController extends \BaseController {
}
return $table->addColumn('amount', function($model){ return '$' . money_format('%i', $model->amount); })
- ->addColumn('credit_date', function($model) { return timestampToDateString($model->credit_date); })
+ ->addColumn('credit_date', function($model) { return Utils::timestampToDateString($model->credit_date); })
->addColumn('dropdown', function($model)
{
return '
@@ -113,7 +113,7 @@ class CreditController extends \BaseController {
}
$credit->client_id = Input::get('client');
- $credit->credit_date = toSqlDate(Input::get('credit_date'));
+ $credit->credit_date = Utils::toSqlDate(Input::get('credit_date'));
$credit->amount = floatval(Input::get('amount'));
$credit->save();
@@ -137,7 +137,7 @@ class CreditController extends \BaseController {
}
}
- $message = pluralize('Successfully '.$action.'d ? credit', count($ids));
+ $message = Utils::pluralize('Successfully '.$action.'d ? credit', count($ids));
Session::flash('message', $message);
return Redirect::to('credits');
diff --git a/app/controllers/InvoiceController.php b/app/controllers/InvoiceController.php
index b98ed0eb8e..fd26459061 100755
--- a/app/controllers/InvoiceController.php
+++ b/app/controllers/InvoiceController.php
@@ -43,8 +43,8 @@ class InvoiceController extends \BaseController {
return $table->addColumn('total', function($model){ return '$' . money_format('%i', $model->total); })
->addColumn('balance', function($model) { return '$' . money_format('%i', $model->balance); })
- ->addColumn('invoice_date', function($model) { return fromSqlDate($model->invoice_date); })
- ->addColumn('due_date', function($model) { return fromSqlDate($model->due_date); })
+ ->addColumn('invoice_date', function($model) { return Utils::fromSqlDate($model->invoice_date); })
+ ->addColumn('due_date', function($model) { return Utils::fromSqlDate($model->due_date); })
->addColumn('invoice_status_name', function($model) { return $model->invoice_status_name; })
->addColumn('dropdown', function($model)
{
@@ -237,7 +237,7 @@ class InvoiceController extends \BaseController {
public function edit($publicId)
{
$invoice = Invoice::scope($publicId)->with('account.country', 'client', 'invoice_items')->firstOrFail();
- trackViewed($invoice->invoice_number . ' - ' . $invoice->client->name, ENTITY_INVOICE);
+ Utils::trackViewed($invoice->invoice_number . ' - ' . $invoice->client->name, ENTITY_INVOICE);
$data = array(
'account' => $invoice->account,
@@ -352,8 +352,8 @@ class InvoiceController extends \BaseController {
$invoice->invoice_number = trim(Input::get('invoice_number'));
$invoice->discount = 0;
- $invoice->invoice_date = toSqlDate(Input::get('invoice_date'));
- $invoice->due_date = toSqlDate(Input::get('due_date'));
+ $invoice->invoice_date = Utils::toSqlDate(Input::get('invoice_date'));
+ $invoice->due_date = Utils::toSqlDate(Input::get('due_date'));
$invoice->notes = Input::get('notes');
$client->invoices()->save($invoice);
@@ -493,7 +493,7 @@ class InvoiceController extends \BaseController {
}
}
- $message = pluralize('Successfully '.$action.'d ? invoice', count($ids));
+ $message = Utils::pluralize('Successfully '.$action.'d ? invoice', count($ids));
Session::flash('message', $message);
return Redirect::to('invoices');
diff --git a/app/controllers/PaymentController.php b/app/controllers/PaymentController.php
index c4506870f0..038fbb90ef 100755
--- a/app/controllers/PaymentController.php
+++ b/app/controllers/PaymentController.php
@@ -38,7 +38,7 @@ class PaymentController extends \BaseController
return $table->addColumn('invoice_number', function($model) { return $model->invoice_public_id ? link_to('invoices/' . $model->invoice_public_id . '/edit', $model->invoice_invoice_number) : ''; })
->addColumn('amount', function($model) { return '$' . $model->amount; })
- ->addColumn('payment_date', function($model) { return timestampToDateString($model->payment_date); })
+ ->addColumn('payment_date', function($model) { return Utils::timestampToDateString($model->payment_date); })
->addColumn('dropdown', function($model)
{
return '
@@ -122,7 +122,7 @@ class PaymentController extends \BaseController
$payment->client_id = Input::get('client');
$payment->invoice_id = $invoiceId;
- $payment->payment_date = toSqlDate(Input::get('payment_date'));
+ $payment->payment_date = Utils::toSqlDate(Input::get('payment_date'));
$payment->amount = floatval(Input::get('amount'));
$payment->save();
@@ -146,7 +146,7 @@ class PaymentController extends \BaseController
}
}
- $message = pluralize('Successfully '.$action.'d ? payment', count($ids));
+ $message = Utils::pluralize('Successfully '.$action.'d ? payment', count($ids));
Session::flash('message', $message);
return Redirect::to('payments');
diff --git a/app/controllers/UserController.php b/app/controllers/UserController.php
index e26a8da9cc..8a01ce33f5 100755
--- a/app/controllers/UserController.php
+++ b/app/controllers/UserController.php
@@ -74,7 +74,7 @@ class UserController extends BaseController {
{
if( Confide::user() )
{
- return Redirect::to('/');
+ return Redirect::to('/clients');
}
else
{
@@ -173,6 +173,14 @@ class UserController extends BaseController {
*/
public function do_forgot_password()
{
+ Confide::forgotPassword( Input::get( 'email' ) );
+
+ $notice_msg = Lang::get('confide::confide.alerts.password_forgot');
+ return Redirect::action('UserController@login')
+ ->with( 'notice', $notice_msg );
+
+
+ /*
if( Confide::forgotPassword( Input::get( 'email' ) ) )
{
$notice_msg = Lang::get('confide::confide.alerts.password_forgot');
@@ -186,6 +194,7 @@ class UserController extends BaseController {
->withInput()
->with( 'error', $error_msg );
}
+ */
}
/**
diff --git a/app/libraries/utils.php b/app/libraries/utils.php
new file mode 100755
index 0000000000..eb433f0e7a
--- /dev/null
+++ b/app/libraries/utils.php
@@ -0,0 +1,152 @@
+ 10) {
+ $countryCode = substr($phoneNumber, 0, strlen($phoneNumber)-10);
+ $areaCode = substr($phoneNumber, -10, 3);
+ $nextThree = substr($phoneNumber, -7, 3);
+ $lastFour = substr($phoneNumber, -4, 4);
+
+ $phoneNumber = '+'.$countryCode.' ('.$areaCode.') '.$nextThree.'-'.$lastFour;
+ }
+ else if(strlen($phoneNumber) == 10) {
+ $areaCode = substr($phoneNumber, 0, 3);
+ $nextThree = substr($phoneNumber, 3, 3);
+ $lastFour = substr($phoneNumber, 6, 4);
+
+ $phoneNumber = '('.$areaCode.') '.$nextThree.'-'.$lastFour;
+ }
+ else if(strlen($phoneNumber) == 7) {
+ $nextThree = substr($phoneNumber, 0, 3);
+ $lastFour = substr($phoneNumber, 3, 4);
+
+ $phoneNumber = $nextThree.'-'.$lastFour;
+ }
+
+ return $phoneNumber;
+ }
+
+ function pluralize($string, $count)
+ {
+ $string = str_replace('?', $count, $string);
+ return $count == 1 ? $string : $string . 's';
+ }
+
+ function toArray($data)
+ {
+ return json_decode(json_encode((array) $data), true);
+ }
+
+ function toSpaceCase($camelStr)
+ {
+ return preg_replace('/([a-z])([A-Z])/s','$1 $2', $camelStr);
+ }
+
+ function timestampToDateTimeString($timestamp) {
+ $tz = Session::get('tz');
+ if (!$tz) {
+ $tz = 'US/Eastern';
+ }
+ $date = new Carbon($timestamp);
+ $date->tz = $tz;
+ if ($date->year < 1900) {
+ return '';
+ }
+
+ return $date->format('l M jS, Y g:ia');
+ }
+
+ function timestampToDateString($timestamp) {
+ $tz = Session::get('tz');
+ if (!$tz) {
+ $tz = 'US/Eastern';
+ }
+ $date = new Carbon($timestamp);
+ $date->tz = $tz;
+ if ($date->year < 1900) {
+ return '';
+ }
+ return $date->toFormattedDateString();
+ }
+
+ /*
+ function toDateString($date)
+ {
+ if ($date->year < 1900) {
+ return '';
+ }
+ $tz = Session::get('tz');
+ if (!$tz) {
+ $tz = 'US/Eastern';
+ }
+ $date->tz = $tz;
+ return $date->toFormattedDateString();
+ }
+ */
+
+ function toSqlDate($date)
+ {
+ if (!$date)
+ {
+ return '';
+ }
+
+ return DateTime::createFromFormat('m/d/Y', $date);
+ }
+
+ function fromSqlDate($date)
+ {
+ if (!$date || $date == '0000-00-00')
+ {
+ return '';
+ }
+
+ return DateTime::createFromFormat('Y-m-d', $date)->format('m/d/Y');
+ }
+
+ function trackViewed($name, $type)
+ {
+ $url = Request::url();
+ $viewed = Session::get(RECENTLY_VIEWED);
+
+ if (!$viewed)
+ {
+ $viewed = [];
+ }
+
+ $object = new stdClass;
+ $object->url = $url;
+ $object->name = ucwords($type) . ': ' . $name;
+
+ for ($i=0; $i
url == $item->url)
+ {
+ array_splice($viewed, $i, 1);
+ break;
+ }
+ }
+
+ array_unshift($viewed, $object);
+
+ if (count($viewed) > RECENTLY_VIEWED_LIMIT)
+ {
+ array_pop($viewed);
+ }
+
+ Session::put(RECENTLY_VIEWED, $viewed);
+ }
+
+
+}
\ No newline at end of file
diff --git a/app/models/Client.php b/app/models/Client.php
index fc07d9b009..75c83db1d7 100755
--- a/app/models/Client.php
+++ b/app/models/Client.php
@@ -86,7 +86,7 @@ class Client extends EntityModel
if ($this->work_phone)
{
- $str .= '' . $this->work_phone;
+ $str .= '' . Utils::formatPhoneNumber($this->work_phone);
}
return $str;
diff --git a/app/models/Contact.php b/app/models/Contact.php
index ec1aa284ba..9d417a0a09 100755
--- a/app/models/Contact.php
+++ b/app/models/Contact.php
@@ -63,7 +63,7 @@ class Contact extends EntityModel
if ($this->phone)
{
- $str .= '' . $this->phone;
+ $str .= '' . Utils::formatPhoneNumber($this->phone);
}
if ($str)
diff --git a/app/models/User.php b/app/models/User.php
index 0e88039d9b..b7f1ab07d8 100755
--- a/app/models/User.php
+++ b/app/models/User.php
@@ -4,7 +4,7 @@ use Illuminate\Auth\UserInterface;
use Illuminate\Auth\Reminders\RemindableInterface;
use Zizaco\Confide\ConfideUser;
-class User extends ConfideUser implements UserInterface, RemindableInterface, iPerson
+class User extends ConfideUser implements UserInterface, RemindableInterface
{
protected $softDelete = true;
diff --git a/app/routes.php b/app/routes.php
index 93dbf0103e..bffbf9129f 100755
--- a/app/routes.php
+++ b/app/routes.php
@@ -39,7 +39,7 @@ Route::filter('auth', function()
{
if (!Auth::check())
{
- return Redirect::to('/');
+ return Redirect::to('/login');
}
});
@@ -105,142 +105,6 @@ HTML::macro('image_data', function($imagePath) {
});
-function pluralize($string, $count)
-{
- $string = str_replace('?', $count, $string);
- return $count == 1 ? $string : $string . 's';
-}
-
-function toArray($data)
-{
- return json_decode(json_encode((array) $data), true);
-}
-
-function toSpaceCase($camelStr)
-{
- return preg_replace('/([a-z])([A-Z])/s','$1 $2', $camelStr);
-}
-
-function timestampToDateTimeString($timestamp) {
- $tz = Session::get('tz');
- if (!$tz) {
- $tz = 'US/Eastern';
- }
- $date = new Carbon($timestamp);
- $date->tz = $tz;
- if ($date->year < 1900) {
- return '';
- }
-
- return $date->format('l M jS, Y g:ia');
-}
-
-function timestampToDateString($timestamp) {
- $tz = Session::get('tz');
- if (!$tz) {
- $tz = 'US/Eastern';
- }
- $date = new Carbon($timestamp);
- $date->tz = $tz;
- if ($date->year < 1900) {
- return '';
- }
- return $date->toFormattedDateString();
-}
-
-
-function toDateString($date)
-{
- if ($date->year < 1900) {
- return '';
- }
- $tz = Session::get('tz');
- if (!$tz) {
- $tz = 'US/Eastern';
- }
- $date->tz = $tz;
- return $date->toFormattedDateString();
-}
-
-
-function toDateTimeString($date)
-{
-
-}
-
-function toSqlDate($date)
-{
- if (!$date)
- {
- return '';
- }
-
- return DateTime::createFromFormat('m/d/Y', $date);
-}
-
-function fromSqlDate($date)
-{
- if (!$date || $date == '0000-00-00')
- {
- return '';
- }
-
- return DateTime::createFromFormat('Y-m-d', $date)->format('m/d/Y');
-}
-
-function fromSqlTimestamp($date)
-{
- if (!$date || $date == '0000-00-00 00:00:00')
- {
- return '';
- }
-
- return DateTime::createFromFormat('Y-m-d H:i:s', $date)->format('m/d/Y h:ia');
-}
-
-function processedRequest($url)
-{
- //Session::put(Input::get('_token'), $url);
- //Session::put('_token', md5(microtime()));
-}
-
-
-
-function trackViewed($name, $type)
-{
- $url = Request::url();
- $viewed = Session::get(RECENTLY_VIEWED);
-
- if (!$viewed)
- {
- $viewed = [];
- }
-
- $object = new stdClass;
- $object->url = $url;
- $object->name = ucwords($type) . ': ' . $name;
-
- for ($i=0; $iurl == $item->url)
- {
- array_splice($viewed, $i, 1);
- break;
- }
- }
-
- array_unshift($viewed, $object);
-
- if (count($viewed) > RECENTLY_VIEWED_LIMIT)
- {
- array_pop($viewed);
- }
-
- Session::put(RECENTLY_VIEWED, $viewed);
-}
-
define("ENV_DEVELOPMENT", "local");
define("ENV_STAGING", "staging");
@@ -264,23 +128,8 @@ define("ACCOUNT_EXPORT", "export");
define("DEFAULT_INVOICE_NUMBER", "0001");
define("RECENTLY_VIEWED_LIMIT", 8);
-
define('INVOICE_STATUS_DRAFT', 1);
define('INVOICE_STATUS_SENT', 2);
define('INVOICE_STATUS_VIEWED', 3);
define('INVOICE_STATUS_PARTIAL', 4);
-define('INVOICE_STATUS_PAID', 5);
-
-
-
-interface iPerson
-{
- //public function getFullName();
- //public function getPersonType();
-}
-
-interface iEntity
-{
- //public function getName();
- //public function getEntityType();
-}
\ No newline at end of file
+define('INVOICE_STATUS_PAID', 5);
\ No newline at end of file
diff --git a/app/views/accounts/settings.blade.php b/app/views/accounts/settings.blade.php
index 933f48344f..10aba2fedc 100755
--- a/app/views/accounts/settings.blade.php
+++ b/app/views/accounts/settings.blade.php
@@ -28,9 +28,9 @@
@if ($field == 'solutionType' || $field == 'landingPage')
{{-- do nothing --}}
@elseif ($field == 'testMode' || $field == 'developerMode')
- {{ Former::checkbox($gateway->id.'_'.$field)->label(toSpaceCase($field))->text('Enable') }}
+ {{ Former::checkbox($gateway->id.'_'.$field)->label(Utils::toSpaceCase($field))->text('Enable') }}
@else
- {{ Former::text($gateway->id.'_'.$field)->label(toSpaceCase($field)) }}
+ {{ Former::text($gateway->id.'_'.$field)->label(Utils::toSpaceCase($field)) }}
@endif
@endforeach
diff --git a/app/views/clients/show.blade.php b/app/views/clients/show.blade.php
index acc7c6b851..a6dd573cc0 100755
--- a/app/views/clients/show.blade.php
+++ b/app/views/clients/show.blade.php
@@ -28,7 +28,7 @@
{{ $client->name }}
@if ($client->last_login > 0)
- Last logged in {{ timestampToDateTimeString($client->last_login); }}
+ Last logged in {{ Utils::timestampToDateTimeString($client->last_login); }}
@endif
diff --git a/app/views/header.blade.php b/app/views/header.blade.php
index ae5474ab00..e15179c84d 100755
--- a/app/views/header.blade.php
+++ b/app/views/header.blade.php
@@ -35,7 +35,7 @@
@if (!Auth::check() || Auth::user()->showGreyBackground())
body {
- background-color: #EEEEEE;
+ background-color: #F6F6F6;
}
@endif
diff --git a/app/views/invoices/edit.blade.php b/app/views/invoices/edit.blade.php
index ffae6cb53d..2d796ae057 100755
--- a/app/views/invoices/edit.blade.php
+++ b/app/views/invoices/edit.blade.php
@@ -5,7 +5,7 @@
{{ Former::open($url)->method($method)->addClass('main_form')->rules(array(
- 'invoice_number' => 'required',
+ 'invoice_number' => 'required',
'invoice_date' => 'required',
'product_key' => 'max:14',
)); }}
@@ -15,8 +15,8 @@
@if ($invoice)
{{ Former::populate($invoice); }}
{{ Former::populateField('id', $invoice->public_id); }}
- {{ Former::populateField('invoice_date', fromSqlDate($invoice->invoice_date)); }}
- {{ Former::populateField('due_date', fromSqlDate($invoice->due_date)); }}
+ {{ Former::populateField('invoice_date', Utils::fromSqlDate($invoice->invoice_date)); }}
+ {{ Former::populateField('due_date', Utils::fromSqlDate($invoice->due_date)); }}
@else
{{ Former::populateField('invoice_number', $invoiceNumber) }}
{{ Former::populateField('invoice_date', date('m/d/Y')) }}
diff --git a/app/views/users/forgot_password.blade.php b/app/views/users/forgot_password.blade.php
index e69de29bb2..ff9058cd7f 100755
--- a/app/views/users/forgot_password.blade.php
+++ b/app/views/users/forgot_password.blade.php
@@ -0,0 +1,76 @@
+@extends('master')
+
+@section('head')
+
+
+
+@stop
+
+@section('body')
+
+
+ {{ Former::open('forgot_password')->addClass('form-signin') }}
+
+
+
+ {{ Form::text('email', Input::old('email'), array('placeholder' => 'Email address')) }}
+
+
+
{{ Button::primary_submit('Send email', array('class' => 'btn-lg'))->block() }}
+
+
+ @if ( Session::get('error') )
+
{{{ Session::get('error') }}}
+ @endif
+
+ @if ( Session::get('notice') )
+
{{{ Session::get('notice') }}}
+ @endif
+
+
+ {{ Former::close() }}
+
+
+
+@stop
\ No newline at end of file
diff --git a/app/views/users/login.blade.php b/app/views/users/login.blade.php
index a0a379205d..ebbefb5b8e 100755
--- a/app/views/users/login.blade.php
+++ b/app/views/users/login.blade.php
@@ -1,20 +1,6 @@
-
-
-
-
-
-
-
-
-
+@extends('master')
-
-
-
-
+@section('head')
-
-
- {{ Basset::show('bootstrapper.css') }}
- {{ Basset::show('bootstrapper.js') }}
-
-
-
-
+@stop
+@section('body')
- {{ Form::open(array('url' => 'login', 'class' => 'form-signin')) }}
+ {{ Former::open('login')->addClass('form-signin') }}
@@ -85,8 +65,8 @@
{{ Button::primary_submit('Sign In', array('class' => 'btn-lg'))->block() }}
- {{ link_to('user/forgot_password', 'Recover your password') }}
-
+ {{ link_to('forgot_password', 'Recover your password') }}
+
@if ( Session::get('error') )
{{{ Session::get('error') }}}
@@ -97,12 +77,8 @@
@endif
- {{ Form::close() }}
+ {{ Former::close() }}
-
-
-
-
-
+@stop
\ No newline at end of file
diff --git a/bootstrap/start.php b/bootstrap/start.php
index 9d742bc958..e9f67416a8 100755
--- a/bootstrap/start.php
+++ b/bootstrap/start.php
@@ -29,6 +29,7 @@ $app->redirectIfTrailingSlash();
$env = $app->detectEnvironment(array(
'local' => array('precise64'),
+ 'staging' => array('host107.hostmonster.com')
));
diff --git a/composer.json b/composer.json
index 3716c0e4f3..d2743351c6 100755
--- a/composer.json
+++ b/composer.json
@@ -22,7 +22,8 @@
"app/models",
"app/database/migrations",
"app/database/seeds",
- "app/tests/TestCase.php"
+ "app/tests/TestCase.php",
+ "app/libraries"
]
},
"scripts": {
diff --git a/public/js/bootstrap-combobox.js b/public/js/bootstrap-combobox.js
index 639c42ac02..d46eb80a1a 100755
--- a/public/js/bootstrap-combobox.js
+++ b/public/js/bootstrap-combobox.js
@@ -93,6 +93,7 @@
this.$element.attr('class', this.$source.attr('class'));
this.$element.attr('tabindex', this.$source.attr('tabindex'));
this.$source.removeAttr('tabindex');
+ this.$source.removeAttr('required');
}
, select: function () {