final checkout and card

This commit is contained in:
Kevin Adametz 2019-02-21 21:38:36 +01:00
parent 4bd21bd986
commit 1953c97cd0
33 changed files with 2131 additions and 1084 deletions

10
.env
View file

@ -1,11 +1,12 @@
APP_NAME="mivita.care" APP_NAME=mivita.care
APP_ENV=local APP_ENV=local
APP_DEBUG=true APP_DEBUG=true
APP_KEY=base64:HrWQ9AV3Zt2TU0iq1OeUUpTUaXwNUdh8xHmx7RXTif4= APP_KEY=base64:HrWQ9AV3Zt2TU0iq1OeUUpTUaXwNUdh8xHmx7RXTif4=
APP_URL=http://mivita.local/ APP_URL=https://mivita.local/
APP_DOMAIN=mivita.local APP_DOMAIN=mivita.local
APP_PROTOCOL=http:// APP_PROTOCOL=https://
APP_URL_MAIN= APP_URL_MAIN=
APP_URL_CHECKOUT=checkout.
#APP_URL_MAIN=dev. #APP_URL_MAIN=dev.
APP_URL_CRM=mein. APP_URL_CRM=mein.
@ -22,6 +23,9 @@ DB_PASSWORD=KT32vQ7
#DB_USERNAME=d02c1ed2 #DB_USERNAME=d02c1ed2
#DB_PASSWORD=H7mdYuVTV6pNHDVu #DB_PASSWORD=H7mdYuVTV6pNHDVu
PAYONE_URL = checkout.mivita.care
PAYONE_TS = checkout.mivita.care/transaction/status
PAYONE_KEY = Zjop5cvP2UeB7Qhy
BROADCAST_DRIVER=log BROADCAST_DRIVER=log
CACHE_DRIVER=file CACHE_DRIVER=file

924
.idea/workspace.xml generated

File diff suppressed because it is too large Load diff

View file

@ -5,7 +5,7 @@ namespace PHPSTORM_META {
/** /**
* PhpStorm Meta file, to provide autocomplete information for PhpStorm * PhpStorm Meta file, to provide autocomplete information for PhpStorm
* Generated on 2019-01-03 18:54:53. * Generated on 2019-02-21 17:50:01.
* *
* @author Barry vd. Heuvel <barryvdh@gmail.com> * @author Barry vd. Heuvel <barryvdh@gmail.com>
* @see https://github.com/barryvdh/laravel-ide-helper * @see https://github.com/barryvdh/laravel-ide-helper

View file

@ -3,7 +3,7 @@
/** /**
* A helper file for Laravel 5, to provide autocomplete information to your IDE * A helper file for Laravel 5, to provide autocomplete information to your IDE
* Generated for Laravel 5.6.39 on 2019-01-03 18:54:52. * Generated for Laravel 5.6.39 on 2019-02-21 17:50:01.
* *
* This file should not be included in your code, only analyzed by your IDE! * This file should not be included in your code, only analyzed by your IDE!
* *
@ -17425,12 +17425,61 @@ namespace App\Services\Facade {
/** /**
* *
* *
* @param $shipping
* @static * @static
*/ */
public static function setShipping($shipping) public static function putShippingExtra($key, $value)
{ {
return \App\Services\Yard::setShipping($shipping); return \App\Services\Yard::putShippingExtra($key, $value);
}
/**
*
*
* @static
*/
public static function getShippingExtra($key)
{
return \App\Services\Yard::getShippingExtra($key);
}
/**
*
*
* @static
*/
public static function getShippingCountryName()
{
return \App\Services\Yard::getShippingCountryName();
}
/**
*
*
* @static
*/
public static function getShippingCountryId()
{
return \App\Services\Yard::getShippingCountryId();
}
/**
*
*
* @static
*/
public static function getYContent()
{
return \App\Services\Yard::getYContent();
}
/**
*
*
* @static
*/
public static function setShippingCountryWithPrice($shipping_country_id)
{
return \App\Services\Yard::setShippingCountryWithPrice($shipping_country_id);
} }
/** /**
@ -17477,6 +17526,20 @@ namespace App\Services\Facade {
return \App\Services\Yard::totalWithShipping($decimals, $decimalPoint, $thousandSeperator); return \App\Services\Yard::totalWithShipping($decimals, $decimalPoint, $thousandSeperator);
} }
/**
* Get the total price of the items in the cart.
*
* @param int $decimals
* @param string $decimalPoint
* @param string $thousandSeperator
* @return string
* @static
*/
public static function weight($decimals = null, $decimalPoint = null, $thousandSeperator = null)
{
return \App\Services\Yard::weight($decimals, $decimalPoint, $thousandSeperator);
}
/** /**
* Get the total price of the items in the cart. * Get the total price of the items in the cart.
* *

View file

@ -70,11 +70,34 @@ namespace App{
* @method static \Illuminate\Database\Eloquent\Builder|\App\User newQuery() * @method static \Illuminate\Database\Eloquent\Builder|\App\User newQuery()
* @method static \Illuminate\Database\Eloquent\Builder|\App\User query() * @method static \Illuminate\Database\Eloquent\Builder|\App\User query()
* @method static \Illuminate\Database\Eloquent\Builder|\App\User whereAccountId($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\User whereAccountId($value)
* @property-read \App\Models\UserShop $user_shop * @property-read \App\Models\UserShop $shop
*/ */
class User extends \Eloquent {} class User extends \Eloquent {}
} }
namespace App\Models{
/**
* App\Models\ShippingCountry
*
* @property int $id
* @property int $shipping_id
* @property int|null $country_id
* @property \Illuminate\Support\Carbon|null $created_at
* @property \Illuminate\Support\Carbon|null $updated_at
* @property-read \App\Models\Country|null $country
* @property-read \App\Models\Shipping $shipping
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingCountry newModelQuery()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingCountry newQuery()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingCountry query()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingCountry whereCountryId($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingCountry whereCreatedAt($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingCountry whereId($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingCountry whereShippingId($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingCountry whereUpdatedAt($value)
*/
class ShippingCountry extends \Eloquent {}
}
namespace App\Models{ namespace App\Models{
/** /**
* App\Models\Category * App\Models\Category
@ -130,6 +153,40 @@ namespace App\Models{
class UserUpdateEmail extends \Eloquent {} class UserUpdateEmail extends \Eloquent {}
} }
namespace App\Models{
/**
* App\Models\ShippingPrice
*
* @property int $id
* @property int $shipping_id
* @property float|null $price
* @property float|null $tax
* @property float|null $factor
* @property float|null $total_from
* @property float|null $total_to
* @property int|null $weight_from
* @property int|null $weight_to
* @property \Illuminate\Support\Carbon|null $created_at
* @property \Illuminate\Support\Carbon|null $updated_at
* @property-read \App\Models\Shipping $shipping
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice newModelQuery()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice newQuery()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice query()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice whereCreatedAt($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice whereFactor($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice whereId($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice wherePrice($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice whereShippingId($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice whereTax($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice whereTotalFrom($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice whereTotalTo($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice whereUpdatedAt($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice whereWeightFrom($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\ShippingPrice whereWeightTo($value)
*/
class ShippingPrice extends \Eloquent {}
}
namespace App\Models{ namespace App\Models{
/** /**
* App\Models\Product * App\Models\Product
@ -202,10 +259,39 @@ namespace App\Models{
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Product newModelQuery() * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Product newModelQuery()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Product newQuery() * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Product newQuery()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Product query() * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Product query()
* @property int|null $weight
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Product whereWeight($value)
*/ */
class Product extends \Eloquent {} class Product extends \Eloquent {}
} }
namespace App\Models{
/**
* App\Models\Shipping
*
* @property int $id
* @property string $name
* @property array|null $trans_name
* @property float|null $free
* @property int $active
* @property \Illuminate\Support\Carbon|null $created_at
* @property \Illuminate\Support\Carbon|null $updated_at
* @property-read \Illuminate\Database\Eloquent\Collection|\App\Models\ShippingCountry[] $countries
* @property-read \Illuminate\Database\Eloquent\Collection|\App\Models\ShippingPrice[] $prices
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Shipping newModelQuery()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Shipping newQuery()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Shipping query()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Shipping whereActive($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Shipping whereCreatedAt($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Shipping whereFree($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Shipping whereId($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Shipping whereName($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Shipping whereTransName($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\Shipping whereUpdatedAt($value)
*/
class Shipping extends \Eloquent {}
}
namespace App\Models{ namespace App\Models{
/** /**
* App\Models\Country * App\Models\Country
@ -422,13 +508,12 @@ namespace App\Models{
* @property string $name * @property string $name
* @property string $slug * @property string $slug
* @property int $active * @property int $active
* @property int|null $set_defaults
* @property string|null $active_date * @property string|null $active_date
* @property string $title * @property string|null $title
* @property array|null $trans_title * @property string|null $contact
* @property string|null $copy * @property string|null $accessibility
* @property array|null $trans_copy * @property string|null $about
* @property string|null $info
* @property array|null $trans_info
* @property array|null $featured * @property array|null $featured
* @property string|null $filename * @property string|null $filename
* @property string|null $originalname * @property string|null $originalname
@ -438,6 +523,7 @@ namespace App\Models{
* @property \Illuminate\Support\Carbon|null $created_at * @property \Illuminate\Support\Carbon|null $created_at
* @property \Illuminate\Support\Carbon|null $updated_at * @property \Illuminate\Support\Carbon|null $updated_at
* @property \Illuminate\Support\Carbon|null $deleted_at * @property \Illuminate\Support\Carbon|null $deleted_at
* @property-read \Illuminate\Database\Eloquent\Collection|\App\Models\UserShopOnSite[] $on_sites
* @property-read \App\User $user * @property-read \App\User $user
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop findSimilarSlugs($attribute, $config, $slug) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop findSimilarSlugs($attribute, $config, $slug)
* @method static bool|null forceDelete() * @method static bool|null forceDelete()
@ -446,25 +532,24 @@ namespace App\Models{
* @method static \Illuminate\Database\Query\Builder|\App\Models\UserShop onlyTrashed() * @method static \Illuminate\Database\Query\Builder|\App\Models\UserShop onlyTrashed()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop query() * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop query()
* @method static bool|null restore() * @method static bool|null restore()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereAbout($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereAccessibility($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereActive($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereActive($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereActiveDate($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereActiveDate($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereCopy($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereContact($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereCreatedAt($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereCreatedAt($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereDeletedAt($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereDeletedAt($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereExt($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereExt($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereFeatured($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereFeatured($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereFilename($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereFilename($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereId($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereId($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereInfo($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereMine($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereMine($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereName($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereName($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereOriginalname($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereOriginalname($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereSetDefaults($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereSize($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereSize($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereSlug($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereSlug($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereTitle($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereTitle($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereTransCopy($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereTransInfo($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereTransTitle($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereUpdatedAt($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereUpdatedAt($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereUserId($value) * @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShop whereUserId($value)
* @method static \Illuminate\Database\Query\Builder|\App\Models\UserShop withTrashed() * @method static \Illuminate\Database\Query\Builder|\App\Models\UserShop withTrashed()
@ -473,6 +558,39 @@ namespace App\Models{
class UserShop extends \Eloquent {} class UserShop extends \Eloquent {}
} }
namespace App\Models{
/**
* App\Models\UserShopOnSite
*
* @property int $id
* @property int $user_shop_id
* @property string|null $filename
* @property string|null $original_name
* @property string|null $ext
* @property string|null $mine
* @property int|null $size
* @property string $slug
* @property \Illuminate\Support\Carbon|null $created_at
* @property \Illuminate\Support\Carbon|null $updated_at
* @property-read \App\Models\UserShop $product
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite findSimilarSlugs($attribute, $config, $slug)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite newModelQuery()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite newQuery()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite query()
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite whereCreatedAt($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite whereExt($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite whereFilename($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite whereId($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite whereMine($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite whereOriginalName($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite whereSize($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite whereSlug($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite whereUpdatedAt($value)
* @method static \Illuminate\Database\Eloquent\Builder|\App\Models\UserShopOnSite whereUserShopId($value)
*/
class UserShopOnSite extends \Eloquent {}
}
namespace App\Models{ namespace App\Models{
/** /**
* App\Models\ProductCategory * App\Models\ProductCategory

View file

@ -5,8 +5,9 @@ namespace App\Http\Controllers\Web;
use App\Http\Controllers\Controller; use App\Http\Controllers\Controller;
use App\Models\Product; use App\Models\Product;
use App\Models\ShippingCountry; use App\Models\ShoppingInstance;
use Util; use Validator;
use App\Services\Util;
use Yard; use Yard;
use Input; use Input;
@ -33,8 +34,10 @@ class CardController extends Controller
if($product->images->count()){ if($product->images->count()){
$image = $product->images->first()->slug; $image = $product->images->first()->slug;
} }
Yard::instance('shopping')->add($product->id, $product->getLang('name'), $quantity, $product->price, ['image' => $image, 'slug' => $product_slug]); Yard::instance('shopping')->add($product->id, $product->getLang('name'), $quantity, $product->price, ['image' => $image, 'slug' => $product_slug, 'weight' => $product->weight]);
\Session()->flash('show-card-after-add', true);
} }
return back(); return back();
} }
@ -50,7 +53,8 @@ class CardController extends Controller
$image = $product->images->first()->slug; $image = $product->images->first()->slug;
} }
$quantity = Input::get('quantity') ? Input::get('quantity') : 1; $quantity = Input::get('quantity') ? Input::get('quantity') : 1;
Yard::instance('shopping')->add($product->id, $product->getLang('name'), $quantity, $product->price, ['image' => $image, 'slug' => $product->slug]); Yard::instance('shopping')->add($product->id, $product->getLang('name'), $quantity, $product->price, ['image' => $image, 'slug' => $product->slug, 'weight' => $product->weight]);
\Session()->flash('show-card-after-add', true);
} }
return back(); return back();
@ -60,12 +64,11 @@ class CardController extends Controller
public function showCard(){ public function showCard(){
if(Input::get('selected_country')){ if(Input::get('selected_country')){
$selected_country = Input::get('selected_country'); Yard::instance('shopping')->setShippingCountryWithPrice(Input::get('selected_country'));
}else{ }else{
$ShippingCountry = ShippingCountry::where('country_id', 1)->first(); // $ShippingCountry = ShippingCountry::where('country_id', 1)->first();
$selected_country = $ShippingCountry->id; // $selected_country = $ShippingCountry->id;
} }
Yard::instance('shopping')->setShippingCountry($selected_country);
$data = [ $data = [
'user_shop' => Util::getUserShop(), 'user_shop' => Util::getUserShop(),
@ -86,29 +89,31 @@ class CardController extends Controller
return back(); return back();
} }
public function checkoutCard(){# public function checkoutServer(){
if(Input::get('selected_country')){
$selected_country = Input::get('selected_country');
}else{ $user_shop = Util::getUserShop();
$ShippingCountry = ShippingCountry::where('country_id', 1)->first();
$selected_country = $ShippingCountry->id;
} do {
Yard::instance('shopping')->setShippingCountry($selected_country); $identifier = Util::getToken();
$data = [ } while( ShoppingInstance::where('identifier', $identifier)->count() );
'user_shop' => Util::getUserShop(),
]; ShoppingInstance::create([
return view('web.templates.checkout', $data); 'identifier' => $identifier,
'user_shop_id' => $user_shop->id,
'subdomain' => url('/'),
'country_id' => Yard::instance('shopping')->getShippingCountryId(),
]);
Yard::instance('shopping')->store($identifier);
//add to DB
$path = route('checkout.checkout_card', ['identifier'=>$identifier]);
$path = str_replace('http', 'https', $path);
return redirect()->secure($path);
} }
public function checkoutFinalCard(){
$data = [
'user_shop' => Util::getUserShop(),
];
return view('web.templates.checkout-final', $data);
}
public function removeCard($rowId){ public function removeCard($rowId){
Yard::instance('shopping')->remove($rowId); Yard::instance('shopping')->remove($rowId);

View file

@ -10,7 +10,7 @@ use App\Services\Util;
use Yard; use Yard;
use Input; use Input;
class CardController extends Controller class CheckoutController extends Controller
{ {
/** /**
* Create a new controller instance. * Create a new controller instance.
@ -23,72 +23,12 @@ class CardController extends Controller
//Cart::instance('wishlist')->add('sdjk922', 'Product 2', 1, 19.95, ['size' => 'medium']); public function checkout(){
public function addToCardGet($id, $quantity = 1, $product_slug = false)
{
$product = Product::find($id); $user_shop = Util::getUserShop();
if($product){
$image = "";
if($product->images->count()){
$image = $product->images->first()->slug;
}
Yard::instance('shopping')->add($product->id, $product->getLang('name'), $quantity, $product->price, ['image' => $image, 'slug' => $product_slug, 'weight' => $product->weight]);
\Session()->flash('show-card-after-add', true);
}
return back();
}
public function addToCardPost($id)
{
$product = Product::find($id);
if($product){
$image = "";
if($product->images->count()){
$image = $product->images->first()->slug;
}
$quantity = Input::get('quantity') ? Input::get('quantity') : 1;
Yard::instance('shopping')->add($product->id, $product->getLang('name'), $quantity, $product->price, ['image' => $image, 'slug' => $product->slug, 'weight' => $product->weight]);
\Session()->flash('show-card-after-add', true);
}
return back();
}
public function showCard(){
if(Input::get('selected_country')){
Yard::instance('shopping')->setShippingCountryWithPrice(Input::get('selected_country'));
}else{
// $ShippingCountry = ShippingCountry::where('country_id', 1)->first();
// $selected_country = $ShippingCountry->id;
}
$data = [
'user_shop' => Util::getUserShop(),
];
return view('web.templates.card', $data);
}
public function updateCard(){
$data = Input::all();
if(isset($data['quantity'])){
foreach ($data['quantity'] as $rowId => $qty){
Yard::instance('shopping')->update($rowId, $qty);
}
}else{
$this->deleteCard();
}
return back();
}
public function checkoutCard(){#
if(Input::get('selected_country')){ if(Input::get('selected_country')){
Yard::instance('shopping')->setShippingCountryWithPrice(Input::get('selected_country')); Yard::instance('shopping')->setShippingCountryWithPrice(Input::get('selected_country'));
}else{ }else{
@ -101,7 +41,7 @@ class CardController extends Controller
return view('web.templates.checkout', $data); return view('web.templates.checkout', $data);
} }
public function checkoutFinalCard(){ public function checkoutFinal(){
$rules = array( $rules = array(
'billing.firstname'=>'required', 'billing.firstname'=>'required',
@ -136,7 +76,6 @@ class CardController extends Controller
public function removeCard($rowId){ public function removeCard($rowId){
Yard::instance('shopping')->remove($rowId); Yard::instance('shopping')->remove($rowId);
return back(); return back();
} }
@ -147,8 +86,4 @@ class CardController extends Controller
return back(); return back();
} }
} }

View file

@ -8,7 +8,7 @@ use App\Mail\MailContact;
use GuzzleHttp\Client; use GuzzleHttp\Client;
use Input; use Input;
use Illuminate\Support\Facades\Mail; use Illuminate\Support\Facades\Mail;
use Util; use App\Services\Util;
use Validator; use Validator;

View file

@ -7,7 +7,7 @@ use App\Http\Controllers\Controller;
use App\Models\Category; use App\Models\Category;
use App\Models\Product; use App\Models\Product;
use Input; use Input;
use Util; use App\Services\Util;
class SiteController extends Controller class SiteController extends Controller
{ {

View file

@ -58,6 +58,7 @@ class Kernel extends HttpKernel
'admin' => \App\Http\Middleware\Admin::class, 'admin' => \App\Http\Middleware\Admin::class,
'superadmin' => \App\Http\Middleware\SuperAdmin::class, 'superadmin' => \App\Http\Middleware\SuperAdmin::class,
'subdomain' => \App\Http\Middleware\Subdomain::class, 'subdomain' => \App\Http\Middleware\Subdomain::class,
'checkout' => \App\Http\Middleware\Checkout::class,
'bindings' => \Illuminate\Routing\Middleware\SubstituteBindings::class, 'bindings' => \Illuminate\Routing\Middleware\SubstituteBindings::class,
'cache.headers' => \Illuminate\Http\Middleware\SetCacheHeaders::class, 'cache.headers' => \Illuminate\Http\Middleware\SetCacheHeaders::class,
'can' => \Illuminate\Auth\Middleware\Authorize::class, 'can' => \Illuminate\Auth\Middleware\Authorize::class,

View file

@ -2,13 +2,15 @@
namespace App\Http\Middleware; namespace App\Http\Middleware;
use App\Models\ShoppingInstance;
use App\Models\UserShop; use App\Models\UserShop;
use Closure; use Closure;
use Auth; use Auth;
use phpDocumentor\Reflection\DocBlock\Tags\Uses; use phpDocumentor\Reflection\DocBlock\Tags\Uses;
use Util; use App\Services\Util;
use Yard;
class Subdomain class Checkout
{ {
/** /**
* Handle an incoming request. * Handle an incoming request.
@ -19,15 +21,29 @@ class Subdomain
*/ */
public function handle($request, Closure $next) public function handle($request, Closure $next)
{ {
if(!empty($request->route('subdomain'))){
$user_shop = UserShop::where('slug', $request->route('subdomain'))->where('active', 1)->first(); if($identifier = ShoppingInstance::where('identifier', $request->route('identifier'))->first()){
$request->route()->forgetParameter('subdomain'); //user shop
Util::setPostRoute('user.'); $user_shop = $identifier->user_shop;
if($user_shop){ if($user_shop && $user_shop->active == 1){
Util::setPostRoute('user.');
\Session::put('user_shop', $user_shop); \Session::put('user_shop', $user_shop);
return $next($request); \Session::put('isCheckout', true);
} }
//restore yard
Yard::instance('shopping')->restore($request->route('identifier'));
Yard::instance('shopping')->setShippingCountryWithPrice($identifier->country_id);
ShoppingInstance::where('identifier', $request->route('identifier'))->delete();
$request->route()->forgetParameter('identifier');
return $next($request);
} }
if(\Session::has('user_shop') && \Session::has('isCheckout') && Yard::instance('shopping')->count()){
return $next($request);
}
return redirect(config('app.url')); return redirect(config('app.url'));
} }

View file

@ -3,10 +3,10 @@
namespace App\Http\Middleware; namespace App\Http\Middleware;
use App\Models\UserShop; use App\Models\UserShop;
use App\Services\Util;
use Closure; use Closure;
use Auth; use Auth;
use phpDocumentor\Reflection\DocBlock\Tags\Uses; use phpDocumentor\Reflection\DocBlock\Tags\Uses;
use Util;
class Subdomain class Subdomain
{ {
@ -19,7 +19,6 @@ class Subdomain
*/ */
public function handle($request, Closure $next) public function handle($request, Closure $next)
{ {
if(!empty($request->route('subdomain'))){ if(!empty($request->route('subdomain'))){
$user_shop = UserShop::where('slug', $request->route('subdomain'))->where('active', 1)->first(); $user_shop = UserShop::where('slug', $request->route('subdomain'))->where('active', 1)->first();
$request->route()->forgetParameter('subdomain'); $request->route()->forgetParameter('subdomain');

View file

@ -6,7 +6,7 @@ use Illuminate\Bus\Queueable;
use Illuminate\Mail\Mailable; use Illuminate\Mail\Mailable;
use Illuminate\Queue\SerializesModels; use Illuminate\Queue\SerializesModels;
use Illuminate\Contracts\Queue\ShouldQueue; use Illuminate\Contracts\Queue\ShouldQueue;
use Util; use App\Services\Util;
class MailContact extends Mailable class MailContact extends Mailable
{ {

View file

@ -0,0 +1,26 @@
<?php
namespace App\Models;
use Illuminate\Database\Eloquent\Model;
class ShoppingInstance extends Model
{
protected $table = 'shopping_instances';
protected $fillable = [
'identifier', 'user_shop_id', 'subdomain', 'country_id'
];
public function user_shop()
{
return $this->belongsTo('App\Models\UserShop', 'user_shop_id');
}
public function country()
{
return $this->belongsTo('App\Models\Country', 'country_id');
}
}

View file

@ -6,8 +6,15 @@ namespace App\Services;
class Util class Util
{ {
private static $postRoute = 'base.'; private static $postRoute = 'base.';
public static function getToken()
{
return hash_hmac('sha256', str_random(40), config('app.key'));
}
public static function formatDate(){ public static function formatDate(){
if(\App::getLocale() == "en"){ if(\App::getLocale() == "en"){
return 'yyyy-mm-dd'; return 'yyyy-mm-dd';
@ -47,6 +54,7 @@ class Util
public static function addRoute($p = []){ public static function addRoute($p = []){
$b = []; $b = [];
if(\Session::has('user_shop')){ if(\Session::has('user_shop')){
if($user_shop = \Session::get('user_shop')){ if($user_shop = \Session::get('user_shop')){
$b = ['subdomain' => $user_shop->slug]; $b = ['subdomain' => $user_shop->slug];
@ -55,4 +63,24 @@ class Util
return array_merge($p, $b); return array_merge($p, $b);
} }
public static function isCheckout(){
if(\Session::has('isCheckout')){
if(\Session::get('isCheckout') == true){
return true;
}
}
return false;
}
public static function getUserShopBackUrl($uri){
if(\Session::has('user_shop')){
if($user_shop = \Session::get('user_shop')){
return 'http://'.$user_shop->slug.".".Config('app.domain').$uri;
}
}
return url($uri);
}
} }

View file

@ -6,52 +6,95 @@ use \Gloudemans\Shoppingcart\Cart;
use Gloudemans\Shoppingcart\CartItem; use Gloudemans\Shoppingcart\CartItem;
use Illuminate\Session\SessionManager; use Illuminate\Session\SessionManager;
use Illuminate\Contracts\Events\Dispatcher; use Illuminate\Contracts\Events\Dispatcher;
use Illuminate\Support\Collection;
class Yard extends Cart class Yard extends Cart
{ {
private $shipping = 0; private $shipping = 0;
private $shipping_country_id = 0; private $shipping_country_id = 7; //default de
private $ysession;
private $yinstance;
public function __construct(SessionManager $session, Dispatcher $events) public function __construct(SessionManager $session, Dispatcher $events)
{ {
$this->ysession = $session;
$this->yinstance = sprintf('%s.%s', 'cart', 'shipping_extras');
if($this->getShippingExtra('shipping_price')){
$this->shipping = floatval($this->getShippingExtra('shipping_price'));
}
if($this->getShippingExtra('shipping_country_id')){
$this->shipping_country_id = $this->getShippingExtra('shipping_country_id');
}
parent::__construct($session, $events); parent::__construct($session, $events);
} }
public static function getTaxRate() public static function getTaxRate()
{ {
return config('cart.tax'); return config('cart.tax');
} }
/** public function putShippingExtra($key, $value){
* @param $shipping
*/ $content = $this->getYContent();
public function setShipping($shipping) $content->put($key, $value);
{ $this->ysession->put($this->yinstance, $content);
$this->shipping = floatval($shipping); ;
} }
public function setShippingCountry($shipping_country_id) public function getShippingExtra($key){
$content = $this->getYContent();
if ($content->has($key)){
return $content->get($key);
}
return false;
}
public function getShippingCountryName(){
$shippingCountry = ShippingCountry::find($this->shipping_country_id);
if($shippingCountry && $shippingCountry->country){
return $shippingCountry->country->getLocated();
}
return "";
}
public function getShippingCountryId()
{ {
$this->shipping_country_id = $shipping_country_id ; return $this->shipping_country_id;
if($this->shipping_country_id > 0){ }
$shippingCountry = ShippingCountry::find($this->shipping_country_id);
public function getYContent()
{
if (is_null($this->ysession->get($this->yinstance))) {
return new Collection([]);
}
return $this->ysession->get($this->yinstance);
}
public function setShippingCountryWithPrice($shipping_country_id)
{
$this->shipping_country_id = $shipping_country_id;
$this->putShippingExtra('shipping_country_id', $shipping_country_id);
if($shipping_country_id > 0){
$shippingCountry = ShippingCountry::find($shipping_country_id);
$shipping = $shippingCountry->shipping; $shipping = $shippingCountry->shipping;
if($this->weight()){
//blance by weigt
}
$price = $shipping->prices->first(); $price = $shipping->prices->first();
if($price){ if($price){
$this->setShipping($price->price); $this->shipping = floatval($price->price);
$this->putShippingExtra('shipping_price', $this->shipping);
} }
} }
} }
public function getShippingCountry()
{
return $this->shipping_country_id;
}
/** /**
* @param null $decimals * @param null $decimals
@ -101,7 +144,23 @@ class Yard extends Cart
/**
* Get the total price of the items in the cart.
*
* @param int $decimals
* @param string $decimalPoint
* @param string $thousandSeperator
* @return string
*/
public function weight($decimals = null, $decimalPoint = null, $thousandSeperator = null)
{
$content = $this->getContent();
$total = $content->reduce(function ($total, CartItem $cartItem) {
return $total + ($cartItem->options->weight ? intval($cartItem->options->weight) : 0);
}, 0);
return $total;
}
/** /**
* Get the total price of the items in the cart. * Get the total price of the items in the cart.
* *

View file

@ -52,16 +52,18 @@ return [
| |
*/ */
'url' => env('APP_URL', 'http://mivita.local/'), 'url' => env('APP_URL', 'mivita.local/'),
'domain' => env('APP_DOMAIN', 'mivita.local'), 'domain' => env('APP_DOMAIN', 'https://mivita.local'),
'protocol' => env('APP_PROTOCOL', 'http://'), 'protocol' => env('APP_PROTOCOL', 'https://'),
'pre_url_main' => env('APP_URL_MAIN', ''), 'pre_url_main' => env('APP_URL_MAIN', ''),
'pre_url_crm' => env('APP_URL_CRM', 'mein.'), 'pre_url_crm' => env('APP_URL_CRM', 'mein.'),
'checkout_url' => env('APP_URL_CHECKOUT', 'checkout.'),
/* 'url_backend' => env('APP_URL', 'http://mivita.local/'),
'url_backend' => env('APP_URL', 'http://mivita.local/'), /* 'url_backend' => env('APP_URL', 'http://mivita.local/'),
'url_backend' => env('APP_URL', 'http://mivita.local/'), 'url_backend' => env('APP_URL', 'http://mivita.local/'),
*/ 'url_backend' => env('APP_URL', 'http://mivita.local/'),
*/
/* /*

View file

@ -0,0 +1,46 @@
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateShoppingInstancesTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('shopping_instances', function (Blueprint $table) {
$table->string('identifier')->unique()->index();
$table->unsignedInteger('user_shop_id');
$table->unsignedInteger('country_id');
$table->string('subdomain');
$table->primary(['identifier']);
$table->timestamps();
$table->foreign('user_shop_id')
->references('id')
->on('user_shops');
$table->foreign('country_id')
->references('id')
->on('countries');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('shopping_instances');
}
}

View file

@ -153,3 +153,535 @@ div.heading-title p {
border: #b5c49b 1px solid; border: #b5c49b 1px solid;
} }
.btn-sm {
font-size: 14px;
}
.btn {
font-size: 16px;
}
.btn-text-500{
font-weight: 600;
}
div.shop-item-buttons .btn-xs {
font-size: 13px;
}
#header li.quick-cart .quick-cart-box {
padding-bottom: 0;
border: 1px solid #9ca985;
}
form input.form-control, form select.form-control, form textarea.form-control {
padding: 8px 10px;
}
form .row {
margin-bottom: 10px;
}
form .select2-container .select2-selection--single .select2-selection__rendered {
padding: 12px 20px;
height: 45px;
}
@-webkit-keyframes burst {
0% {
opacity: 1
}
75% {
-webkit-transform: scale(1.6);
transform: scale(1.6);
opacity: 1
}
85% {
-webkit-transform: scale(1.7);
transform: scale(1.7);
opacity: 0
}
100% {
opacity: 0
}
}
@keyframes burst {
0% {
opacity: 1
}
75% {
-webkit-transform: scale(1.6);
transform: scale(1.6);
opacity: 1
}
85% {
-webkit-transform: scale(1.7);
transform: scale(1.7);
opacity: 0
}
100% {
opacity: 0
}
}
.faa-burst.animated, .faa-burst.animated-hover:hover, .faa-parent.animated-hover:hover > .faa-burst {
-webkit-animation: burst 3s infinite linear;
animation: burst 3s infinite linear;
margin-left: 3px;
margin-right: 3px
}
.faa-burst.animated-hover.faa-fast:hover, .faa-burst.animated.faa-fast,
.faa-parent.animated-hover:hover > .faa-burst.faa-fast {
-webkit-animation: burst 1s infinite linear;
animation: burst 1s infinite linear
}
.faa-burst.animated-hover.faa-slow:hover, .faa-burst.animated.faa-slow,
.faa-parent.animated-hover:hover > .faa-burst.faa-slow {
-webkit-animation: burst 3s infinite linear;
animation: burst 3s infinite linear
}
/* HORIZONTAL */
@-webkit-keyframes horizontal {
0% {
-webkit-transform: translate(0,0);
transform: translate(0,0);
}
6% {
-webkit-transform: translate(5px,0);
transform: translate(5px,0);
}
12% {
-webkit-transform: translate(0,0);
transform: translate(0,0);
}
18% {
-webkit-transform: translate(5px,0);
transform: translate(5px,0);
}
24% {
-webkit-transform: translate(0,0);
transform: translate(0,0);
}
30% {
-webkit-transform: translate(5px,0);
transform: translate(5px,0);
}
36% {
-webkit-transform: translate(0,0);
transform: translate(0,0);
}
}
@keyframes horizontal {
0% {
-webkit-transform: translate(0,0);
-ms-transform: translate(0,0);
transform: translate(0,0);
}
6% {
-webkit-transform: translate(5px,0);
-ms-transform: translate(5px,0);
transform: translate(5px,0);
}
12% {
-webkit-transform: translate(0,0);
-ms-transform: translate(0,0);
transform: translate(0,0);
}
18% {
-webkit-transform: translate(5px,0);
-ms-transform: translate(5px,0);
transform: translate(5px,0);
}
24% {
-webkit-transform: translate(0,0);
-ms-transform: translate(0,0);
transform: translate(0,0);
}
30% {
-webkit-transform: translate(5px,0);
-ms-transform: translate(5px,0);
transform: translate(5px,0);
}
36% {
-webkit-transform: translate(0,0);
-ms-transform: translate(0,0);
transform: translate(0,0);
}
}
.faa-horizontal.animated,
.faa-horizontal.animated-hover:hover,
.faa-parent.animated-hover:hover > .faa-horizontal {
-webkit-animation: horizontal 4s ease infinite;
animation: horizontal 4s ease infinite;
}
/* BOUNCE */
@-webkit-keyframes bounce {
0%, 10%, 20%, 50%, 80% {
-webkit-transform: translateY(0);
transform: translateY(0);
}
40% {
-webkit-transform: translateY(-15px);
transform: translateY(-15px);
}
60% {
-webkit-transform: translateY(-15px);
transform: translateY(-15px);
}
}
@keyframes bounce {
0%, 10%, 20%, 50%, 80% {
-webkit-transform: translateY(0);
-ms-transform: translateY(0);
transform: translateY(0);
}
40% {
-webkit-transform: translateY(-15px);
-ms-transform: translateY(-15px);
transform: translateY(-15px);
}
60% {
-webkit-transform: translateY(-15px);
-ms-transform: translateY(-15px);
transform: translateY(-15px);
}
}
.faa-bounce.animated,
.faa-bounce.animated-hover:hover,
.faa-parent.animated-hover:hover > .faa-bounce {
-webkit-animation: bounce 2s ease infinite;
animation: bounce 2s ease infinite;
}
/* SPIN */
@-webkit-keyframes spin {
0% {
-webkit-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(359deg);
transform: rotate(359deg);
}
}
@keyframes spin {
0% {
-webkit-transform: rotate(0deg);
-ms-transform: rotate(0deg);
transform: rotate(0deg);
}
100% {
-webkit-transform: rotate(359deg);
-ms-transform: rotate(359deg);
transform: rotate(359deg);
}
}
.faa-spin.animated,
.faa-spin.animated-hover:hover,
.faa-parent.animated-hover:hover > .faa-spin {
-webkit-animation: spin 1.5s linear infinite;
animation: spin 1.5s linear infinite;
}
/* FLOAT */
@-webkit-keyframes float {
0% {
-webkit-transform: translateY(0);
transform: translateY(0);
}
50% {
-webkit-transform: translateY(-6px);
transform: translateY(-6px);
}
100% {
-webkit-transform: translateY(0);
transform: translateY(0);
}
}
@keyframes float {
0% {
-webkit-transform: translateY(0);
-ms-transform: translateY(0);
transform: translateY(0);
}
50% {
-webkit-transform: translateY(-6px);
-ms-transform: translateY(-6px);
transform: translateY(-6px);
}
100% {
-webkit-transform: translateY(0);
-ms-transform: translateY(0);
transform: translateY(0);
}
}
.faa-float.animated,
.faa-float.animated-hover:hover,
.faa-parent.animated-hover:hover > .faa-float {
-webkit-animation: float 2s linear infinite;
animation: float 2s linear infinite;
}
/* PULSE */
@-webkit-keyframes pulse {
0% {
-webkit-transform: scale(1.1);
transform: scale(1.1);
}
50% {
-webkit-transform: scale(0.8);
transform: scale(0.8);
}
100% {
-webkit-transform: scale(1.1);
transform: scale(1.1);
}
}
@keyframes pulse {
0% {
-webkit-transform: scale(1.1);
-ms-transform: scale(1.1);
transform: scale(1.1);
}
50% {
-webkit-transform: scale(0.8);
-ms-transform: scale(0.8);
transform: scale(0.8);
}
100% {
-webkit-transform: scale(1.1);
-ms-transform: scale(1.1);
transform: scale(1.1);
}
}
.faa-pulse.animated,
.faa-pulse.animated-hover:hover,
.faa-parent.animated-hover:hover > .faa-pulse {
-webkit-animation: pulse 2s linear infinite;
animation: pulse 2s linear infinite;
}
/* SHAKE */
.faa-shake.animated,
.faa-shake.animated-hover:hover,
.faa-parent.animated-hover:hover > .faa-shake {
-webkit-animation: wrench 2.5s ease infinite;
animation: wrench 2.5s ease infinite;
}
/* TADA */
@-webkit-keyframes tada {
0% {
-webkit-transform: scale(1);
transform: scale(1);
}
10%, 20% {
-webkit-transform: scale(.9) rotate(-8deg);
transform: scale(.9) rotate(-8deg);
}
30%, 50%, 70% {
-webkit-transform: scale(1.3) rotate(8deg);
transform: scale(1.3) rotate(8deg);
}
40%, 60% {
-webkit-transform: scale(1.3) rotate(-8deg);
transform: scale(1.3) rotate(-8deg);
}
80% {
-webkit-transform: scale(1) rotate(0);
transform: scale(1) rotate(0);
}
}
@keyframes tada {
0% {
-webkit-transform: scale(1);
-ms-transform: scale(1);
transform: scale(1);
}
10%, 20% {
-webkit-transform: scale(.9) rotate(-8deg);
-ms-transform: scale(.9) rotate(-8deg);
transform: scale(.9) rotate(-8deg);
}
30%, 50%, 70% {
-webkit-transform: scale(1.3) rotate(8deg);
-ms-transform: scale(1.3) rotate(8deg);
transform: scale(1.3) rotate(8deg);
}
40%, 60% {
-webkit-transform: scale(1.3) rotate(-8deg);
-ms-transform: scale(1.3) rotate(-8deg);
transform: scale(1.3) rotate(-8deg);
}
80% {
-webkit-transform: scale(1) rotate(0);
-ms-transform: scale(1) rotate(0);
transform: scale(1) rotate(0);
}
}
.faa-tada.animated,
.faa-tada.animated-hover:hover,
.faa-parent.animated-hover:hover > .faa-tada {
-webkit-animation: tada 2s linear infinite;
animation: tada 2s linear infinite;
}
/* PASSING */
@-webkit-keyframes passing {
0% {
-webkit-transform: translateX(-50%);
transform: translateX(-50%);
opacity: 0;
}
50% {
-webkit-transform: translateX(0%);
transform: translateX(0%);
opacity: 1;
}
100% {
-webkit-transform: translateX(50%);
transform: translateX(50%);
opacity: 0;
}
}
@keyframes passing {
0% {
-webkit-transform: translateX(-50%);
-ms-transform: translateX(-50%);
transform: translateX(-50%);
opacity: 0;
}
50% {
-webkit-transform: translateX(0%);
-ms-transform: translateX(0%);
transform: translateX(0%);
opacity: 1;
}
100% {
-webkit-transform: translateX(50%);
-ms-transform: translateX(50%);
transform: translateX(50%);
opacity: 0;
}
}
.faa-passing.animated,
.faa-passing.animated-hover:hover,
.faa-parent.animated-hover:hover > .faa-passing {
-webkit-animation: passing 3s linear infinite;
animation: passing 3s linear infinite;
}
/* WAVE */
@-webkit-keyframes burst {
0% {
opacity: .6;
}
50% {
-webkit-transform: scale(1.8);
transform: scale(1.8);
opacity: 0;
}
100% {
opacity: 0;
}
}
@keyframes burst {
0% {
opacity: .6;
}
50% {
-webkit-transform: scale(1.8);
-ms-transform: scale(1.8);
transform: scale(1.8);
opacity: 0;
}
100% {
opacity: 0;
}
}
.faa-burst.animated,
.faa-burst.animated-hover:hover,
.faa-parent.animated-hover:hover > .faa-burst {
-webkit-animation: burst 3s infinite linear;
animation: burst 3s infinite linear;
}

View file

@ -179,7 +179,19 @@ return [
'user_shop_name' => 'Shop Name', 'user_shop_name' => 'Shop Name',
'user_shop_active' => 'Nutzungsbedinungen', 'user_shop_active' => 'Nutzungsbedinungen',
'g-recaptcha-response' => 'google reCaptcha', 'g-recaptcha-response' => 'google reCaptcha',
'accepted_data_protection' => 'Einwilligung Datenschutzerklärung' 'accepted_data_protection' => 'Einwilligung Datenschutzerklärung',
'billing.firstname'=>'Vorname',
'billing.lastname'=>'Nachname',
'billing.email'=>'E-Mail-Adresse',
'billing.address'=>'Adresse',
'billing.zipcode'=>'PLZ',
'billing.city' => 'Stadt',
'accepted_data_checkbox' => 'Einwilligung',
'shipping.firstname'=>'Vorname',
'shipping.lastname'=>'Nachname',
'shipping.address'=>'Adresse',
'shipping.zipcode'=>'PLZ',
'shipping.city' => 'Stadt'
], ],
]; ];

View file

@ -43,8 +43,6 @@
<!-- SCROLL TO TOP --> <!-- SCROLL TO TOP -->
<a href="#" id="toTop"></a> <a href="#" id="toTop"></a>
<!-- JAVASCRIPT FILES --> <!-- JAVASCRIPT FILES -->
<script type="text/javascript">var plugin_path = "{{ url('/assets/plugins/').'/' }}"</script> <script type="text/javascript">var plugin_path = "{{ url('/assets/plugins/').'/' }}"</script>
<script type="text/javascript" src="{{ asset('/assets/plugins/jquery/jquery-2.2.3.min.js') }}"></script> <script type="text/javascript" src="{{ asset('/assets/plugins/jquery/jquery-2.2.3.min.js') }}"></script>

View file

@ -41,74 +41,16 @@
<!-- TOP NAV --> <!-- TOP NAV -->
<header id="topNav"> <header id="topNav">
<div class="container"> <div class="container">
<!-- Mobile Menu Button --> <!-- Mobile Menu Button -->
<button class="btn btn-mobile" data-toggle="collapse" data-target=".nav-main-collapse"> <button class="btn btn-mobile" data-toggle="collapse" data-target=".nav-main-collapse">
<i class="fa fa-bars"></i> <i class="fa fa-bars"></i>
</button> </button>
<ul class="pull-right nav nav-pills nav-second-main has-topBar">
<!-- QUICK SHOP CART -->
<li class="quick-cart">
<a href="#" style="border: 1px solid #c3c3c3; padding: 10px;">
<span style="position: relative">
<span class="badge badge-success btn-xs badge-corner">{{ Yard::instance('shopping')->count() }}</span>
<i class="fa fa-shopping-cart"></i>
</span>
&nbsp;
@if(Yard::instance('shopping')->count())
<span class="">{{ \Yard::instance('shopping')->subtotal() }} </span>
@endif
</a>
<div class="quick-cart-box" style="display: none;">
<h4>Warenkorb</h4>
<div class="quick-cart-wrapper">
@foreach(Yard::instance('shopping')->content() as $row)
<a href="{{ url('/produkte/alle-produkte/'.$row->options->slug) }}"><!-- cart item -->
@if($row->options->has('image'))
<img src="{{ route('product_image', [$row->options->image]) }}" width="50" height="66" alt="">
@else
<img src="{{ asset('/assets/images/1x1.png') }}" width="50" height="66" alt="">
@endif
<h5>{{ $row->name }}</h5>
<span class="price">{{ $row->qty }}x <strong>{{ $row->price() }} </strong></span>
</a><!-- /cart item -->
@endforeach
</div>
<!-- quick cart footer -->
<div class="quick-cart-footer clearfix">
<div class="text-left">
<strong>Zwischensumme:</strong> <strong class="pull-right">{{ Yard::instance('shopping')->subtotal() }} </strong>
<br>
<em style="font-size: 0.9em">inkl. MwSt. zzgl. Versandkosten</em>
</div>
<a href="{{ route(Util::getPostRoute().'card_show', Util::addRoute()) }}" class="btn btn-primary btn-block mt-3">zum Warenkorb</a>
</div>
</div>
</li>
</ul>
<!-- Logo --> <!-- Logo -->
<a class="logo pull-left" href="{{ url('/') }}"> <a class="logo pull-left" href="{{ url('/') }}">
<img class="fixed_top" src="/assets/images/logo_mivita.png" alt="mivita" /> <img class="fixed_top" src="/assets/images/logo_mivita.png" alt="mivita" />
<img class="fixed_scroll" src="/assets/images/logo_mivita_fixed.png" alt="mivita" /> <img class="fixed_scroll" src="/assets/images/logo_mivita_fixed.png" alt="mivita" />
</a> </a>
<div class="navbar-collapse pull-right nav-main-collapse collapse"> <div class="navbar-collapse pull-right nav-main-collapse collapse">
<nav class="nav-main"> <nav class="nav-main">
<ul id="topMain" class="nav nav-pills nav-main nav-onepage"> <ul id="topMain" class="nav nav-pills nav-main nav-onepage">
@ -140,9 +82,7 @@
</ul> </ul>
</nav> </nav>
</div> </div>
</div> </div>
</header> </header>
<!-- /Top Nav --> <!-- /Top Nav -->
</div> </div>

View file

@ -1,23 +1,12 @@
@extends('web.layouts.application') @extends('web.layouts.application')
@section('layout-content') @section('layout-content')
@include('web.layouts.includes.header') @include('web.layouts.includes.header')
<!-- wrapper --> <!-- wrapper -->
<div id="wrapper"> <div id="wrapper">
@yield('content') @yield('content')
<!-- /FOOTER --> <!-- /FOOTER -->
@include('web.layouts.includes.footer') @include('web.layouts.includes.footer')
</div> </div>
<!-- /wrapper --> <!-- /wrapper -->
@endsection @endsection

View file

@ -158,8 +158,7 @@
@endforeach @endforeach
</div> </div>
<a href="{{route(Util::getPostRoute().'card_delete', Util::addRoute())}}" class="btn btn-default btn-sm margin-top-20 margin-right-10 pull-left"><i class="glyphicon glyphicon-remove"></i> Warenkorb löschen</a> <a href="{{route(Util::getPostRoute().'card_delete', Util::addRoute())}}" class="btn btn-default btn-sm margin-top-20 margin-right-10 pull-left"><i class="glyphicon glyphicon-remove"></i> Warenkorb löschen</a>
<button type="submit" class="btn btn-primary margin-top-20 pull-right"><i class="glyphicon glyphicon-refresh"></i> Warenkorb aktualisieren</button> <button type="submit" class="btn btn-sm btn-default margin-top-20 pull-right"><i class="glyphicon glyphicon-refresh"></i> Warenkorb aktualisieren</button>
<div class="clearfix"></div> <div class="clearfix"></div>
</div> </div>
@ -202,19 +201,16 @@
<div class="small"> <div class="small">
<form action="{{ route(Util::getPostRoute().'card_show', Util::addRoute()) }}" method="GET" style="margin-bottom: 0;"> <form action="{{ route(Util::getPostRoute().'card_show', Util::addRoute()) }}" method="GET" style="margin-bottom: 0;">
<select name="selected_country" class="select2" onchange="this.form.submit()"> <select name="selected_country" class="select2" onchange="this.form.submit()">
{!! HTMLHelper::getCountriesForShipping(Yard::instance('shopping')->getShippingCountry()) !!} {!! HTMLHelper::getCountriesForShipping(Yard::instance('shopping')->getShippingCountryId()) !!}
</select> </select>
</form> </form>
</div> </div>
</div> </div>
<div class="clearfix mb-2"> <div class="clearfix mb-2">
<span class="pull-right small">{{ Yard::instance('shopping')->shipping() }} </span> <span class="pull-right small">{{ Yard::instance('shopping')->shipping() }} </span>
<span class="pull-left small">Versandkosten:</span> <span class="pull-left small">Versandkosten:</span>
</div> </div>
<hr class="mt-4 mb-4"> <hr class="mt-4 mb-4">
<div class="clearfix mb-2"> <div class="clearfix mb-2">
<span class="pull-right small">{{ Yard::instance('shopping')->subtotalWithShipping() }} </span> <span class="pull-right small">{{ Yard::instance('shopping')->subtotalWithShipping() }} </span>
<span class="pull-left small">Summe ohne MwSt:</span> <span class="pull-left small">Summe ohne MwSt:</span>
@ -222,27 +218,22 @@
<div class="clearfix mb-2"> <div class="clearfix mb-2">
<span class="pull-right small">{{ Yard::instance('shopping')->taxWithShipping() }} </span> <span class="pull-right small">{{ Yard::instance('shopping')->taxWithShipping() }} </span>
<span class="pull-left small"> zzgl. {{ Yard::getTaxRate() }} % MwSt.:</span> <span class="pull-left small"> zzgl. {{ Yard::getTaxRate() }} % MwSt:</span>
</div> </div>
<hr /> <hr />
<span class="clearfix "> <span class="clearfix ">
<span class="pull-right size-20"><strong>{{ Yard::instance('shopping')->totalWithShipping() }} </strong></span> <span class="pull-right size-20"><strong>{{ Yard::instance('shopping')->totalWithShipping() }} </strong></span>
<strong class="pull-left">Gesamtsumme:</strong> <strong class="pull-left">Gesamtsumme:</strong>
</span> </span>
<a href="{{ route(Util::getPostRoute().'card_checkout_server', Util::addRoute()) }}" class="btn btn-primary btn-lg btn-block mt-4 btn-text-500 faa-parent animated-hover"><i class="fa fa-mail-forward faa-horizontal"></i> zur Kasse</a>
<hr>
<a href="{{ route(Util::getPostRoute().'card_checkout', Util::addRoute()) }}" class="btn btn-primary btn-lg btn-block size-15 mt-4"><i class="fa fa-mail-forward"></i> zur Kasse</a> <p class="text-center" style="line-height: 1.2em;"><em class="small text-center"> <i class="fa fa-lock"></i> Sie werden auf unseren checkout Server weitergeletet, die Verbindung ist mit SSL verschlüsselt.</em></p>
</div> </div>
</div> </div>
</div> </div>
@endif @endif
</div> </div>
</div> </div>
<br><br> <br><br>
<hr> <hr>

View file

@ -12,6 +12,9 @@
<!-- /PAGE HEADER --> <!-- /PAGE HEADER -->
<style> <style>
.checkbox.error{
color:#b92c28 !important;
}
div.shop-item { div.shop-item {
margin-bottom:30px; margin-bottom:30px;
border: 1px solid #ddd; border: 1px solid #ddd;
@ -88,7 +91,20 @@
<!-- CHECKOUT --> <!-- CHECKOUT -->
<section> <section>
<div class="container"> <div class="container">
{{-- @if ($errors->any())
<div class="row">
<div class="col-sm-12">
<div class="alert alert-danger">
<ul>
@foreach ($errors->all() as $error)
<li>{{ $error }}</li>
@endforeach
</ul>
</div>
</div>
</div>
@endif
--}}
{{-- {{--
<!-- NOT LOGGED IN --> <!-- NOT LOGGED IN -->
<!-- <div class="mb-30 box-border-shadow p-20"> <!-- <div class="mb-30 box-border-shadow p-20">
@ -97,320 +113,399 @@
</div> </div>
--> -->
<!-- /NOT LOGGED IN --> <!-- /NOT LOGGED IN -->
--}} --}}<!-- CHECKOUT -->
@if ($errors->any())
<!-- CHECKOUT --> <div class="row">
<div class=""> <div class="col-sm-12">
{!! Form::open(['url' => route(Util::getPostRoute().'card_checkout_final', Util::addRoute()), 'class' => 'row clearfix', 'id'=>'']) !!} <div class="alert alert-danger">
Bitte überprüfen Sie das Formular und vervollständigen alle Angaben.
</div>
</div>
<div class="col-lg-7 col-sm-7"> </div>
@endif
<!-- BILLING --> <div class="m-checkout">
<fieldset class="mb-0 box-border-shadow p-20"> {!! Form::open(['url' => route('checkout.checkout_card_final'), 'class' => 'row clearfix', 'id'=>'']) !!}
<div class="col-lg-7 col-sm-7">
<h4>Rechnung &amp; Versand</h4> <!-- BILLING -->
<fieldset class="mb-0 box-border-shadow p-20">
<hr /> <h4>Rechnung &amp; Versand</h4>
<hr />
<div class="row"> <div class="row">
<div class="col-md-12 col-sm-12">
<div class="col-md-12 col-sm-12"> <div class="form-group">
<label class="mt-0 fs-14 fw-400" for="billing_company">Firma</label> <label class="mt-0 fs-14 fw-400" for="billing_company">Firmenname (optional)</label>
<input id="billing_company" name="billing[company]" type="text" class="form-control" /> {!! Form::text('billing[company]', null, ['class' => 'form-control', 'id'=>'billing_company']) !!}
</div>
</div> </div>
</div>
<div class="row"> </div>
<div class="col-md-6 col-sm-6"> <div class="row">
<label class="mt-0 fs-14 fw-400" for="billing_firstname">Vorname*</label> <div class="col-md-6 col-sm-6">
<input id="billing_firstname" name="billing[firstname]" type="text" class="form-control required" /> <div class="form-group">
</div> <label class="mt-0 fs-14 fw-400" for="billing_firstname">Vorname*</label>
<div class="col-md-6 col-sm-6"> {!! Form::text('billing[firstname]', null, ['class' => 'form-control '.($errors->has('billing.firstname') ? 'error' : ''), 'id'=>'billing_firstname']) !!}
<label class="mt-0 fs-14 fw-400" for="billing_lastname">Nachname *</label> @if ($errors->has('billing.firstname'))
<input id="billing_lastname" name="billing[lastname]" type="text" class="form-control required" /> <label for="billing_firstname" class="error text-danger small" style="display: block;">{{ $errors->first('billing.firstname') }}</label>
</div> @endif
</div> </div>
</div>
<div class="col-md-6 col-sm-6">
<div class="form-group">
<div class="row"> <label class="mt-0 fs-14 fw-400" for="billing_lastname">Nachname*</label>
<div class="col-lg-12"> {!! Form::text('billing[lastname]', null, ['class' => 'form-control '.($errors->has('billing.lastname') ? 'error' : ''), 'id'=>'billing_lastname']) !!}
<label class="mt-0 fs-14 fw-400" for="billing_address1">Straße Nr. *</label> @if ($errors->has('billing.lastname'))
<input id="billing_address1" name="billing[address][]" type="text" class="form-control required" placeholder="" /> <label for="billing_lastname" class="error text-danger small" style="display: block;">{{ $errors->first('billing.lastname') }}</label>
@endif
<!--<input id="billing_address2" name="billing[address][]" type="text" class="form-control margin-top-10" placeholder="Address 2" />-->
</div>
</div> </div>
</div>
</div>
<div class="row"> <div class="row">
<div class="col-md-6 col-sm-6"> <div class="col-lg-12">
<label class="mt-0 fs-14 fw-400" for="billing_zipcode">PLZ *</label> <div class="form-group">
<input id="billing_zipcode" name="billing[zipcode]" type="text" class="form-control required" /> <label class="mt-0 fs-14 fw-400" for="billing_address">Straße Nr. *</label>
</div> {!! Form::text('billing[address]', null, ['class' => 'form-control '.($errors->has('billing.address') ? 'error' : ''), 'id'=>'billing_address']) !!}
<div class="col-md-6 col-sm-6"> @if ($errors->has('billing.address'))
<label class="mt-0 fs-14 fw-400" for="billing_city">Stadt *</label> <label for="billing_address" class="error text-danger small" style="display: block;">{{ $errors->first('billing.address') }}</label>
<input id="billing_city" name="billing[city]" type="text" class="form-control required" /> @endif
</div>
</div> </div>
</div>
<div class="row"> <div class="col-lg-12">
<div class="col-md-12 col-sm-12"> <div class="form-group">
<label class="mt-0 fs-14 fw-400" for="billing_state">Land *</label> <label class="mt-0 fs-14 fw-400" for="billing_address_2">Wohnung / Gebäude (optional)</label>
<select id="billing_state" name="billing[state]" class="form-control pointer selectpicker required"> {!! Form::text('billing[address_2]', null, ['class' => 'form-control '.($errors->has('billing.address_2') ? 'error' : ''), 'id'=>'billing_address_2']) !!}
<option value="">Select...</option> @if ($errors->has('billing.address_]'))
<option value="1">...</option> <label for="billing_address_2" class="error text-danger small" style="display: block;">{{ $errors->first('billing.address_2') }}</label>
<option value="2">...</option> @endif
<option value="">..............</option>
</select>
</div>
</div> </div>
</div>
</div>
<div class="row"> <div class="row">
<div class="col-md-6 col-sm-6"> <div class="col-md-6 col-sm-6">
<label class="mt-0 fs-14 fw-400" for="billing_phone">Telefon *</label> <label class="mt-0 fs-14 fw-400" for="billing_zipcode">PLZ *</label>
<input id="billing_phone" name="billing[phone]" type="text" class="form-control required" /> {!! Form::text('billing[zipcode]', null, ['class' => 'form-control '.($errors->has('billing.zipcode') ? 'error' : ''), 'id'=>'billing_zipcode']) !!}
</div> @if ($errors->has('billing.zipcode'))
<div class="col-md-6 col-sm-6"> <label for="billing_zipcode" class="error text-danger small" style="display: block;">{{ $errors->first('billing.zipcode') }}</label>
<label class="mt-0 fs-14 fw-400" for="billing_fax">Fax</label> @endif
<input id="billing_fax" name="billing[fax]" type="text" class="form-control" /> </div>
</div> <div class="col-md-6 col-sm-6">
</div> <label class="mt-0 fs-14 fw-400" for="billing_city">Stadt *</label>
<div class="row"> {!! Form::text('billing[city]', null, ['class' => 'form-control '.($errors->has('billing.city') ? 'error' : ''), 'id'=>'billing_city']) !!}
<div class="col-md-12 col-sm-12"> @if ($errors->has('billing.city'))
<label class="mt-0 fs-14 fw-400" for="billing_email">Email *</label> <label for="billing_city" class="error text-danger small" style="display: block;">{{ $errors->first('billing.city') }}</label>
<input id="billing_email" name="billing[email]" type="text" class="form-control required" /> @endif
</div> </div>
</div>
<div class="row">
<div class="col-lg-12 nomargin clearfix">
<label class="mt-0 fs-14 fw-400 checkbox pull-left"><!-- see assets/js/view/demo.shop.js - CHECKOUT section -->
<input id="shipswitch" name="shipping[same_as_billing]" type="checkbox" value="1" checked="checked" />
<i></i> <span class="weight-300">Versand an die gleiche Adresse</span>
</label>
</div>
</div>
</fieldset>
<!-- /BILLING -->
<!-- SHIPPING -->
<fieldset id="shipping" class="softhide mt-40">
<div class="box-border-shadow p-20">
<h4>Versand Adresse</h4>
<hr />
<div class="row">
<div class="col-md-12 col-sm-12">
<label class="mt-0 fs-14 fw-400" for="shipping_company">Firma</label>
<input id="shipping_company" name="shipping[company]" type="text" class="form-control" />
</div>
</div>
<div class="row">
<div class="col-md-6 col-sm-6">
<label class="mt-0 fs-14 fw-400" for="shipping_firstname">Vorname*</label>
<input id="shipping_firstname" name="shipping[firstname]" type="text" class="form-control required" />
</div>
<div class="col-md-6 col-sm-6">
<label class="mt-0 fs-14 fw-400" for="shipping_lastname">Nachname *</label>
<input id="shipping_lastname" name="shipping[lastname]" type="text" class="form-control required" />
</div>
</div>
<div class="row">
<div class="col-lg-12">
<label class="mt-0 fs-14 fw-400" for="shipping_address1">Straße Nr. *</label>
<input id="shipping_address1" name="shipping[address][]" type="text" class="form-control required" placeholder="" />
<!--<input id="shipping_address2" name="shipping[address][]" type="text" class="form-control margin-top-10" placeholder="Address 2" />-->
</div>
</div>
<div class="row">
<div class="col-md-6 col-sm-6">
<label class="mt-0 fs-14 fw-400" for="shipping_zipcode">PLZ *</label>
<input id="shipping_zipcode" name="shipping[zipcode]" type="text" class="form-control required" />
</div>
<div class="col-md-6 col-sm-6">
<label class="mt-0 fs-14 fw-400" for="shipping_city">Stadt *</label>
<input id="shipping_city" name="shipping[city]" type="text" class="form-control required" />
</div>
</div>
<div class="row">
<div class="col-md-12 col-sm-12">
<label class="mt-0 fs-14 fw-400" for="shipping_state">Land *</label>
<select id="shipping_state" name="shipping[state]" class="form-control pointer selectpicker required">
<option value="">Select...</option>
<option value="1">...</option>
<option value="2">...</option>
<option value="">..............</option>
</select>
</div>
</div>
<div class="row">
<div class="col-md-6 col-sm-6">
<label class="mt-0 fs-14 fw-400" for="shipping_phone">Telefon *</label>
<input id="shipping_phone" name="shipping[phone]" type="text" class="form-control required" />
</div>
<div class="col-md-6 col-sm-6">
<label class="mt-0 fs-14 fw-400" for="shipping_fax">Fax</label>
<input id="shipping_fax" name="shipping[fax]" type="text" class="form-control" />
</div>
</div>
</div>
</fieldset>
<!-- /SHIPPING -->
</div> </div>
<div class="row">
<div class="col-md-12 col-sm-12">
<label class="mt-0 fs-14 fw-400" for="billing_state">Land *</label>
<select id="billing_state" name="billing[state]" class="form-control select2 required" disabled="true">
{!! HTMLHelper::getCountriesForShipping(Yard::instance('shopping')->getShippingCountryId()) !!}
</select>
</div>
</div>
<div class="row">
<div class="col-md-12 col-sm-12">
<label class="mt-0 fs-14 fw-400" for="billing_phone">Telefon (optional)</label>
{!! Form::text('billing[phone]', null, ['class' => 'form-control '.($errors->has('billing.phone') ? 'error' : ''), 'id'=>'billing_phone']) !!}
@if ($errors->has('billing.phone'))
<label for="billing_phone" class="error text-danger small" style="display: block;">{{ $errors->first('billing.phone') }}</label>
@endif
</div>
</div>
<div class="row">
<div class="col-md-12 col-sm-12">
<label class="mt-0 fs-14 fw-400" for="billing_email">E-Mail *</label>
{!! Form::email('billing[email]', null, ['class' => 'form-control '.($errors->has('billing.email') ? 'error' : ''), 'id'=>'billing_email']) !!}
@if ($errors->has('billing.email'))
<label for="billing_email" class="error text-danger small" style="display: block;">{{ $errors->first('billing.email') }}</label>
@endif
</div>
</div>
<div class="col-lg-5 col-sm-5"> <div class="row">
<div class="col-md-12 col-sm-12">
<!-- PAYMENT METHOD -->
<fieldset class="box-border-shadow p-20">
<h4>Zahlungsart</h4>
<hr> <hr>
<label class="checkbox {{ ($errors->has('accepted_data_checkbox') ? 'error' : '') }}" for="accepted_data_checkbox" style="font-size: 14px;line-height: 22px; font-weight: 400">
{!! Form::checkbox('accepted_data_checkbox', 1, false, ['id'=>'accepted_data_checkbox', 'class' => 'form-control '.($errors->has('accepted_data_checkbox') ? 'error' : '')]) !!}
<i></i> Mit Klick auf "Jetzt kaufen" akzeptiere ich die <a href="{{ url('/datenschutz') }}">Allgemeinen Geschäftsbedingungen</a>, die <a href="{{ url('/datenschutz') }}">Widerrufsbestimmungen</a> und die <a href="{{ url('/datenschutz') }}">Datenschutzbelehrung</a>, damit für die Bestellung meine Daten verarbeitet werden können.
</label>
@if ($errors->has('accepted_data_checkbox'))
<label for="accepted_data_checkbox" class="error text-danger small" style="display: block;">{{ $errors->first('accepted_data_checkbox') }}</label>
@endif
</div>
</div>
<div class="toggle-transparent toggle-bordered-full clearfix">
<div class="toggle active">
<div class="toggle-content">
<div class="row nomargin-bottom"> <div class="row">
<div class="col-lg-12 nomargin clearfix">
<label class="mt-0 fs-14 fw-400 radio pull-left nomargin-top">
<input id="payment_check" name="payment[method]" type="radio" value="1" checked="checked" />
<i></i> <span class="weight-300">Paypal</span>
</label>
</div>
<div class="col-lg-12 nomargin clearfix">
<label class="mt-0 fs-14 fw-400 radio pull-left">
<input id="payment_card" name="payment[method]" type="radio" value="2" />
<i></i> <span class="weight-300">Kredit Karte</span>
</label>
</div>
</div>
</div> <div class="col-lg-12 nomargin clearfix">
<hr>
<label class="mt-0 fs-14 fw-400 checkbox pull-left"><!-- see assets/js/view/demo.shop.js - CHECKOUT section -->
{!! Form::checkbox('shipping[same_as_billing]', 1, true, ['id'=>'shipswitch', 'class' => '']) !!}
<i></i> <span class="weight-300">Versand an die gleiche Adresse</span>
</label>
</div>
</div>
</fieldset>
<!-- /BILLING -->
<!-- SHIPPING -->
<fieldset id="shipping" class="softhide mt-40">
<div class="box-border-shadow p-20">
<h4>Versand Adresse</h4>
<hr />
<div class="row">
<div class="col-md-12 col-sm-12">
<label class="mt-0 fs-14 fw-400" for="shipping_company">Firmenname (optional)</label>
{!! Form::text('shipping[company]', null, ['class' => 'form-control', 'id'=>'billing_company']) !!}
</div>
</div>
<div class="row">
<div class="col-md-6 col-sm-6">
<div class="form-group">
<label class="mt-0 fs-14 fw-400" for="shipping_firstname">Vorname*</label>
{!! Form::text('shipping[firstname]', null, ['class' => 'form-control '.($errors->has('shipping.firstname') ? 'error' : ''), 'id'=>'shipping_firstname']) !!}
@if ($errors->has('shipping.firstname'))
<label for="shipping_firstname" class="error text-danger small" style="display: block;">{{ $errors->first('shipping.firstname') }}</label>
@endif
</div> </div>
</div> </div>
</fieldset> <div class="col-md-6 col-sm-6">
<!-- /PAYMENT METHOD --> <div class="form-group">
<label class="mt-0 fs-14 fw-400" for="shipping_lastname">Nachname*</label>
{!! Form::text('shipping[lastname]', null, ['class' => 'form-control '.($errors->has('shipping.lastname') ? 'error' : ''), 'id'=>'shipping_lastname']) !!}
@if ($errors->has('shipping.lastname'))
<label for="shipping_lastname" class="error text-danger small" style="display: block;">{{ $errors->first('shipping.lastname') }}</label>
@endif
<!-- TOTAL / PLACE ORDER -->
<div class="toggle-transparent toggle-bordered-full clearfix">
<div class="toggle active">
<div class="toggle-content">
<div class="clearfix mb-2">
<span class="pull-right">{{ Yard::instance('shopping')->total() }} </span>
<strong class="pull-left">Zwischensumme:</strong>
</div>
<div class="clearfix mb-2">
<span class="pull-right small">{{ Yard::instance('shopping')->shipping() }} </span>
<span class="pull-left small">Versandkosten:</span>
</div>
<hr class="mt-4 mb-4">
<div class="clearfix mb-2">
<span class="pull-right small">{{ Yard::instance('shopping')->subtotalWithShipping() }} </span>
<span class="pull-left small">Summe ohne MwSt:</span>
</div>
<div class="clearfix mb-2">
<span class="pull-right small">{{ Yard::instance('shopping')->taxWithShipping() }} </span>
<span class="pull-left small"> zzgl. {{ Yard::getTaxRate() }} % MwSt.:</span>
</div>
<hr />
<span class="clearfix ">
<span class="pull-right size-20"><strong>{{ Yard::instance('shopping')->totalWithShipping() }} </strong></span>
<strong class="pull-left">Gesamtsumme:</strong>
</span>
<button class="btn btn-primary btn-lg btn-block size-15 mt-4"><i class="fa fa-mail-forward"></i> Bestellung absenden</button>
</div> </div>
</div> </div>
</div> </div>
<!-- /TOTAL / PLACE ORDER -->
{{-- <div class="row">
<div class="col-lg-12">
<div class="form-group">
<label class="mt-0 fs-14 fw-400" for="shipping_address">Straße Nr. *</label>
{!! Form::text('shipping[address]', null, ['class' => 'form-control '.($errors->has('shipping.address') ? 'error' : ''), 'id'=>'shipping_address']) !!}
@if ($errors->has('shipping.address'))
<label for="shipping_address" class="error text-danger small" style="display: block;">{{ $errors->first('shipping.address') }}</label>
@endif
</div>
</div>
<div class="col-lg-12">
<div class="form-group">
<label class="mt-0 fs-14 fw-400" for="shipping_address_2">Wohnung / Gebäude (optional)</label>
{!! Form::text('shipping[address_2]', null, ['class' => 'form-control '.($errors->has('shipping.address_2') ? 'error' : ''), 'id'=>'shipping_address_2']) !!}
@if ($errors->has('shipping.address_]'))
<label for="shipping_address_2" class="error text-danger small" style="display: block;">{{ $errors->first('shipping.address_2') }}</label>
@endif
</div>
</div>
</div>
<!-- CREATE ACCOUNT --> <div class="row">
<div class="toggle-transparent toggle-bordered-full margin-top-30 clearfix"> <div class="col-md-6 col-sm-6">
<div class="toggle active"> <label class="mt-0 fs-14 fw-400" for="shipping_zipcode">PLZ *</label>
<div class="toggle-content"> {!! Form::text('shipping[zipcode]', null, ['class' => 'form-control '.($errors->has('shipping.zipcode') ? 'error' : ''), 'id'=>'shipping_zipcode']) !!}
@if ($errors->has('shipping.zipcode'))
<label for="shipping_zipcode" class="error text-danger small" style="display: block;">{{ $errors->first('shipping.zipcode') }}</label>
@endif
</div>
<div class="col-md-6 col-sm-6">
<label class="mt-0 fs-14 fw-400" for="shipping_city">Stadt *</label>
{!! Form::text('shipping[city]', null, ['class' => 'form-control '.($errors->has('shipping.city') ? 'error' : ''), 'id'=>'shipping_city']) !!}
@if ($errors->has('shipping.city'))
<label for="shipping_city" class="error text-danger small" style="display: block;">{{ $errors->first('shipping.city') }}</label>
@endif
</div>
<div class="clearfix"> </div>
<label class="mt-0 fs-14 fw-400 checkbox pull-left">
<input id="accountswitch" name="create-account[yes]" type="checkbox" value="1" />
<i></i> <span class="weight-300">Create an account for later use</span>
</label>
</div>
<!-- CREATE ACCOUNT FORM --> <div class="row">
<div id="newaccount" class="margin-top-10 margin-bottom-30 softhide"> <div class="col-md-12 col-sm-12">
<label class="mt-0 fs-14 fw-400" for="shipping_state">Land *</label>
<select id="shipping_state" name="shipping[state]" class="form-control select2 required" disabled="true">
{!! HTMLHelper::getCountriesForShipping(Yard::instance('shopping')->getShippingCountryId()) !!}
</select>
</div>
</div>
<div class="row nomargin-bottom"> <div class="row">
<div class="col-md-6 col-sm-6"> <div class="col-md-12 col-sm-12">
<label class="mt-0 fs-14 fw-400" for="account:password">Password *</label> <label class="mt-0 fs-14 fw-400" for="shipping_phone">Telefon (optional)</label>
<input id="account:password" name="account[password]" type="password" class="form-control" /> {!! Form::text('shipping[phone]', null, ['class' => 'form-control '.($errors->has('shipping.phone') ? 'error' : ''), 'id'=>'shipping_phone']) !!}
</div> @if ($errors->has('shipping.phone'))
<div class="col-md-6 col-sm-6"> <label for="shipping_phone" class="error text-danger small" style="display: block;">{{ $errors->first('shipping.phone') }}</label>
<label class="mt-0 fs-14 fw-400" for="account:password2">Confirm Password *</label> @endif
<input id="account:password2" name="account[password2]" type="password" class="form-control" /> </div>
</div> </div>
</div> </div>
<small class="text-warning">NOTE: Email address will be used to login</small> </fieldset>
<!-- /SHIPPING -->
</div> <a href="{{ Util::getUserShopBackUrl('/card/show') }}" class="btn btn-default btn-sm btn- size-15 mt-4"><i class="fa fa-chevron-left"></i> zurück zum Warenkorb</a>
<!-- /CREATE ACCOUNT FORM --> </div>
<div class="col-lg-5 col-sm-5">
<!-- PAYMENT METHOD -->
<fieldset class="box-border-shadow p-20">
<h4>Zahlungsart</h4>
<hr>
<div class="toggle-transparent toggle-bordered-full clearfix">
<div class="toggle active">
<div class="toggle-content">
<div class="row nomargin-bottom">
<div class="col-lg-12 nomargin clearfix">
<label class="mt-0 fs-14 fw-400 radio pull-left nomargin-top">
<input id="payment_check" name="payment[method]" type="radio" value="paypal" checked="checked" />
<i></i> <span class="weight-300">Paypal</span>
</label>
</div>
<div class="col-lg-12 nomargin clearfix">
<label class="mt-0 fs-14 fw-400 radio pull-left">
<input id="payment_card" name="payment[method]" type="radio" value="sofort" />
<i></i> <span class="weight-300">Sofortüberweisung</span>
</label>
</div>
<div class="col-lg-12 nomargin clearfix">
<label class="mt-0 fs-14 fw-400 radio pull-left">
<input id="payment_card" name="payment[method]" type="radio" value="credit" />
<i></i> <span class="weight-300">Kredit Karte</span>
</label>
</div>
<div class="col-lg-12 nomargin clearfix">
<label class="mt-0 fs-14 fw-400 radio pull-left">
<input id="payment_card" name="payment[method]" type="radio" value="sepa" />
<i></i> <span class="weight-300">Lastschrift SEPA</span>
</label>
</div>
<div class="col-lg-12 nomargin clearfix">
<label class="mt-0 fs-14 fw-400 radio pull-left">
<input id="payment_card" name="payment[method]" type="radio" value="voraus" />
<i></i> <span class="weight-300">Vorauskasse</span>
</label>
</div>
</div>
</div>
</div>
</div>
</fieldset>
<!-- /PAYMENT METHOD -->
<!-- TOTAL / PLACE ORDER -->
<div class="toggle-transparent toggle-bordered-full clearfix">
<div class="toggle active">
<div class="toggle-content">
<div class="clearfix mb-2">
<span class="pull-right">{{ Yard::instance('shopping')->total() }} </span>
<strong class="pull-left">Zwischensumme:</strong>
</div>
<hr class="mt-4 mb-4">
<div class="clearfix mb-2">
<span class="pull-right small">{{ Yard::instance('shopping')->shipping() }} </span>
<span class="pull-left small">Versandkosten:</span>
</div>
<div class="clearfix mb-2">
<span class="pull-right small">{{ Yard::instance('shopping')->getShippingCountryName() }}</span>
<span class="pull-left small">Versandland:</span>
</div>
<hr class="mt-4 mb-4">
<div class="clearfix mb-2">
<span class="pull-right small">{{ Yard::instance('shopping')->subtotalWithShipping() }} </span>
<span class="pull-left small">Summe ohne MwSt:</span>
</div>
<div class="clearfix mb-2">
<span class="pull-right small">{{ Yard::instance('shopping')->taxWithShipping() }} </span>
<span class="pull-left small"> zzgl. {{ Yard::getTaxRate() }} % MwSt:</span>
</div>
<hr />
<div class="clearfix">
<span class="pull-right size-20"><strong>{{ Yard::instance('shopping')->totalWithShipping() }} </strong></span>
<strong class="pull-left">Gesamtsumme:</strong>
</div>
<button type="submit" class="btn btn-primary btn-lg btn-block size-18 btn-text-500 mt-4 faa-parent animated-hover"><i class="fa fa-mail-forward faa-horizontal"></i> Jetzt kaufen</button>
<hr><p class="text-center" style="line-height: 1.2em;"><em class="small text-center"> <i class="fa fa-lock"></i> Sind alle Ihre Angaben vollsätndig ausgefüllt, klicken Sie auf "Jetzt kaufen" und Sie werden zu unserem Zahlungsanbieter weitergeleitet, die Verbindung wird ist SSL verschlüsselt.</em></p>
</div>
</div>
</div>
</div>
<!-- /TOTAL / PLACE ORDER -->
{{--
<!-- CREATE ACCOUNT -->
<div class="toggle-transparent toggle-bordered-full margin-top-30 clearfix">
<div class="toggle active">
<div class="toggle-content">
<div class="clearfix">
<label class="mt-0 fs-14 fw-400 checkbox pull-left">
<input id="accountswitch" name="create-account[yes]" type="checkbox" value="1" />
<i></i> <span class="weight-300">Create an account for later use</span>
</label>
</div> </div>
</div>
<!-- /CREATE ACCOUNT -->
--}}
{!! Form::close() !!} <!-- CREATE ACCOUNT FORM -->
<div id="newaccount" class="margin-top-10 margin-bottom-30 softhide">
<div class="row nomargin-bottom">
<div class="col-md-6 col-sm-6">
<label class="mt-0 fs-14 fw-400" for="account:password">Password *</label>
<input id="account:password" name="account[password]" type="password" class="form-control" />
</div>
<div class="col-md-6 col-sm-6">
<label class="mt-0 fs-14 fw-400" for="account:password2">Confirm Password *</label>
<input id="account:password2" name="account[password2]" type="password" class="form-control" />
</div>
</div>
<small class="text-warning">NOTE: Email address will be used to login</small>
</div>
<!-- /CREATE ACCOUNT FORM -->
</div>
</div>
</div>
<!-- /CREATE ACCOUNT -->
--}}
</div> </div>
<!-- /CHECKOUT --> <!-- /CHECKOUT -->
{!! Form::close() !!}
</div> </div>
</div>
</section> </section>
<!-- /CHECKOUT --> <!-- /CHECKOUT -->
<!-- /CART --> <!-- /CART -->

View file

@ -134,7 +134,7 @@
genannte Datenverarbeitung ein. genannte Datenverarbeitung ein.
</label> </label>
@if ($errors->has('accepted_data_protection')) @if ($errors->has('accepted_data_protection'))
<label for="last_name" class="error text-danger small" style="display: block;">{{ $errors->first('accepted_data_protection') }}</label> <label for="accepted_data_protection" class="error text-danger small" style="display: block;">{{ $errors->first('accepted_data_protection') }}</label>
@endif @endif
</div> </div>

View file

@ -25,28 +25,12 @@
@endif @endif
@endforeach @endforeach
</a> </a>
<!-- /product image(s) -->
<!-- hover buttons -->
{{--
<div class="shop-option-over">
<a class="btn btn-default add-wishlist" href="#" data-item-id="4" data-toggle="tooltip" title="" data-original-title="Auf die Wunschliste"><i class="fa fa-heart nopadding"></i></a>
</div>
--}}
<!-- /hover buttons -->
<!-- product more info -->
{{-- <div class="shop-item-info">
<span class="label label-success">NEW</span>
</div>--}}
<!-- /product more info -->
</div> </div>
@if($user_shop)
<div class="shop-item-summary text-center "> <div class="shop-item-summary text-center ">
<h2 class=""><a <h2 class=""><a href="{{ url('/produkte/'.$subsite.'/'.$product->slug) }}">{{ $product->getLang('name') }}</a></h2>
href="{{ url('/produkte/'.$subsite.'/'.$product->slug) }}">{{ $product->getLang('name') }}</a>
</h2>
<!-- rating --> <!-- rating -->
<div class="shop-item-rating-line"> <div class="shop-item-rating-line">
@ -60,20 +44,23 @@
</div> </div>
<!-- /price --> <!-- /price -->
</div> </div>
<!-- buttons --> <!-- buttons -->
<div class="shop-item-buttons text-left"> <div class="shop-item-buttons text-left">
<a href="{{ route(Util::getPostRoute().'card_add_get', Util::addRoute([$product->id, 1, $product->slug])) }}" <a href="{{ route(Util::getPostRoute().'card_add_get', Util::addRoute([$product->id, 1, $product->slug])) }}"
data-quantity="1" data-product_id="{{ $product->id }}" data-quantity="1" data-product_id="{{ $product->id }}"
aria-label="{{ $product->getLang('name') }} zu deinem Warenkorb hinzufügen" aria-label="{{ $product->getLang('name') }} zu deinem Warenkorb hinzufügen"
class="btn btn-primary btn-xs" rel="nofollow"> class="btn btn-primary btn-xs btn-text-500 faa-parent animated-hover" rel="nofollow">
<i class="fa fa-cart-plus"></i> In den Warenkorb <i class="fa fa-cart-plus faa-horizontal"></i> In den Warenkorb
</a> </a>
<a class="float-right btn btn-primary btn-xs" <a class="float-right btn btn-primary btn-xs btn-text-500 faa-parent animated-hover"
href="{{ url('/produkte/'.$subsite.'/'.$product->slug) }}"> href="{{ url('/produkte/'.$subsite.'/'.$product->slug) }}">
<i class="fa fa-list"></i> Details <i class="fa fa-list faa-horizonta"></i> Details
</a> </a>
</div> </div>
@else
<div class="shop-item-buttons text-center">
<a class="btn btn-primary btn-sm btn-text-500 faa-parent animated-hover" href="{{ url('/produkte/'.$subsite.'/'.$product->slug) }}">{{ $product->getLang('name') }} <i class="fa fa-lg fa-chevron-circle-right faa-horizontal"></i> </a>
</div>
@endif
<!-- /buttons --> <!-- /buttons -->
</div> </div>

View file

@ -65,7 +65,6 @@
</figure> </figure>
</div> </div>
<!-- Thumbnails (required height:100px) --> <!-- Thumbnails (required height:100px) -->
<div data-for="zoom-primary" class="zoom-more owl-carousel owl-padding-3 featured" <div data-for="zoom-primary" class="zoom-more owl-carousel owl-padding-3 featured"
data-plugin-options='{"singleItem": false, "autoPlay": false, "navigation": true, "pagination": false}'> data-plugin-options='{"singleItem": false, "autoPlay": false, "navigation": true, "pagination": false}'>
@ -78,44 +77,42 @@
</a> </a>
@php ($activ = '') @php ($activ = '')
@endforeach @endforeach
</div> </div>
<!-- /Thumbnails --> <!-- /Thumbnails -->
@endif @endif
</div> </div>
<!-- /IMAGE --> <!-- /IMAGE -->
<!-- ITEM DESC --> <!-- ITEM DESC -->
<div class="col-lg-6 col-sm-6"> <div class="col-lg-6 col-sm-6">
{{--
<div class="pull-right">
<a class="btn btn-default add-wishlist" href="#" data-item-id="1" data-toggle="tooltip" title="" data-original-title="Add To Wishlist"><i class="fa fa-heart nopadding"></i></a>
</div>
--}}
<h1 class="small-h1">{{ $product->getLang('name') }}</h1> <h1 class="small-h1">{{ $product->getLang('name') }}</h1>
{!! $product->getLang('copy') !!} {!! $product->getLang('copy') !!}
<hr/> <hr/>
<div class="shop-item-price text-right">
{{ $product->getFormattedPrice() }} <br>
<span style="font-size: 0.7em; color:#999; font-weight: 400;"><em>inkl. 19% MwSt. zzgl. Versandkosten</em></span>
</div>
<hr> @if($user_shop)
<div class="shop-item-price text-right"> <div class="shop-item-price text-right">
{!! Form::open(['url' => route(Util::getPostRoute().'card_add_post', Util::addRoute([$product->id])), 'class' => 'mb-0', 'id'=>'']) !!} {{ $product->getFormattedPrice() }} <br>
<div class="qty float-left"> <span style="font-size: 0.7em; color:#999; font-weight: 400;"><em>inkl. 19% MwSt. zzgl. Versandkosten</em></span>
<input type="number" value="1" name="quantity" maxlength="3" max="999" min="1"><br>
</div> </div>
<button class="btn btn-primary">In den Warenkorb</button> <hr>
<br> <div class="shop-item-price text-right">
<span style="font-size: 0.7em; color:#999; font-weight: 400;"><em>Lieferzeit: 1-3 Werktage</em></span> {!! Form::open(['url' => route(Util::getPostRoute().'card_add_post', Util::addRoute([$product->id])), 'class' => 'mb-0', 'id'=>'']) !!}
{!! Form::close() !!} <div class="qty float-left">
</div> <input type="number" value="1" name="quantity" maxlength="3" max="999" min="1"><br>
<hr> </div>
<button class="btn btn-primary btn-text-500 faa-parent animated-hover"><i class="fa fa-cart-plus faa-horizontal"></i> In den Warenkorb</button>
<br>
<span style="font-size: 0.7em; color:#999; font-weight: 400;"><em>Lieferzeit: 1-3 Werktage</em></span>
{!! Form::close() !!}
</div>
<hr>
@endif
<div class="shop-item-price text-right"> <div class="shop-item-price text-right">
<span class="pull-left"><strong>Inhalt:</strong></span> <span class="pull-left"><strong>Inhalt:</strong></span>
<span style="font-size: 0.8em">{{ $product->contents }}</span> <span style="font-size: 0.8em">{{ $product->contents }}</span>

View file

@ -2,7 +2,7 @@
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="utf-8" /> <meta charset="utf-8" />
<title>mivita care</title> <title>@if($user_shop->title) {{ $user_shop->title }}@endif | mivita care</title>
<meta name="description" content="" /> <meta name="description" content="" />
<meta name="Author" content="" /> <meta name="Author" content="" />
@ -43,8 +43,6 @@
<!-- SCROLL TO TOP --> <!-- SCROLL TO TOP -->
<a href="#" id="toTop"></a> <a href="#" id="toTop"></a>
<!-- JAVASCRIPT FILES --> <!-- JAVASCRIPT FILES -->
<script type="text/javascript">var plugin_path = "{{ url('/assets/plugins/').'/' }}"</script> <script type="text/javascript">var plugin_path = "{{ url('/assets/plugins/').'/' }}"</script>
<script type="text/javascript" src="{{ asset('/assets/plugins/jquery/jquery-2.2.3.min.js') }}"></script> <script type="text/javascript" src="{{ asset('/assets/plugins/jquery/jquery-2.2.3.min.js') }}"></script>
@ -66,14 +64,22 @@
// Shipping Address show|hide // Shipping Address show|hide
jQuery("#shipswitch").bind("click", function() { jQuery("#shipswitch").bind("click", function() {
jQuery('#shipping').slideToggle(200, function() { jQuery('#shipping').slideToggle(200, function() {
// scroll down to shipping area. // scroll down to shipping area.
if(jQuery('#shipping').is(":visible")) { if(jQuery('#shipping').is(":visible")) {
_scrollTo('#shipping', 150); _scrollTo('#shipping', 150);
} }
}); });
}); });
</script>
if(!jQuery('#shipswitch').is(':checked')){
jQuery('#shipping').show();
}
jQuery('.quick-cart-box-close').on('click', function () {
jQuery('.quick-cart-box').css('display', 'none');
});
</script>
</body> </body>
</html> </html>

View file

@ -1,22 +1,25 @@
<div class="alert alert-success bordered-bottom nomargin"> <div class="alert alert-success bordered-bottom nomargin">
<div class="container"> <div class="container">
<div class="row"> <div class="row">
<div class="col-12"><!-- left text --> <div class="col-12"><!-- left text -->
<p class="font-lato weight-300 size-20 nomargin-bottom"> <p class="font-lato weight-300 size-20 nomargin-bottom">
Du möchtest Vertriebspartner werden oder hast Fragen zu unseren Produkten? Du möchtest Vertriebspartner werden oder hast Fragen zu unseren Produkten?
</p> </p>
<h3>Jetzt Kontakt aufnehmen: <a href="{{url('/kontakt')}}" rel="nofollow" class="btn btn-primary btn-lg">zum Kontakt</a> @if(Util::isCheckout())
<h3>
Jetzt Kontakt aufnehmen: <a href="{{ Util::getUserShopBackUrl('/kontakt') }}" rel="nofollow" class="btn btn-primary btn-lg">zum Kontakt</a>
</h3> </h3>
@else
<h3>
Jetzt Kontakt aufnehmen: <a href="{{url('/kontakt')}}" rel="nofollow" class="btn btn-primary btn-lg">zum Kontakt</a>
</h3>
@endif
</div><!-- /left text --> </div><!-- /left text -->
</div> </div>
</div> </div>
</div> </div>
<!-- /CALLOUT --> <!-- /CALLOUT -->
@ -26,27 +29,16 @@
<div class="container"> <div class="container">
<div class="row"> <div class="row">
<div class="col-md-4"> <div class="col-md-4">
<!-- Footer Logo --> <!-- Footer Logo -->
<img class="footer-logo" src="{{asset('/assets/images/logo_dark.png')}}" alt=""/> <img class="footer-logo" src="{{asset('/assets/images/logo_dark.png')}}" alt=""/>
</div> </div>
<div class="col-md-4"> <div class="col-md-4">
<!-- Contact Address --> <!-- Contact Address -->
<br> <br>
<address> <address>
<ul class="list-unstyled"> <ul class="list-unstyled">
@if($user_shop->title) @if($user_shop->title)
<li class="footer-sprite title"> <li class="footer-sprite title">
<strong style="color: #97b085; font-size: 1.1em;">{{ $user_shop->title }}</strong> <strong style="color: #97b085; font-size: 1.1em;">{{ $user_shop->title }}</strong>
@ -65,7 +57,16 @@
<!-- /Contact Address --> <!-- /Contact Address -->
</div> </div>
@if(Util::isCheckout())
<div class="col-md-4">
<!-- Links -->
<h4 class="letter-spacing-1">&nbsp;</h4>
<a href="{{ Util::getUserShopBackUrl('/card/show') }}">
<i class="fa fa-chevron-left"></i> zurück zum Warenkorb
</a>
<!-- /Links -->
</div>
@else
<div class="col-md-4"> <div class="col-md-4">
<!-- Links --> <!-- Links -->
<h4 class="letter-spacing-1">Inhalte</h4> <h4 class="letter-spacing-1">Inhalte</h4>
@ -86,19 +87,29 @@
<!-- /Links --> <!-- /Links -->
</div> </div>
@endif
</div> </div>
</div> </div>
<div class="copyright"> <div class="copyright">
<div class="container"> <div class="container">
@if(Util::isCheckout())
<ul class="pull-right nomargin list-inline mobile-block"> <ul class="pull-right nomargin list-inline mobile-block">
<li class="{{ Request::is('datenschutz') ? ' active' : '' }}"><a <li><a href="{{ Util::getUserShopBackUrl('/datenschutz') }}">Datenschutzerklärung</a></li>
href="{{ url('/datenschutz') }}">Datenschutzerklärung</a></li>
<li>&bull;</li> <li>&bull;</li>
<li class="{{ Request::is('impressum') ? ' active' : '' }} "><a <li><a href="{{ Util::getUserShopBackUrl('/impressum') }}">Impressum</a></li>
href="{{ url('/impressum') }}">Impressum</a></li>
</ul> </ul>
@else
<ul class="pull-right nomargin list-inline mobile-block">
<li class="{{ Request::is('datenschutz') ? ' active' : '' }}"><a
href="{{ url('/datenschutz') }}">Datenschutzerklärung</a></li>
<li>&bull;</li>
<li class="{{ Request::is('impressum') ? ' active' : '' }} "><a
href="{{ url('/impressum') }}">Impressum</a></li>
</ul>
@endif
&copy; All Rights Reserved, mivita.care &copy; All Rights Reserved, mivita.care
</div> </div>
</div> </div>

View file

@ -37,6 +37,17 @@
#header.fixed ul.nav-second-main { #header.fixed ul.nav-second-main {
margin-top: 8px; margin-top: 8px;
} }
#header li.quick-cart .quick-cart-box a.btn-sm{
padding: 8px !important;
font-size: 13px;
line-height: 1.2em;
}
#header li.quick-cart .quick-cart-box a.btn-default{
background-color: transparent;
border: #b0adb3 1px solid;
}
</style> </style>
<!-- TOP NAV --> <!-- TOP NAV -->
<header id="topNav"> <header id="topNav">
@ -47,98 +58,107 @@
<i class="fa fa-bars"></i> <i class="fa fa-bars"></i>
</button> </button>
<ul class="pull-right nav nav-pills nav-second-main has-topBar"> @if(Util::isCheckout())
<a class="logo pull-left" href="{{ Util::getUserShopBackUrl('/') }}">
<img class="fixed_top" src="/assets/images/logo_mivita.png" alt="mivita" />
<img class="fixed_scroll" src="/assets/images/logo_mivita_fixed.png" alt="mivita" />
</a>
<!-- QUICK SHOP CART --> <div class="navbar-collapse pull-right nav-main-collapse collapse">
<li class="quick-cart"> <nav class="nav-main">
<ul id="topMain" class="nav nav-pills nav-main nav-onepage">
<li class="">
<a href="{{ Util::getUserShopBackUrl('/card/show') }}">
<i class="fa fa-chevron-left"></i> zurück zum Warenkorb
</a>
</li>
</ul>
</nav>
</div>
@else
<ul class="pull-right nav nav-pills nav-second-main has-topBar">
<!-- QUICK SHOP CART -->
<li class="quick-cart">
<a href="#" style="border: 1px solid #c3c3c3; padding: 10px;"> <a href="#" style="border: 1px solid #c3c3c3; padding: 10px;">
<span style="position: relative"> <span style="position: relative">
<span class="badge badge-success btn-xs badge-corner">{{ Yard::instance('shopping')->count() }}</span> <span class="badge badge-success btn-xs badge-corner faa-horizontal animated">{{ Yard::instance('shopping')->count() }}</span>
<i class="fa fa-shopping-cart"></i> <i class="fa fa-shopping-cart"></i>
</span> </span>
&nbsp; &nbsp;
@if(Yard::instance('shopping')->count())
<span class="">{{ \Yard::instance('shopping')->subtotal() }} </span>
@endif
</a>
<div class="quick-cart-box" style="display: @if(Session::has('show-card-after-add')) block @else none @endif">
<h4>Warenkorb</h4>
@if(Yard::instance('shopping')->count()) <div class="quick-cart-wrapper">
<span class="">{{ \Yard::instance('shopping')->subtotal() }} </span> @foreach(Yard::instance('shopping')->content() as $row)
@endif <a href="{{ url('/produkte/alle-produkte/'.$row->options->slug) }}"><!-- cart item -->
</a> @if($row->options->has('image'))
<div class="quick-cart-box" style="display: none;"> <img src="{{ route('product_image', [$row->options->image]) }}" width="50" height="66" alt="">
<h4>Warenkorb</h4> @else
<img src="{{ asset('/assets/images/1x1.png') }}" width="50" height="66" alt="">
@endif
<h5>{{ $row->name }}</h5>
<span class="price">{{ $row->qty }}x <strong>{{ $row->price() }} </strong></span>
<div class="quick-cart-wrapper"> </a><!-- /cart item -->
@endforeach
</div>
<!-- quick cart footer -->
<div class="quick-cart-footer clearfix">
<div class="text-left">
<strong>Zwischensumme:</strong> <strong class="pull-right">{{ Yard::instance('shopping')->subtotal() }} </strong>
<br>
<em style="font-size: 0.9em">inkl. MwSt. zzgl. Versandkosten</em>
</div>
<a href="{{ route(Util::getPostRoute().'card_show', Util::addRoute()) }}" class="btn btn-primary btn-text-500 btn-block mt-3 faa-parent animated-hover">zum Warenkorb <i class="fa fa-shopping-cart faa-horizontal"></i></a>
<a href="#" class="btn btn-sm btn-default mt-3 quick-cart-box-close">schließen</a>
@foreach(Yard::instance('shopping')->content() as $row)
<a href="{{ url('/produkte/alle-produkte/'.$row->options->slug) }}"><!-- cart item -->
@if($row->options->has('image'))
<img src="{{ route('product_image', [$row->options->image]) }}" width="50" height="66" alt="">
@else
<img src="{{ asset('/assets/images/1x1.png') }}" width="50" height="66" alt="">
@endif
<h5>{{ $row->name }}</h5>
<span class="price">{{ $row->qty }}x <strong>{{ $row->price() }} </strong></span>
</a><!-- /cart item -->
@endforeach
</div>
<!-- quick cart footer -->
<div class="quick-cart-footer clearfix">
<div class="text-left">
<strong>Zwischensumme:</strong> <strong class="pull-right">{{ Yard::instance('shopping')->subtotal() }} </strong>
<br>
<em style="font-size: 0.9em">inkl. MwSt. zzgl. Versandkosten</em>
</div> </div>
<a href="{{ route(Util::getPostRoute().'card_show', Util::addRoute()) }}" class="btn btn-primary btn-block mt-3">zum Warenkorb</a>
</div> </div>
</div> </li>
</li> </ul>
</ul> <!-- Logo -->
<a class="logo pull-left" href="{{ url('/') }}">
<img class="fixed_top" src="/assets/images/logo_mivita.png" alt="mivita" />
<!-- Logo --> <img class="fixed_scroll" src="/assets/images/logo_mivita_fixed.png" alt="mivita" />
<a class="logo pull-left" href="{{ url('/') }}"> </a>
<img class="fixed_top" src="/assets/images/logo_mivita.png" alt="mivita" /> <div class="navbar-collapse pull-right nav-main-collapse collapse">
<img class="fixed_scroll" src="/assets/images/logo_mivita_fixed.png" alt="mivita" /> <nav class="nav-main">
</a> <ul id="topMain" class="nav nav-pills nav-main nav-onepage">
<div class="navbar-collapse pull-right nav-main-collapse collapse"> <li class="{{ Request::is('/') ? ' active' : '' }}">
<nav class="nav-main"> <a href="/">
<ul id="topMain" class="nav nav-pills nav-main nav-onepage"> Start
<li class="{{ Request::is('/') ? ' active' : '' }}"> </a>
<a href="/"> </li>
Start <li class="{{ Request::is('aloevera') ? ' active' : '' }}">
</a> <a href="{{url('/aloevera')}}">
</li> Aloe Vera
<li class="{{ Request::is('aloevera') ? ' active' : '' }}"> </a>
<a href="{{url('/aloevera')}}"> </li>
Aloe Vera <li class="{{ Request::is('produkte/*') ? ' active' : '' }}">
</a> <a href="{{url('/produkte/alle-produkte')}}/">
</li> Produktwelt
<li class="{{ Request::is('produkte/*') ? ' active' : '' }}"> </a>
<a href="{{url('/produkte/alle-produkte')}}/"> </li>
Produktwelt <li class="{{ Request::is('geschaeftsmodell/*') ? ' active' : '' }}">
</a> <a href="{{url('/geschaeftsmodell/karrierechancen')}} ">
</li> Karrierechancen
<li class="{{ Request::is('geschaeftsmodell/*') ? ' active' : '' }}"> </a>
<a href="{{url('/geschaeftsmodell/karrierechancen')}} "> </li>
Karrierechancen <li class="{{ Request::is('kontakt') ? ' active' : '' }}">
</a> <a href="{{ url('kontakt') }}">
</li> Kontakt
<li class="{{ Request::is('kontakt') ? ' active' : '' }}"> </a>
<a href="{{ url('kontakt') }}"> </li>
Kontakt </ul>
</a> </nav>
</li> </div>
</ul> @endif
</nav>
</div>
</div> </div>
</header> </header>
<!-- /Top Nav --> <!-- /Top Nav -->

View file

@ -1,23 +1,10 @@
@extends('web.user.layouts.application') @extends('web.user.layouts.application')
@section('layout-content') @section('layout-content')
@include('web.user.layouts.includes.header') @include('web.user.layouts.includes.header')
<!-- wrapper --> <!-- wrapper -->
<div id="wrapper"> <div id="wrapper">
@yield('content') @yield('content')
<!-- /FOOTER -->
@include('web.user.layouts.includes.footer') @include('web.user.layouts.includes.footer')
</div> </div>
<!-- /wrapper -->
@endsection @endsection

View file

@ -51,7 +51,7 @@ Route::get('/shop/product/image/{slug}', function($slug = null)
})->name('shop_product_image'); })->name('shop_product_image');
//main site //main site mivita
Route::domain(config('app.pre_url_main').config('app.domain'))->group(function () { Route::domain(config('app.pre_url_main').config('app.domain'))->group(function () {
Route::get('/datenschutz', 'HomeController@legalDataProtected')->name('datenschutz'); Route::get('/datenschutz', 'HomeController@legalDataProtected')->name('datenschutz');
@ -60,20 +60,21 @@ Route::domain(config('app.pre_url_main').config('app.domain'))->group(function (
Route::post('/kontakt', 'Web\ContactController@store')->name('contact_store'); Route::post('/kontakt', 'Web\ContactController@store')->name('contact_store');
Route::get('/', 'Web\SiteController@index')->name('/'); Route::get('/', 'Web\SiteController@index')->name('/');
Route::get('/card/add/{id}/{quantity?}/{product_slug?}', 'Web\CardController@addToCardGet')->name('base.card_add_get');
/* Route::get('/card/add/{id}/{quantity?}/{product_slug?}', 'Web\CardController@addToCardGet')->name('base.card_add_get');
Route::post('/card/add/{id}', 'Web\CardController@addToCardPost')->name('base.card_add_post'); Route::post('/card/add/{id}', 'Web\CardController@addToCardPost')->name('base.card_add_post');
Route::get('/card/show', 'Web\CardController@showCard')->name('base.card_show'); Route::get('/card/show', 'Web\CardController@showCard')->name('base.card_show');
Route::get('/card/checkout', 'Web\CardController@checkoutCard')->name('base.card_checkout'); Route::get('/card/checkout', 'Web\CardController@checkoutCard')->name('base.card_checkout');
Route::post('/card/checkout_final', 'Web\CardController@checkoutFinalCard')->name('base.card_checkout_final'); Route::post('/card/checkout_final', 'Web\CardController@checkoutFinalCard')->name('base.card_checkout_final');
Route::post('/card/update', 'Web\CardController@updateCard')->name('base.card_update'); Route::post('/card/update', 'Web\CardController@updateCard')->name('base.card_update');
Route::get('/card/remove/{rowId}', 'Web\CardController@removeCard')->name('base.card_remove'); Route::get('/card/remove/{rowId}', 'Web\CardController@removeCard')->name('base.card_remove');
Route::get('/card/delete', 'Web\CardController@deleteCard')->name('base.card_delete'); Route::get('/card/delete', 'Web\CardController@deleteCard')->name('base.card_delete');*/
Route::get('/{site}/{subsite?}/{product_slug?}', 'Web\SiteController@site')->name('base.site'); Route::get('/{site}/{subsite?}/{product_slug?}', 'Web\SiteController@site')->name('base.site');
}); });
/* ROUTING FOR CRM / CMS*/ /* ROUTING FOR CRM mein.mivita / CMS*/
Route::domain(config('app.pre_url_crm').config('app.domain'))->group(function () { Route::domain(config('app.pre_url_crm').config('app.domain'))->group(function () {
Auth::routes(); Auth::routes();
@ -228,8 +229,22 @@ Route::domain(config('app.pre_url_crm').config('app.domain'))->group(function ()
}); });
/* ROUTING the checkout.mivita ... */
Route::domain(config('app.checkout_url').config('app.domain'))->group(function () {
Route::group(['middleware' => ['checkout']], function() {
Route::get('/checkout/card/{identifier}', 'Web\CheckoutController@checkout')->name('checkout.checkout_card');
Route::post('/checkout/card/final', 'Web\CheckoutController@checkoutFinal')->name('checkout.checkout_card_final');
Route::get('/transaction/status/', 'Web\CheckoutController@transactionStatus')->name('checkout.transaction_status');
Route::post('/transaction/status/', 'Web\CheckoutController@transactionStatus')->name('checkout.transaction_status');
});
});
/* ROUTING the SUBDOMAINS user.mivita ... */
/* ROUTING the SUBDOMAINS*/
Route::domain('{subdomain}.'.config('app.domain'))->group(function () { Route::domain('{subdomain}.'.config('app.domain'))->group(function () {
Route::group(['middleware' => ['subdomain']], function() { Route::group(['middleware' => ['subdomain']], function() {
@ -242,8 +257,7 @@ Route::domain('{subdomain}.'.config('app.domain'))->group(function () {
Route::get('/card/add/{id}/{quantity?}/{product_slug?}', 'Web\CardController@addToCardGet')->name('user.card_add_get'); Route::get('/card/add/{id}/{quantity?}/{product_slug?}', 'Web\CardController@addToCardGet')->name('user.card_add_get');
Route::post('/card/add/{id}', 'Web\CardController@addToCardPost')->name('user.card_add_post'); Route::post('/card/add/{id}', 'Web\CardController@addToCardPost')->name('user.card_add_post');
Route::get('/card/show', 'Web\CardController@showCard')->name('user.card_show'); Route::get('/card/show', 'Web\CardController@showCard')->name('user.card_show');
Route::get('/card/checkout', 'Web\CardController@checkoutCard')->name('user.card_checkout'); Route::get('/card/checkout/server', 'Web\CardController@checkoutServer')->name('user.card_checkout_server');
Route::post('/card/checkout_final', 'Web\CardController@checkoutFinalCard')->name('user.card_checkout_final');
Route::post('/card/update', 'Web\CardController@updateCard')->name('user.card_update'); Route::post('/card/update', 'Web\CardController@updateCard')->name('user.card_update');
Route::get('/card/remove/{rowId}', 'Web\CardController@removeCard')->name('user.card_remove'); Route::get('/card/remove/{rowId}', 'Web\CardController@removeCard')->name('user.card_remove');
Route::get('/card/delete', 'Web\CardController@deleteCard')->name('user.card_delete'); Route::get('/card/delete', 'Web\CardController@deleteCard')->name('user.card_delete');