Browse Source

adding rating select

master
rosh 4 years ago
parent
commit
6e9fe20928
  1. 13
      react/src/pages/Movie.js

13
react/src/pages/Movie.js

@ -49,6 +49,19 @@ function Movie(props) {
].map(value => { ].map(value => {
return <div key={value}>{value}</div>; return <div key={value}>{value}</div>;
})} })}
<div>
Rating
<select>
{["Select",1,2,3,4,5,6,7,8,9,10].map(r=> (
<option value={String(r)}
selected={
movie.rating === String(r) ? true : false
}>
{r}
</option>
))}
</select>
</div>
</div> </div>
); );
} }

Loading…
Cancel
Save