Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
meibuyu-micro
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
without authentication
meibuyu-micro
Commits
1b9a982c
Commit
1b9a982c
authored
Sep 02, 2020
by
王源
🎧
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加shopify产品相关文件
parent
7bf1df7f
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
86 additions
and
0 deletions
+86
-0
ShopifyApp.php
src/Shopify/ShopifyApp.php
+8
-0
Product.php
src/Shopify/lib/Product.php
+34
-0
ProductImage.php
src/Shopify/lib/ProductImage.php
+16
-0
ProductVariant.php
src/Shopify/lib/ProductVariant.php
+28
-0
No files found.
src/Shopify/ShopifyApp.php
View file @
1b9a982c
...
...
@@ -14,6 +14,8 @@ use Meibuyu\Micro\Shopify\lib\Collect;
use
Meibuyu\Micro\Shopify\lib\Collection
;
use
Meibuyu\Micro\Shopify\lib\CustomCollection
;
use
Meibuyu\Micro\Shopify\lib\Metafield
;
use
Meibuyu\Micro\Shopify\lib\Product
;
use
Meibuyu\Micro\Shopify\lib\ProductVariant
;
use
Meibuyu\Micro\Shopify\lib\SmartCollection
;
use
Meibuyu\Micro\Shopify\lib\Webhook
;
...
...
@@ -27,12 +29,16 @@ use Meibuyu\Micro\Shopify\lib\Webhook;
* @property-read CustomCollection $CustomCollection
* @property-read SmartCollection $SmartCollection
* @property-read Metafield $Metafield
* @property-read Product $Product
* @property-read ProductVariant $ProductVariant
*
* @method Webhook Webhook(integer $id = null)
* @method Collection Collection(integer $id = null)
* @method CustomCollection CustomCollection(integer $id = null)
* @method SmartCollection SmartCollection(integer $id = null)
* @method Metafield Metafield(integer $id = null)
* @method Product Product(integer $id = null)
* @method ProductVariant ProductVariant(integer $id = null)
*
*/
class
ShopifyApp
...
...
@@ -45,6 +51,8 @@ class ShopifyApp
'CustomCollection'
,
'SmartCollection'
,
'Metafield'
,
'Product'
,
'ProductVariant'
,
];
protected
$childResources
=
array
(
...
...
src/Shopify/lib/Product.php
0 → 100644
View file @
1b9a982c
<?php
/**
* Created by PhpStorm.
* User: Zero
* Date: 2020/9/2
* Time: 16:50
*/
namespace
Meibuyu\Micro\Shopify\lib
;
/**
* Class Product
* @package Meibuyu\Micro\Shopify\lib
*
* @property-read ProductImage $Image
* @property-read ProductVariant $Variant
* @property-read Metafield $Metafield
*
* @method ProductImage Image(integer $id = null)
* @method ProductVariant Variant(integer $id = null)
* @method Metafield Metafield(integer $id = null)
*/
class
Product
extends
AbstractShopify
{
protected
$resourceKey
=
'product'
;
protected
$childResource
=
[
'ProductImage'
=>
'Image'
,
'ProductVariant'
=>
'Variant'
,
'Metafield'
,
];
}
src/Shopify/lib/ProductImage.php
0 → 100644
View file @
1b9a982c
<?php
/**
* Created by PhpStorm.
* User: Zero
* Date: 2020/9/2
* Time: 16:50
*/
namespace
Meibuyu\Micro\Shopify\lib
;
class
ProductImage
extends
AbstractShopify
{
protected
$resourceKey
=
'image'
;
}
src/Shopify/lib/ProductVariant.php
0 → 100644
View file @
1b9a982c
<?php
/**
* Created by PhpStorm.
* User: Zero
* Date: 2020/9/2
* Time: 16:50
*/
namespace
Meibuyu\Micro\Shopify\lib
;
/**
* Class ProductVariant
* @package Meibuyu\Micro\Shopify\lib
*
* @property-read Metafield $Metafield
*
* @method Metafield Metafield(integer $id = null)
*/
class
ProductVariant
extends
AbstractShopify
{
protected
$resourceKey
=
'variant'
;
protected
$childResource
=
[
'Metafield'
,
];
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment