Skip to content

Commit

Permalink
Merge branch 'release/1.0-rc10'
Browse files Browse the repository at this point in the history
  • Loading branch information
IllyaMoskvin committed Feb 21, 2020
2 parents 9ff2c24 + 3836c1e commit c909225
Show file tree
Hide file tree
Showing 135 changed files with 572 additions and 1,538 deletions.
8 changes: 8 additions & 0 deletions app/Console/Commands/Import/ImportUlan.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,14 @@ public function handle()
$result = $this->fetchUlan($agent, $agent->birth_date, $agent->death_date);

$gotit = $this->updateUlan($agent, $result, 'with birth and death year');

// Now let's try only name
if (!$gotit)
{
$result = $this->fetchUlan($agent, null, null);

$gotit = $this->updateUlan($agent, $result, 'with no years');
}
}
}

Expand Down
2 changes: 1 addition & 1 deletion app/Models/AbstractPivot.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
abstract class AbstractPivot extends Pivot
{

use Instancable, Transformable, Fakeable;
use Instancable, Transformable;

// TODO: Abstract `getDate` logic from BaseModel into Trait, so that we can `use` it here?
Expand Down
2 changes: 0 additions & 2 deletions app/Models/Archive/ArchiveImage.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ class ArchiveImage extends BaseModel

protected $primaryKey = 'id';

protected $fakeIdsStartAt = 999000;

protected $casts = [
'subject_terms' => 'array',
'source_created_at' => 'datetime',
Expand Down
2 changes: 1 addition & 1 deletion app/Models/BaseModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
class BaseModel extends AbstractModel
{

use Transformable, Instancable, Fakeable, Documentable;
use Transformable, Instancable, Documentable;

/**
* The name of the field that the source API provides a last updated timestamp in.
Expand Down
2 changes: 0 additions & 2 deletions app/Models/Collections/AgentRole.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,4 @@ class AgentRole extends CollectionsModel

protected $primaryKey = 'citi_id';

protected $fakeIdsStartAt = 9000;

}
2 changes: 0 additions & 2 deletions app/Models/Collections/AgentType.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,4 @@ class AgentType extends CollectionsModel

protected $primaryKey = 'citi_id';

protected $fakeIdsStartAt = 99900;

}
2 changes: 0 additions & 2 deletions app/Models/Collections/ArtworkDateQualifier.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,4 @@ class ArtworkDateQualifier extends CollectionsModel

protected $primaryKey = 'citi_id';

protected $fakeIdsStartAt = 9900;

}
2 changes: 0 additions & 2 deletions app/Models/Collections/ArtworkPlaceQualifier.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,4 @@ class ArtworkPlaceQualifier extends CollectionsModel

protected $primaryKey = 'citi_id';

protected $fakeIdsStartAt = 9000;

}
2 changes: 0 additions & 2 deletions app/Models/Collections/ArtworkType.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,4 @@ class ArtworkType extends CollectionsModel

protected $primaryKey = 'citi_id';

protected $fakeIdsStartAt = 99900;

}
2 changes: 0 additions & 2 deletions app/Models/CollectionsModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ class CollectionsModel extends BaseModel

protected static $source = 'Collections';

protected $fakeIdsStartAt = 999000000;

protected $isInCiti = true;

}
2 changes: 0 additions & 2 deletions app/Models/Dsc/Section.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ class Section extends DscModel

use ElasticSearchable;

protected $fakeIdsStartAt = 90000000000;

protected $touches = [
'artwork',
];
Expand Down
2 changes: 0 additions & 2 deletions app/Models/DscModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ class DscModel extends BaseModel

protected $primaryKey = 'dsc_id';

protected $fakeIdsStartAt = 9990000;

protected $hasSourceDates = false;

}
29 changes: 0 additions & 29 deletions app/Models/Fakeable.php

This file was deleted.

3 changes: 0 additions & 3 deletions app/Models/LibraryModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,6 @@ class LibraryModel extends BaseModel

protected $primaryKey = 'id';

// TODO: Add seeders for these models
// protected $fakeIdsStartAt = 9990000;

protected $hasSourceDates = false;

}
2 changes: 0 additions & 2 deletions app/Models/MembershipModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,4 @@ class MembershipModel extends BaseModel

protected $primaryKey = 'membership_id';

protected $fakeIdsStartAt = 99900000;

}
2 changes: 0 additions & 2 deletions app/Models/MobileModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,4 @@ class MobileModel extends BaseModel

protected $hasSourceDates = false;

protected $fakeIdsStartAt = 9990000;

}
2 changes: 0 additions & 2 deletions app/Models/ShopModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,4 @@ class ShopModel extends BaseModel

protected $primaryKey = 'shop_id';

protected $fakeIdsStartAt = 999000;

}
2 changes: 0 additions & 2 deletions app/Models/StaticArchive/Site.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ class Site extends BaseModel

protected $primaryKey = 'site_id';

protected $fakeIdsStartAt = 9990000;

protected $hasSourceDates = false;

protected $touches = [
Expand Down
2 changes: 0 additions & 2 deletions app/Models/Web/Page.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@
class Page extends WebModel
{

protected $hasSourceDates = false;

protected $casts = [
'publish_start_date' => 'datetime',
'publish_end_date' => 'datetime',
Expand Down
16 changes: 0 additions & 16 deletions app/Transformers/Outbound/Collections/ArtworkArtistPivot.php
Original file line number Diff line number Diff line change
Expand Up @@ -66,22 +66,6 @@ protected function getFields()
'doc' => 'Whether this is a preferred artist',
'type' => 'boolean',
],

// TODO: Refactor relationships:
'artwork_title' => [
'doc' => 'Name of the work this artist made',
'type' => 'string',
'value' => function ($item) {
return $item->artwork->title ?? null;
},
],
'artwork_id' => [
'doc' => 'Unique identifier of the work this artist made',
'type' => 'number',
'value' => function ($item) {
return $item->artwork->citi_id ?? null;
},
],
'artist_title' => [
'doc' => 'Name of the artist',
'type' => 'string',
Expand Down
5 changes: 0 additions & 5 deletions app/Transformers/Outbound/Collections/Asset.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,6 @@ protected function getFields()
'default' => true,
],
],
'copyright_notice' => [
'doc' => 'Statement notifying how the asset is protected by copyright. Applies to the asset itself, not artwork it may be related to.',
'type' => 'string',
'elasticsearch' => 'text',
],
'is_multimedia_resource' => [
'doc' => 'Whether this resource is considered to be multimedia',
'type' => 'boolean',
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
"brianium/paratest": "^3.1",
"filp/whoops": "~2.0",
"fzaninotto/faker": "~1.4",
"itsgoingd/clockwork": "^3.1",
"itsgoingd/clockwork": "^4.0",
"mockery/mockery": "0.9.*",
"phpstan/phpstan": "^0.11.12",
"phpunit/phpunit": "^8.5",
Expand Down
19 changes: 12 additions & 7 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion config/aic.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
| or any other location as required by the application or its packages.
*/

'version' => '1.0-rc9',
'version' => '1.0-rc10',

/*
|--------------------------------------------------------------------------
Expand Down
Loading

0 comments on commit c909225

Please sign in to comment.