BranchGroup
Representa a grupo de sucursales para manejo interno del sistema. Esto permite agrupar Branches para otorgar
privilegios a grupos de administradores fácilmente, cuando las Branches son administradas por el mismo grupo de
Admins.
Modelo BranchGroup
{
"id": 1,
"name": "default",
"created_at": "2020-08-06 02:58:46",
"updated_at": "2020-12-18 03:39:42",
"display_unavailable_goods": false,
"enable_shoppers": false,
"is_market": false,
"logo_url": "http://127.0.0.1:8000/storage/static/default/product_category_logo.png",
"is_featured": false,
"in_order": 65535,
"promo_label": null,
"enable_pool": true,
"rating_e2": 500,
"rating_sum": 0,
"rating_count": 0,
"display_spent_goods": true,
"domain": "b1",
"custom_domain": null,
"settings": {
"template": "store_1",
"color_primary": "/docs/3/branch_group#aaaaaa",
"color_accent": "/docs/3/branch_group#777777"
}
}
Insertar BranchGroup
Método |
URI |
Cabeceras |
POST |
/companies/{companyId}/branch-groups |
Authorization |
{
"name": "required|string|max:64",
"display_unavailable_goods": "boolean",
"display_spent_goods": "boolean",
"enable_shoppers": "boolean",
"enable_pool": "boolean",
"is_market": "boolean",
"in_order": "integer|min:1",
"promo_label": "string|max:32",
"domain": "required|max:32|domain",
"custom_domain": "max:255|url"
}
Listar BranchGroup
{info} Soporta:
Paginación
Filters
Carga dinámica
Método |
URI |
Cabeceras |
GET |
/companies/{companyId}/branch-groups |
Authorization |
Listar Setting
Método |
URI |
Cabeceras |
GET |
/companies/{companyId}/branch-groups/{branchGroupId}/settings |
Authorization |
{info} Soporta:
Paginación
Filters
Método |
URI |
Cabeceras |
GET |
/companies/{companyId}/branch-categories/{branchCategoryId}/branch-groups |
N/A |
Mostrar BranchGroup
{info} Soporta:
Carga dinámica
Método |
URI |
Cabeceras |
GET |
/companies/{companyId}/branch-groups/{branchGroupId} |
Authorization |
Actualizar BranchGroup
Método |
URI |
Cabeceras |
PATCH |
/companies/{companyId}/branch-groups/{branchGroupId} |
Authorization |
{
"name": "string|max:64",
"display_unavailable_goods": "boolean",
"display_spent_goods": "boolean",
"enable_shoppers": "boolean",
"enable_pool": "boolean",
"is_market": "boolean",
"in_order": "integer|min:1",
"promo_label": "string|max:32",
"domain": "required|max:32|domain",
"custom_domain": "max:255|url"
}
Actualizar Setting
Método |
URI |
Cabeceras |
PATCH |
/companies/{companyId}/branch-groups/{branchGroupId}/settings |
Authorization |
{
"add_rating_sum": "integer|min:0",
"add_rating_count": "integer|min:0",
"import_config": "array",
"color_primary": "string|regex:/^#(?:[0-9a-fA-F]{3}){1,2}$/",
"color_accent": "string|regex:/^#(?:[0-9a-fA-F]{3}){1,2}$/",
"template": "string|in:store_1,food_1,market_1"
}
Eliminar BranchGroup
Método |
URI |
Cabeceras |
DELETE |
/companies/{companyId}/branch-groups/{branchGroupId} |
Authorization |
Acciones de BranchGroup
Upload Logo
Método |
URI |
Cabeceras |
POST |
/companies/{companyId}/branch-groups/{branchGroupId}/upload-logo |
Authorization |
{
"image": "required|image|mimes:jpeg,png,bmp|max:8192|dimensions:min_width=600,ratio=1/1"
}
Set Featured Enabled
Método |
URI |
Cabeceras |
POST |
/companies/{companyId}/branch-groups/{branchGroupId}/set-featured-enabled |
Authorization |
Set Featured Disabled
Método |
URI |
Cabeceras |
POST |
/companies/{companyId}/branch-groups/{branchGroupId}/set-featured-disabled |
Authorization |
Index Allowed
Método |
URI |
Cabeceras |
GET |
/companies/{companyId}/branch-groups/{branchGroupId}/allowed-settings |
Authorization |
Enlaces de BranchGroup