public function Job::cloneAsUnprocessed in Translation Management Tool 8
Clones job as unprocessed.
Overrides JobInterface::cloneAsUnprocessed
File
- src/
Entity/ Job.php, line 250
Class
- Job
- Entity class for the tmgmt_job entity.
Namespace
Drupal\tmgmt\EntityCode
public function cloneAsUnprocessed() {
$clone = $this
->createDuplicate();
$clone->uid->value = 0;
$clone->reference->value = '';
$clone->created->value = \Drupal::time()
->getRequestTime();
$clone->state->value = Job::STATE_UNPROCESSED;
return $clone;
}