chore(server): typeorm definitions fix part 3 (#1796)

* chore(server): tidy up exif typeorm entity definition

* chore(server): tidy up shared link typeorm entity definition

* chore(server): tidy up smart info typeorm entity definition

* chore(server): tidy up tag typeorm entity definition

* ci: add job that checks typeorm migrations are correct and up-to-date
This commit is contained in:
Zack Pollard
2023-02-20 01:50:27 +00:00
committed by GitHub
parent 5d3e8f17d1
commit d1ea6a897e
21 changed files with 140 additions and 101 deletions

View File

@@ -13,7 +13,6 @@ part of openapi.api;
class ExifResponseDto {
/// Returns a new [ExifResponseDto] instance.
ExifResponseDto({
this.id,
this.fileSizeInByte,
this.make,
this.model,
@@ -35,8 +34,6 @@ class ExifResponseDto {
this.country,
});
int? id;
int? fileSizeInByte;
String? make;
@@ -77,7 +74,6 @@ class ExifResponseDto {
@override
bool operator ==(Object other) => identical(this, other) || other is ExifResponseDto &&
other.id == id &&
other.fileSizeInByte == fileSizeInByte &&
other.make == make &&
other.model == model &&
@@ -101,7 +97,6 @@ class ExifResponseDto {
@override
int get hashCode =>
// ignore: unnecessary_parenthesis
(id == null ? 0 : id!.hashCode) +
(fileSizeInByte == null ? 0 : fileSizeInByte!.hashCode) +
(make == null ? 0 : make!.hashCode) +
(model == null ? 0 : model!.hashCode) +
@@ -123,15 +118,10 @@ class ExifResponseDto {
(country == null ? 0 : country!.hashCode);
@override
String toString() => 'ExifResponseDto[id=$id, fileSizeInByte=$fileSizeInByte, make=$make, model=$model, imageName=$imageName, exifImageWidth=$exifImageWidth, exifImageHeight=$exifImageHeight, orientation=$orientation, dateTimeOriginal=$dateTimeOriginal, modifyDate=$modifyDate, lensModel=$lensModel, fNumber=$fNumber, focalLength=$focalLength, iso=$iso, exposureTime=$exposureTime, latitude=$latitude, longitude=$longitude, city=$city, state=$state, country=$country]';
String toString() => 'ExifResponseDto[fileSizeInByte=$fileSizeInByte, make=$make, model=$model, imageName=$imageName, exifImageWidth=$exifImageWidth, exifImageHeight=$exifImageHeight, orientation=$orientation, dateTimeOriginal=$dateTimeOriginal, modifyDate=$modifyDate, lensModel=$lensModel, fNumber=$fNumber, focalLength=$focalLength, iso=$iso, exposureTime=$exposureTime, latitude=$latitude, longitude=$longitude, city=$city, state=$state, country=$country]';
Map<String, dynamic> toJson() {
final json = <String, dynamic>{};
if (this.id != null) {
json[r'id'] = this.id;
} else {
// json[r'id'] = null;
}
if (this.fileSizeInByte != null) {
json[r'fileSizeInByte'] = this.fileSizeInByte;
} else {
@@ -249,7 +239,6 @@ class ExifResponseDto {
}());
return ExifResponseDto(
id: mapValueOfType<int>(json, r'id'),
fileSizeInByte: mapValueOfType<int>(json, r'fileSizeInByte'),
make: mapValueOfType<String>(json, r'make'),
model: mapValueOfType<String>(json, r'model'),