idplein/twinfield-booking 问题修复 & 功能扩展

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

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

idplein/twinfield-booking

Composer 安装命令:

composer require idplein/twinfield-booking

包简介

Package to book invoices to twinfield

README 文档

README

Installation

First add the repository to your composer.json, so composer can find this package.

"repositories": [
    {
        "type": "vcs",
        "url": "ssh://git@gitlab.qlic.nl/packages/twinfield-booking.git"
    }
],

Then add the package as a dependency.

composer require qlic/twinfield-booking

In case you are running Laravel < 5.5 Add the following provider to your service providers (in config/app.php)

Qlic\Twinfield\Booking\Providers\TwinfieldBookingServiceProvider::class,

In case you need to tweak things, you can publish the config file.

php artisan vendor:publish --provider="Qlic\Twinfield\Booking\Providers\TwinfieldBookingServiceProvider"

Usage

Typehint InvoiceBookerContract and use it's methods.

Example:

<?php

use Qlic\Twinfield\Booking\Contracts\InvoiceBookerContract;
use Qlic\Twinfield\Booking\Contracts\InvoiceContract;
// use your Invoice class here

class ABC
{
    private $invoiceBooker;

    public function __construct(InvoiceBookerContract $invoiceBooker)
    {
        $this->invoiceBooker = $invoiceBooker;
    }

    public function random(Invoice $invoice)
    {
        $this->invoiceBooker->createTransaction(new InvoiceWrapper($invoice));
    }
}

// Write a wrapper implementing the invoice contract
class InvoiceWrapper implements InvoiceContract
{
    private $invoice;

    public function __construct(Invoice $invoice)
    {
        $this->invoice = $invoice;
    }

    // Implement all methods here
}

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: Unknown
  • 更新时间: 2023-06-22