定制 aiarmada/cart 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

aiarmada/cart

最新稳定版本:v1.4.7

Composer 安装命令:

composer require aiarmada/cart

包简介

A comprehensive commerce ecosystem for Laravel with cart, payments, vouchers, shipping, and inventory management.

README 文档

README

This package contains the core implementation that powers AIArmada Cart. It is published as aiarmada/cart on Packagist and intended for Laravel 12 applications seeking a feature-rich shopping cart engine.

Highlights

  • 📦 Pluggable storage – session, cache, and database drivers that implement a shared interface.
  • 🛒 Composable cart architecture – traits manage items, totals, metadata, and conditions.
  • 🔁 Multi-instance by default – support any number of cart buckets per user or session.
  • 🧮 Accurate calculations – Akaunting\Money integration for precise totals and rounding.
  • 📈 Observability hooks – metrics, conflict tracking, and per-operation performance measurements.

Documentation

The full project documentation lives in the repository root under docs/. Start with:

JSON vs JSONB (PostgreSQL)

Migrations default to portable json columns. To opt into jsonb on a fresh install, set one of the following BEFORE running migrations:

COMMERCE_JSON_COLUMN_TYPE=jsonb
# or per-package override
CART_JSON_COLUMN_TYPE=jsonb

Or run the interactive setup:

php artisan commerce:configure-database

When using PostgreSQL + jsonb, GIN indexes are created automatically on items, conditions, and metadata.

Local Development

Clone the monorepo and install dependencies:

composer install
vendor/bin/pest

When editing code:

  • Keep strict types and typed signatures.
  • Honour StorageInterface when extending storage implementations.
  • Update or add tests for behavioural changes.
  • Format using vendor/bin/pint --dirty.

Testing

Run the unit suite for the core package:

vendor/bin/pest tests/Unit

Use Pest filters (--group, --filter) to target specific areas.

Contributing

Please review the Laravel Cart Coding Guidelines before submitting PRs. Contributions from the community are welcome—issues, bug reports, and feature suggestions keep the project healthy.

License

AIArmada Cart is released under the MIT license.

统计信息

  • 总下载量: 96
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 3
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2025-11-06