Toggle navigation
Toggle navigation
This project
Loading...
Sign in
2020-1-capstone-design1
/
PKH_Project1
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
2
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
Yoonjunhyeon
2020-05-03 19:57:26 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
71b26994550dca44f61b47bf22c5f487e740f0cd
71b26994
1 parent
12b6dad9
자동화 부분 수정 (자동화 미완성...)
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
31 additions
and
28 deletions
web/backend/init
web/backend/init(not yet) → web/backend/initrun
web/backend/run
web/backend/templates/index.html
web/backend/vue2djangoTemplate.py
web/backend/init
View file @
71b2699
#!/bin/bash
cd
../frontend
npm install
npm run build
cd
../backend
. env/bin/activate
pip install -r requirements.txt
rm -rf static
./manage.py collectstatic
rm -rf static/admin
rm -rf static/rest_framework
python manage.py makemigrations
python manage.py migrate
python manage.py runserver 0.0.0.0:8000
\ No newline at end of file
# python vue2djangoTemplate.py (자동화 - 작성예정, 어캐함??ㅠ)
# 현재 vue index를 django template으로 자동화 하는 코드를 작성하지 못하여,
# 수동으로 바꿔야 합니다.
# 이 스크립트를 실행 후에 생기는 static/index.html의
# href, src 링크를 templates/index.html의 href, src로 변경하면 정상적으로 작동합니다.
\ No newline at end of file
...
...
web/backend/init
(not yet)
→
web/backend/init
run
View file @
71b2699
#!/bin/bash
cd
../frontend
npm install
npm run build
cd
../backend
. env/bin/activate
pip install -r requirements.txt
rm -rf static
./manage.py collectstatic
rm -rf static/admin
rm -rf static/rest_framework
python vue2djangoTemplate.py
\ No newline at end of file
python manage.py makemigrations
python manage.py migrate
python vue2djangoTemplate.py
python manage.py runserver 0.0.0.0:8000
\ No newline at end of file
...
...
web/backend/run
View file @
71b2699
#!/bin/bash
. env/bin/activate
python manage.py migrate
python manage.py runserver 0.0.0.0:8000
\ No newline at end of file
...
...
web/backend/templates/index.html
View file @
71b2699
...
...
@@ -25,30 +25,4 @@
<script
src=
"{% static '/js/app.a2bbd68a.js' %}"
></script>
</body>
</html>
<!DOCTYPE html>
<html
lang=
en
>
<head>
<meta
charset=
utf-8
>
<meta
http-equiv=
X-UA-Compatible
content=
"IE=edge"
>
<meta
name=
viewport
content=
"width=device-width,initial-scale=1"
>
<link
rel=
icon
href=
/favicon.ico
>
<title>
Profit-Hunter
</title>
<link
href=
/css/app.1dc1d4aa.css
rel=
preload
as=
style
>
<link
href=
/css/chunk-vendors.abb36e73.css
rel=
preload
as=
style
>
<link
href=
/js/app.a2bbd68a.js
rel=
preload
as=
script
>
<link
href=
/js/chunk-vendors.c489da91.js
rel=
preload
as=
script
>
<link
href=
/css/chunk-vendors.abb36e73.css
rel=
stylesheet
>
<link
href=
/css/app.1dc1d4aa.css
rel=
stylesheet
>
</head>
<body><noscript><strong>
We're sorry but front doesn't work properly without JavaScript enabled. Please enable it to
continue.
</strong></noscript>
<div
id=
app
></div>
<script
src=
/js/chunk-vendors.c489da91.js
></script>
<script
src=
/js/app.a2bbd68a.js
></script>
</body>
</html>
\ No newline at end of file
...
...
web/backend/vue2djangoTemplate.py
View file @
71b2699
import
os
read
=
open
(
"static/index.html"
,
'r'
)
write
=
open
(
"templates/index.html"
,
'w'
)
...
...
Please
register
or
login
to post a comment