summaryrefslogtreecommitdiff
path: root/modules/taxonomy
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2007-07-01 17:41:16 +0000
committerDries Buytaert <dries@buytaert.net>2007-07-01 17:41:16 +0000
commite59852d336467e7269853724a28d80bc070bcbf6 (patch)
tree5be53c3b52d923476e8be517f15251f1487efa9c /modules/taxonomy
parentc11cb4ec24479e801076c094f043f2084b344d0c (diff)
downloadbrdo-e59852d336467e7269853724a28d80bc070bcbf6.tar.gz
brdo-e59852d336467e7269853724a28d80bc070bcbf6.tar.bz2
- Rollback of patch #147723: delete API. Talked to Steven and Gabor and we
unanimously agreed to rollback the deletion API. We all support the features this patch added, yet not its actual design and implementation. After some talk, we decided that it would be better for Drupal -- in the long term -- not to go with a solution that isn't 100%. We also recognize that in the short term, this patch would have been useful addition. So let's figure out how we can implement this properly in D7.
Diffstat (limited to 'modules/taxonomy')
-rw-r--r--modules/taxonomy/taxonomy.module18
1 files changed, 8 insertions, 10 deletions
diff --git a/modules/taxonomy/taxonomy.module b/modules/taxonomy/taxonomy.module
index 71fc80bef..03c164b47 100644
--- a/modules/taxonomy/taxonomy.module
+++ b/modules/taxonomy/taxonomy.module
@@ -384,14 +384,13 @@ function taxonomy_vocabulary_confirm_delete(&$form_state, $vid) {
$form['type'] = array('#type' => 'value', '#value' => 'vocabulary');
$form['vid'] = array('#type' => 'value', '#value' => $vid);
$form['name'] = array('#type' => 'value', '#value' => $vocabulary->name);
-
- $options = array('description' => t('Deleting a vocabulary will delete all the terms in it. This action cannot be undone.'));
-
return confirm_form($form,
t('Are you sure you want to delete the vocabulary %title?',
array('%title' => $vocabulary->name)),
'admin/content/taxonomy',
- $options);
+ t('Deleting a vocabulary will delete all the terms in it. This action cannot be undone.'),
+ t('Delete'),
+ t('Cancel'));
}
function taxonomy_vocabulary_confirm_delete_submit($form, &$form_state) {
@@ -621,14 +620,13 @@ function taxonomy_term_confirm_delete(&$form_state, $tid) {
$form['type'] = array('#type' => 'value', '#value' => 'term');
$form['name'] = array('#type' => 'value', '#value' => $term->name);
$form['tid'] = array('#type' => 'value', '#value' => $tid);
-
- $options = array('description' => t('Deleting a term will delete all its children if there are any. This action cannot be undone.'));
-
return confirm_form($form,
t('Are you sure you want to delete the term %title?',
array('%title' => $term->name)),
'admin/content/taxonomy',
- $options);
+ t('Deleting a term will delete all its children if there are any. This action cannot be undone.'),
+ t('Delete'),
+ t('Cancel'));
}
function taxonomy_term_confirm_delete_submit($form, &$form_state) {
@@ -878,14 +876,14 @@ function taxonomy_node_save($node, $terms) {
* Remove associations of a node to its terms.
*/
function taxonomy_node_delete($node) {
- drupal_delete_add_query('DELETE FROM {term_node} WHERE nid = %d', $node->nid);
+ db_query('DELETE FROM {term_node} WHERE nid = %d', $node->nid);
}
/**
* Remove associations of a node to its terms.
*/
function taxonomy_node_delete_revision($node) {
- drupal_delete_add_query('DELETE FROM {term_node} WHERE vid = %d', $node->vid);
+ db_query('DELETE FROM {term_node} WHERE vid = %d', $node->vid);
}
/**