translation fixes..

This commit is contained in:
Cüneyt Şentürk 2021-01-11 23:04:55 +03:00
parent 813ebfe600
commit b4d406096b
2 changed files with 4 additions and 6 deletions

View File

@ -714,7 +714,7 @@ abstract class DocumentIndex extends Base
return $textDocumentStatus; return $textDocumentStatus;
} }
$translation = $this->getTextFromConfig($type, 'document_status', '.statuses.'); $translation = $this->getTextFromConfig($type, 'document_status', 'statuses.');
if (!empty($translation)) { if (!empty($translation)) {
return $translation; return $translation;

View File

@ -536,7 +536,7 @@ abstract class DocumentShow extends Base
return $textStatusMessage; return $textStatusMessage;
} }
$default_key = config('type.' . $type . '.translation.prefix') . '.messages.draft'; $default_key = 'messages.draft';
$translation = $this->getTextFromConfig($type, 'status_message', $default_key); $translation = $this->getTextFromConfig($type, 'status_message', $default_key);
@ -622,9 +622,7 @@ abstract class DocumentShow extends Base
return $textHistories; return $textHistories;
} }
$default_key = config('type.' . $type . '.translation.prefix') . '.histories'; $translation = $this->getTextFromConfig($type, 'histories', 'histories');
$translation = $this->getTextFromConfig($type, 'histories', $default_key);
if (!empty($translation)) { if (!empty($translation)) {
return $translation; return $translation;
@ -639,7 +637,7 @@ abstract class DocumentShow extends Base
return $textHistoryStatus; return $textHistoryStatus;
} }
$translation = $this->getTextFromConfig($type, 'document_status', '.statuses.'); $translation = $this->getTextFromConfig($type, 'document_status', 'statuses.');
if (!empty($translation)) { if (!empty($translation)) {
return $translation; return $translation;