Start making it more robust
- Use structured data for search/render - Start testing component - Start testing domain logic
This commit is contained in:
@@ -13,7 +13,7 @@ export default {
|
||||
async mounted() {
|
||||
const detectedBarcodes = new Set([]);
|
||||
const barcodeDetector = await barcodeReaderSetup();
|
||||
const video = this.el;
|
||||
this.cameraPreview = this.el.querySelector("#camera-preview");
|
||||
const constraints = {
|
||||
audio: false,
|
||||
video: {
|
||||
@@ -27,17 +27,17 @@ export default {
|
||||
.getUserMedia(constraints)
|
||||
.then((mediaStream) => {
|
||||
console.debug("Camera access allowed")
|
||||
this.pushEventTo(video, "camera:allowed", {});
|
||||
video.srcObject = mediaStream;
|
||||
video.onloadedmetadata = () => {
|
||||
video.play();
|
||||
this.pushEventTo(this.cameraPreview, "camera_allowed", {});
|
||||
this.cameraPreview.srcObject = mediaStream;
|
||||
this.cameraPreview.onloadedmetadata = () => {
|
||||
this.cameraPreview.play();
|
||||
this.scanInterval = window.setInterval(async () => {
|
||||
const barcodes = await barcodeDetector.detect(video);
|
||||
const barcodes = await barcodeDetector.detect(this.cameraPreview);
|
||||
if (barcodes.length <= 0) return;
|
||||
|
||||
barcodes.forEach(barcode => {
|
||||
if (!detectedBarcodes.has(barcode.rawValue)) {
|
||||
this.pushEventTo(video, "barcode:scanned", { number: barcode.rawValue });
|
||||
this.pushEventTo(this.cameraPreview, "barcode_scanned", { number: barcode.rawValue });
|
||||
detectedBarcodes.add(barcode.rawValue);
|
||||
};
|
||||
});
|
||||
@@ -46,11 +46,11 @@ export default {
|
||||
})
|
||||
.catch((err) => {
|
||||
console.error(`${err.name}: ${err.message}`);
|
||||
this.pushEventTo(video, "camera:denied", {});
|
||||
this.pushEventTo(this.cameraPreview, "camera_denied", {});
|
||||
});
|
||||
},
|
||||
destroyed() {
|
||||
this.el.srcObject.getTracks().forEach(track => track.stop());
|
||||
this.cameraPreview.srcObject.getTracks().forEach(track => track.stop());
|
||||
window.clearInterval(this.scanInterval);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,39 @@
|
||||
defmodule MusicBrainz.ReleaseSearchResult do
|
||||
@enforce_keys [:id, :title, :release_group, :artists, :date, :barcode, :media]
|
||||
defstruct [:id, :title, :release_group, :artists, :date, :barcode, :media]
|
||||
|
||||
alias MusicBrainz.ReleaseGroup
|
||||
|
||||
def from_api_response(r) do
|
||||
%__MODULE__{
|
||||
id: r["id"],
|
||||
title: r["title"],
|
||||
release_group: parse_release_group(r["release-group"]),
|
||||
artists:
|
||||
r["artist-credit"]
|
||||
|> Enum.map(fn ac -> ac["artist"]["name"] end)
|
||||
|> Enum.join(", "),
|
||||
date: r["date"],
|
||||
barcode: r["barcode"],
|
||||
media: parse_media(r["media"])
|
||||
}
|
||||
end
|
||||
|
||||
defp parse_release_group(rg) do
|
||||
%{
|
||||
id: rg["id"],
|
||||
type: ReleaseGroup.parse_type(rg["primary-type"]),
|
||||
title: rg["title"]
|
||||
}
|
||||
end
|
||||
|
||||
defp parse_media(media) do
|
||||
Enum.map(media, fn m ->
|
||||
%{
|
||||
format: m["format"],
|
||||
track_count: m["track-count"],
|
||||
disc_count: m["disc-count"]
|
||||
}
|
||||
end)
|
||||
end
|
||||
end
|
||||
@@ -142,7 +142,8 @@ defmodule MusicLibrary.Records do
|
||||
def search_release_by_barcode(barcode) do
|
||||
case music_brainz_config().api.search_release_by_barcode(barcode, music_brainz_config()) do
|
||||
{:ok, releases} ->
|
||||
{:ok, releases}
|
||||
{:ok,
|
||||
Enum.map(releases, fn r -> MusicBrainz.ReleaseSearchResult.from_api_response(r) end)}
|
||||
|
||||
error ->
|
||||
error
|
||||
|
||||
@@ -17,14 +17,21 @@ defmodule MusicLibraryWeb.RecordLive.BarcodeScannerComponent do
|
||||
@impl true
|
||||
def render(assigns) do
|
||||
~H"""
|
||||
<div>
|
||||
<h1>Barcode Scan</h1>
|
||||
<video id="camera-view" phx-hook="BarcodeScanner"></video>
|
||||
<div id="barcode-scanner" phx-hook="BarcodeScanner" phx-target={@myself}>
|
||||
<header>
|
||||
<h1 class="text-sm font-medium leading-6 text-zinc-700 dark:text-zinc-400">
|
||||
{gettext("Scan one or more barcodes")}
|
||||
</h1>
|
||||
</header>
|
||||
<div>
|
||||
<p>{@camera}</p>
|
||||
<video id="camera-preview"></video>
|
||||
</div>
|
||||
<ul>
|
||||
<li :for={release <- assigns.releases}>
|
||||
<span>{release["id"]}</span>
|
||||
<span>{release["barcode"]}</span>
|
||||
<span>{release["title"]}</span>
|
||||
<span>{release.id}</span>
|
||||
<span>{release.barcode}</span>
|
||||
<span>{release.title}</span>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
@@ -32,17 +39,17 @@ defmodule MusicLibraryWeb.RecordLive.BarcodeScannerComponent do
|
||||
end
|
||||
|
||||
@impl true
|
||||
def handle_event("camera:allowed", _params, socket) do
|
||||
def handle_event("camera_allowed", _params, socket) do
|
||||
Logger.debug(fn -> "Camera access allowed" end)
|
||||
{:noreply, assign(socket, camera: :allowed)}
|
||||
end
|
||||
|
||||
def handle_event("camera:denied", _params, socket) do
|
||||
def handle_event("camera_denied", _params, socket) do
|
||||
Logger.debug(fn -> "Camera access denied" end)
|
||||
{:noreply, assign(socket, camera: :denied)}
|
||||
end
|
||||
|
||||
def handle_event("barcode:scanned", %{"number" => number}, socket) do
|
||||
def handle_event("barcode_scanned", %{"number" => number}, socket) do
|
||||
Logger.debug(fn -> "Scanned barcode #{number}" end)
|
||||
|
||||
{:ok, releases} =
|
||||
|
||||
@@ -629,3 +629,8 @@ msgstr ""
|
||||
#, elixir-autogen, elixir-format
|
||||
msgid "Scan barcodes · Collection"
|
||||
msgstr ""
|
||||
|
||||
#: lib/music_library_web/live/record_live/barcode_scanner_component.ex:23
|
||||
#, elixir-autogen, elixir-format
|
||||
msgid "Scan one or more barcodes"
|
||||
msgstr ""
|
||||
|
||||
@@ -6,6 +6,7 @@ defmodule MusicLibrary.RecordsTest do
|
||||
alias MusicBrainz.APIBehaviourMock
|
||||
import MusicLibrary.RecordsFixtures
|
||||
import MusicLibrary.ReleaseGroupsFixtures
|
||||
import MusicBrainz.Fixtures.Release
|
||||
import Mox
|
||||
|
||||
setup :verify_on_exit!
|
||||
@@ -325,4 +326,22 @@ defmodule MusicLibrary.RecordsTest do
|
||||
"14A033C9315419E0903B4D74EA6A95D4DC58CC7FE82F6F03BDA5750E7D3A590C"
|
||||
end
|
||||
end
|
||||
|
||||
describe "search_release_by_barcode/1" do
|
||||
test "it returns releases belonging to the same release group" do
|
||||
barcode = "5052205070023"
|
||||
releases = releases(:queen_greatest_hits)
|
||||
|
||||
expect(APIBehaviourMock, :search_release_by_barcode, fn ^barcode, _config ->
|
||||
{:ok, releases}
|
||||
end)
|
||||
|
||||
assert {:ok, results} = Records.search_release_by_barcode(barcode)
|
||||
|
||||
assert Enum.all?(results, fn result ->
|
||||
result.release_group.id == "69ce61c8-127f-3809-95d8-62fdf3ae1347" &&
|
||||
result.release_group.title == "Greatest Hits"
|
||||
end)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -326,4 +326,22 @@ defmodule MusicLibraryWeb.CollectionLive.IndexTest do
|
||||
assert_path(session, ~p"/collection/#{record.id}")
|
||||
end
|
||||
end
|
||||
|
||||
describe "Add via barcode scan" do
|
||||
test "it tracks the camera status", %{conn: conn} do
|
||||
session =
|
||||
conn
|
||||
|> visit(~p"/collection/scan")
|
||||
|> assert_has("h1", text: "Scan one or more barcodes")
|
||||
|> assert_has("p", text: "pending")
|
||||
|
||||
session
|
||||
|> unwrap(fn view ->
|
||||
view
|
||||
|> element("#barcode-scanner")
|
||||
|> render_hook("camera_denied")
|
||||
end)
|
||||
|> assert_has("p", text: "denied")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -29,7 +29,10 @@ defmodule MusicLibraryWeb.ConnCase do
|
||||
import Phoenix.ConnTest
|
||||
import MusicLibraryWeb.ConnCase
|
||||
import PhoenixTest
|
||||
import Phoenix.LiveViewTest, only: [render: 1, render_async: 1]
|
||||
|
||||
import Phoenix.LiveViewTest,
|
||||
only: [render: 1, render_async: 1, render_hook: 2, render_hook: 3, element: 2, element: 3]
|
||||
|
||||
import MusicLibraryWeb.LiveTestHelpers
|
||||
end
|
||||
end
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
defmodule MusicBrainz.Fixtures.Release do
|
||||
@fixtures_folder Path.join([File.cwd!(), "test/support/fixtures/music_brainz"])
|
||||
|
||||
def releases(:queen_greatest_hits) do
|
||||
Path.join([@fixtures_folder, "releases - queen - greatest hits.json"])
|
||||
|> File.read!()
|
||||
|> Jason.decode!()
|
||||
|> Map.get("releases")
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,679 @@
|
||||
{
|
||||
"created": "2025-02-13T18:57:53.874Z",
|
||||
"count": 9,
|
||||
"offset": 0,
|
||||
"releases": [
|
||||
{
|
||||
"id": "6d1830ce-2ac6-46a3-b3be-f56b8eb14a98",
|
||||
"score": 100,
|
||||
"status-id": "4e304316-386d-3409-af2e-78857eec5cfe",
|
||||
"packaging-id": "ec27701a-4a22-37f4-bfac-6616e0f9750a",
|
||||
"count": 1,
|
||||
"title": "Greatest Hits",
|
||||
"status": "Official",
|
||||
"disambiguation": "made in Italy",
|
||||
"packaging": "Jewel Case",
|
||||
"text-representation": {
|
||||
"language": "eng",
|
||||
"script": "Latn"
|
||||
},
|
||||
"artist-credit": [
|
||||
{
|
||||
"name": "Queen",
|
||||
"artist": {
|
||||
"id": "0383dadf-2a4e-4d10-a46a-e9e041da8eb3",
|
||||
"name": "Queen",
|
||||
"sort-name": "Queen",
|
||||
"disambiguation": "UK rock group"
|
||||
}
|
||||
}
|
||||
],
|
||||
"release-group": {
|
||||
"id": "69ce61c8-127f-3809-95d8-62fdf3ae1347",
|
||||
"type-id": "dd2a21e1-0c00-3729-a7a0-de60b84eb5d1",
|
||||
"primary-type-id": "f529b476-6e62-324f-b0aa-1f3e33d313fc",
|
||||
"title": "Greatest Hits",
|
||||
"primary-type": "Album",
|
||||
"secondary-types": [
|
||||
"Compilation"
|
||||
],
|
||||
"secondary-type-ids": [
|
||||
"dd2a21e1-0c00-3729-a7a0-de60b84eb5d1"
|
||||
]
|
||||
},
|
||||
"date": "1994",
|
||||
"country": "XE",
|
||||
"release-events": [
|
||||
{
|
||||
"date": "1994",
|
||||
"area": {
|
||||
"id": "89a675c2-3e37-3518-b83c-418bad59a85a",
|
||||
"name": "Europe",
|
||||
"sort-name": "Europe",
|
||||
"iso-3166-1-codes": [
|
||||
"XE"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"barcode": "077778950424",
|
||||
"label-info": [
|
||||
{
|
||||
"catalog-number": "0777 7 89504 2 4",
|
||||
"label": {
|
||||
"id": "df7d1c7f-ef95-425f-8eef-445b3d7bcbd9",
|
||||
"name": "Parlophone"
|
||||
}
|
||||
}
|
||||
],
|
||||
"track-count": 17,
|
||||
"media": [
|
||||
{
|
||||
"format": "CD",
|
||||
"disc-count": 0,
|
||||
"track-count": 17
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "5bf3eba2-f12f-409e-856f-14c0608d96bb",
|
||||
"score": 100,
|
||||
"status-id": "4e304316-386d-3409-af2e-78857eec5cfe",
|
||||
"packaging-id": "ec27701a-4a22-37f4-bfac-6616e0f9750a",
|
||||
"count": 1,
|
||||
"title": "Greatest Hits",
|
||||
"status": "Official",
|
||||
"packaging": "Jewel Case",
|
||||
"text-representation": {
|
||||
"language": "eng",
|
||||
"script": "Latn"
|
||||
},
|
||||
"artist-credit": [
|
||||
{
|
||||
"name": "Queen",
|
||||
"artist": {
|
||||
"id": "0383dadf-2a4e-4d10-a46a-e9e041da8eb3",
|
||||
"name": "Queen",
|
||||
"sort-name": "Queen",
|
||||
"disambiguation": "UK rock group"
|
||||
}
|
||||
}
|
||||
],
|
||||
"release-group": {
|
||||
"id": "69ce61c8-127f-3809-95d8-62fdf3ae1347",
|
||||
"type-id": "dd2a21e1-0c00-3729-a7a0-de60b84eb5d1",
|
||||
"primary-type-id": "f529b476-6e62-324f-b0aa-1f3e33d313fc",
|
||||
"title": "Greatest Hits",
|
||||
"primary-type": "Album",
|
||||
"secondary-types": [
|
||||
"Compilation"
|
||||
],
|
||||
"secondary-type-ids": [
|
||||
"dd2a21e1-0c00-3729-a7a0-de60b84eb5d1"
|
||||
]
|
||||
},
|
||||
"date": "1994",
|
||||
"country": "ZA",
|
||||
"release-events": [
|
||||
{
|
||||
"date": "1994",
|
||||
"area": {
|
||||
"id": "50cc7852-862e-30ae-aa82-385fe7135b7f",
|
||||
"name": "South Africa",
|
||||
"sort-name": "South Africa",
|
||||
"iso-3166-1-codes": [
|
||||
"ZA"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"barcode": "077778950424",
|
||||
"label-info": [
|
||||
{
|
||||
"catalog-number": "CDEMCJ (WF) 5543",
|
||||
"label": {
|
||||
"id": "ee80e50f-a604-465f-bf41-4a46af342beb",
|
||||
"name": "EMI Music South Africa"
|
||||
}
|
||||
}
|
||||
],
|
||||
"track-count": 17,
|
||||
"media": [
|
||||
{
|
||||
"format": "CD",
|
||||
"disc-count": 1,
|
||||
"track-count": 17
|
||||
}
|
||||
],
|
||||
"tags": [
|
||||
{
|
||||
"count": 1,
|
||||
"name": "rock"
|
||||
},
|
||||
{
|
||||
"count": 1,
|
||||
"name": "british"
|
||||
},
|
||||
{
|
||||
"count": 1,
|
||||
"name": "hard rock"
|
||||
},
|
||||
{
|
||||
"count": 1,
|
||||
"name": "glam rock"
|
||||
},
|
||||
{
|
||||
"count": 1,
|
||||
"name": "art rock"
|
||||
},
|
||||
{
|
||||
"count": 1,
|
||||
"name": "pop rock"
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "a23332b3-c5e9-4785-85a6-0e3e12e21404",
|
||||
"score": 100,
|
||||
"status-id": "4e304316-386d-3409-af2e-78857eec5cfe",
|
||||
"packaging-id": "ec27701a-4a22-37f4-bfac-6616e0f9750a",
|
||||
"count": 1,
|
||||
"title": "Greatest Hits",
|
||||
"status": "Official",
|
||||
"packaging": "Jewel Case",
|
||||
"text-representation": {
|
||||
"language": "eng",
|
||||
"script": "Latn"
|
||||
},
|
||||
"artist-credit": [
|
||||
{
|
||||
"name": "Queen",
|
||||
"artist": {
|
||||
"id": "0383dadf-2a4e-4d10-a46a-e9e041da8eb3",
|
||||
"name": "Queen",
|
||||
"sort-name": "Queen",
|
||||
"disambiguation": "UK rock group"
|
||||
}
|
||||
}
|
||||
],
|
||||
"release-group": {
|
||||
"id": "69ce61c8-127f-3809-95d8-62fdf3ae1347",
|
||||
"type-id": "dd2a21e1-0c00-3729-a7a0-de60b84eb5d1",
|
||||
"primary-type-id": "f529b476-6e62-324f-b0aa-1f3e33d313fc",
|
||||
"title": "Greatest Hits",
|
||||
"primary-type": "Album",
|
||||
"secondary-types": [
|
||||
"Compilation"
|
||||
],
|
||||
"secondary-type-ids": [
|
||||
"dd2a21e1-0c00-3729-a7a0-de60b84eb5d1"
|
||||
]
|
||||
},
|
||||
"date": "1994-05-01",
|
||||
"country": "GB",
|
||||
"release-events": [
|
||||
{
|
||||
"date": "1994-05-01",
|
||||
"area": {
|
||||
"id": "8a754a16-0027-3a29-b6d7-2b40ea0481ed",
|
||||
"name": "United Kingdom",
|
||||
"sort-name": "United Kingdom",
|
||||
"iso-3166-1-codes": [
|
||||
"GB"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"barcode": "077778950424",
|
||||
"asin": "B000024A70",
|
||||
"label-info": [
|
||||
{
|
||||
"catalog-number": "CDPCSD 141",
|
||||
"label": {
|
||||
"id": "df7d1c7f-ef95-425f-8eef-445b3d7bcbd9",
|
||||
"name": "Parlophone"
|
||||
}
|
||||
}
|
||||
],
|
||||
"track-count": 17,
|
||||
"media": [
|
||||
{
|
||||
"format": "CD",
|
||||
"disc-count": 2,
|
||||
"track-count": 17
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "84213105-f89d-4243-9b71-c27f1d17598c",
|
||||
"score": 100,
|
||||
"status-id": "4e304316-386d-3409-af2e-78857eec5cfe",
|
||||
"packaging-id": "ec27701a-4a22-37f4-bfac-6616e0f9750a",
|
||||
"count": 1,
|
||||
"title": "Greatest Hits",
|
||||
"status": "Official",
|
||||
"disambiguation": "made in Holland",
|
||||
"packaging": "Jewel Case",
|
||||
"text-representation": {
|
||||
"language": "eng",
|
||||
"script": "Latn"
|
||||
},
|
||||
"artist-credit": [
|
||||
{
|
||||
"name": "Queen",
|
||||
"artist": {
|
||||
"id": "0383dadf-2a4e-4d10-a46a-e9e041da8eb3",
|
||||
"name": "Queen",
|
||||
"sort-name": "Queen",
|
||||
"disambiguation": "UK rock group"
|
||||
}
|
||||
}
|
||||
],
|
||||
"release-group": {
|
||||
"id": "69ce61c8-127f-3809-95d8-62fdf3ae1347",
|
||||
"type-id": "dd2a21e1-0c00-3729-a7a0-de60b84eb5d1",
|
||||
"primary-type-id": "f529b476-6e62-324f-b0aa-1f3e33d313fc",
|
||||
"title": "Greatest Hits",
|
||||
"primary-type": "Album",
|
||||
"secondary-types": [
|
||||
"Compilation"
|
||||
],
|
||||
"secondary-type-ids": [
|
||||
"dd2a21e1-0c00-3729-a7a0-de60b84eb5d1"
|
||||
]
|
||||
},
|
||||
"date": "1994",
|
||||
"country": "XE",
|
||||
"release-events": [
|
||||
{
|
||||
"date": "1994",
|
||||
"area": {
|
||||
"id": "89a675c2-3e37-3518-b83c-418bad59a85a",
|
||||
"name": "Europe",
|
||||
"sort-name": "Europe",
|
||||
"iso-3166-1-codes": [
|
||||
"XE"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"barcode": "077778950424",
|
||||
"asin": "B000024A70",
|
||||
"label-info": [
|
||||
{
|
||||
"catalog-number": "0777 7 89504 2 4",
|
||||
"label": {
|
||||
"id": "df7d1c7f-ef95-425f-8eef-445b3d7bcbd9",
|
||||
"name": "Parlophone"
|
||||
}
|
||||
}
|
||||
],
|
||||
"track-count": 17,
|
||||
"media": [
|
||||
{
|
||||
"format": "CD",
|
||||
"disc-count": 19,
|
||||
"track-count": 17
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "2ba90d62-2ebe-447a-8b0c-8d79827b4972",
|
||||
"score": 100,
|
||||
"status-id": "4e304316-386d-3409-af2e-78857eec5cfe",
|
||||
"packaging-id": "ec27701a-4a22-37f4-bfac-6616e0f9750a",
|
||||
"count": 1,
|
||||
"title": "Greatest Hits",
|
||||
"status": "Official",
|
||||
"disambiguation": "made in Italy",
|
||||
"packaging": "Jewel Case",
|
||||
"text-representation": {
|
||||
"language": "eng",
|
||||
"script": "Latn"
|
||||
},
|
||||
"artist-credit": [
|
||||
{
|
||||
"name": "Queen",
|
||||
"artist": {
|
||||
"id": "0383dadf-2a4e-4d10-a46a-e9e041da8eb3",
|
||||
"name": "Queen",
|
||||
"sort-name": "Queen",
|
||||
"disambiguation": "UK rock group"
|
||||
}
|
||||
}
|
||||
],
|
||||
"release-group": {
|
||||
"id": "69ce61c8-127f-3809-95d8-62fdf3ae1347",
|
||||
"type-id": "dd2a21e1-0c00-3729-a7a0-de60b84eb5d1",
|
||||
"primary-type-id": "f529b476-6e62-324f-b0aa-1f3e33d313fc",
|
||||
"title": "Greatest Hits",
|
||||
"primary-type": "Album",
|
||||
"secondary-types": [
|
||||
"Compilation"
|
||||
],
|
||||
"secondary-type-ids": [
|
||||
"dd2a21e1-0c00-3729-a7a0-de60b84eb5d1"
|
||||
]
|
||||
},
|
||||
"date": "1994",
|
||||
"country": "XE",
|
||||
"release-events": [
|
||||
{
|
||||
"date": "1994",
|
||||
"area": {
|
||||
"id": "89a675c2-3e37-3518-b83c-418bad59a85a",
|
||||
"name": "Europe",
|
||||
"sort-name": "Europe",
|
||||
"iso-3166-1-codes": [
|
||||
"XE"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"barcode": "077778950424",
|
||||
"label-info": [
|
||||
{
|
||||
"catalog-number": "0777 7 89504 2 4",
|
||||
"label": {
|
||||
"id": "df7d1c7f-ef95-425f-8eef-445b3d7bcbd9",
|
||||
"name": "Parlophone"
|
||||
}
|
||||
}
|
||||
],
|
||||
"track-count": 17,
|
||||
"media": [
|
||||
{
|
||||
"format": "CD",
|
||||
"disc-count": 1,
|
||||
"track-count": 17
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "aba1cf59-e390-4279-b4a4-ad7bd1f7ab28",
|
||||
"score": 100,
|
||||
"status-id": "4e304316-386d-3409-af2e-78857eec5cfe",
|
||||
"packaging-id": "ec27701a-4a22-37f4-bfac-6616e0f9750a",
|
||||
"count": 1,
|
||||
"title": "Greatest Hits",
|
||||
"status": "Official",
|
||||
"disambiguation": "D.A.T.A. Pressing",
|
||||
"packaging": "Jewel Case",
|
||||
"text-representation": {
|
||||
"language": "eng",
|
||||
"script": "Latn"
|
||||
},
|
||||
"artist-credit": [
|
||||
{
|
||||
"name": "Queen",
|
||||
"artist": {
|
||||
"id": "0383dadf-2a4e-4d10-a46a-e9e041da8eb3",
|
||||
"name": "Queen",
|
||||
"sort-name": "Queen",
|
||||
"disambiguation": "UK rock group"
|
||||
}
|
||||
}
|
||||
],
|
||||
"release-group": {
|
||||
"id": "69ce61c8-127f-3809-95d8-62fdf3ae1347",
|
||||
"type-id": "dd2a21e1-0c00-3729-a7a0-de60b84eb5d1",
|
||||
"primary-type-id": "f529b476-6e62-324f-b0aa-1f3e33d313fc",
|
||||
"title": "Greatest Hits",
|
||||
"primary-type": "Album",
|
||||
"secondary-types": [
|
||||
"Compilation"
|
||||
],
|
||||
"secondary-type-ids": [
|
||||
"dd2a21e1-0c00-3729-a7a0-de60b84eb5d1"
|
||||
]
|
||||
},
|
||||
"date": "1994",
|
||||
"country": "AU",
|
||||
"release-events": [
|
||||
{
|
||||
"date": "1994",
|
||||
"area": {
|
||||
"id": "106e0bec-b638-3b37-b731-f53d507dc00e",
|
||||
"name": "Australia",
|
||||
"sort-name": "Australia",
|
||||
"iso-3166-1-codes": [
|
||||
"AU"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"barcode": "077778950424",
|
||||
"label-info": [
|
||||
{
|
||||
"catalog-number": "0777 7 89504 2 4",
|
||||
"label": {
|
||||
"id": "df7d1c7f-ef95-425f-8eef-445b3d7bcbd9",
|
||||
"name": "Parlophone"
|
||||
}
|
||||
}
|
||||
],
|
||||
"track-count": 17,
|
||||
"media": [
|
||||
{
|
||||
"format": "CD",
|
||||
"disc-count": 1,
|
||||
"track-count": 17
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "87f214f5-39bf-3341-848a-547697d02474",
|
||||
"score": 100,
|
||||
"status-id": "4e304316-386d-3409-af2e-78857eec5cfe",
|
||||
"count": 1,
|
||||
"title": "Greatest Hits",
|
||||
"status": "Official",
|
||||
"text-representation": {
|
||||
"language": "eng",
|
||||
"script": "Latn"
|
||||
},
|
||||
"artist-credit": [
|
||||
{
|
||||
"name": "Queen",
|
||||
"artist": {
|
||||
"id": "0383dadf-2a4e-4d10-a46a-e9e041da8eb3",
|
||||
"name": "Queen",
|
||||
"sort-name": "Queen",
|
||||
"disambiguation": "UK rock group"
|
||||
}
|
||||
}
|
||||
],
|
||||
"release-group": {
|
||||
"id": "69ce61c8-127f-3809-95d8-62fdf3ae1347",
|
||||
"type-id": "dd2a21e1-0c00-3729-a7a0-de60b84eb5d1",
|
||||
"primary-type-id": "f529b476-6e62-324f-b0aa-1f3e33d313fc",
|
||||
"title": "Greatest Hits",
|
||||
"primary-type": "Album",
|
||||
"secondary-types": [
|
||||
"Compilation"
|
||||
],
|
||||
"secondary-type-ids": [
|
||||
"dd2a21e1-0c00-3729-a7a0-de60b84eb5d1"
|
||||
]
|
||||
},
|
||||
"date": "1994",
|
||||
"country": "MX",
|
||||
"release-events": [
|
||||
{
|
||||
"date": "1994",
|
||||
"area": {
|
||||
"id": "3e08b2cd-69f3-317c-b1e4-e71be581839e",
|
||||
"name": "Mexico",
|
||||
"sort-name": "Mexico",
|
||||
"iso-3166-1-codes": [
|
||||
"MX"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"barcode": "077778950424",
|
||||
"asin": "B000024A70",
|
||||
"label-info": [
|
||||
{
|
||||
"catalog-number": "0777 7 89504 2 4",
|
||||
"label": {
|
||||
"id": "df7d1c7f-ef95-425f-8eef-445b3d7bcbd9",
|
||||
"name": "Parlophone"
|
||||
}
|
||||
}
|
||||
],
|
||||
"track-count": 17,
|
||||
"media": [
|
||||
{
|
||||
"format": "CD",
|
||||
"disc-count": 19,
|
||||
"track-count": 17
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "92ff5ffc-2bb6-4eff-afa6-4d2d819fd10e",
|
||||
"score": 100,
|
||||
"status-id": "4e304316-386d-3409-af2e-78857eec5cfe",
|
||||
"packaging-id": "ec27701a-4a22-37f4-bfac-6616e0f9750a",
|
||||
"count": 1,
|
||||
"title": "Greatest Hits",
|
||||
"status": "Official",
|
||||
"disambiguation": "Regency Media pressing IFPI 6Z08",
|
||||
"packaging": "Jewel Case",
|
||||
"text-representation": {
|
||||
"language": "eng",
|
||||
"script": "Latn"
|
||||
},
|
||||
"artist-credit": [
|
||||
{
|
||||
"name": "Queen",
|
||||
"artist": {
|
||||
"id": "0383dadf-2a4e-4d10-a46a-e9e041da8eb3",
|
||||
"name": "Queen",
|
||||
"sort-name": "Queen",
|
||||
"disambiguation": "UK rock group"
|
||||
}
|
||||
}
|
||||
],
|
||||
"release-group": {
|
||||
"id": "69ce61c8-127f-3809-95d8-62fdf3ae1347",
|
||||
"type-id": "dd2a21e1-0c00-3729-a7a0-de60b84eb5d1",
|
||||
"primary-type-id": "f529b476-6e62-324f-b0aa-1f3e33d313fc",
|
||||
"title": "Greatest Hits",
|
||||
"primary-type": "Album",
|
||||
"secondary-types": [
|
||||
"Compilation"
|
||||
],
|
||||
"secondary-type-ids": [
|
||||
"dd2a21e1-0c00-3729-a7a0-de60b84eb5d1"
|
||||
]
|
||||
},
|
||||
"date": "2008",
|
||||
"country": "AU",
|
||||
"release-events": [
|
||||
{
|
||||
"date": "2008",
|
||||
"area": {
|
||||
"id": "106e0bec-b638-3b37-b731-f53d507dc00e",
|
||||
"name": "Australia",
|
||||
"sort-name": "Australia",
|
||||
"iso-3166-1-codes": [
|
||||
"AU"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"barcode": "077778950424",
|
||||
"label-info": [
|
||||
{
|
||||
"catalog-number": "0777 7 89504 2 4",
|
||||
"label": {
|
||||
"id": "df7d1c7f-ef95-425f-8eef-445b3d7bcbd9",
|
||||
"name": "Parlophone"
|
||||
}
|
||||
}
|
||||
],
|
||||
"track-count": 17,
|
||||
"media": [
|
||||
{
|
||||
"format": "CD",
|
||||
"disc-count": 1,
|
||||
"track-count": 17
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "f67a1e58-693b-4c64-8acd-93aaefb1345f",
|
||||
"score": 100,
|
||||
"status-id": "4e304316-386d-3409-af2e-78857eec5cfe",
|
||||
"packaging-id": "ec27701a-4a22-37f4-bfac-6616e0f9750a",
|
||||
"count": 1,
|
||||
"title": "Greatest Hits",
|
||||
"status": "Official",
|
||||
"disambiguation": "SM Pressing",
|
||||
"packaging": "Jewel Case",
|
||||
"text-representation": {
|
||||
"language": "eng",
|
||||
"script": "Latn"
|
||||
},
|
||||
"artist-credit": [
|
||||
{
|
||||
"name": "Queen",
|
||||
"artist": {
|
||||
"id": "0383dadf-2a4e-4d10-a46a-e9e041da8eb3",
|
||||
"name": "Queen",
|
||||
"sort-name": "Queen",
|
||||
"disambiguation": "UK rock group"
|
||||
}
|
||||
}
|
||||
],
|
||||
"release-group": {
|
||||
"id": "69ce61c8-127f-3809-95d8-62fdf3ae1347",
|
||||
"type-id": "dd2a21e1-0c00-3729-a7a0-de60b84eb5d1",
|
||||
"primary-type-id": "f529b476-6e62-324f-b0aa-1f3e33d313fc",
|
||||
"title": "Greatest Hits",
|
||||
"primary-type": "Album",
|
||||
"secondary-types": [
|
||||
"Compilation"
|
||||
],
|
||||
"secondary-type-ids": [
|
||||
"dd2a21e1-0c00-3729-a7a0-de60b84eb5d1"
|
||||
]
|
||||
},
|
||||
"date": "1994",
|
||||
"country": "AU",
|
||||
"release-events": [
|
||||
{
|
||||
"date": "1994",
|
||||
"area": {
|
||||
"id": "106e0bec-b638-3b37-b731-f53d507dc00e",
|
||||
"name": "Australia",
|
||||
"sort-name": "Australia",
|
||||
"iso-3166-1-codes": [
|
||||
"AU"
|
||||
]
|
||||
}
|
||||
}
|
||||
],
|
||||
"barcode": "077778950424",
|
||||
"label-info": [
|
||||
{
|
||||
"catalog-number": "0777 7 89504 2 4",
|
||||
"label": {
|
||||
"id": "df7d1c7f-ef95-425f-8eef-445b3d7bcbd9",
|
||||
"name": "Parlophone"
|
||||
}
|
||||
}
|
||||
],
|
||||
"track-count": 17,
|
||||
"media": [
|
||||
{
|
||||
"format": "CD",
|
||||
"disc-count": 1,
|
||||
"track-count": 17
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user