Added the mia_core application.

This commit is contained in:
依瑪貓 2020-07-04 08:17:08 +08:00
parent 6295641366
commit aa89286cd9
6 changed files with 28 additions and 0 deletions

3
mia_core/admin.py Normal file
View File

@ -0,0 +1,3 @@
from django.contrib import admin
# Register your models here.

5
mia_core/apps.py Normal file
View File

@ -0,0 +1,5 @@
from django.apps import AppConfig
class MiaCoreConfig(AppConfig):
name = 'mia_core'

11
mia_core/digest_auth.py Normal file
View File

@ -0,0 +1,11 @@
from mia_core.models import User
class AccountBackend:
def get_partial_digest(self, username):
if username != "imacat":
return None
return "5486b64881adaf7bc1485cc26e57e51e"
def get_user(self, username):
return User(username)

3
mia_core/models.py Normal file
View File

@ -0,0 +1,3 @@
from django.db import models
# Create your models here.

3
mia_core/tests.py Normal file
View File

@ -0,0 +1,3 @@
from django.test import TestCase
# Create your tests here.

3
mia_core/views.py Normal file
View File

@ -0,0 +1,3 @@
from django.shortcuts import render
# Create your views here.