sosow0212
@sosow0212
Reviews Written
2
Average Rating
5.0
Posts
Q&A
๋ค๋๋ค์์ member ?์ ๋ํ prodct ๋ฆฌ์คํธ ์กฐํ ๋ฐฉ๋ฒ
Member ์ Product ๊ฐ์ฒด ์ฌ์ด์ Link ๋ผ๋ ํ ์ด๋ธ์ ๋ง๋ค์ด์ ์ผ๋๋ค + ๋ค๋์ผ ๋ฐฉ์์ผ๋ก ๊ด๊ณ๋ฅผ ๋งบ์ด์ฃผ๊ณ , ํ์ํ ๋์๋ JPA ๋ฅผ ํตํด์ findByMemberAndProduct(Member member, Product product) ์ด๋ฐ์์ผ๋ก Link ํ ์ด๋ธ์ ๋ถ๋ฌ์ Link.product ๋ฆฌ์คํธ๋ฅผ ์กฐํํ ์ ์์๊ฒ๋๋ค! ์ด๊ฒ ๋ฐ๋ฅธ ๋ฐฉ๋ฒ์ธ์ง๋ ์ ๋ ์ ํํ๋ ๋ชจ๋ฅด๊ฒ ์ด์ ์กฐ์ธ ์ป๊ณ ์ถ์ต๋๋ค^^
- 0
- 2
- 388
Q&A
์ค๋ฅ๊ฐ ๋น๋๋ค..
์ค๋ฅ ํด๊ฒฐํ์ต๋๋ค.. ์ ๊ฐ html ํ์ผ ์์ ์ฃผ์์ ์ฌ์ฉ ํ๋๋ฐ, ์ง์ฐ๋ ํด๊ฒฐ ๋์ต๋๋ค!
- 0
- 1
- 432
Q&A
์ ์๋ ์ง๋ฌธ์ด ์์ต๋๋ค.
ํด๊ฒฐํ์ต๋๋ค. ์ ๋ ๊ฐ์ ์ค๋ฅ๊ฐ ๋์ ๋ถ๋ค์ LandingPage.js ์์ fetch(endpoint) .then~~~ ๋ถ๋ถ์์ setMovies(...[response.results]); setMainMovieImage(...[response.results[0]]); ๋ก ๋ฐ๊พธ์๋ฉด ํด๊ฒฐ ๋ฉ๋๋ค.
- 1
- 1
- 258
Q&A
npm run dev ๋ช ๋ น์ด ์ค๋ฅ
import React, { useEffect, useState } from 'react'; import { FaCode } from "react-icons/fa"; import { API_URL, API_KEY, IMAGE_BASE_URL } from '../../Config'; import MainImage from './Sections/MainImage'; // npm run dev function LandingPage() { const [Movies, setMovies] = useState([]) const [MainMovieImage, setMainMovieImage] = useState(null) useEffect(() => { const endpoint = `${API_URL}movie/popular?api_key=${API_KEY}&language=en-US&page=1`; fetch(endpoint) .then(response => response.json()) .then(response => { console.log(response) setMovies([response.results]) setMainMovieImage([response.results[0]]) }) }, []) return ( div style={{ width: '100%', margin: '0' }}> {/* Main Image */} {MainMovieImage && MainImage image={`${IMAGE_BASE_URL}w1280${MainMovieImage.backdrop_path}`} title={MainMovieImage.original_title} text={MainMovieImage.overview} /> } div style={{ width: '85%', margin: '1rem auto' }}> h2>Movies by latesth2> hr /> {/* Movie Grid Cards */} div> div style={{ display: 'flex', justifyContent: 'center' }}> button>Load Morebutton> div> div> ) } export default LandingPage ๊ฒฐ๊ณผ ์ถ๋ ฅ์ด ์ ๋ผ์ ใ ใ
- 2
- 3
- 585




