yevgnenll / art_archive_flask Goto Github PK
View Code? Open in Web Editor NEWiOS 스쿨을 위한 api 설계
iOS 스쿨을 위한 api 설계
flask에 관련된 모든 setting은 pip로 해결할 수 있음
s3는 사용하지 않는걸로..
요청사항에 따라 user_id 를 입력받을 컬럼을 새로 만들었음
이제는 post, get 등에서 user_id와 관련된 값이 나오도록
로직을 수정해야함
pillow를 이용해서 섬네일 이미지 만들기
-[ ]: user_id 기준으로 list를 보여줌 user_id = 1이면 1이 올린 데이터만 나오도록
-[ ]: pagination 아예 없애도록 -> user_id에 해당하는 데이터 다 보여주기
-[ ]: title, image_url, user_id 로 post, get 되도록 수정
ios 스쿨이 초보자를 숙련자로 이끄는 과정이니 만큼 아직은 join과 FK에 대한
개념은 고려하지 않는것으로 요청됨
따라서 Artist 테이블을 삭제하고
해당 테이블에 있던 artist name을 모두 images 테이블로 옮김
insert into masterpiece (id, image_url, title, year, artist_name, user_id, description)
select i.id, i.image_url, i.title, i.year, a.name as artist_name, i.user_id, i.description from images as i
join artists as a
on i.`artist_id` = a.id
해당 쿼리
먼저 masterpiece라는 테이블로 옮기고 다른 테이블을 삭제한 뒤 images로 이름은 변경함
그런데 문서를 읽다 보면 slack에서는 user_id가 알파벳을 포함한 언어였지만
문서에서는 숫자로 구분됨 -> 이 부분을 정확하게 확인하고 필요하면 수정할것
sudo service nginx start | stop | restart
uwsgi archive.ini --enable-threads
Pillow build essential
$ sudo apt-get install libtiff5-dev libjpeg8-dev zlib1g-dev \
libfreetype6-dev liblcms2-dev libwebp-dev tcl8.6-dev tk8.6-dev python-tk
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.