nextgen-tech/gs1-decoder 问题修复 & 功能扩展

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

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

nextgen-tech/gs1-decoder

Composer 安装命令:

composer require nextgen-tech/gs1-decoder

包简介

README 文档

README

Basic GS1-128 (EAN128) decoder in PHP.

Installation

composer require nextgen-tech/gs1-decoder

Run Tests

# run PHPUnit tests
vendor/bin/phpunit

# run PHPStan analyse
vendor/bin/phpstan analyse

To run all tests automatically on several platforms you can use act, which mimics GitHub Actions locally:

$ act -P ubuntu-latest=shivammathur/node:latest

Usage

use NGT\Barcode\GS1Decoder\Decoder;

$decoder = new Decoder($delimiter = '[FNC1]');
$barcode = $decoder->decode('0195012345678903422616[FNC1]3103000123');

print_r($barcode->toArray());
Array
(
    [value] => 0195012345678903422616[FNC1]3103000123
    [delimiter] => [FNC1]
    [identifiers] => Array
        (
            [01] => Array
                (
                    [code] => 01
                    [title] => GTIN
                    [name] => Global Trade Item Number
                    [length] => 14
                    [content] => 95012345678903
                    [raw_content] => 95012345678903
                )

            [422] => Array
                (
                    [code] => 422
                    [title] => ORIGIN
                    [name] => Country of origin of a trade item
                    [length] => 3
                    [content] => 616
                    [raw_content] => 616
                )

            [310] => Array
                (
                    [code] => 310
                    [title] => NET WEIGHT (kg)
                    [name] => Net weight, kilograms
                    [length] => 6
                    [content] => 0.123
                    [raw_content] => 000123
                    [decimals] => 3
                )

        )

)

List of implemented identifiers

Identifier Title Description
00 SSCC Serial Shipping Container Code
01 GTIN Global Trade Item Number (GTIN)
02 CONTENT GTIN of contained trade items
10 BATCH/LOT Batch or lot number
11 PROD DATE Production date
12 DUE DATE Due date
13 PACK DATE Packaging date
15 BEST BEFORE Best before date
16 SELL BY Sell by date
17 USE BY Expiration date
20 VARIANT Internal product variant
21 SERIAL Serial number
91 INTERNAL Company internal information
422 ORIGIN Country of origin of a trade item
3100-3105 NET WEIGHT (kg) Net weight, kilograms
3920-3929 PRICE Applicable amount payable, single monetary area (variable measure trade item)
8005 PRICE PER UNIT Price per unit of measure
8008 PROD TIME Date and time of production

The list of all GS1 Application Identifiers can be found here

nextgen-tech/gs1-decoder 适用场景与选型建议

nextgen-tech/gs1-decoder 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 29.61k 次下载、GitHub Stars 达 10, 最近一次更新时间为 2020 年 10 月 27 日, 在 PHP 生态内属于活跃度较高的组件。

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

围绕 nextgen-tech/gs1-decoder 我们能提供哪些服务?
定制开发 / 二次开发

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

BUG 修复 & 性能优化

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

项目外包 & 长期维护

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

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

统计信息

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

GitHub 信息

  • Stars: 10
  • Watchers: 1
  • Forks: 5
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-10-27