adding release year

This commit is contained in:
2026-07-17 20:36:54 -06:00
parent 4501133b5c
commit 111c107474
2 changed files with 17 additions and 1 deletions
+1
View File
@@ -17,6 +17,7 @@ type Ranking struct {
type Movie struct { type Movie struct {
ID bson.ObjectID `bson:"_id" json:"_id"` ID bson.ObjectID `bson:"_id" json:"_id"`
ImdbID string `bson:"imdb_id" json:"imdb_id" validate:"required"` ImdbID string `bson:"imdb_id" json:"imdb_id" validate:"required"`
ReleaseYear int `bson:"release_year" json:"release_year" validate:"required"` // how to get this to be a numeric value that is four digits starting with 19?
Title string `bson:"title" json:"title" validate:"required,min=2,max=500"` Title string `bson:"title" json:"title" validate:"required,min=2,max=500"`
PosterPath string `bson:"poster_path" json:"poster_path" validate:"required,url"` PosterPath string `bson:"poster_path" json:"poster_path" validate:"required,url"`
YoutubeId string `bson:"youtube_id" json:"youtube_id" validate:"required"` YoutubeId string `bson:"youtube_id" json:"youtube_id" validate:"required"`
+15
View File
@@ -2,6 +2,7 @@
{ {
"imdb_id": "tt0111161", "imdb_id": "tt0111161",
"title": "The Shawshank Redemption", "title": "The Shawshank Redemption",
"release_year": 1994,
"poster_path": "https://image.tmdb.org/t/p/w300/2GgerXCbCMgvt2kLwWEmJWCSG65.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/2GgerXCbCMgvt2kLwWEmJWCSG65.jpg",
"youtube_id": "PLl99DlL6b4", "youtube_id": "PLl99DlL6b4",
"genre": [ "genre": [
@@ -19,6 +20,7 @@
{ {
"imdb_id": "tt7131622", "imdb_id": "tt7131622",
"title": "Once upon a time in Hollywood", "title": "Once upon a time in Hollywood",
"release_year": 2019,
"poster_path": "https://image.tmdb.org/t/p/w300/wQKeS2JrsRF8XSfd9zqflrc5gad.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/wQKeS2JrsRF8XSfd9zqflrc5gad.jpg",
"youtube_id": "ELeMaP8EPAA", "youtube_id": "ELeMaP8EPAA",
"genre": [ "genre": [
@@ -40,6 +42,7 @@
{ {
"imdb_id": "tt0080339", "imdb_id": "tt0080339",
"title": "Airplane!", "title": "Airplane!",
"release_year": 1980,
"poster_path": "https://image.tmdb.org/t/p/w300/zOiB3p2WTTiwCFgTMnXuDGgzbTN.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/zOiB3p2WTTiwCFgTMnXuDGgzbTN.jpg",
"youtube_id": "07pPmCfKi3U", "youtube_id": "07pPmCfKi3U",
"genre": [ "genre": [
@@ -57,6 +60,7 @@
{ {
"imdb_id": "tt1119646", "imdb_id": "tt1119646",
"title": "The Hangover", "title": "The Hangover",
"release_year": 2009,
"poster_path": "https://image.tmdb.org/t/p/w300/c15rH9S5JN83UXqu9iM4TQsW6Rl.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/c15rH9S5JN83UXqu9iM4TQsW6Rl.jpg",
"youtube_id": "jj6wcUes1no", "youtube_id": "jj6wcUes1no",
"genre": [ "genre": [
@@ -74,6 +78,7 @@
{ {
"imdb_id": "tt0109040", "imdb_id": "tt0109040",
"title": "Ace Ventura: Pet Detective", "title": "Ace Ventura: Pet Detective",
"release_year": 1994,
"poster_path": "https://image.tmdb.org/t/p/w300/dukxJWd72ffNWfqfFSVFFuym4RG.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/dukxJWd72ffNWfqfFSVFFuym4RG.jpg",
"youtube_id": "qjBb1CKLpzE", "youtube_id": "qjBb1CKLpzE",
"genre": [ "genre": [
@@ -91,6 +96,7 @@
{ {
"imdb_id": "tt0105695", "imdb_id": "tt0105695",
"title": "Unforgiven", "title": "Unforgiven",
"release_year": 1992,
"poster_path": "https://image.tmdb.org/t/p/w300/7W0CsZBe5fkX29DvHBi5Ct1WqLe.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/7W0CsZBe5fkX29DvHBi5Ct1WqLe.jpg",
"youtube_id": "6_UlfsdGiEc", "youtube_id": "6_UlfsdGiEc",
"genre": [ "genre": [
@@ -112,6 +118,7 @@
{ {
"imdb_id": "tt0060196", "imdb_id": "tt0060196",
"title": "The Good, The Bad, and the Ugly", "title": "The Good, The Bad, and the Ugly",
"release_year": 1966,
"poster_path": "https://image.tmdb.org/t/p/w300/e881nA7p982CHL5GjI1LICwHMd7.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/e881nA7p982CHL5GjI1LICwHMd7.jpg",
"youtube_id": "WCN5JJY_wiA", "youtube_id": "WCN5JJY_wiA",
"genre": [ "genre": [
@@ -129,6 +136,7 @@
{ {
"imdb_id": "tt0903624", "imdb_id": "tt0903624",
"title": "The Hobbit: An Unexpected Journey", "title": "The Hobbit: An Unexpected Journey",
"release_year": 2012,
"poster_path": "https://image.tmdb.org/t/p/w300/vdAGcr1F6wJPRryeODVAcy2mU4z.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/vdAGcr1F6wJPRryeODVAcy2mU4z.jpg",
"youtube_id": "9PSXjr1gbjc", "youtube_id": "9PSXjr1gbjc",
"genre": [ "genre": [
@@ -146,6 +154,7 @@
{ {
"imdb_id": "tt0241527", "imdb_id": "tt0241527",
"title": "Harry Potter and the Philosopher's Stone", "title": "Harry Potter and the Philosopher's Stone",
"release_year": 2001,
"poster_path": "https://image.tmdb.org/t/p/w300/e6JYlushXIXK85JGfDHEFHrrNYK.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/e6JYlushXIXK85JGfDHEFHrrNYK.jpg",
"youtube_id": "VyHV0BRtdxo", "youtube_id": "VyHV0BRtdxo",
"genre": [ "genre": [
@@ -163,6 +172,7 @@
{ {
"imdb_id": "tt2267998", "imdb_id": "tt2267998",
"title": "Gone Girl", "title": "Gone Girl",
"release_year": 2014,
"poster_path": "https://image.tmdb.org/t/p/w300/xpA0q0DJWKe7AY63pVPZbGLwuo5.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/xpA0q0DJWKe7AY63pVPZbGLwuo5.jpg",
"youtube_id": "2-_-1nJf8Vg", "youtube_id": "2-_-1nJf8Vg",
"genre": [ "genre": [
@@ -184,6 +194,7 @@
{ {
"imdb_id": "tt8946378", "imdb_id": "tt8946378",
"title": "Knives Out", "title": "Knives Out",
"release_year": 2019,
"poster_path": "https://image.tmdb.org/t/p/w300/hVcCOlHU0HmGBBQNmS9RlalBXGz.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/hVcCOlHU0HmGBBQNmS9RlalBXGz.jpg",
"youtube_id": "qGqiHJTsRkQ", "youtube_id": "qGqiHJTsRkQ",
"genre": [ "genre": [
@@ -209,6 +220,7 @@
{ {
"imdb_id": "tt0080684", "imdb_id": "tt0080684",
"title": "Star Wars: The Empire Strikes Back", "title": "Star Wars: The Empire Strikes Back",
"release_year": 1980,
"poster_path": "https://image.tmdb.org/t/p/w300/1mh82R1qLKwdutQVGnpHItdwPCP.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/1mh82R1qLKwdutQVGnpHItdwPCP.jpg",
"youtube_id": "JNwNXF9Y6kY", "youtube_id": "JNwNXF9Y6kY",
"genre": [ "genre": [
@@ -230,6 +242,7 @@
{ {
"imdb_id": "tt0102975", "imdb_id": "tt0102975",
"title": "Star Trek: The Undiscovered Country", "title": "Star Trek: The Undiscovered Country",
"release_year": 1991,
"poster_path": "https://image.tmdb.org/t/p/w300/jukY1tFpuXgqrJLl1PvdOMarCvN.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/jukY1tFpuXgqrJLl1PvdOMarCvN.jpg",
"youtube_id": "RYA2q2Sm_Jo", "youtube_id": "RYA2q2Sm_Jo",
"genre": [ "genre": [
@@ -251,6 +264,7 @@
{ {
"imdb_id": "tt1297919", "imdb_id": "tt1297919",
"title": "Blitz", "title": "Blitz",
"release_year": 2011,
"poster_path": "https://image.tmdb.org/t/p/w300/tI4fPu0LZ0FNdZdi6fvYGCRiuQs.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/tI4fPu0LZ0FNdZdi6fvYGCRiuQs.jpg",
"youtube_id": "mhO2WJ3MNRI", "youtube_id": "mhO2WJ3MNRI",
"genre": [ "genre": [
@@ -276,6 +290,7 @@
{ {
"imdb_id": "tt0790724", "imdb_id": "tt0790724",
"title": "Jack Reacher", "title": "Jack Reacher",
"release_year": 2012,
"poster_path": "https://image.tmdb.org/t/p/w300/8sih1uieUopA9zrEO1meNhmm7aO.jpg", "poster_path": "https://image.tmdb.org/t/p/w300/8sih1uieUopA9zrEO1meNhmm7aO.jpg",
"youtube_id": "A7FiWkyevqY", "youtube_id": "A7FiWkyevqY",
"genre": [ "genre": [