Skip to content
Snippets Groups Projects
Commit 4b201c1c authored by Torsten Oppermann's avatar Torsten Oppermann
Browse files

[TASK] Update dependencies of company table

parent aa07c76a
No related branches found
No related tags found
No related merge requests found
......@@ -26,7 +26,7 @@ namespace SGalinski\SgJobs\Controller;
* This copyright notice MUST APPEAR in all copies of the script!
***************************************************************/
use SGalinski\SgJobs\Domain\Model\Location;
use SGalinski\SgJobs\Domain\Model\Company;
use SGalinski\SgJobs\Service\BackendService;
use TYPO3\CMS\Backend\Template\Components\DocHeaderComponent;
use TYPO3\CMS\Backend\Utility\BackendUtility;
......@@ -48,10 +48,10 @@ class BackendController extends ActionController {
protected $docHeaderComponent;
/**
* @var \SGalinski\SgJobs\Domain\Repository\LocationRepository
* @var \SGalinski\SgJobs\Domain\Repository\CompanyRepository
* @inject
*/
private $locationRepository;
private $companyRepository;
/**
* @var \SGalinski\SgJobs\Domain\Repository\JobRepository
......@@ -97,13 +97,13 @@ class BackendController extends ActionController {
// get all Locations
/** @noinspection PhpUndefinedMethodInspection */
/** @var QueryResultInterface $categories */
$locations = $this->locationRepository->findByPid($this->rootPageUid);
$companies = $this->companyRepository->findByPid($this->rootPageUid);
$locationOptions = [];
/** @var Location $location */
/** @var $locations Location[][] */
foreach ($locations as $location) {
$locationOptions[$location->getUid()] = $location->getCity();
/** @var Company $companies */
/** @var $companies Company[][] */
foreach ($companies as $company) {
$locationOptions[$company->getUid()] = $company->getCity();
}
$this->view->assign('locationOptions', $locationOptions);
$this->view->assign('filters', $filters);
......
......@@ -29,9 +29,9 @@ namespace SGalinski\SgJobs\Domain\Repository;
use TYPO3\CMS\Extbase\Persistence\Repository;
/**
* Location Repository
* Company Repository
*/
class LocationRepository extends Repository {
class CompanyRepository extends Repository {
/**
* initializes the object
......
......@@ -174,7 +174,7 @@ return [
'type' => 'text',
'cols' => 40,
'rows' => 10,
'eval' => 'trim, required'
'eval' => ''
],
'defaultExtras' => 'richtext[]'
],
......@@ -185,7 +185,7 @@ return [
'type' => 'text',
'cols' => 40,
'rows' => 10,
'eval' => 'trim, required'
'eval' => ''
],
'defaultExtras' => 'richtext[]'
],
......@@ -196,7 +196,7 @@ return [
'type' => 'text',
'cols' => 40,
'rows' => 10,
'eval' => 'trim, required'
'eval' => ''
],
'defaultExtras' => 'richtext[]'
],
......
......@@ -20,7 +20,7 @@
</td>
<td style="white-space: normal;">
<a href="#" onclick="{editOnClick}">
<span>{job.title} - {job.location.0.city}</span>
<span>{job.title} - {job.company.0.name}, {job.company.0.city}</span>
</a>
</td>
<td nowrap="nowrap" class="col-control">
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment