Skip to content

Commit 668a98b

Browse files
authored
Merge pull request #55 from avored/dev
merging dev to master
2 parents 7050f19 + 8a0d645 commit 668a98b

File tree

206 files changed

+1769
-3702
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

206 files changed

+1769
-3702
lines changed

composer.json

+3
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,9 @@
3434
"mockery/mockery" : "1.2.*"
3535
},
3636
"autoload" : {
37+
"classmap": [
38+
"database/factories"
39+
],
3740
"psr-4" : {
3841
"AvoRed\\Framework\\" : "src/"
3942

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<?php
2+
3+
use Faker\Generator as Faker;
4+
5+
$factory->define(AvoRed\Framework\Models\Database\Category::class, function (Faker $faker) {
6+
$name = $faker->text(5);
7+
return [
8+
'name' => $name,
9+
'slug' => str_slug($name),
10+
];
11+
});

database/factories/CountryFactory.php

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<?php
2+
3+
use Faker\Generator as Faker;
4+
5+
$factory->define(AvoRed\Framework\Models\Database\Country::class, function (Faker $faker) {
6+
return [
7+
'name' => 'new zealand',
8+
'code' => 'nzd',
9+
'phone_code' => '0064',
10+
'currency_code' => 'NZD',
11+
'currency_symbol' => '$',
12+
'lang_code' => 'English'
13+
];
14+
});

database/factories/RoleFactory.php

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<?php
2+
3+
use Faker\Generator as Faker;
4+
5+
$factory->define(AvoRed\Framework\Models\Database\Role::class, function (Faker $faker) {
6+
return [
7+
'name' => $faker->text(rand(5,10)),
8+
'description' => $faker->text(rand(50,60))
9+
];
10+
});
+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?php
2+
3+
use Faker\Generator as Faker;
4+
5+
$factory->define(AvoRed\Framework\Models\Database\SiteCurrency::class, function (Faker $faker) {
6+
return [
7+
'name' => 'currency name',
8+
'code' => $faker->currencyCode,
9+
'symbol' => '$',
10+
'conversion_rate' => 1.00,
11+
'status' => 'ENABLED'
12+
];
13+
});

database/factories/StateFactory.php

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?php
2+
3+
use Faker\Generator as Faker;
4+
use AvoRed\Framework\Models\Database\Country;
5+
6+
$factory->define(AvoRed\Framework\Models\Database\State::class, function (Faker $faker) {
7+
$country = factory(Country::class)->create();
8+
return [
9+
'name' => 'new zealand',
10+
'code' => 'state for new zealand',
11+
'country_id' => $country->id
12+
];
13+
});

database/factories/UserFactory.php

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
<?php
2+
3+
use Faker\Generator as Faker;
4+
5+
$factory->define(AvoRed\Framework\Models\Database\User::class, function (Faker $faker) {
6+
return [
7+
'first_name' => $faker->firstName,
8+
'last_name' => $faker->lastName,
9+
'email' => $faker->email,
10+
'password' => bcrypt($faker->phoneNumber),
11+
'phone' => $faker->phoneNumber,
12+
'status' => 'LIVE'
13+
14+
];
15+
});
+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<?php
2+
3+
use Faker\Generator as Faker;
4+
5+
$factory->define(AvoRed\Framework\Models\Database\UserGroup::class, function (Faker $faker) {
6+
return [
7+
'name' =>$faker->text(rand(5,10)),
8+
'is_default' => rand(0,1)
9+
];
10+
});

database/migrations/2017_03_29_000000_avored_framework_schema.php

+2
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,7 @@ public function up()
144144
$table->integer('qty');
145145
$table->decimal('price', 11, 6);
146146
$table->decimal('tax_amount', 11, 6);
147+
$table->json('product_info')->nullable()->default(null);
147148
$table->timestamps();
148149

149150
$table->foreign('order_id')->references('id')->on('orders');
@@ -592,6 +593,7 @@ public function up()
592593
$table->increments('id');
593594
$table->string('name')->nullable()->default(null);
594595
$table->string('identifier')->nullable()->default(null);
596+
$table->tinyInteger('is_default')->nullable()->default(0);
595597
$table->timestamps();
596598
});
597599

phpcs.xml

+64
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
<?xml version="1.0"?>
2+
<ruleset name="AvoRed Coding Standards">
3+
4+
<!--
5+
The name attribute of the ruleset tag is displayed
6+
when running PHP_CodeSniffer with the -v command line
7+
argument. The description tag below is not displayed anywhere
8+
except in this file, so it can contain information for
9+
developers who may change this file in the future.
10+
-->
11+
<description>The AvoRed Coding Standards</description>
12+
13+
<!--
14+
If no files or directories are specified on the command line
15+
your custom standard can specify what files should be checked
16+
instead.
17+
Note that specifying any file or directory path
18+
on the command line will ignore all file tags.
19+
-->
20+
<file>src/Permission</file>
21+
22+
<!--
23+
You can hard-code ignore patterns directly into your
24+
custom standard so you don't have to specify the
25+
patterns on the command line.
26+
-->
27+
<exclude-pattern>*/config/*</exclude-pattern>
28+
<exclude-pattern>*/database/*</exclude-pattern>
29+
<exclude-pattern>*/resources/*</exclude-pattern>
30+
<exclude-pattern>*/routes/*</exclude-pattern>
31+
<exclude-pattern>*/tests/*</exclude-pattern>
32+
33+
<!--
34+
You can hard-code command line values into your custom standard.
35+
Note that this does not work for the command line values:
36+
-v[v][v], -l, -d, -sniffs and -standard
37+
The following tags are equivalent to the command line arguments:
38+
-p
39+
-->
40+
<arg name="colors"/>
41+
42+
<!--
43+
You can hard-code custom php.ini settings into your custom standard.
44+
The following tag sets the memory limit to 64M.
45+
-->
46+
<ini name="memory_limit" value="128M"/>
47+
48+
<!--
49+
Include all sniffs in the PEAR standard. Note that the
50+
path to the standard does not have to be specified as the
51+
PEAR standard exists inside the PHP_CodeSniffer install
52+
directory.
53+
-->
54+
<rule ref="PEAR">
55+
<exclude name="PEAR.Commenting.FileComment" />
56+
<exclude name="PEAR.Commenting.ClassComment" />
57+
<exclude name="PEAR.Commenting.FunctionComment" />
58+
</rule>
59+
60+
<rule ref="PEAR">
61+
<exclude name="Generic.Commenting.DocComment" />
62+
</rule>
63+
64+
</ruleset>

phpunit.xml

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
</filter>
2323

2424
<!--logging>
25-
<log type="coverage-html" target="../../public/cov/framework"
25+
<log type="coverage-html" target="../../../public/cov/framework"
2626
lowUpperBound="50" highLowerBound="80"/>
2727
</logging-->
28-
</phpunit>
28+
</phpunit>

resources/assets/images/logo.svg

-16
This file was deleted.

resources/assets/js/chat/index.js

-8
This file was deleted.

resources/assets/js/components/ExampleComponent.vue

-23
This file was deleted.

0 commit comments

Comments
 (0)