/[drupal]/contributions/modules/workflow_ng/workflow_ng/workflow_ng_ui.module
ViewVC logotype

Diff of /contributions/modules/workflow_ng/workflow_ng/workflow_ng_ui.module

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph | View Patch Patch

revision 1.1.2.14.2.6, Wed May 7 09:30:15 2008 UTC revision 1.1.2.14.2.7, Thu Feb 19 15:49:35 2009 UTC
# Line 238  function workflow_ng_ui_configuration_ta Line 238  function workflow_ng_ui_configuration_ta
238        }        }
239        $ops[] = l(t('clone'), $path .'/clone', array(), drupal_get_destination());        $ops[] = l(t('clone'), $path .'/clone', array(), drupal_get_destination());
240    
241          // If the event label is missing, the module providing the event is gone and the
242          // rule can't be edited.
243          $event_label = workflow_ng_get_events('labels', $cfg['#event']);
244        $rows[] = array(        $rows[] = array(
245          l($cfg['#label'], $path),          $event_label ? l($cfg['#label'], $path) : check_plain($cfg['#label']),
246          check_plain(workflow_ng_get_events('labels', $cfg['#event'])),          $event_label ? check_plain($event_label) : array('class' => 'error', 'data' => check_plain($cfg['#event'])),
247          check_plain($cfg['#module']),          check_plain($cfg['#module']),
248          workflow_ng_ui_configuration_status($cfg),          workflow_ng_ui_configuration_status($cfg),
249          implode(' ', $ops),          implode(' ', $ops),
250        );        );
251          if (!$event_label) {
252            workflow_ng_handle_error_msg(t("%event can't be found. Probably the providing module has been deactivated.", array('%event' => $cfg['#event'])));
253          }
254      }      }
255    }    }
256    
# Line 713  function workflow_ng_ui_element_configur Line 719  function workflow_ng_ui_element_configur
719      $event = workflow_ng_get_events('all', $form['cfg']['#value']['#event']);      $event = workflow_ng_get_events('all', $form['cfg']['#value']['#event']);
720      _workflow_ng_element_defaults($event);      _workflow_ng_element_defaults($event);
721      //TODO: for d6 remove argument_info      //TODO: for d6 remove argument_info
722      $argument_info = workflow_ng_ui_event_get_argument_info($form['cfg']['#value'], $element);      $argument_info = workflow_ng_ui_event_get_argument_info($form['cfg']['#value'], $element);
723      $info = array('element' => &$element, 'event' => &$event);      $info = array('element' => &$element, 'event' => &$event);
724    
725      $form['configure'] = $function($element['#settings'], $argument_info, $info);      $form['configure'] = $function($element['#settings'], $argument_info, $info);
# Line 811  function workflow_ng_ui_argument_map_for Line 817  function workflow_ng_ui_argument_map_for
817      $argument_info = workflow_ng_ui_event_get_argument_info($form['cfg']['#value'], $element);      $argument_info = workflow_ng_ui_event_get_argument_info($form['cfg']['#value'], $element);
818    
819      foreach ($element['#arguments'] as $name => $info) {      foreach ($element['#arguments'] as $name => $info) {
820    
821        $args = workflow_ng_ui_get_possible_arguments($info, $argument_info);        $args = workflow_ng_ui_get_possible_arguments($info, $argument_info);
822        $form['map'][$name] = array(        $form['map'][$name] = array(
823          '#type' => 'select',          '#type' => 'select',
# Line 1241  function workflow_ng_ui_get_modules($ele Line 1247  function workflow_ng_ui_get_modules($ele
1247   * Gets $argument_info, which contains all available arguments   * Gets $argument_info, which contains all available arguments
1248   * For this we need to get the arguments of the event as well as further arguments that   * For this we need to get the arguments of the event as well as further arguments that
1249   * might be provided by actions of this or preceding configurations   * might be provided by actions of this or preceding configurations
1250   *   *
1251   * @param $cfg The configuration for which to get the argument info   * @param $cfg The configuration for which to get the argument info
1252   * @param $element An optional element, which is currently edited   * @param $element An optional element, which is currently edited
1253   */   */
# Line 1274  function workflow_ng_ui_event_get_argume Line 1280  function workflow_ng_ui_event_get_argume
1280    
1281  /*  /*
1282   * Gets all new arguments defined by actions, which are executed until the given   * Gets all new arguments defined by actions, which are executed until the given
1283   * configuration   * configuration
1284   */   */
1285  function workflow_ng_get_new_arguments(&$elements, &$cfg_name) {  function workflow_ng_get_new_arguments(&$elements, &$cfg_name) {
1286    if (!isset($cfg_name)) {    if (!isset($cfg_name)) {

Legend:
Removed from v.1.1.2.14.2.6  
changed lines
  Added in v.1.1.2.14.2.7

  ViewVC Help
Powered by ViewVC 1.1.2