2024-05-11 03:22:01 +00:00
# Generated by Django 4.1.13 on 2024-05-09 03:16
2023-06-12 05:59:54 +00:00
2024-05-11 03:22:01 +00:00
import common . db . fields
2021-03-11 12:17:44 +00:00
import django . core . validators
2023-06-12 05:59:54 +00:00
from django . db import migrations , models
2024-05-11 03:22:01 +00:00
import uuid
2021-03-11 12:17:44 +00:00
class Migration ( migrations . Migration ) :
2024-05-11 03:22:01 +00:00
2021-03-11 12:17:44 +00:00
initial = True
dependencies = [
]
operations = [
migrations . CreateModel (
2024-05-11 03:22:01 +00:00
name = ' CommandFilterACL ' ,
2021-03-11 12:17:44 +00:00
fields = [
2024-05-11 03:22:01 +00:00
( ' created_by ' , models . CharField ( blank = True , max_length = 128 , null = True , verbose_name = ' Created by ' ) ) ,
( ' updated_by ' , models . CharField ( blank = True , max_length = 128 , null = True , verbose_name = ' Updated by ' ) ) ,
( ' date_created ' , models . DateTimeField ( auto_now_add = True , null = True , verbose_name = ' Date created ' ) ) ,
( ' date_updated ' , models . DateTimeField ( auto_now = True , verbose_name = ' Date updated ' ) ) ,
( ' comment ' , models . TextField ( blank = True , default = ' ' , verbose_name = ' Comment ' ) ) ,
2021-03-11 12:17:44 +00:00
( ' id ' , models . UUIDField ( default = uuid . uuid4 , primary_key = True , serialize = False ) ) ,
2024-05-11 03:22:01 +00:00
( ' org_id ' , models . CharField ( blank = True , db_index = True , default = ' ' , max_length = 36 , verbose_name = ' Organization ' ) ) ,
( ' priority ' , models . IntegerField ( default = 50 , help_text = ' 1-100, the lower the value will be match first ' , validators = [ django . core . validators . MinValueValidator ( 1 ) , django . core . validators . MaxValueValidator ( 100 ) ] , verbose_name = ' Priority ' ) ) ,
( ' action ' , models . CharField ( default = ' reject ' , max_length = 64 , verbose_name = ' Action ' ) ) ,
( ' is_active ' , models . BooleanField ( default = True , verbose_name = ' Active ' ) ) ,
( ' users ' , common . db . fields . JSONManyToManyField ( default = dict , to = ' users.User ' , verbose_name = ' Users ' ) ) ,
( ' name ' , models . CharField ( max_length = 128 , verbose_name = ' Name ' ) ) ,
( ' assets ' , common . db . fields . JSONManyToManyField ( default = dict , to = ' assets.Asset ' , verbose_name = ' Assets ' ) ) ,
( ' accounts ' , models . JSONField ( default = list , verbose_name = ' Accounts ' ) ) ,
] ,
options = {
' verbose_name ' : ' Command acl ' ,
' ordering ' : ( ' priority ' , ' -is_active ' , ' name ' ) ,
' abstract ' : False ,
} ,
) ,
migrations . CreateModel (
name = ' CommandGroup ' ,
fields = [
( ' created_by ' , models . CharField ( blank = True , max_length = 128 , null = True , verbose_name = ' Created by ' ) ) ,
( ' updated_by ' , models . CharField ( blank = True , max_length = 128 , null = True , verbose_name = ' Updated by ' ) ) ,
2021-03-11 12:17:44 +00:00
( ' date_created ' , models . DateTimeField ( auto_now_add = True , null = True , verbose_name = ' Date created ' ) ) ,
( ' date_updated ' , models . DateTimeField ( auto_now = True , verbose_name = ' Date updated ' ) ) ,
2024-05-11 03:22:01 +00:00
( ' comment ' , models . TextField ( blank = True , default = ' ' , verbose_name = ' Comment ' ) ) ,
( ' id ' , models . UUIDField ( default = uuid . uuid4 , primary_key = True , serialize = False ) ) ,
( ' org_id ' , models . CharField ( blank = True , db_index = True , default = ' ' , max_length = 36 , verbose_name = ' Organization ' ) ) ,
2021-03-11 12:17:44 +00:00
( ' name ' , models . CharField ( max_length = 128 , verbose_name = ' Name ' ) ) ,
2024-05-11 03:22:01 +00:00
( ' type ' , models . CharField ( choices = [ ( ' command ' , ' Command ' ) , ( ' regex ' , ' Regex ' ) ] , default = ' command ' , max_length = 16 , verbose_name = ' Type ' ) ) ,
2024-05-24 06:54:56 +00:00
( ' content ' , models . TextField ( help_text = ' One command per line ' , verbose_name = ' Content ' ) ) ,
2024-05-11 03:22:01 +00:00
( ' ignore_case ' , models . BooleanField ( default = True , verbose_name = ' Ignore case ' ) ) ,
] ,
options = {
' verbose_name ' : ' Command group ' ,
} ,
) ,
migrations . CreateModel (
name = ' ConnectMethodACL ' ,
fields = [
( ' created_by ' , models . CharField ( blank = True , max_length = 128 , null = True , verbose_name = ' Created by ' ) ) ,
( ' updated_by ' , models . CharField ( blank = True , max_length = 128 , null = True , verbose_name = ' Updated by ' ) ) ,
( ' date_created ' , models . DateTimeField ( auto_now_add = True , null = True , verbose_name = ' Date created ' ) ) ,
( ' date_updated ' , models . DateTimeField ( auto_now = True , verbose_name = ' Date updated ' ) ) ,
( ' comment ' , models . TextField ( blank = True , default = ' ' , verbose_name = ' Comment ' ) ) ,
( ' id ' , models . UUIDField ( default = uuid . uuid4 , primary_key = True , serialize = False ) ) ,
( ' name ' , models . CharField ( max_length = 128 , unique = True , verbose_name = ' Name ' ) ) ,
( ' priority ' , models . IntegerField ( default = 50 , help_text = ' 1-100, the lower the value will be match first ' , validators = [ django . core . validators . MinValueValidator ( 1 ) , django . core . validators . MaxValueValidator ( 100 ) ] , verbose_name = ' Priority ' ) ) ,
( ' action ' , models . CharField ( default = ' reject ' , max_length = 64 , verbose_name = ' Action ' ) ) ,
2021-03-11 12:17:44 +00:00
( ' is_active ' , models . BooleanField ( default = True , verbose_name = ' Active ' ) ) ,
2024-05-11 03:22:01 +00:00
( ' users ' , common . db . fields . JSONManyToManyField ( default = dict , to = ' users.User ' , verbose_name = ' Users ' ) ) ,
( ' connect_methods ' , models . JSONField ( default = list , verbose_name = ' Connect methods ' ) ) ,
] ,
options = {
' verbose_name ' : ' Connect method acl ' ,
' ordering ' : ( ' priority ' , ' -is_active ' , ' name ' ) ,
' abstract ' : False ,
} ,
) ,
migrations . CreateModel (
name = ' LoginACL ' ,
fields = [
( ' created_by ' , models . CharField ( blank = True , max_length = 128 , null = True , verbose_name = ' Created by ' ) ) ,
( ' updated_by ' , models . CharField ( blank = True , max_length = 128 , null = True , verbose_name = ' Updated by ' ) ) ,
( ' date_created ' , models . DateTimeField ( auto_now_add = True , null = True , verbose_name = ' Date created ' ) ) ,
( ' date_updated ' , models . DateTimeField ( auto_now = True , verbose_name = ' Date updated ' ) ) ,
2021-03-11 12:17:44 +00:00
( ' comment ' , models . TextField ( blank = True , default = ' ' , verbose_name = ' Comment ' ) ) ,
2024-05-11 03:22:01 +00:00
( ' id ' , models . UUIDField ( default = uuid . uuid4 , primary_key = True , serialize = False ) ) ,
( ' name ' , models . CharField ( max_length = 128 , unique = True , verbose_name = ' Name ' ) ) ,
( ' priority ' , models . IntegerField ( default = 50 , help_text = ' 1-100, the lower the value will be match first ' , validators = [ django . core . validators . MinValueValidator ( 1 ) , django . core . validators . MaxValueValidator ( 100 ) ] , verbose_name = ' Priority ' ) ) ,
( ' action ' , models . CharField ( default = ' reject ' , max_length = 64 , verbose_name = ' Action ' ) ) ,
( ' is_active ' , models . BooleanField ( default = True , verbose_name = ' Active ' ) ) ,
( ' users ' , common . db . fields . JSONManyToManyField ( default = dict , to = ' users.User ' , verbose_name = ' Users ' ) ) ,
( ' rules ' , models . JSONField ( default = dict , verbose_name = ' Rule ' ) ) ,
2021-03-11 12:17:44 +00:00
] ,
options = {
2024-05-11 03:22:01 +00:00
' verbose_name ' : ' Login acl ' ,
2023-06-15 02:45:07 +00:00
' ordering ' : ( ' priority ' , ' -is_active ' , ' name ' ) ,
2024-05-11 03:22:01 +00:00
' abstract ' : False ,
2021-03-11 12:17:44 +00:00
} ,
) ,
migrations . CreateModel (
name = ' LoginAssetACL ' ,
fields = [
2024-05-11 03:22:01 +00:00
( ' created_by ' , models . CharField ( blank = True , max_length = 128 , null = True , verbose_name = ' Created by ' ) ) ,
( ' updated_by ' , models . CharField ( blank = True , max_length = 128 , null = True , verbose_name = ' Updated by ' ) ) ,
2021-03-11 12:17:44 +00:00
( ' date_created ' , models . DateTimeField ( auto_now_add = True , null = True , verbose_name = ' Date created ' ) ) ,
( ' date_updated ' , models . DateTimeField ( auto_now = True , verbose_name = ' Date updated ' ) ) ,
( ' comment ' , models . TextField ( blank = True , default = ' ' , verbose_name = ' Comment ' ) ) ,
2024-05-11 03:22:01 +00:00
( ' id ' , models . UUIDField ( default = uuid . uuid4 , primary_key = True , serialize = False ) ) ,
( ' org_id ' , models . CharField ( blank = True , db_index = True , default = ' ' , max_length = 36 , verbose_name = ' Organization ' ) ) ,
( ' priority ' , models . IntegerField ( default = 50 , help_text = ' 1-100, the lower the value will be match first ' , validators = [ django . core . validators . MinValueValidator ( 1 ) , django . core . validators . MaxValueValidator ( 100 ) ] , verbose_name = ' Priority ' ) ) ,
( ' action ' , models . CharField ( default = ' reject ' , max_length = 64 , verbose_name = ' Action ' ) ) ,
( ' is_active ' , models . BooleanField ( default = True , verbose_name = ' Active ' ) ) ,
( ' users ' , common . db . fields . JSONManyToManyField ( default = dict , to = ' users.User ' , verbose_name = ' Users ' ) ) ,
( ' name ' , models . CharField ( max_length = 128 , verbose_name = ' Name ' ) ) ,
( ' assets ' , common . db . fields . JSONManyToManyField ( default = dict , to = ' assets.Asset ' , verbose_name = ' Assets ' ) ) ,
( ' accounts ' , models . JSONField ( default = list , verbose_name = ' Accounts ' ) ) ,
( ' rules ' , models . JSONField ( default = dict , verbose_name = ' Rule ' ) ) ,
2021-03-11 12:17:44 +00:00
] ,
options = {
2024-05-11 03:22:01 +00:00
' verbose_name ' : ' Login asset acl ' ,
2023-06-15 02:45:07 +00:00
' ordering ' : ( ' priority ' , ' -is_active ' , ' name ' ) ,
2024-05-11 03:22:01 +00:00
' abstract ' : False ,
2021-03-11 12:17:44 +00:00
} ,
) ,
]