Пример #1
0
 public function testTWorks()
 {
     $stringa = "str";
     $file = "f";
     App::shouldReceive('setLocale');
     Lang::shouldReceive('get')->once()->with("{$file}.{$stringa}");
     L::t($stringa, $file);
 }
Пример #2
0
 public function validate()
 {
     if ($this->row_orders->isEmpty()) {
         $this->errors->add("row_orders", L::t("There is no product in the cart."));
         return false;
     }
     return true;
 }
 /**
  * Translates a to url
  *
  * @param nome     action
  * @param $params  parametri
  * @return mixed
  */
 public function to($name, $params = null)
 {
     return $this->base("to", L::t($name), $params);
 }
Пример #4
0
 public function sendEmailToClient()
 {
     $mailer = App::make('palmamailer');
     // get the client email
     $email = $this->getClientEmail();
     // send the email with the information
     $mailer->sendTo($email, ["session_order_key" => $this->session_mail_order, 'email' => $email], L::t('Order number:') . $this->order->id . ' ' . L::t('created succesfully'), 'catalog::mail.order-sent-client');
 }