thelia/customer-family-module 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

thelia/customer-family-module

Composer 安装命令:

composer require thelia/customer-family-module

包简介

For creating customer families

README 文档

README

Create customer families (professional, private individual, ...) and manage specific prices.

Also allow to define purchase prices for products.

Compatibility

Thelia >= 2.3.x

For use with lower version of Thelia look for older tags on this module.

Installation

Manually

  • Copy the module into <thelia_root>/local/modules/CustomerFamily directory and be sure that the name of the module is CustomerFamily.
  • Activate it in your thelia administration panel

Composer

Add it in your main thelia composer.json file

composer require thelia/customer-family-module:~1.5.0

Usage

This module is visible in the BackOffice Customer Edit.

Use the first tab to create, edit or remove families. You can also define default family, use to show specific price to unlogged customers.

The second tab allows you to define how prices are calculated for each family, depending on the products purchase price.

Product's prices are automatically changed in the 'product' loop, you don't need to use 'customer_family_pse_calculated_prices' loop (see below) to get product's prices.

Loops

Use provided loops to display for example taxed or untaxed price depending on the customer's family.

customer_family

This loop returns client families

Input arguments

Argument Description
id family id
exclude_id exclude family id
is_default filter default family

Output values

Argument Description
CUSTOMER_FAMILY_ID customer family id
CODE customer family code
TITLE_CUSTOMER_FAMILY customer family title
IS_DEFAULT default customer family

Example

{loop type="customer_family" name="customer_family_loop" current_product=$product_id limit="4"}
    {$CODE} ({$TITLE_CUSTOMER_FAMILY})
{/loop}

customer_customer_family

This loop returns customer family for specific customer or inverse

Input arguments

Argument Description
customer_id customer id
customer_family_id family id
customer_family_code family code

Output values

Argument Description
CUSTOMER_FAMILY_ID customer family id
CUSTOMER_ID customer id

Example

{loop type="customer_customer_family" name="customer_customer_family_loop" customer_id="4"}

{/loop}

customer_family_price

This loop returns the customer family's equation data

Input arguments

Argument Description
customer_family_id family id
promo equation for the promo price or not
use_equation is the equation used to calculate price

Output values

Argument Description
CUSTOMER_FAMILY_ID customer family id
PROMO equation for the promo price or not
USE_EQUATION is the equation used to calculate price
AMOUNT_ADDED_BEFORE amount directly added to the purchase price
AMOUNT_ADDED_AFTER amount added to the purchase price after the multiplication
COEFFICIENT coefficient the purchase price added to AMOUNT_ADDED_BEFORE is multiplied by
IS_TAXED are taxes applied on the final calculated price

Example

{loop type="customer_family_price" name="customer_family_price_loop" customer_family_id=1 promo=0}
    {$AMOUNT_ADDED_BEFORE}
    ...
{/loop}

customer_family_pse_calculated_prices

This loop returns the PSE's calculated price based on the given customer family & currency

Input arguments

Argument Description
pse_id mandatory, PSE id
currency_id currency id (if not given, use default currency)
customer_family_id mandatory, customer family id

Output values

Argument Description
CALCULATED_PRICE customer family id
CALCULATED_TAXED_PRICE equation for the promo price or not
CALCULATED_PROMO_PRICE is the equation used to calculate price
CALCULATED_TAXED_PROMO_PRICE amount directly added to the purchase price

Example

{loop type="customer_family_pse_calculated_prices" name="customer_family_pse_calculated_prices_loop" pse_id=22 customer_family_id=1}
    {$CALCULATED_TAXED_PRICE}
    ...
{/loop}

Form customer_family_customer_create_form

This form extend customer_create_form

Fields

Name Type Required
customer_family_id integer true

Default

By default, two families are created

  • Private individual
  • Professional

thelia/customer-family-module 适用场景与选型建议

thelia/customer-family-module 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 1.25k 次下载、GitHub Stars 达 0, 最近一次更新时间为 2015 年 02 月 27 日, 在 PHP 生态内属于活跃度较高的组件。

我们在过去多个企业项目中使用过 thelia/customer-family-module 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 thelia/customer-family-module 我们能提供哪些服务?
定制开发 / 二次开发

基于 thelia/customer-family-module 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: LGPL-3.0
  • 更新时间: 2015-02-27