Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
midterm_robo_mommy
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Raul Jarod Conanan
midterm_robo_mommy
Commits
2cc6c087
Commit
2cc6c087
authored
Mar 05, 2023
by
RJC
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pulled Dashboard app from dev branch
parent
e276ee54
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
90 additions
and
0 deletions
+90
-0
__init__.py
widget_robo_mommy/Dashboard/__init__.py
+0
-0
admin.py
widget_robo_mommy/Dashboard/admin.py
+14
-0
apps.py
widget_robo_mommy/Dashboard/apps.py
+6
-0
0001_initial.py
widget_robo_mommy/Dashboard/migrations/0001_initial.py
+22
-0
__init__.py
widget_robo_mommy/Dashboard/migrations/__init__.py
+0
-0
models.py
widget_robo_mommy/Dashboard/models.py
+10
-0
Dashboard.html
...t_robo_mommy/Dashboard/templates/Dashboard/Dashboard.html
+19
-0
tests.py
widget_robo_mommy/Dashboard/tests.py
+3
-0
urls.py
widget_robo_mommy/Dashboard/urls.py
+9
-0
views.py
widget_robo_mommy/Dashboard/views.py
+7
-0
No files found.
widget_robo_mommy/Dashboard/__init__.py
0 → 100644
View file @
2cc6c087
widget_robo_mommy/Dashboard/admin.py
0 → 100644
View file @
2cc6c087
from
django.contrib
import
admin
from
.models
import
Department
class
DepartmentAdmin
(
admin
.
ModelAdmin
):
model
=
Department
list_display
=
(
'dept_name'
,
'home_unit'
)
search_fields
=
(
'dept_name'
,
'home_unit'
)
admin
.
site
.
register
(
Department
,
DepartmentAdmin
)
widget_robo_mommy/Dashboard/apps.py
0 → 100644
View file @
2cc6c087
from
django.apps
import
AppConfig
class
DashboardConfig
(
AppConfig
):
default_auto_field
=
'django.db.models.BigAutoField'
name
=
'Dashboard'
widget_robo_mommy/Dashboard/migrations/0001_initial.py
0 → 100644
View file @
2cc6c087
# Generated by Django 4.1.6 on 2023-03-03 15:37
from
django.db
import
migrations
,
models
class
Migration
(
migrations
.
Migration
):
initial
=
True
dependencies
=
[
]
operations
=
[
migrations
.
CreateModel
(
name
=
'Department'
,
fields
=
[
(
'id'
,
models
.
BigAutoField
(
auto_created
=
True
,
primary_key
=
True
,
serialize
=
False
,
verbose_name
=
'ID'
)),
(
'dept_name'
,
models
.
CharField
(
max_length
=
50
)),
(
'home_unit'
,
models
.
CharField
(
max_length
=
100
)),
],
),
]
widget_robo_mommy/Dashboard/migrations/__init__.py
0 → 100644
View file @
2cc6c087
widget_robo_mommy/Dashboard/models.py
0 → 100644
View file @
2cc6c087
from
django.db
import
models
from
django.contrib.auth.models
import
User
class
Department
(
models
.
Model
):
dept_name
=
models
.
CharField
(
max_length
=
50
)
home_unit
=
models
.
CharField
(
max_length
=
100
)
class
WidgetUser
(
User
):
pass
widget_robo_mommy/Dashboard/templates/Dashboard/Dashboard.html
0 → 100644
View file @
2cc6c087
<!DOCTYPE HTML>
<HTML>
<Head>
<h1>
Welcome to Widget!
</h1>
</Head>
<h2>
WIDGET USERS
</h2>
<ul>
{% for Department in object_list %}
<li>
{{Department.dept_name}}, {{Department.home_unit}}
</li>
{% endfor %}
</ul>
</HTML>
widget_robo_mommy/Dashboard/tests.py
0 → 100644
View file @
2cc6c087
from
django.test
import
TestCase
# Create your tests here.
widget_robo_mommy/Dashboard/urls.py
0 → 100644
View file @
2cc6c087
from
django.urls
import
path
from
.views
import
DashboardView
urlpatterns
=
[
path
(
''
,
DashboardView
.
as_view
()),
]
app_name
=
"Dashboard"
\ No newline at end of file
widget_robo_mommy/Dashboard/views.py
0 → 100644
View file @
2cc6c087
from
.models
import
Department
from
django.views
import
generic
class
DashboardView
(
generic
.
ListView
):
model
=
Department
template_name
=
'Dashboard/Dashboard.html'
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment