diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2011-10-07 18:01:16 -0300 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2011-10-07 18:01:16 -0300 |
commit | 1ead83e432413da9f0828c19a427ad586d5a23b6 (patch) | |
tree | b0b45ae44de2b0cb69f0a587ce9176dd78bd0f3b | |
parent | af9f953bd66ebf3c276a13ff0259519301e2959a (diff) | |
download | muamba-1ead83e432413da9f0828c19a427ad586d5a23b6.tar.gz muamba-1ead83e432413da9f0828c19a427ad586d5a23b6.tar.bz2 |
Cleanup
-rw-r--r-- | muamba.handlers.inc | 21 | ||||
-rw-r--r-- | muamba.module | 4 | ||||
-rw-r--r-- | muamba.views.inc | 4 |
3 files changed, 4 insertions, 25 deletions
diff --git a/muamba.handlers.inc b/muamba.handlers.inc index 28f5753..16c1f38 100644 --- a/muamba.handlers.inc +++ b/muamba.handlers.inc @@ -30,24 +30,3 @@ class views_handler_filter_muamba_status extends views_handler_filter_in_operato } } } - -/** - * Active transactions. - * - * @todo - */ -class views_handler_field_muamba_active extends views_handler_field_boolean { - /** - * Override parent::query() and don't alter query. - */ - function query() { - $this->field_alias = 'muamba_active_'. $this->position; - } - - /** - * Renders the field. - */ - function render($values) { - parent::render($values); - } -} diff --git a/muamba.module b/muamba.module index 1d72289..6342f49 100644 --- a/muamba.module +++ b/muamba.module @@ -285,8 +285,8 @@ function muamba_views_api() { function muamba_node_update($node) { if ($node->type == MUAMBA_NODE_TYPE) { db_update('muamba') - ->fields(array('owner' => $node->uid) - ->condition('nid', $node->nid) + ->fields(array('owner' => $node->uid)) + ->condition('nid', $node->nid, '=') ->execute(); } } diff --git a/muamba.views.inc b/muamba.views.inc index 409498a..584fbe7 100644 --- a/muamba.views.inc +++ b/muamba.views.inc @@ -111,11 +111,11 @@ function muamba_views_data() { 'title' => t('Active'), 'help' => t('Active or inactive transactions'), 'field' => array( - 'handler' => 'views_handler_field_muamba_active', + 'handler' => 'views_handler_field_boolean', 'click sortable' => TRUE, ), 'filter' => array( - 'handler' => 'views_handler_filter_muamba_active', + 'handler' => 'views_handler_filter_boolean_operator', ), 'sort' => array( 'handler' => 'views_handler_sort', |