You are here

function globallink_menu_get_sent_rows_by_mlid in GlobalLink Connect for Drupal 7.5

Same name and namespace in other branches
  1. 7.7 globallink_menu/globallink_menu.inc \globallink_menu_get_sent_rows_by_mlid()
  2. 7.6 globallink_menu/globallink_menu.inc \globallink_menu_get_sent_rows_by_mlid()

Gets active menu submission rows by menu ID.

Parameters

string $mlid: The menu ID.

Return value

Associative array of menu active submission rows. FALSE if the array is empty.

2 calls to globallink_menu_get_sent_rows_by_mlid()
globallink_menu_dashboard_form_validate in globallink_menu/globallink_menu_send.inc
Validates menu form input.
globallink_menu_send_for_translations in globallink_menu/globallink_menu.inc
Sends menus for translation.

File

globallink_menu/globallink_menu.inc, line 813

Code

function globallink_menu_get_sent_rows_by_mlid($mlid) {
  $result = db_select('globallink_core_menu', 'tc')
    ->fields('tc')
    ->condition('object_id', $mlid, '=')
    ->condition('status', array(
    'Sent for Translations',
    'Error',
  ), 'IN')
    ->execute();
  $rows = array();
  foreach ($result as $row) {
    $rows[] = $row;
  }
  return $rows;
}