Skip to content

Commit

Permalink
first commit
Browse files Browse the repository at this point in the history
  • Loading branch information
rizhk committed Apr 17, 2020
0 parents commit cd9ad64
Show file tree
Hide file tree
Showing 556 changed files with 42,237 additions and 0 deletions.
Binary file added .DS_Store
Binary file not shown.
1 change: 1 addition & 0 deletions .ftpquota
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
13973 157520815
5 changes: 5 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
* text=auto
*.css linguist-vendored
*.scss linguist-vendored
*.js linguist-vendored
CHANGELOG.md export-ignore
11 changes: 11 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
/node_modules
/public/hot
/public/storage
/storage/*.key
/vendor
/.idea
/.vagrant
Homestead.json
Homestead.yaml
npm-debug.log
.env
20 changes: 20 additions & 0 deletions .htaccess
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<IfModule mod_rewrite.c>
<IfModule mod_negotiation.c>
Options -MultiViews
</IfModule>

RewriteEngine On

# Redirect Trailing Slashes If Not A Folder...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)/$ /$1 [L,R=301]

# Handle Front Controller...
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^ index.php [L]

# Handle Authorization Header
RewriteCond %{HTTP:Authorization} .
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
</IfModule>
22 changes: 22 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "Listen for XDebug",
"type": "php",
"request": "launch",
"port": 9000
},
{
"name": "Launch currently open script",
"type": "php",
"request": "launch",
"program": "${file}",
"cwd": "${fileDirname}",
"port": 9000
}
]
}
29 changes: 29 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# README #

This README would normally document whatever steps are necessary to get your application up and running.

### What is this repository for? ###

* Quick summary
* Version
* [Learn Markdown](https://bitbucket.org/tutorials/markdowndemo)

### How do I get set up? ###

* Summary of set up
* Configuration
* Dependencies
* Database configuration
* How to run tests
* Deployment instructions

### Contribution guidelines ###

* Writing tests
* Code review
* Other guidelines

### Who do I talk to? ###

* Repo owner or admin
* Other community or team contact
57 changes: 57 additions & 0 deletions Untitled Document
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@


$data = [

"aps" => [

"alert" => [

"title" => "Push Remote Rich Notifications",

"subtitle" => "iOS 10 - New API",

"body" => "Media Image Rich notification"

],

"mutable-content" => 1,

"category" => "imageIdentifier"

],

"data" => [

"attachment-url"=> "https://raw.githubusercontent.com/Sweefties/iOS10-NewAPI-UserNotifications-Example/master/source/iOS10-NewAPI-UserNotifications-Example.jpg"

]

];



$message = PushNotification::Message('Hello World, i`m a push message',array(
'badge' => 1,
'sound' => 'example.aiff',
"mutable-content" => 1,
"media-url" => "https://i.imgur.com/t4WGJQx.jpg",
'actionLocKey' => 'Action button title!',
'locKey' => 'localized key',
'locArgs' => array(
'localized args',
'localized args',
),
'launchImage' => 'image.jpg',

'custom' => array('custom data' => array(
"mutable-content" => 1,
"media-url" => "https://i.imgur.com/t4WGJQx.jpg",
'we' => 'want', 'send to app'
))

'custom' => array( "mutable-content" => 1,
"media-url" => "https://i.imgur.com/t4WGJQx.jpg" )
)
);

return json_encode($message);
38 changes: 38 additions & 0 deletions app/Addon.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
<?php

namespace App;

use Illuminate\Database\Eloquent\Model;

class Addon extends Model
{
/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = [
'name','shop_id'
];

/**
* The attributes that should be hidden for arrays.
*
* @var array
*/
protected $hidden = [
'created_at', 'updated_at',
];

/**
* Products belonging to the category
*/
/*public function products()
{
return $this->belongsToMany('App\Product');
}
public function addon_price(){
return $this->belongsToMany('App\Addon','addon_product')->withPivot('price');
}*/
}
32 changes: 32 additions & 0 deletions app/AddonProduct.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<?php

namespace App;

use Illuminate\Database\Eloquent\Model;

class AddonProduct extends Model
{
/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = [
'addon_id','product_id','price'
];

/**
* The attributes that should be hidden for arrays.
*
* @var array
*/
protected $hidden = [
'created_at', 'updated_at',
];
protected $with = ['addon'];
public function addon()
{
return $this->hasOne('App\Addon','id','addon_id');
}

}
41 changes: 41 additions & 0 deletions app/Admin.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
<?php

namespace App;

use App\Notifications\AdminResetPassword;
use Illuminate\Notifications\Notifiable;
use Illuminate\Foundation\Auth\User as Authenticatable;
use Spatie\Permission\Traits\HasRoles;
class Admin extends Authenticatable
{
use Notifiable,HasRoles;
protected $guard_name = 'admin';
/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = [
'name', 'email', 'password','phone','avatar'
];

/**
* The attributes that should be hidden for arrays.
*
* @var array
*/
protected $hidden = [
'password', 'remember_token',
];

/**
* Send the password reset notification.
*
* @param string $token
* @return void
*/
public function sendPasswordResetNotification($token)
{
$this->notify(new AdminResetPassword($token));
}
}
17 changes: 17 additions & 0 deletions app/Card.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?php

namespace App;

use Illuminate\Database\Eloquent\Model;

class Card extends Model
{
/**
* The attributes that should be hidden for arrays.
*
* @var array
*/
protected $hidden = [
'created_at', 'updated_at'
];
}
42 changes: 42 additions & 0 deletions app/CartAddon.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
<?php

namespace App;

use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
class CartAddon extends Model
{

use SoftDeletes;

/**
* The attributes that are mass assignable.
*
* @var array
*/
protected $fillable = [
'user_cart_id',
'addon_product_id',
'quantity'
];
/**
* The attributes that should be hidden for arrays.
*
* @var array
*/
protected $hidden = [
'created_at', 'updated_at'
];

protected $with = ['addon_product','addon_product.addon'];
/**
* Products belonging to the category
*/
public function addon_product()
{
return $this->belongsTo('App\AddonProduct','addon_product_id');
}



}
Loading

0 comments on commit cd9ad64

Please sign in to comment.