Commit 1fce4662 authored by Timothy J. Baek's avatar Timothy J. Baek
Browse files

refac: folder rename web -> webui

parent 6e89a481
...@@ -29,8 +29,8 @@ import time ...@@ -29,8 +29,8 @@ import time
from urllib.parse import urlparse from urllib.parse import urlparse
from typing import Optional, List, Union from typing import Optional, List, Union
from apps.web.models.models import Models from apps.webui.models.models import Models
from apps.web.models.users import Users from apps.webui.models.users import Users
from constants import ERROR_MESSAGES from constants import ERROR_MESSAGES
from utils.utils import ( from utils.utils import (
decode_token, decode_token,
......
...@@ -10,8 +10,8 @@ import logging ...@@ -10,8 +10,8 @@ import logging
from pydantic import BaseModel from pydantic import BaseModel
from apps.web.models.models import Models from apps.webui.models.models import Models
from apps.web.models.users import Users from apps.webui.models.users import Users
from constants import ERROR_MESSAGES from constants import ERROR_MESSAGES
from utils.utils import ( from utils.utils import (
decode_token, decode_token,
......
...@@ -14,7 +14,7 @@ You will need to create a migration file to ensure that existing databases are u ...@@ -14,7 +14,7 @@ You will need to create a migration file to ensure that existing databases are u
2. Make your changes to the models. 2. Make your changes to the models.
3. From the `backend` directory, run the following command: 3. From the `backend` directory, run the following command:
```bash ```bash
pw_migrate create --auto --auto-source apps.web.models --database sqlite:///${SQLITE_DB} --directory apps/web/internal/migrations ${MIGRATION_NAME} pw_migrate create --auto --auto-source apps.webui.models --database sqlite:///${SQLITE_DB} --directory apps/web/internal/migrations ${MIGRATION_NAME}
``` ```
- `$SQLITE_DB` should be the path to the database file. - `$SQLITE_DB` should be the path to the database file.
- `$MIGRATION_NAME` should be a descriptive name for the migration. - `$MIGRATION_NAME` should be a descriptive name for the migration.
......
from fastapi import FastAPI, Depends from fastapi import FastAPI, Depends
from fastapi.routing import APIRoute from fastapi.routing import APIRoute
from fastapi.middleware.cors import CORSMiddleware from fastapi.middleware.cors import CORSMiddleware
from apps.web.routers import ( from apps.webui.routers import (
auths, auths,
users, users,
chats, chats,
......
...@@ -5,10 +5,10 @@ import uuid ...@@ -5,10 +5,10 @@ import uuid
import logging import logging
from peewee import * from peewee import *
from apps.web.models.users import UserModel, Users from apps.webui.models.users import UserModel, Users
from utils.utils import verify_password from utils.utils import verify_password
from apps.web.internal.db import DB from apps.webui.internal.db import DB
from config import SRC_LOG_LEVELS from config import SRC_LOG_LEVELS
......
...@@ -7,7 +7,7 @@ import json ...@@ -7,7 +7,7 @@ import json
import uuid import uuid
import time import time
from apps.web.internal.db import DB from apps.webui.internal.db import DB
#################### ####################
# Chat DB Schema # Chat DB Schema
......
...@@ -8,7 +8,7 @@ import logging ...@@ -8,7 +8,7 @@ import logging
from utils.utils import decode_token from utils.utils import decode_token
from utils.misc import get_gravatar_url from utils.misc import get_gravatar_url
from apps.web.internal.db import DB from apps.webui.internal.db import DB
import json import json
......
...@@ -3,8 +3,8 @@ from peewee import * ...@@ -3,8 +3,8 @@ from peewee import *
from playhouse.shortcuts import model_to_dict from playhouse.shortcuts import model_to_dict
from typing import List, Union, Optional from typing import List, Union, Optional
from apps.web.internal.db import DB from apps.webui.internal.db import DB
from apps.web.models.chats import Chats from apps.webui.models.chats import Chats
import time import time
import uuid import uuid
......
...@@ -8,7 +8,7 @@ from peewee import * ...@@ -8,7 +8,7 @@ from peewee import *
from playhouse.shortcuts import model_to_dict from playhouse.shortcuts import model_to_dict
from pydantic import BaseModel, ConfigDict from pydantic import BaseModel, ConfigDict
from apps.web.internal.db import DB, JSONField from apps.webui.internal.db import DB, JSONField
from typing import List, Union, Optional from typing import List, Union, Optional
from config import SRC_LOG_LEVELS from config import SRC_LOG_LEVELS
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment