r24062 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r24061‎ | r24062 | r24063 >
Date:15:20, 13 July 2007
Author:kim
Status:old
Tags:
Comment:
tpyos
Modified paths:
  • /trunk/extensions/Wikidata/OmegaWiki/Controller.php (modified) (history)
  • /trunk/extensions/Wikidata/OmegaWiki/SpecialNeedsTranslation.php (modified) (history)
  • /trunk/extensions/Wikidata/OmegaWiki/SpecialTransaction.php (modified) (history)

Diff [purge]

Index: trunk/extensions/Wikidata/OmegaWiki/SpecialNeedsTranslation.php
@@ -45,7 +45,8 @@
4646
4747 protected function showExpressionsNeedingTranslation($sourceLanguageId, $destinationLanguageId,$collectionId) {
4848 global
49 - $definedMeaningIdAttribute, $expressionIdAttribute, $expressionAttribute, $expressionStructure, $spellingAttribute, $languageAttribute;
 49+ $definedMeaningIdAttribute, $expressionIdAttribute, $expressionAttribute, $expressionStructure, $omegaWikiAttributes;
 50+ $o=$omegaWikiAttributes;
5051
5152 $dc=wdGetDataSetContext();
5253 require_once("Transaction.php");
@@ -87,15 +88,15 @@
8889
8990 while ($row = $dbr->fetchObject($queryResult)) {
9091 $expressionRecord = new ArrayRecord($expressionStructure);
91 - $expressionRecord->setAttributeValue($languageAttribute, $row->source_language_id);
92 - $expressionRecord->setAttributeValue($spellingAttribute, $row->source_spelling);
 92+ $expressionRecord->language = $row->source_language_id;
 93+ $expressionRecord->spelling = $row->source_spelling;
9394
9495 $recordSet->addRecord(array($row->source_defined_meaning_id, $row->source_expression_id, $expressionRecord, getDefinedMeaningDefinition($row->source_defined_meaning_id)));
9596 }
9697
9798 $expressionEditor = new RecordTableCellEditor($expressionAttribute);
98 - $expressionEditor->addEditor(new LanguageEditor($languageAttribute, new SimplePermissionController(false), false));
99 - $expressionEditor->addEditor(new SpellingEditor($spellingAttribute, new SimplePermissionController(false), false));
 99+ $expressionEditor->addEditor(new LanguageEditor($o->language, new SimplePermissionController(false), false));
 100+ $expressionEditor->addEditor(new SpellingEditor($o->spelling, new SimplePermissionController(false), false));
100101
101102 $editor = new RecordSetTableEditor(null, new SimplePermissionController(false), new ShowEditFieldChecker(true), new AllowAddController(false), false, false, null);
102103 $editor->addEditor($expressionEditor);
Index: trunk/extensions/Wikidata/OmegaWiki/Controller.php
@@ -442,7 +442,7 @@
443443 $translatedTextAttribute;
444444
445445 if ($this->filterLanguageId == 0)
446 - $expressionLanguageId = $record->getAttributeValue($expressionAttribute)->languageAttribute;
 446+ $expressionLanguageId = $record->getAttributeValue($expressionAttribute)->language;
447447 else
448448 $expressionLanguageId = $this->filterLanguageId;
449449
Index: trunk/extensions/Wikidata/OmegaWiki/SpecialTransaction.php
@@ -129,8 +129,10 @@
130130 function initializeAttributes() {
131131 global
132132 $operationAttribute, $isLatestAttribute, $definedMeaningIdAttribute, $definedMeaningReferenceAttribute,
133 - $languageAttribute, $textAttribute, $definedMeaningReferenceStructure, $rollBackStructure, $rollBackAttribute;
 133+ $omegaWikiAttributes, $definedMeaningReferenceStructure, $rollBackStructure, $rollBackAttribute;
134134
 135+ $o=$omegaWikiAttributes;
 136+
135137 $operationAttribute = new Attribute('operation', 'Operation', 'text');
136138 $isLatestAttribute = new Attribute('is-latest', 'Is latest', 'boolean');
137139
@@ -143,7 +145,7 @@
144146
145147 $addTransactionIdAttribute = new Attribute('add-transaction-id', 'Add transaction ID', 'identifier');
146148
147 - $translatedContentHistoryStructure = new Structure($addTransactionIdAttribute, $textAttribute, $recordLifeSpanAttribute);
 149+ $translatedContentHistoryStructure = new Structure($addTransactionIdAttribute, $o->text, $recordLifeSpanAttribute);
148150 $translatedContentHistoryKeyStructure = new Structure($addTransactionIdAttribute);
149151 $translatedContentHistoryAttribute = new Attribute('translated-content-history', 'History', $translatedContentHistoryStructure);
150152 $translatedContentIdAttribute = new Attribute('translated-content-id', 'Translated content ID', 'object-id');
@@ -162,8 +164,8 @@
163165 $definedMeaningIdAttribute,
164166 $definedMeaningReferenceAttribute,
165167 $translatedContentIdAttribute,
166 - $languageAttribute,
167 - $textAttribute,
 168+ $o->language,
 169+ $o->text,
168170 $operationAttribute,
169171 $isLatestAttribute
170172 );
@@ -264,14 +266,16 @@
265267 $updatedLinkAttribute = new Attribute('updated-link', 'Link properties', $updatedLinkStructure);
266268
267269 global
268 - $updatedTextAttribute, $updatedTextStructure, $textAttribute;
 270+ $updatedTextAttribute, $updatedTextStructure, $omegaWikiAttributes;
269271
 272+ $o=$omegaWikiAttributes;
 273+
270274 $updatedTextStructure = new Structure(
271275 $rollBackAttribute,
272276 $valueIdAttribute,
273277 $objectIdAttribute,
274278 $attributeAttribute,
275 - $textAttribute,
 279+ $o->text,
276280 $operationAttribute,
277281 $isLatestAttribute
278282 );
@@ -306,8 +310,8 @@
307311 $objectIdAttribute,
308312 $attributeAttribute,
309313 $translatedContentIdAttribute,
310 - $languageAttribute,
311 - $textAttribute,
 314+ $o->language,
 315+ $o->text,
312316 $operationAttribute,
313317 $isLatestAttribute
314318 );
@@ -364,8 +368,8 @@
365369 $definedMeaningReferenceAttribute,
366370 $translatedContentIdAttribute,
367371 $sourceAttribute,
368 - $languageAttribute,
369 - $textAttribute,
 372+ $o->language,
 373+ $o->text,
370374 $operationAttribute,
371375 $isLatestAttribute
372376 );
@@ -499,7 +503,7 @@
500504 function getTranslatedContentHistory($translatedContentId, $languageId, $isLatest) {
501505 global
502506 $translatedContentHistoryStructure, $translatedContentHistoryKeyStructure,
503 - $textAttribute, $addTransactionIdAttribute, $recordLifeSpanAttribute;
 507+ $addTransactionIdAttribute, $recordLifeSpanAttribute;
504508
505509 $dc=wdGetDataSetContext();
506510 $recordSet = new ArrayRecordSet($translatedContentHistoryStructure, $translatedContentHistoryKeyStructure);
@@ -517,7 +521,7 @@
518522
519523 while ($row = $dbr->fetchObject($queryResult)) {
520524 $record = new ArrayRecord($translatedContentHistoryStructure);
521 - $record->setAttributeValue($textAttribute, $row->text_text);
 525+ $record->text = $row->text_text;
522526 $record->setAttributeValue($addTransactionIdAttribute, (int) $row->add_transaction_id);
523527 $record->setAttributeValue($recordLifeSpanAttribute, getRecordLifeSpanTuple((int) $row->add_transaction_id, (int) $row->remove_transaction_id));
524528
@@ -530,10 +534,10 @@
531535
532536 function getUpdatedTextRecord($text, $history) {
533537 global
534 - $updatedTextStructure, $textAttribute, $translatedContentHistoryAttribute;
 538+ $updatedTextStructure, $translatedContentHistoryAttribute;
535539
536540 $result = new ArrayRecord($updatedTextStructure);
537 - $result->setAttributeValue($textAttribute, $text);
 541+ $result->text = $text;
538542 $result->setAttributeValue($translatedContentHistoryAttribute, $history);
539543
540544 return $result;
@@ -542,10 +546,12 @@
543547 function getUpdatedDefinedMeaningDefinitionRecordSet($transactionId) {
544548
545549 global
546 - $languageAttribute, $textAttribute, $definedMeaningIdAttribute,
 550+ $omegaWikiAttributes, $definedMeaningIdAttribute,
547551 $definedMeaningReferenceAttribute, $updatedDefinitionStructure, $translatedContentIdAttribute,
548552 $operationAttribute, $isLatestAttribute, $rollBackTranslatedContentAttribute, $rollBackTranslatedContentStructure;
549553
 554+ $o=$omegaWikiAttributes;
 555+
550556 $dc=wdGetDataSetContext();
551557
552558 $dbr = &wfGetDB(DB_SLAVE);
@@ -560,15 +566,15 @@
561567 " AND " . getAtTransactionRestriction("{$dc}_defined_meaning", $transactionId)
562568 );
563569
564 - $recordSet = new ArrayRecordSet($updatedDefinitionStructure, new Structure($definedMeaningIdAttribute, $languageAttribute));
 570+ $recordSet = new ArrayRecordSet($updatedDefinitionStructure, new Structure($definedMeaningIdAttribute, $o->language));
565571
566572 while ($row = $dbr->fetchObject($queryResult)) {
567573 $record = new ArrayRecord($updatedDefinitionStructure);
568574 $record->setAttributeValue($definedMeaningIdAttribute, $row->defined_meaning_id);
569575 $record->setAttributeValue($definedMeaningReferenceAttribute, getDefinedMeaningReferenceRecord($row->defined_meaning_id));
570576 $record->setAttributeValue($translatedContentIdAttribute, $row->translated_content_id);
571 - $record->setAttributeValue($languageAttribute, $row->language_id);
572 - $record->setAttributeValue($textAttribute, $row->text_text);
 577+ $record->language = $row->language_id;
 578+ $record->text = $row->text_text;
573579 $record->setAttributeValue($operationAttribute, $row->operation);
574580 $record->setAttributeValue($isLatestAttribute, $row->is_latest);
575581 $record->setAttributeValue($rollBackTranslatedContentAttribute, simpleRecord($rollBackTranslatedContentStructure, array($row->is_latest, $row->operation, getTranslatedContentHistory($row->translated_content_id, $row->language_id, $row->is_latest))));
@@ -618,10 +624,12 @@
619625
620626 function getUpdatedAlternativeDefinitionTextRecordSet($transactionId) {
621627 global
622 - $languageAttribute, $textAttribute, $definedMeaningIdAttribute, $sourceAttribute,
 628+ $omegaWikiAttributes, $definedMeaningIdAttribute, $sourceAttribute,
623629 $definedMeaningReferenceAttribute, $updatedAlternativeDefinitionTextStructure, $translatedContentIdAttribute,
624630 $rollBackTranslatedContentStructure, $rollBackTranslatedContentAttribute, $operationAttribute, $isLatestAttribute;
625631
 632+ $o=$omegaWikiAttributes;
 633+
626634 $dc=wdGetDataSetContext();
627635 $dbr = &wfGetDB(DB_SLAVE);
628636 $queryResult = $dbr->query(
@@ -635,7 +643,7 @@
636644 " AND " . getAtTransactionRestriction("{$dc}_alt_meaningtexts", $transactionId)
637645 );
638646
639 - $recordSet = new ArrayRecordSet($updatedAlternativeDefinitionTextStructure, new Structure($translatedContentIdAttribute, $languageAttribute));
 647+ $recordSet = new ArrayRecordSet($updatedAlternativeDefinitionTextStructure, new Structure($translatedContentIdAttribute, $o->language));
640648
641649 while ($row = $dbr->fetchObject($queryResult)) {
642650 $record = new ArrayRecord($updatedAlternativeDefinitionTextStructure);
@@ -643,8 +651,8 @@
644652 $record->setAttributeValue($definedMeaningReferenceAttribute, getDefinedMeaningReferenceRecord($row->meaning_mid));
645653 $record->setAttributeValue($translatedContentIdAttribute, $row->translated_content_id);
646654 $record->setAttributeValue($sourceAttribute, getDefinedMeaningReferenceRecord($row->source_id));
647 - $record->setAttributeValue($languageAttribute, $row->language_id);
648 - $record->setAttributeValue($textAttribute, $row->text_text);
 655+ $record->language = $row->language_id;
 656+ $record->text = $row->text_text;
649657 $record->setAttributeValue($operationAttribute, $row->operation);
650658 $record->setAttributeValue($isLatestAttribute, $row->is_latest);
651659 $record->setAttributeValue($rollBackTranslatedContentAttribute, simpleRecord($rollBackTranslatedContentStructure, array($row->is_latest, $row->operation, getTranslatedContentHistory($row->translated_content_id, $row->language_id, $row->is_latest))));
@@ -654,14 +662,15 @@
655663 return $recordSet;
656664 }
657665
658 -function getUpdatedSyntransesRecordSet($transactionId) {
 666+function getUpdatedSyntransesRecordSet($transactionId, $dc=null) {
659667 global
660668 $updatedSyntransesStructure, $definedMeaningIdAttribute, $definedMeaningReferenceAttribute,
661 - $expressionAttribute, $expressionStructure, $languageAttribute, $spellingAttribute, $syntransIdAttribute,
 669+ $expressionAttribute, $expressionStructure, $omegaWikiAttributes, $syntransIdAttribute,
662670 $expressionIdAttribute, $identicalMeaningAttribute,
663671 $isLatestAttribute, $operationAttribute, $rollBackAttribute, $rollBackStructure;
664672
665 - $dc=wdGetDataSetContext();
 673+ $o=$omegaWikiAttributes;
 674+ $dc=wdGetDataSetContext($dc);
666675
667676 $dbr = &wfGetDB(DB_SLAVE);
668677 $queryResult = $dbr->query(
@@ -678,8 +687,8 @@
679688
680689 while ($row = $dbr->fetchObject($queryResult)) {
681690 $expressionRecord = new ArrayRecord($expressionStructure);
682 - $expressionRecord->setAttributeValue($languageAttribute, $row->language_id);
683 - $expressionRecord->setAttributeValue($spellingAttribute, $row->spelling);
 691+ $expressionRecord->language = $row->language_id;
 692+ $expressionRecord->spelling = $row->spelling;
684693
685694 $record = new ArrayRecord($updatedSyntransesStructure);
686695 $record->setAttributeValue($syntransIdAttribute, $row->syntrans_sid);
@@ -902,7 +911,7 @@
903912
904913 function getUpdatedTextRecordSet($transactionId) {
905914 global
906 - $objectIdAttribute, $valueIdAttribute, $attributeAttribute, $textAttribute,
 915+ $objectIdAttribute, $valueIdAttribute, $attributeAttribute,
907916 $updatedTextStructure,
908917 $operationAttribute, $isLatestAttribute, $rollBackAttribute, $rollBackStructure;
909918
@@ -923,7 +932,7 @@
924933 $record->setAttributeValue($valueIdAttribute, $row->value_id);
925934 $record->setAttributeValue($objectIdAttribute, $row->object_id);
926935 $record->setAttributeValue($attributeAttribute, getDefinedMeaningReferenceRecord($row->attribute_mid));
927 - $record->setAttributeValue($textAttribute, $row->text);
 936+ $record->text= $row->text;
928937 $record->setAttributeValue($operationAttribute, $row->operation);
929938 $record->setAttributeValue($isLatestAttribute, $row->is_latest);
930939 $record->setAttributeValue($rollBackAttribute, simpleRecord($rollBackStructure, array($row->is_latest, $row->operation)));
@@ -974,10 +983,12 @@
975984
976985 function getUpdatedTranslatedTextRecordSet($transactionId) {
977986 global
978 - $languageAttribute, $textAttribute, $objectIdAttribute, $valueIdAttribute, $attributeAttribute,
 987+ $objectAttributeValues, $objectIdAttribute, $valueIdAttribute, $attributeAttribute,
979988 $updatedTranslatedTextStructure, $translatedContentIdAttribute,
980989 $operationAttribute, $isLatestAttribute, $rollBackTranslatedContentAttribute, $rollBackTranslatedContentStructure;
981990
 991+ $o=$omegaWikiAttributes;
 992+
982993 $dc=wdGetDataSetContext();
983994 $dbr = &wfGetDB(DB_SLAVE);
984995 $queryResult = $dbr->query(
@@ -991,7 +1002,7 @@
9921003 " AND " . getAtTransactionRestriction("{$dc}_translated_content_attribute_values", $transactionId)
9931004 );
9941005
995 - $recordSet = new ArrayRecordSet($updatedTranslatedTextStructure, new Structure($valueIdAttribute, $languageAttribute));
 1006+ $recordSet = new ArrayRecordSet($updatedTranslatedTextStructure, new Structure($valueIdAttribute, $o->language));
9961007
9971008 while ($row = $dbr->fetchObject($queryResult)) {
9981009 $record = new ArrayRecord($updatedTranslatedTextStructure);
@@ -999,8 +1010,8 @@
10001011 $record->setAttributeValue($objectIdAttribute, $row->object_id);
10011012 $record->setAttributeValue($attributeAttribute, getDefinedMeaningReferenceRecord($row->attribute_mid));
10021013 $record->setAttributeValue($translatedContentIdAttribute, $row->translated_content_id);
1003 - $record->setAttributeValue($languageAttribute, $row->language_id);
1004 - $record->setAttributeValue($textAttribute, $row->text_text);
 1014+ $record->language = $row->language_id;
 1015+ $record->text = $row->text_text;
10051016 $record->setAttributeValue($operationAttribute, $row->operation);
10061017 $record->setAttributeValue($isLatestAttribute, $row->is_latest);
10071018 $record->setAttributeValue($rollBackTranslatedContentAttribute, simpleRecord($rollBackTranslatedContentStructure, array($row->is_latest, $row->operation, getTranslatedContentHistory($row->translated_content_id, $row->language_id, $row->is_latest))));
@@ -1012,10 +1023,12 @@
10131024
10141025 function getTranslatedContentHistorySelector($attribute) {
10151026 global
1016 - $textAttribute, $recordLifeSpanAttribute;
1017 -
 1027+ $omegaWikiAttributes, $recordLifeSpanAttribute;
 1028+
 1029+ $o=$omegaWikiAttributes;
 1030+
10181031 $result = createSuggestionsTableViewer($attribute);
1019 - $result->addEditor(createLongTextViewer($textAttribute));
 1032+ $result->addEditor(createLongTextViewer($o->text));
10201033 $result->addEditor(createTableLifeSpanEditor($recordLifeSpanAttribute));
10211034
10221035 $result = new RecordSetRecordSelector($result);
@@ -1025,9 +1038,10 @@
10261039
10271040 function getUpdatedDefinedMeaningDefinitionEditor($attribute, $showRollBackOptions) {
10281041 global
1029 - $definedMeaningReferenceAttribute, $languageAttribute, $textAttribute,
 1042+ $definedMeaningReferenceAttribute, $omegaWikiAttributes,
10301043 $operationAttribute, $isLatestAttribute, $rollBackTranslatedContentAttribute, $translatedContentHistoryAttribute;
10311044
 1045+ $o=$omegaWikiAttributes;
10321046 $editor = createTableViewer($attribute);
10331047
10341048 if ($showRollBackOptions) {
@@ -1038,8 +1052,8 @@
10391053 }
10401054
10411055 $editor->addEditor(createDefinedMeaningReferenceViewer($definedMeaningReferenceAttribute));
1042 - $editor->addEditor(createLanguageViewer($languageAttribute));
1043 - $editor->addEditor(createLongTextViewer($textAttribute));
 1056+ $editor->addEditor(createLanguageViewer($o->language));
 1057+ $editor->addEditor(createLongTextViewer($o->text));
10441058 $editor->addEditor(createShortTextViewer($operationAttribute));
10451059 $editor->addEditor(createBooleanViewer($isLatestAttribute));
10461060
@@ -1067,8 +1081,10 @@
10681082
10691083 function getUpdatedAlternativeDefinitionTextEditor($attribute, $showRollBackOptions) {
10701084 global
1071 - $definedMeaningReferenceAttribute, $languageAttribute, $textAttribute, $sourceAttribute,
 1085+ $definedMeaningReferenceAttribute, $omegaWikiAttributes, $sourceAttribute,
10721086 $operationAttribute, $isLatestAttribute, $rollBackTranslatedContentAttribute, $translatedContentHistoryAttribute;
 1087+
 1088+ $o=$omegaWikiAttributes;
10731089
10741090 $editor = createTableViewer($attribute);
10751091
@@ -1080,8 +1096,8 @@
10811097 }
10821098
10831099 $editor->addEditor(createDefinedMeaningReferenceViewer($definedMeaningReferenceAttribute));
1084 - $editor->addEditor(createLanguageViewer($languageAttribute));
1085 - $editor->addEditor(createLongTextViewer($textAttribute));
 1100+ $editor->addEditor(createLanguageViewer($o->language));
 1101+ $editor->addEditor(createLongTextViewer($o->text));
10861102 $editor->addEditor(createDefinedMeaningReferenceViewer($sourceAttribute));
10871103 $editor->addEditor(createShortTextViewer($operationAttribute));
10881104 $editor->addEditor(createBooleanViewer($isLatestAttribute));
@@ -1187,9 +1203,11 @@
11881204
11891205 function getUpdatedTextEditor($attribute, $showRollBackOptions) {
11901206 global
1191 - $objectIdAttribute, $valueIdAttribute, $attributeAttribute, $textAttribute,
 1207+ $objectIdAttribute, $valueIdAttribute, $attributeAttribute, $omegaWikiAttributes,
11921208 $rollBackAttribute, $operationAttribute, $isLatestAttribute;
11931209
 1210+ $o=$omegaWikiAttributes;
 1211+
11941212 $editor = createTableViewer($attribute);
11951213
11961214 if ($showRollBackOptions)
@@ -1197,7 +1215,7 @@
11981216
11991217 $editor->addEditor(new ObjectPathEditor($objectIdAttribute));
12001218 $editor->addEditor(createDefinedMeaningReferenceViewer($attributeAttribute));
1201 - $editor->addEditor(createLongTextViewer($textAttribute));
 1219+ $editor->addEditor(createLongTextViewer($o->text));
12021220 $editor->addEditor(createShortTextViewer($operationAttribute));
12031221 $editor->addEditor(createBooleanViewer($isLatestAttribute));
12041222
@@ -1225,9 +1243,10 @@
12261244
12271245 function getUpdatedTranslatedTextEditor($attribute, $showRollBackOptions) {
12281246 global
1229 - $objectIdAttribute, $valueIdAttribute, $attributeAttribute, $languageAttribute, $textAttribute,
 1247+ $objectIdAttribute, $valueIdAttribute, $attributeAttribute, $omegaWikiAttributes,
12301248 $operationAttribute, $isLatestAttribute, $rollBackTranslatedContentAttribute, $translatedContentHistoryAttribute;
12311249
 1250+ $o=$omegaWikiAttributes;
12321251 $editor = createTableViewer($attribute);
12331252
12341253 if ($showRollBackOptions) {
@@ -1239,8 +1258,8 @@
12401259
12411260 $editor->addEditor(new ObjectPathEditor($objectIdAttribute));
12421261 $editor->addEditor(createDefinedMeaningReferenceViewer($attributeAttribute));
1243 - $editor->addEditor(createLanguageViewer($languageAttribute));
1244 - $editor->addEditor(createLongTextViewer($textAttribute));
 1262+ $editor->addEditor(createLanguageViewer($o->language));
 1263+ $editor->addEditor(createLongTextViewer($o->text));
12451264 $editor->addEditor(createShortTextViewer($operationAttribute));
12461265 $editor->addEditor(createBooleanViewer($isLatestAttribute));
12471266
@@ -1384,7 +1403,7 @@
13851404
13861405 function rollBackDefinitions($idStack, $definitions) {
13871406 global
1388 - $definedMeaningIdAttribute, $languageAttribute, $translatedContentIdAttribute,
 1407+ $definedMeaningIdAttribute, $translatedContentIdAttribute,
13891408 $isLatestAttribute, $operationAttribute, $rollBackTranslatedContentAttribute;
13901409
13911410 $definitionsKeyStructure = $definitions->getKey();
@@ -1393,7 +1412,7 @@
13941413 $definitionRecord = $definitions->getRecord($i);
13951414
13961415 $definedMeaningId = $definitionRecord->getAttributeValue($definedMeaningIdAttribute);
1397 - $languageId = $definitionRecord->getAttributeValue($languageAttribute);
 1416+ $languageId = $definitionRecord->language;
13981417 $isLatest = $definitionRecord->getAttributeValue($isLatestAttribute);
13991418
14001419 if ($isLatest) {
@@ -1414,7 +1433,7 @@
14151434
14161435 function rollBackTranslatedTexts($idStack, $translatedTexts) {
14171436 global
1418 - $valueIdAttribute, $languageAttribute, $translatedContentIdAttribute,
 1437+ $valueIdAttribute, $translatedContentIdAttribute,
14191438 $isLatestAttribute, $operationAttribute, $rollBackTranslatedContentAttribute;
14201439
14211440 $translatedTextsKeyStructure = $translatedTexts->getKey();
@@ -1423,7 +1442,7 @@
14241443 $translatedTextRecord = $translatedTexts->getRecord($i);
14251444
14261445 $valueId = $translatedTextRecord->getAttributeValue($valueIdAttribute);
1427 - $languageId = $translatedTextRecord->getAttributeValue($languageAttribute);
 1446+ $languageId = $translatedTextRecord->language;
14281447 $isLatest = $translatedTextRecord->getAttributeValue($isLatestAttribute);
14291448
14301449 if ($isLatest) {
@@ -1685,7 +1704,7 @@
16861705
16871706 function rollBackTextAttributes($idStack, $textAttributes) {
16881707 global
1689 - $isLatestAttribute, $operationAttribute, $rollBackAttribute, $textAttribute,
 1708+ $isLatestAttribute, $operationAttribute, $rollBackAttribute,
16901709 $valueIdAttribute, $objectIdAttribute, $attributeAttribute, $translatedContentIdAttribute;
16911710
16921711 $textAttributesKeyStructure = $textAttributes->getKey();
@@ -1704,7 +1723,7 @@
17051724 $valueId,
17061725 $textAttributeRecord->getAttributeValue($objectIdAttribute),
17071726 getMeaningId($textAttributeRecord, $attributeAttribute),
1708 - $textAttributeRecord->getAttributeValue($textAttribute),
 1727+ $textAttributeRecord->text,
17091728 $textAttributeRecord->getAttributeValue($operationAttribute)
17101729 );
17111730
@@ -1723,7 +1742,7 @@
17241743 function rollBackSyntranses($idStack, $syntranses) {
17251744 global
17261745 $isLatestAttribute, $operationAttribute, $rollBackAttribute, $syntransIdAttribute, $identicalMeaningAttribute,
1727 - $spellingAttribute, $languageAttribute, $expressionAttribute, $definedMeaningIdAttribute, $expressionIdAttribute;
 1746+ $expressionAttribute, $definedMeaningIdAttribute, $expressionIdAttribute;
17281747
17291748 $syntransesKeyStructure = $syntranses->getKey();
17301749
@@ -1759,7 +1778,7 @@
17601779
17611780 function rollBackAlternativeDefinitionTexts($idStack, $alternativeDefinitionTexts) {
17621781 global
1763 - $definedMeaningIdAttribute, $languageAttribute, $translatedContentIdAttribute,
 1782+ $definedMeaningIdAttribute, $translatedContentIdAttribute,
17641783 $isLatestAttribute, $operationAttribute, $rollBackTranslatedContentAttribute;
17651784
17661785 $alternativeDefinitionTextsKeyStructure = $alternativeDefinitionTexts->getKey();
@@ -1768,7 +1787,7 @@
17691788 $alternativeDefinitionTextRecord = $alternativeDefinitionTexts->getRecord($i);
17701789
17711790 $translatedContentId = $alternativeDefinitionTextRecord->getAttributeValue($translatedContentIdAttribute);
1772 - $languageId = $alternativeDefinitionTextRecord->getAttributeValue($languageAttribute);
 1791+ $languageId = $alternativeDefinitionTextRecord->language;
17731792 $isLatest = $alternativeDefinitionTextRecord->getAttributeValue($isLatestAttribute);
17741793
17751794 if ($isLatest) {

Status & tagging log