mirror of
https://github.com/aaru-dps/Aaru.git
synced 2025-12-16 19:24:25 +00:00
General code refactor and reformat.
This commit is contained in:
@@ -6,45 +6,24 @@ namespace DiscImageChef.Database.Migrations
|
||||
{
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "Manufacturer",
|
||||
table: "Reports",
|
||||
nullable: true);
|
||||
migrationBuilder.AddColumn<string>("Manufacturer", "Reports", nullable: true);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "Model",
|
||||
table: "Reports",
|
||||
nullable: true);
|
||||
migrationBuilder.AddColumn<string>("Model", "Reports", nullable: true);
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "Revision",
|
||||
table: "Reports",
|
||||
nullable: true);
|
||||
migrationBuilder.AddColumn<string>("Revision", "Reports", nullable: true);
|
||||
|
||||
migrationBuilder.AddColumn<int>(
|
||||
name: "Type",
|
||||
table: "Reports",
|
||||
nullable: false,
|
||||
defaultValue: 0);
|
||||
migrationBuilder.AddColumn<int>("Type", "Reports", nullable: false, defaultValue: 0);
|
||||
}
|
||||
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "Manufacturer",
|
||||
table: "Reports");
|
||||
migrationBuilder.DropColumn("Manufacturer", "Reports");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "Model",
|
||||
table: "Reports");
|
||||
migrationBuilder.DropColumn("Model", "Reports");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "Revision",
|
||||
table: "Reports");
|
||||
migrationBuilder.DropColumn("Revision", "Reports");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "Type",
|
||||
table: "Reports");
|
||||
migrationBuilder.DropColumn("Type", "Reports");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,4 @@
|
||||
using System;
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
namespace DiscImageChef.Database.Migrations
|
||||
{
|
||||
@@ -7,84 +6,75 @@ namespace DiscImageChef.Database.Migrations
|
||||
{
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropTable(
|
||||
name: "ModePage_2A");
|
||||
migrationBuilder.DropTable("ModePage_2A");
|
||||
|
||||
migrationBuilder.AddColumn<byte[]>(
|
||||
name: "ModeSense2AData",
|
||||
table: "Mmc",
|
||||
nullable: true);
|
||||
migrationBuilder.AddColumn<byte[]>("ModeSense2AData", "Mmc", nullable: true);
|
||||
}
|
||||
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "ModeSense2AData",
|
||||
table: "Mmc");
|
||||
migrationBuilder.DropColumn("ModeSense2AData", "Mmc");
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "ModePage_2A",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<int>(nullable: false)
|
||||
.Annotation("Sqlite:Autoincrement", true),
|
||||
AccurateCDDA = table.Column<bool>(nullable: false),
|
||||
AudioPlay = table.Column<bool>(nullable: false),
|
||||
BCK = table.Column<bool>(nullable: false),
|
||||
BUF = table.Column<bool>(nullable: false),
|
||||
BufferSize = table.Column<ushort>(nullable: false),
|
||||
C2Pointer = table.Column<bool>(nullable: false),
|
||||
CDDACommand = table.Column<bool>(nullable: false),
|
||||
CMRSupported = table.Column<ushort>(nullable: false),
|
||||
Composite = table.Column<bool>(nullable: false),
|
||||
CurrentSpeed = table.Column<ushort>(nullable: false),
|
||||
CurrentWriteSpeed = table.Column<ushort>(nullable: false),
|
||||
CurrentWriteSpeedSelected = table.Column<ushort>(nullable: false),
|
||||
DeinterlaveSubchannel = table.Column<bool>(nullable: false),
|
||||
DigitalPort1 = table.Column<bool>(nullable: false),
|
||||
DigitalPort2 = table.Column<bool>(nullable: false),
|
||||
Eject = table.Column<bool>(nullable: false),
|
||||
ISRC = table.Column<bool>(nullable: false),
|
||||
LSBF = table.Column<bool>(nullable: false),
|
||||
LeadInPW = table.Column<bool>(nullable: false),
|
||||
Length = table.Column<byte>(nullable: false),
|
||||
LoadingMechanism = table.Column<byte>(nullable: false),
|
||||
Lock = table.Column<bool>(nullable: false),
|
||||
LockState = table.Column<bool>(nullable: false),
|
||||
MaxWriteSpeed = table.Column<ushort>(nullable: false),
|
||||
MaximumSpeed = table.Column<ushort>(nullable: false),
|
||||
Method2 = table.Column<bool>(nullable: false),
|
||||
Mode2Form1 = table.Column<bool>(nullable: false),
|
||||
Mode2Form2 = table.Column<bool>(nullable: false),
|
||||
MultiSession = table.Column<bool>(nullable: false),
|
||||
PS = table.Column<bool>(nullable: false),
|
||||
PreventJumper = table.Column<bool>(nullable: false),
|
||||
RCK = table.Column<bool>(nullable: false),
|
||||
ReadBarcode = table.Column<bool>(nullable: false),
|
||||
ReadCDR = table.Column<bool>(nullable: false),
|
||||
ReadCDRW = table.Column<bool>(nullable: false),
|
||||
ReadDVDR = table.Column<bool>(nullable: false),
|
||||
ReadDVDRAM = table.Column<bool>(nullable: false),
|
||||
ReadDVDROM = table.Column<bool>(nullable: false),
|
||||
RotationControlSelected = table.Column<byte>(nullable: false),
|
||||
SCC = table.Column<bool>(nullable: false),
|
||||
SDP = table.Column<bool>(nullable: false),
|
||||
SSS = table.Column<bool>(nullable: false),
|
||||
SeparateChannelMute = table.Column<bool>(nullable: false),
|
||||
SeparateChannelVolume = table.Column<bool>(nullable: false),
|
||||
Subchannel = table.Column<bool>(nullable: false),
|
||||
SupportedVolumeLevels = table.Column<ushort>(nullable: false),
|
||||
TestWrite = table.Column<bool>(nullable: false),
|
||||
UPC = table.Column<bool>(nullable: false),
|
||||
WriteCDR = table.Column<bool>(nullable: false),
|
||||
WriteCDRW = table.Column<bool>(nullable: false),
|
||||
WriteDVDR = table.Column<bool>(nullable: false),
|
||||
WriteDVDRAM = table.Column<bool>(nullable: false)
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_ModePage_2A", x => x.Id);
|
||||
});
|
||||
migrationBuilder.CreateTable("ModePage_2A",
|
||||
table => new
|
||||
{
|
||||
Id =
|
||||
table.Column<int>(nullable: false)
|
||||
.Annotation("Sqlite:Autoincrement", true),
|
||||
AccurateCDDA = table.Column<bool>(nullable: false),
|
||||
AudioPlay = table.Column<bool>(nullable: false),
|
||||
BCK = table.Column<bool>(nullable: false),
|
||||
BUF = table.Column<bool>(nullable: false),
|
||||
BufferSize = table.Column<ushort>(nullable: false),
|
||||
C2Pointer = table.Column<bool>(nullable: false),
|
||||
CDDACommand = table.Column<bool>(nullable: false),
|
||||
CMRSupported = table.Column<ushort>(nullable: false),
|
||||
Composite = table.Column<bool>(nullable: false),
|
||||
CurrentSpeed = table.Column<ushort>(nullable: false),
|
||||
CurrentWriteSpeed = table.Column<ushort>(nullable: false),
|
||||
CurrentWriteSpeedSelected = table.Column<ushort>(nullable: false),
|
||||
DeinterlaveSubchannel = table.Column<bool>(nullable: false),
|
||||
DigitalPort1 = table.Column<bool>(nullable: false),
|
||||
DigitalPort2 = table.Column<bool>(nullable: false),
|
||||
Eject = table.Column<bool>(nullable: false),
|
||||
ISRC = table.Column<bool>(nullable: false),
|
||||
LSBF = table.Column<bool>(nullable: false),
|
||||
LeadInPW = table.Column<bool>(nullable: false),
|
||||
Length = table.Column<byte>(nullable: false),
|
||||
LoadingMechanism = table.Column<byte>(nullable: false),
|
||||
Lock = table.Column<bool>(nullable: false),
|
||||
LockState = table.Column<bool>(nullable: false),
|
||||
MaxWriteSpeed = table.Column<ushort>(nullable: false),
|
||||
MaximumSpeed = table.Column<ushort>(nullable: false),
|
||||
Method2 = table.Column<bool>(nullable: false),
|
||||
Mode2Form1 = table.Column<bool>(nullable: false),
|
||||
Mode2Form2 = table.Column<bool>(nullable: false),
|
||||
MultiSession = table.Column<bool>(nullable: false),
|
||||
PS = table.Column<bool>(nullable: false),
|
||||
PreventJumper = table.Column<bool>(nullable: false),
|
||||
RCK = table.Column<bool>(nullable: false),
|
||||
ReadBarcode = table.Column<bool>(nullable: false),
|
||||
ReadCDR = table.Column<bool>(nullable: false),
|
||||
ReadCDRW = table.Column<bool>(nullable: false),
|
||||
ReadDVDR = table.Column<bool>(nullable: false),
|
||||
ReadDVDRAM = table.Column<bool>(nullable: false),
|
||||
ReadDVDROM = table.Column<bool>(nullable: false),
|
||||
RotationControlSelected = table.Column<byte>(nullable: false),
|
||||
SCC = table.Column<bool>(nullable: false),
|
||||
SDP = table.Column<bool>(nullable: false),
|
||||
SSS = table.Column<bool>(nullable: false),
|
||||
SeparateChannelMute = table.Column<bool>(nullable: false),
|
||||
SeparateChannelVolume = table.Column<bool>(nullable: false),
|
||||
Subchannel = table.Column<bool>(nullable: false),
|
||||
SupportedVolumeLevels = table.Column<ushort>(nullable: false),
|
||||
TestWrite = table.Column<bool>(nullable: false),
|
||||
UPC = table.Column<bool>(nullable: false),
|
||||
WriteCDR = table.Column<bool>(nullable: false),
|
||||
WriteCDRW = table.Column<bool>(nullable: false),
|
||||
WriteDVDR = table.Column<bool>(nullable: false),
|
||||
WriteDVDRAM = table.Column<bool>(nullable: false)
|
||||
},
|
||||
constraints: table => { table.PrimaryKey("PK_ModePage_2A", x => x.Id); });
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace DiscImageChef.Database.Models
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System;
|
||||
using DiscImageChef.CommonTypes.Metadata;
|
||||
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace DiscImageChef.Database.Models
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace DiscImageChef.Database.Models
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace DiscImageChef.Database.Models
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace DiscImageChef.Database.Models
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace DiscImageChef.Database.Models
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace DiscImageChef.Database.Models
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace DiscImageChef.Database.Models
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System;
|
||||
using DiscImageChef.CommonTypes.Metadata;
|
||||
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using System.ComponentModel.DataAnnotations.Schema;
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
// ----------------------------------------------------------------------------
|
||||
// Copyright © 2011-2019 Natalia Portillo
|
||||
// ****************************************************************************/
|
||||
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace DiscImageChef.Database.Models
|
||||
|
||||
Reference in New Issue
Block a user