You are here

sms_user_handler_field_status.inc in SMS Framework 7

Same filename and directory in other branches
  1. 6.2 modules/sms_user/includes/sms_user_handler_field_status.inc

Views handler to display the sms number status.

File

modules/sms_user/includes/sms_user_handler_field_status.inc
View source
<?php

/**
 * @file
 * Views handler to display the sms number status.
 */

/**
 * Field handler to show the sms number status.
 *
 * @ingroup views_field_handlers
 */
class sms_user_handler_field_status extends views_handler_field {

  /**
   * {@inheritdoc}
   */
  function render($values) {
    $status = @$values->{$this->field_alias};
    switch ($status) {
      case SMS_USER_PENDING:
        return t('Pending');
      case SMS_USER_CONFIRMED:
        return t('Confirmed');
      default:
        return '';
    }
  }

}

Classes

Namesort descending Description
sms_user_handler_field_status Field handler to show the sms number status.