-
Notifications
You must be signed in to change notification settings - Fork 372
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This PR looks to add variant generation to the filament hub. This isn't a port of the current offering in `0.7` but is instead a complete reimagining of how it should work, inspired by some other popular systems out there.
- Loading branch information
1 parent
8a92100
commit d8bbaee
Showing
38 changed files
with
4,585 additions
and
160 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
@import '../../vendor/filament/filament/resources/css/theme.css'; | ||
@import '../../vendor/filament/filament/resources/css/theme.css'; |
Large diffs are not rendered by default.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,102 @@ | ||
<?php | ||
|
||
return [ | ||
'label' => 'Product Variant', | ||
'plural_label' => 'Product Variants', | ||
'pages' => [ | ||
'edit' => [ | ||
'title' => 'Basic Information', | ||
], | ||
'media' => [ | ||
'title' => 'Media', | ||
'form' => [ | ||
'no_selection' => [ | ||
'label' => 'You do not currently have an image selected for this variant.', | ||
], | ||
'no_media_available' => [ | ||
'label' => 'There is currently no media available on this product.', | ||
], | ||
'images' => [ | ||
'label' => 'Primary Image', | ||
'helper_text' => 'Select the product image which represents this variant.', | ||
], | ||
], | ||
], | ||
'identifiers' => [ | ||
'title' => 'Identifiers', | ||
], | ||
'inventory' => [ | ||
'title' => 'Inventory', | ||
], | ||
'shipping' => [ | ||
'title' => 'Shipping', | ||
], | ||
], | ||
'form' => [ | ||
'sku' => [ | ||
'label' => 'SKU', | ||
], | ||
'gtin' => [ | ||
'label' => 'Global Trade Item Number (GTIN)', | ||
], | ||
'mpn' => [ | ||
'label' => 'Manufacturer Part Number (MPN)', | ||
], | ||
'ean' => [ | ||
'label' => 'UPC/EAN', | ||
], | ||
'stock' => [ | ||
'label' => 'In Stock', | ||
], | ||
'backorder' => [ | ||
'label' => 'On Backorder', | ||
], | ||
'purchasable' => [ | ||
'label' => 'Purchasability', | ||
'options' => [ | ||
'always' => 'Always', | ||
'in_stock' => 'In Stock', | ||
'backorder' => 'Backorder Only', | ||
], | ||
], | ||
'unit_quantity' => [ | ||
'label' => 'Unit Quantity', | ||
'helper_text' => 'How many individual items make up 1 unit.', | ||
], | ||
'min_quantity' => [ | ||
'label' => 'Minimum Quantity', | ||
'helper_text' => 'The minimum quantity of a product variant that can be bought in a single purchase.', | ||
], | ||
'quantity_increment' => [ | ||
'label' => 'Quantity Increment', | ||
'helper_text' => 'The product variant must be purchased in multiples of this quantity.', | ||
], | ||
'shippable' => [ | ||
'label' => 'Shippable', | ||
], | ||
'length_value' => [ | ||
'label' => 'Length', | ||
], | ||
'length_unit' => [ | ||
'label' => 'Length Unit', | ||
], | ||
'width_value' => [ | ||
'label' => 'Width', | ||
], | ||
'width_unit' => [ | ||
'label' => 'Width Unit', | ||
], | ||
'height_value' => [ | ||
'label' => 'Height', | ||
], | ||
'height_unit' => [ | ||
'label' => 'Height Unit', | ||
], | ||
'weight_value' => [ | ||
'label' => 'Weight', | ||
], | ||
'weight_unit' => [ | ||
'label' => 'Weight Unit', | ||
], | ||
], | ||
]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 5 additions & 0 deletions
5
packages/admin/resources/views/actions/switch-variant.blade.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
<div> | ||
@livewire(\Lunar\Admin\Filament\Widgets\Products\VariantSwitcherTable::class, [ | ||
'record' => $record, | ||
]) | ||
</div> |
Oops, something went wrong.