Version Description
(2018-11-2) =
- Fixed bug where automatic downloads only show up as interim
Download this release
Release Info
Developer | ipoulsen |
Plugin | Lingotek Translation |
Version | 1.4.0 |
Comparing to | |
See all releases |
Code changes from version 1.3.9 to 1.4.0
- admin/custom-fields-table.php +0 -0
- admin/manage/view-custom-fields.php +0 -0
- include/group-post.php +3 -4
- lingotek.php +2 -2
- readme.txt +5 -2
admin/custom-fields-table.php
CHANGED
File without changes
|
admin/manage/view-custom-fields.php
CHANGED
File without changes
|
include/group-post.php
CHANGED
@@ -291,13 +291,13 @@ class Lingotek_Group_Post extends Lingotek_Group {
|
|
291 |
// Removes content sanitization so YouTube videos, links, etc don't get removed when inserting translations
|
292 |
remove_filter('content_save_pre', 'wp_filter_post_kses');
|
293 |
remove_filter('content_filtered_save_pre', 'wp_filter_post_kses');
|
294 |
-
|
295 |
$client = new Lingotek_API();
|
296 |
-
|
297 |
$status = $client->get_translation_status($this->document_id, $locale);
|
|
|
298 |
if ($status === -1) {
|
299 |
return;
|
300 |
}
|
|
|
301 |
$translation = $client->get_translation($this->document_id, $locale, $this->source);
|
302 |
if (!$translation || $this->translation_not_ready( json_decode($translation, true) )) return; // If the request failed.
|
303 |
$translation = json_decode($translation, true); // wp_insert_post expects array
|
@@ -336,7 +336,6 @@ class Lingotek_Group_Post extends Lingotek_Group {
|
|
336 |
|
337 |
// create new translation
|
338 |
else if (($this->translations[$locale] == 'ready' || $this->translations[$locale] == 'pending') || $automatic) {
|
339 |
-
$starting_status = $this->translations[$locale];
|
340 |
$content_type_options = get_option('lingotek_content_type');
|
341 |
if (!isset($content_type_options[$post->post_type]['fields']['post_name'])) {
|
342 |
unset($post->post_name); // forces the creation of a new default slug if not translated by Lingotek
|
@@ -360,7 +359,7 @@ class Lingotek_Group_Post extends Lingotek_Group {
|
|
360 |
$tr_lang = $this->pllm->get_language($locale);
|
361 |
PLL()->model->post->set_language($tr_id, $tr_lang);
|
362 |
$this->safe_translation_status_update($locale, 'current', array($tr_lang->slug => $tr_id));
|
363 |
-
if ($
|
364 |
$this->safe_translation_status_update($locale, 'interim');
|
365 |
}
|
366 |
wp_set_object_terms($tr_id, $this->term_id, 'post_translations');
|
291 |
// Removes content sanitization so YouTube videos, links, etc don't get removed when inserting translations
|
292 |
remove_filter('content_save_pre', 'wp_filter_post_kses');
|
293 |
remove_filter('content_filtered_save_pre', 'wp_filter_post_kses');
|
|
|
294 |
$client = new Lingotek_API();
|
|
|
295 |
$status = $client->get_translation_status($this->document_id, $locale);
|
296 |
+
|
297 |
if ($status === -1) {
|
298 |
return;
|
299 |
}
|
300 |
+
|
301 |
$translation = $client->get_translation($this->document_id, $locale, $this->source);
|
302 |
if (!$translation || $this->translation_not_ready( json_decode($translation, true) )) return; // If the request failed.
|
303 |
$translation = json_decode($translation, true); // wp_insert_post expects array
|
336 |
|
337 |
// create new translation
|
338 |
else if (($this->translations[$locale] == 'ready' || $this->translations[$locale] == 'pending') || $automatic) {
|
|
|
339 |
$content_type_options = get_option('lingotek_content_type');
|
340 |
if (!isset($content_type_options[$post->post_type]['fields']['post_name'])) {
|
341 |
unset($post->post_name); // forces the creation of a new default slug if not translated by Lingotek
|
359 |
$tr_lang = $this->pllm->get_language($locale);
|
360 |
PLL()->model->post->set_language($tr_id, $tr_lang);
|
361 |
$this->safe_translation_status_update($locale, 'current', array($tr_lang->slug => $tr_id));
|
362 |
+
if ($status !== 100) {
|
363 |
$this->safe_translation_status_update($locale, 'interim');
|
364 |
}
|
365 |
wp_set_object_terms($tr_id, $this->term_id, 'post_translations');
|
lingotek.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
/**
|
3 |
Plugin name: Lingotek Translation
|
4 |
Plugin URI: http://lingotek.com/wordpress#utm_source=wpadmin&utm_medium=plugin&utm_campaign=wplingotektranslationplugin
|
5 |
-
Version: 1.
|
6 |
Author: Lingotek and Frédéric Demarle
|
7 |
Author uri: http://lingotek.com
|
8 |
Description: Lingotek offers convenient cloud-based localization and translation.
|
@@ -16,7 +16,7 @@ if ( ! function_exists( 'add_action' ) ) {
|
|
16 |
exit();
|
17 |
}
|
18 |
|
19 |
-
define( 'LINGOTEK_VERSION', '1.
|
20 |
define( 'LINGOTEK_MIN_PLL_VERSION', '1.8' );
|
21 |
define( 'LINGOTEK_BASENAME', plugin_basename( __FILE__ ) ); // plugin name as known by WP.
|
22 |
define( 'LINGOTEK_PLUGIN_SLUG', 'lingotek-translation' );// plugin slug (should match above meta: Text Domain).
|
2 |
/**
|
3 |
Plugin name: Lingotek Translation
|
4 |
Plugin URI: http://lingotek.com/wordpress#utm_source=wpadmin&utm_medium=plugin&utm_campaign=wplingotektranslationplugin
|
5 |
+
Version: 1.4.0
|
6 |
Author: Lingotek and Frédéric Demarle
|
7 |
Author uri: http://lingotek.com
|
8 |
Description: Lingotek offers convenient cloud-based localization and translation.
|
16 |
exit();
|
17 |
}
|
18 |
|
19 |
+
define( 'LINGOTEK_VERSION', '1.4.0' ); // plugin version (should match above meta).
|
20 |
define( 'LINGOTEK_MIN_PLL_VERSION', '1.8' );
|
21 |
define( 'LINGOTEK_BASENAME', plugin_basename( __FILE__ ) ); // plugin name as known by WP.
|
22 |
define( 'LINGOTEK_PLUGIN_SLUG', 'lingotek-translation' );// plugin slug (should match above meta: Text Domain).
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Donate link: http://lingotek.com/
|
|
4 |
Tags: automation, bilingual, international, language, Lingotek, localization, multilanguage, multilingual, translate, translation
|
5 |
Requires at least: 3.8
|
6 |
Tested up to: 4.9
|
7 |
-
Stable tag: 1.
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
@@ -123,12 +123,15 @@ For more, visit the [Lingotek documentation site](https://lingotek.atlassian.net
|
|
123 |
|
124 |
== Changelog ==
|
125 |
|
|
|
|
|
|
|
|
|
126 |
= 1.3.9 (2018-11-2) =
|
127 |
|
128 |
* Added bulk custom fields change
|
129 |
* Fixed other minor bugs
|
130 |
|
131 |
-
|
132 |
= 1.3.8 (2018-7-11) =
|
133 |
|
134 |
* Added document metadata fields to translation profiles
|
4 |
Tags: automation, bilingual, international, language, Lingotek, localization, multilanguage, multilingual, translate, translation
|
5 |
Requires at least: 3.8
|
6 |
Tested up to: 4.9
|
7 |
+
Stable tag: 1.4.0
|
8 |
License: GPLv2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
123 |
|
124 |
== Changelog ==
|
125 |
|
126 |
+
= 1.4.0 (2018-11-2) =
|
127 |
+
|
128 |
+
* Fixed bug where automatic downloads only show up as interim
|
129 |
+
|
130 |
= 1.3.9 (2018-11-2) =
|
131 |
|
132 |
* Added bulk custom fields change
|
133 |
* Fixed other minor bugs
|
134 |
|
|
|
135 |
= 1.3.8 (2018-7-11) =
|
136 |
|
137 |
* Added document metadata fields to translation profiles
|