feat: add backend rule group and permission support
This commit is contained in:
@@ -0,0 +1,93 @@
|
||||
from abc import ABC, abstractmethod
|
||||
|
||||
from fastapi_modules.fastapi_leaudit.domian.Dto.evaluationPointGroupDto import (
|
||||
EvaluationPointGroupBatchDeleteDTO,
|
||||
EvaluationPointGroupBatchStatusDTO,
|
||||
EvaluationPointGroupBindingCreateDTO,
|
||||
EvaluationPointGroupBindingUpdateDTO,
|
||||
EvaluationPointGroupCreateDTO,
|
||||
EvaluationPointGroupRebindDTO,
|
||||
EvaluationPointGroupUpdateDTO,
|
||||
)
|
||||
from fastapi_modules.fastapi_leaudit.domian.vo.evaluationPointGroupVo import (
|
||||
EvaluationPointGroupBatchDeleteVO,
|
||||
EvaluationPointGroupBatchStatusVO,
|
||||
EvaluationPointGroupDeleteVO,
|
||||
EvaluationPointGroupListVO,
|
||||
EvaluationPointGroupRebindVO,
|
||||
EvaluationPointGroupVO,
|
||||
RuleGroupBindingVO,
|
||||
)
|
||||
|
||||
|
||||
class IEvaluationPointGroupService(ABC):
|
||||
"""评查点分组服务接口。"""
|
||||
|
||||
@abstractmethod
|
||||
async def ListGroups(
|
||||
self,
|
||||
Name: str | None,
|
||||
Code: str | None,
|
||||
IsEnabled: bool | None,
|
||||
Pid: int | None,
|
||||
Page: int,
|
||||
PageSize: int,
|
||||
) -> EvaluationPointGroupListVO:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def ListAllGroups(self, IncludeDisabled: bool, WithRuleCount: bool) -> list[EvaluationPointGroupVO]:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def ListGroupsByDocumentTypes(
|
||||
self,
|
||||
DocumentTypeIds: list[int],
|
||||
IncludeDisabled: bool,
|
||||
WithRuleCount: bool,
|
||||
) -> list[EvaluationPointGroupVO]:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def GetGroup(self, GroupId: int, WithRuleCount: bool) -> EvaluationPointGroupVO:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def GetChildren(self, GroupId: int, IsEnabled: bool | None, Page: int, PageSize: int) -> EvaluationPointGroupListVO:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def CreateGroup(self, Body: EvaluationPointGroupCreateDTO) -> EvaluationPointGroupVO:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def UpdateGroup(self, GroupId: int, Body: EvaluationPointGroupUpdateDTO) -> EvaluationPointGroupVO:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def DeleteGroup(self, GroupId: int) -> EvaluationPointGroupDeleteVO:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def RebindGroup(self, GroupId: int, Body: EvaluationPointGroupRebindDTO) -> EvaluationPointGroupRebindVO:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def BatchUpdateStatus(self, Body: EvaluationPointGroupBatchStatusDTO) -> EvaluationPointGroupBatchStatusVO:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def BatchDelete(self, Body: EvaluationPointGroupBatchDeleteDTO) -> EvaluationPointGroupBatchDeleteVO:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def CreateBinding(self, GroupId: int, Body: EvaluationPointGroupBindingCreateDTO) -> RuleGroupBindingVO:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def UpdateBinding(self, BindingId: int, Body: EvaluationPointGroupBindingUpdateDTO) -> RuleGroupBindingVO:
|
||||
...
|
||||
|
||||
@abstractmethod
|
||||
async def DeleteBinding(self, BindingId: int) -> None:
|
||||
...
|
||||
Reference in New Issue
Block a user