You are here

public function TMGMTTestSourcePluginController::saveTranslation in Translation Management Tool 7

Saves a translation.

Parameters

TMGMTJobItem $job_item: The job item entity.

Return value

boolean TRUE if the translation was saved successfully, FALSE otherwise.

Overrides TMGMTSourcePluginControllerInterface::saveTranslation

File

tests/tmgmt_test.plugin.source.inc, line 87
Contains the test source plugin.

Class

TMGMTTestSourcePluginController
@file Contains the test source plugin.

Code

public function saveTranslation(TMGMTJobItem $job_item) {

  // Set a variable that can be checked later for a given job item.
  variable_set('tmgmt_test_saved_translation_' . $job_item->item_type . '_' . $job_item->item_id, TRUE);
  $job_item
    ->accepted();
}