function revisioning_revision_states in Revisioning 7
Same name and namespace in other branches
- 8 revisioning_api.inc \revisioning_revision_states()
- 6.3 revisioning_api.inc \revisioning_revision_states()
Return a single or all possible revision state names.
Parameters
int $state: (optional) state id, as defined in revisioning_api.inc
Return value
array|string if $state is provided, state name. Otherwise, an array keyed by state id.
5 calls to revisioning_revision_states()
- revisioning_condition_revision_is_label in ./
revisioning.rules.inc - Label callback for "revisioning_revision_is" condition.
- revisioning_handler_field_revision_state::render in views/
revisioning_handler_field_revision_state.inc - Render the data.
- revisioning_handler_filter_node_state::get_value_options in views/
revisioning_handler_filter_node_state.inc - Get value options.
- revisioning_handler_filter_revision_state::get_value_options in views/
revisioning_handler_filter_revision_state.inc - Get value options.
- revisioning_revision_states_all in ./
revisioning.rules.inc - Wrapper function to always return all revisioning states.
File
- ./
revisioning_api.inc, line 212 - API functions of Revisioning module
Code
function revisioning_revision_states($state = NULL) {
$states = array(
REVISION_ARCHIVED => t('Archived'),
REVISION_CURRENT => t('Current, published'),
REVISION_PENDING => t('Pending'),
);
return $state === NULL ? $states : $states[$state];
}