Skip to content

Commit

Permalink
[0.2] Hotfix - Brand url generation (#862)
Browse files Browse the repository at this point in the history
* Squashed commit of the following:

commit 02c2671
Author: Alec Ritson <hello@itsalec.co.uk>
Date:   Fri Feb 10 11:13:49 2023 +0000

    Update lines.blade.php (#849)

commit 0780a1c
Author: wychoong <67364036+wychoong@users.noreply.github.com>
Date:   Fri Feb 10 18:41:36 2023 +0800

    Update CollectionTree.php (#835)

    Co-authored-by: Alec Ritson <hello@itsalec.co.uk>

commit e558799
Author: Alec Ritson <hello@itsalec.co.uk>
Date:   Fri Feb 10 09:47:16 2023 +0000

    :beer:

commit 8fd4842
Merge: df6f7f7 51af420
Author: Alec Ritson <hello@itsalec.co.uk>
Date:   Fri Feb 10 09:47:03 2023 +0000

    Merge branch '0.2' of github.com:lunarphp/lunar into 0.2

commit df6f7f7
Author: Alec Ritson <hello@itsalec.co.uk>
Date:   Fri Feb 10 09:47:00 2023 +0000

    :beer:

commit 51af420
Author: wychoong <67364036+wychoong@users.noreply.github.com>
Date:   Fri Feb 10 17:43:10 2023 +0800

    [0.2] Hotfix - fix pluck on null (#834)

    * fix pluck on null

    * Update AbstractDiscount.php

    ---------

    Co-authored-by: Alec Ritson <hello@itsalec.co.uk>

commit 7b5ce85
Author: wychoong <67364036+wychoong@users.noreply.github.com>
Date:   Fri Feb 10 17:16:50 2023 +0800

    [0.2] Fix/discount by product (#841)

    * fix

    * add test

    * fix discount minSpend precision

    * fix discount condition logic

    * fix

    * fix coupon check

commit 72f8454
Author: Alec Ritson <hello@itsalec.co.uk>
Date:   Fri Feb 10 09:16:16 2023 +0000

    Hotfix [0.2] - Wrap customer group in array (#846)

    * Wrap customer group in array

    * Update ProductVariantTest.php

commit b8773d3
Author: Ryan Mitchell <ryan@thoughtcollective.com>
Date:   Wed Feb 8 20:43:09 2023 +0000

    When DB::table() is used make sure connection is passed (#826)

commit 650d9db
Merge: dcd39cc de20aff
Author: Alec Ritson <hello@itsalec.co.uk>
Date:   Wed Feb 1 09:57:04 2023 +0000

    Merge branch 'main' into 0.2

commit dcd39cc
Author: Alec Ritson <hello@itsalec.co.uk>
Date:   Tue Jan 31 07:29:15 2023 +0000

    :beer:

* Squashed commit of the following:

commit 1a362cc
Author: Ivanka Todorova <1038697+fakeheal@users.noreply.github.com>
Date:   Tue Feb 14 13:25:25 2023 +0200

    Fix validation of attributes of type TranslatedText (#839)

    * fix: validation rules to be applied on elements in `TranslatedText`

    * fix: "reset" the validation rules applied to each sub-field in `TranslatedText`

    * chore: add tests for validating attribute fields (required/optional) and their additional rules

    ---------

    Co-authored-by: Alec Ritson <hello@itsalec.co.uk>

commit 6c1ab08
Author: Alec Ritson <hello@itsalec.co.uk>
Date:   Tue Feb 14 10:58:15 2023 +0000

    [0.2] Hotfix - Fix collection name on creation (#852)

    * Squashed commit of the following:

    commit 02c2671
    Author: Alec Ritson <hello@itsalec.co.uk>
    Date:   Fri Feb 10 11:13:49 2023 +0000

        Update lines.blade.php (#849)

    commit 0780a1c
    Author: wychoong <67364036+wychoong@users.noreply.github.com>
    Date:   Fri Feb 10 18:41:36 2023 +0800

        Update CollectionTree.php (#835)

        Co-authored-by: Alec Ritson <hello@itsalec.co.uk>

    commit e558799
    Author: Alec Ritson <hello@itsalec.co.uk>
    Date:   Fri Feb 10 09:47:16 2023 +0000

        :beer:

    commit 8fd4842
    Merge: df6f7f7 51af420
    Author: Alec Ritson <hello@itsalec.co.uk>
    Date:   Fri Feb 10 09:47:03 2023 +0000

        Merge branch '0.2' of github.com:lunarphp/lunar into 0.2

    commit df6f7f7
    Author: Alec Ritson <hello@itsalec.co.uk>
    Date:   Fri Feb 10 09:47:00 2023 +0000

        :beer:

    commit 51af420
    Author: wychoong <67364036+wychoong@users.noreply.github.com>
    Date:   Fri Feb 10 17:43:10 2023 +0800

        [0.2] Hotfix - fix pluck on null (#834)

        * fix pluck on null

        * Update AbstractDiscount.php

        ---------

        Co-authored-by: Alec Ritson <hello@itsalec.co.uk>

    commit 7b5ce85
    Author: wychoong <67364036+wychoong@users.noreply.github.com>
    Date:   Fri Feb 10 17:16:50 2023 +0800

        [0.2] Fix/discount by product (#841)

        * fix

        * add test

        * fix discount minSpend precision

        * fix discount condition logic

        * fix

        * fix coupon check

    commit 72f8454
    Author: Alec Ritson <hello@itsalec.co.uk>
    Date:   Fri Feb 10 09:16:16 2023 +0000

        Hotfix [0.2] - Wrap customer group in array (#846)

        * Wrap customer group in array

        * Update ProductVariantTest.php

    commit b8773d3
    Author: Ryan Mitchell <ryan@thoughtcollective.com>
    Date:   Wed Feb 8 20:43:09 2023 +0000

        When DB::table() is used make sure connection is passed (#826)

    commit 650d9db
    Merge: dcd39cc de20aff
    Author: Alec Ritson <hello@itsalec.co.uk>
    Date:   Wed Feb 1 09:57:04 2023 +0000

        Merge branch 'main' into 0.2

    commit dcd39cc
    Author: Alec Ritson <hello@itsalec.co.uk>
    Date:   Tue Jan 31 07:29:15 2023 +0000

        :beer:

    * Check for attribute type when creating

commit 0942397
Author: Alec Ritson <hello@itsalec.co.uk>
Date:   Tue Feb 14 10:57:37 2023 +0000

    Update HasImages.php (#853)

* add test

* enhance url generator to handle non attribute_data

* phpunit warning: expectWarningMessage deprecated

* cleanup

* enhance url generator to handle non attribute_data

* phpunit warning: expectWarningMessage deprecated

* cleanup

* Revert "enhance url generator to handle non attribute_data"

This reverts commit 8073663.

* pint

---------

Co-authored-by: Alec Ritson <hello@itsalec.co.uk>
  • Loading branch information
wychoong and alecritson authored Feb 15, 2023
1 parent f36338a commit fab3b6d
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
namespace Lunar\Hub\Http\Livewire\Components\Brands;

use Illuminate\Support\Arr;
use Illuminate\Support\Str;
use Livewire\Component;
use Lunar\Hub\Http\Livewire\Traits\Notifies;
use Lunar\Models\Brand;
Expand Down Expand Up @@ -84,14 +83,7 @@ public function createBrand()
'name' => $this->brand['name'],
]);

$brand->urls()->create([
'slug' => Str::slug($this->brand['name']),
'default' => true,
'language_id' => Language::getDefault()->id,
]);

$this->brand = null;
$this->slug = null;

$this->showCreateForm = false;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public function render()
{
return view('adminhub::livewire.pages.brands.show')
->layout('adminhub::layouts.app', [
'title' => 'Customers',
'title' => $this->brand->name,
]);
}
}
1 change: 0 additions & 1 deletion packages/core/tests/Unit/Models/BrandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
/**
* @group lunar.brands
*/

class BrandTest extends TestCase
{
use RefreshDatabase;
Expand Down
2 changes: 1 addition & 1 deletion packages/core/tests/Unit/Models/ProductOptionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public function handle_if_not_unique_throw_exception()
$productOption = ProductOption::factory()->create();

$this->expectException(QueryException::class);
$this->expectWarningMessage('UNIQUE constraint failed');
$this->expectExceptionMessage('UNIQUE constraint failed');
ProductOption::factory()->create([
'handle' => $productOption->handle,
]);
Expand Down

0 comments on commit fab3b6d

Please sign in to comment.