Skip to content

Commit

Permalink
#4 Fix form localization issues
Browse files Browse the repository at this point in the history
  • Loading branch information
asmecher committed Apr 15, 2019
1 parent 46e7b27 commit 9a3ff6f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions classes/DepositPoint.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,9 @@ public function getName($locale) {
/**
* Set deposit point name
* @param $title string
* @param $locale string
* @param $locale string?
*/
public function setName($name, $locale) {
public function setName($name, $locale = null) {
return $this->setData('name', $name, $locale);
}

Expand Down
4 changes: 2 additions & 2 deletions controllers/grid/form/SwordDepositPointForm.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ public function readInputData($request) {
'depositPointType'
)
);
$this->setData('name', $request->getUserVar('name')[AppLocale::getLocale()]);
$this->setData('name', $request->getUserVar('name'));
}

/**
Expand Down Expand Up @@ -113,7 +113,7 @@ public function execute() {
}

$depositPoint->setContextId($this->_contextId);
$depositPoint->setName($this->getData('name'), AppLocale::getLocale());
$depositPoint->setName($this->getData('name'));
$depositPoint->setType($this->getData('depositPointType'));
$depositPoint->setSwordUrl($this->getData('swordUrl'));
$depositPoint->setSwordUsername($this->getData('swordUsername'));
Expand Down

0 comments on commit 9a3ff6f

Please sign in to comment.