hsoni/module-shopfinder

Shopfinder Magento 2 模块

安装: 5

依赖: 0

建议者: 0

安全: 0

星标: 0

关注者: 1

分支: 0

类型:magento2-module

1.0.3 2023-04-23 17:22 UTC

This package is auto-updated.

Last update: 2024-09-23 20:13:32 UTC


README

安装

该扩展必须通过 composer 安装。要继续,请在您的终端中运行以下命令

composer require hsoni/module-shopfinder
php bin/magento module:enable Hsoni_Shopfinder
php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy

GraphQL

创建商店

创建新的商店查询格式

mutation {
    createShop(
        input:{
            identifier  :"shop-identifier"
            shop_name  :"Shop Name" 
            country  :"US"
            image  :"image.jpg"
            longitude  :"2.232123"
            latitude  :"123232" 
        }
    ){
        shopfinder_id
        identifier 
        shop_name 
        country
        longitude
        latitude
    }
}

更新商店

更新商店查询格式

mutation {
    updateShop(
        input:{
            shopfinder_id  :3,
            identifier  :"shop-identifier", 
            shop_name  :"New shop name", 
            country  :"UAE",
            longitude  :"122.232123",
            latitude  :"123.232",   
        }
    ){
        message
    }
}

删除商店

删除商店查询格式

mutation {
    deleteShop(
        shopfinder_id: 10
    ){
        message
    }
}

获取所有商店

获取所有商店的列表

{
    shopfinderList(
        pageSize: 10
        pageNo: 1
    ){
        shoplist{
            shopfinder_id
            shop_name
            identifier
            country
            image
            longitude
            latitude
        }
    }
}

获取特定商店

通过shopfinder_id或标识符获取商店

{
    shopfinder(identifier:'shop-identifier') {
        shopfinder_id
        shop_name
        identifier
        country
        image
        longitude
        latitude
    }
}