You are here

function workflow_get_other_states_by_sid in Workflow 7

Same name and namespace in other branches
  1. 7.2 workflow.deprecated.inc \workflow_get_other_states_by_sid()

Given a sid, return all other states in that workflow.

@deprecated: replaced by WorkflowState::getStates($sid)

File

./workflow.deprecated.inc, line 182
Contains contains per-class functions, that are deprecated. Usage: The new code can be tested, by removing this file-include from workflow.module.

Code

function workflow_get_other_states_by_sid($sid) {
  $query = "SELECT sid, state " . "FROM {workflow_states} " . "WHERE wid = (SELECT wid FROM {workflow_states} WHERE sid = :sid AND status = 1 AND sysid = 0) ";
  return db_query($query, array(
    ':sid' => $sid,
  ))
    ->fetchAllKeyed();
}