PHPackages                             agriya/webshoptaxation - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. agriya/webshoptaxation

ActiveLibrary

agriya/webshoptaxation
======================

69PHP

Since May 21Pushed 11y ago8 watchersCompare

[ Source](https://github.com/agriya/webshoptaxation)[ Packagist](https://packagist.org/packages/agriya/webshoptaxation)[ RSS](/packages/agriya-webshoptaxation/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependenciesVersions (1)Used By (0)

WebshopTaxation
===============

[](#webshoptaxation)

This package is to manage the taxation fee for the countries and product in the site. You can manage taxatopm fees easily by calling some easy function Instatllation
=============

[](#instatllation)

1. Install the package by add the following line in composer.json of your root directory

    "require": { ... ... "agriya/webshoptaxation": "dev"

    },

    And then run "composer update"

2, After the package loaded add this line to app/conifg/app.php in the 'providers' array as like follows

```
'providers' => array(
	...
	...
	'Agriya\Webshoptaxation\WebshoptaxationServiceProvider',
}

```

3. After that run the following migrations commands from your root directory to create the tables in ur database. This will create you two tables

    For published package php artisan migrate --package=Agriya/Webshoptaxation

    For workbench package php artisan migrate --bench=Agriya/Webshoptaxation

    Note: run these commands needs to be run from your root directory (where the composer.json has placed)

Thats it of installation. :)

Usage
=====

[](#usage)

---

### Shipments list

[](#shipments-list)

Webshoptaxation::Taxations()-&gt;getTaxations(\[array $array, string $return\_type\]); Parameters
----------

[](#parameters)

$array(required) Array can have either 'id' or 'user\_id' as element. If 'id' is passed, then the specific taxatiion detail will be returned. If 'user\_id' is passed, then all taxatiion details of the specified user will be returned.

$return(optional) This can be either 'list' or 'all'. (default is 'list')

```
				'list'	This will return the result as "id" and "tax name" combination
				'firs'	This will return first result with all fields from taxations table
				'all' 	This will return all the fields from taxations table for the given condition

```

Example
-------

[](#example)

```
Webshoptaxation::Taxations()->getTaxations(array('user_id'=>1), 'all');

	This will return all taxations details of the user id 1 from taxations table

Webshoptaxation::Taxations()->getTaxations(array('user_id'=>1), 'list');

	This will return the list ('id' => 'tax_name') combination for all taxations details for the user id 1 from taxations table

Webshoptaxation::Taxations()->getTaxations(array('id'=>10), 'first');

	This will return single taxations details for the id 10 from taxations table

```

### Add Taxation Details

[](#add-taxation-details)

```
	$inputs = array(
		'user_id' 	=> 1,
		'tax_name' 	=> 'VAT',
		'tax_description' 	=> 'Value added tax',
		'tax_fee' 	=> '14.5',
		'fee_type'	=> 'percentage',
	);
	$taxatonid = Webshoptaxation::Taxations()->addTaxation($inputs);

```

### Update Taxation Details

[](#update-taxation-details)

```
	$inputs = array(
		'tax_name' 	=> 'VAT',
		'tax_description' 	=> 'Value Added Tax',
		'tax_fee' 	=> '10',
		'fee_type'	=> 'flat',
	);

	$taxatonid = Webshoptaxation::Taxations()->updateTaxation(1, $inputs);

```

### Delete Taxation Details

[](#delete-taxation-details)

```
	$taxatonid = Webshoptaxation::Taxations()->deleteTaxation(1);

```

Product Taxation Fees
=====================

[](#product-taxation-fees)

### Get Product Taxation Fees List

[](#get-product-taxation-fees-list-)

 $inputs = array( 'product\_id' =&gt; $product\_id, ); $producttaxatonslist = Webshoptaxation::ProductTaxations()-&gt;getProductTaxations($inputs); ### Add Product Taxation Fees List

[](#add-product-taxation-fees-list-)

 $inputs = array( 'taxation\_id' =&gt; 2, 'product\_id' =&gt; 1, 'tax\_fee' =&gt; '14.5', 'fee\_type' =&gt; 'percentage', ); $producttaxatonid = Webshoptaxation::ProductTaxations()-&gt;addProductTaxation($inputs); ### Update Product Taxation Fees List

[](#update-product-taxation-fees-list-)

```
	Update based on id
	-------------------
			$inputs = array(
				'tax_fee' 	=> '5',
				'fee_type'	=> 'flat',
			);

			$taxatonid = Webshoptaxation::ProductTaxations()->updateProductTaxation(1, $inputs);

	Update based on conditions
	--------------------------
			$inputs = array(
				'tax_fee' 	=> '5',
				'fee_type'	=> 'flat',
			);

			$conditions = array(
				'product_id' => 1,
				'taxation_id' => 2
			);

			$taxatonid = Webshoptaxation::ProductTaxations()->updateProductTaxation(null, $inputs, $conditions);

```

### Delete Product Taxation Fees List

[](#delete-product-taxation-fees-list-)

```
	Delete based on id
	-------------------
			$inputs = array(
				'tax_fee' 	=> '5',
				'fee_type'	=> 'flat',
			);

			$taxatonid = Webshoptaxation::ProductTaxations()->deleteProductTaxation(1);

	Delete based on conditions
	--------------------------
			$inputs = array(
				'tax_fee' 	=> '5',
				'fee_type'	=> 'flat',
			);

			$conditions = array(
				'product_id' => 1,
				'taxation_id' => 2
			);
			$taxatonid = Webshoptaxation::ProductTaxations()->deleteProductTaxation(null, $conditions);

```

###  Health Score

22

—

LowBetter than 22% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/2284930604d5f857ed064491674b1f56e6c0eaed1b00d00b54f8f35a791a7974?d=identicon)[agriya](/maintainers/agriya)

---

Top Contributors

[![rsensan](https://avatars.githubusercontent.com/u/351331?v=4)](https://github.com/rsensan "rsensan (1 commits)")

### Embed Badge

![Health badge](/badges/agriya-webshoptaxation/health.svg)

```
[![Health](https://phpackages.com/badges/agriya-webshoptaxation/health.svg)](https://phpackages.com/packages/agriya-webshoptaxation)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
