feat(dashboard, js-sdk, medusa, tax, types): custom tax providers (#12297)
* wip: setup loaders, add endpoints, module work, types, js sdk * fix: tax module provider loader * feat: select provider on region create, fix enpoint middleware registration * feat: edit form * fix: rename param * chore: changeset * fix: don't default to system provider * fix: admin fixes, dispalt tax provider * fix: some tests and types * fix: remove provider from province regions in test * fix: more tests, optional provider for sublevel regions, fix few types * fix: OE test * feat: edit tax region admin, update tax region core flow changes * feat: migrate script * fix: refactor * chore: use query graph * feat: provider section
This commit is contained in:
@@ -26,10 +26,12 @@ export const setupTaxStructure = async (service: ITaxModuleService) => {
|
||||
const [us, dk, de, ca] = await service.createTaxRegions([
|
||||
{
|
||||
country_code: "US",
|
||||
provider_id: "tp_system_system",
|
||||
default_tax_rate: { name: "US Default Rate", rate: 2, code: "US_DEF" },
|
||||
},
|
||||
{
|
||||
country_code: "DK",
|
||||
provider_id: "tp_system_system",
|
||||
default_tax_rate: {
|
||||
name: "Denmark Default Rate",
|
||||
rate: 25,
|
||||
@@ -38,6 +40,7 @@ export const setupTaxStructure = async (service: ITaxModuleService) => {
|
||||
},
|
||||
{
|
||||
country_code: "DE",
|
||||
provider_id: "tp_system_system",
|
||||
default_tax_rate: {
|
||||
code: "DE19",
|
||||
name: "Germany Default Rate",
|
||||
@@ -46,6 +49,7 @@ export const setupTaxStructure = async (service: ITaxModuleService) => {
|
||||
},
|
||||
{
|
||||
country_code: "CA",
|
||||
provider_id: "tp_system_system",
|
||||
default_tax_rate: {
|
||||
name: "Canada Default Rate",
|
||||
rate: 5,
|
||||
|
||||
Reference in New Issue
Block a user