Toggle navigation
Toggle navigation
This project
Loading...
Sign in
open-source-group1
/
animal-Info
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
Eunsu486
2021-05-31 02:42:49 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
12fd4b61fb0ce9a611c0060bf6cd56e8db12101a
12fd4b61
1 parent
225b3b07
Modifying for merging with eunsuu
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
48 additions
and
39 deletions
app.js
routes/vendors.js
views/index.ejs
views/results/appliance.ejs
views/results/medicine.ejs
views/results/park.ejs
views/results/protection.ejs
app.js
View file @
12fd4b6
...
...
@@ -3,49 +3,36 @@ var express = require('express');
var
path
=
require
(
'path'
);
var
cookieParser
=
require
(
'cookie-parser'
);
var
logger
=
require
(
'morgan'
);
var
indexRouter
=
require
(
'./routes/index'
);
var
usersRouter
=
require
(
'./routes/users'
);
var
categoryRouter
=
require
(
'./routes/category'
);
var
vendorRounter
=
require
(
'./routes/vendors'
);
var
app
=
express
();
var
bodyParser
=
require
(
'body-parser'
);
// view engine setup
app
.
set
(
'views'
,
path
.
join
(
__dirname
,
'views'
));
app
.
set
(
'view engine'
,
'ejs'
);
app
.
use
(
logger
(
'dev'
));
app
.
use
(
express
.
json
());
app
.
use
(
express
.
urlencoded
({
extended
:
false
}));
app
.
use
(
cookieParser
());
app
.
use
(
express
.
static
(
path
.
join
(
__dirname
,
'public'
)));
app
.
use
(
'/'
,
indexRouter
);
app
.
use
(
'/users'
,
usersRouter
);
app
.
use
(
'/category'
,
categoryRouter
);
app
.
use
(
'/vendors/bootstrap'
,
express
.
static
(
path
.
join
(
__dirname
,
"./node_modules/bootstrap/dist"
)));
app
.
use
(
bodyParser
.
urlencoded
({
extended
:
false
}));
// catch 404 and forward to error handler
app
.
use
(
function
(
req
,
res
,
next
)
{
next
(
createError
(
404
));
});
app
.
use
(
'/category'
,
categoryRouter
);
app
.
use
(
'/vendors/bootstrap'
,
express
.
static
(
path
.
join
(
__dirname
,
"./node_modules/bootstrap/dist"
)));
app
.
use
(
bodyParser
.
urlencoded
({
extended
:
false
}));
// error handler
app
.
use
(
function
(
err
,
req
,
res
,
next
)
{
// set locals, only providing error in development
res
.
locals
.
message
=
err
.
message
;
res
.
locals
.
error
=
req
.
app
.
get
(
'env'
)
===
'development'
?
err
:
{};
// render the error page
res
.
status
(
err
.
status
||
500
);
res
.
render
(
'error'
);
});
module
.
exports
=
app
;
module
.
exports
=
app
;
\ No newline at end of file
...
...
routes/vendors.js
View file @
12fd4b6
...
...
@@ -2,3 +2,4 @@ var express = require('express');
var
router
=
express
.
Router
();
var
path
=
require
(
'path'
);
router
.
use
(
'/bootstrap'
,
express
.
static
(
path
.
join
(
__dirname
,
"../node_modules/bootstrap/dist"
)));
module
.
exports
=
router
;
\ No newline at end of file
...
...
views/index.ejs
View file @
12fd4b6
...
...
@@ -94,8 +94,31 @@
<form
action=
"/category/park"
method=
"post"
name=
"location"
id=
"location"
>
<select
onchange=
"sm()"
name=
"user_gu"
id=
"user_gu_select"
>
<option
value=
''
selected=
"true"
disabled=
"true"
>
--Please choose an option--
</option>
<option
value=
'금천구'
>
금천구
</option>
<option
value=
'강남구'
>
강남구
</option>
<option
value=
'강동구'
>
강동구
</option>
<option
value=
'강북구'
>
강북구
</option>
<option
value=
'강서구'
>
강서구
</option>
<option
value=
'관악구'
>
관악구
</option>
<option
value=
'광진구'
>
광진구
</option>
<option
value=
'구로구'
>
구로구
</option>
<option
value=
'금천구'
>
금천구
</option>
<option
value=
'노원구'
>
노원구
</option>
<option
value=
'도봉구'
>
도봉구
</option>
<option
value=
'동대문구'
>
동대문구
</option>
<option
value=
'동작구'
>
동작구
</option>
<option
value=
'마포구'
>
마포구
</option>
<option
value=
'서대문구'
>
서대문구
</option>
<option
value=
'서초구'
>
서초구
</option>
<option
value=
'성동구'
>
성동구
</option>
<option
value=
'성북구'
>
성북구
</option>
<option
value=
'송파구'
>
송파구
</option>
<option
value=
'양천구'
>
양천구
</option>
<option
value=
'영등포구'
>
영등포구
</option>
<option
value=
'용산구'
>
용산구
</option>
<option
value=
'은평구'
>
은평구
</option>
<option
value=
'종로구'
>
종로구
</option>
<option
value=
'중구'
>
중구
</option>
<option
value=
'중랑구'
>
중랑구
</option>
</select>
</form>
...
...
views/results/appliance.ejs
View file @
12fd4b6
it's appliance page
\ No newline at end of file
<h4>동물의료기기 판매 및 임대업체 현황</h4>
<table class="table">
<thead class="thead-dark">
<tr>
<th>이름</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<%=titles%>
</td>
</tr>
</tbody>
</table>
<p class="sum">총 개수 :
<%=appliance_list.length%>
</p>
\ No newline at end of file
...
...
views/results/medicine.ejs
View file @
12fd4b6
...
...
@@ -8,7 +8,7 @@
<tbody>
<tr>
<td>
<%=titles%>
</td>
</tr>
...
...
@@ -16,5 +16,5 @@
</tbody>
</table>
<p class="sum">총 동물약국 개수 :
<%-medicine_list.length%>
</p>
\ No newline at end of file
...
...
views/results/park.ejs
View file @
12fd4b6
...
...
@@ -15,5 +15,5 @@
</tbody>
</table>
<p class="sum">총 도시공원 개수 :
<%=
parks
_list.length%>
<%=
appliance
_list.length%>
</p>
\ No newline at end of file
...
...
views/results/protection.ejs
deleted
100644 → 0
View file @
225b3b0
<h4> 동물 보호소 현황</h4>
<table class="table">
<thead class="thead-dark">
<tr>
<th>동물 보호소명</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<%=titles%>
</td>
</tr>
</tbody>
</table>
<p class="sum">총 동물 보호소 개수 :
<%=protection_list.length%>
</p>
\ No newline at end of file
Please
register
or
login
to post a comment