You are here

function amazon_item_delete in Amazon Product Advertisement API 7

Same name and namespace in other branches
  1. 6 amazon.module \amazon_item_delete()
  2. 7.2 amazon.module \amazon_item_delete()

Delete all vestiges of Amazon item.

Parameters

$asin: ASIN to be deleted.

Return value

No return.

2 calls to amazon_item_delete()
amazon_item_insert in ./amazon.module
Insert 'cleaned' amazon item into database.
amazon_test_form_submit in ./amazon.admin.inc

File

./amazon.module, line 728

Code

function amazon_item_delete($asin) {
  module_invoke_all('amazon_item_delete', $asin);
  db_delete('amazon_item')
    ->condition('asin', $asin)
    ->execute();
  db_delete('amazon_item_participant')
    ->condition('asin', $asin)
    ->execute();
  db_delete('amazon_item_image')
    ->condition('asin', $asin)
    ->execute();
  db_delete('amazon_item_editorial_review')
    ->condition('asin', $asin)
    ->execute();
}