You are here

function workflow_actions_save in Workflow 5

1 call to workflow_actions_save()
workflow_actions_form_submit in ./workflow.module

File

./workflow.module, line 1750

Code

function workflow_actions_save($tid, $aid) {
  actions_register($aid, 'workflow', $tid);
  $data = db_fetch_object(db_query("SELECT tid FROM {workflow_actions} WHERE tid = %d AND aid = '%s'", $tid, $aid));
  if ($data) {
    return;
  }
  db_query("INSERT INTO {workflow_actions} (tid, aid, weight) VALUES (%d, '%s', %d)", $tid, $aid, 0);
}