Skip to content

Commit

Permalink
chore(import-product): disable import product with callback
Browse files Browse the repository at this point in the history
  • Loading branch information
matheusgnreis authored Feb 29, 2024
1 parent 35da2b5 commit 24d1eb1
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 10 deletions.
9 changes: 0 additions & 9 deletions functions/ecom.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -209,15 +209,6 @@ const app = {
},
hide: true
},
import_all_products: {
schema: {
type: 'boolean',
default: false,
title: 'Importar todos produtos',
description: 'Importar produto ao enviar pelo tiny'
},
hide: true
},
update_price: {
schema: {
type: 'boolean',
Expand Down
2 changes: 1 addition & 1 deletion functions/lib/integration/import-product.js
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ module.exports = ({ appSdk, storeId, auth }, tinyToken, queueEntry, appData, can
if (productId) {
method = 'PATCH'
endpoint = `/products/${productId}.json`
} else if (tipo === 'produto' || appData.import_all_products) {
} else if (tipo === 'produto') {
method = 'POST'
endpoint = '/products.json'
} else {
Expand Down

0 comments on commit 24d1eb1

Please sign in to comment.