Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app_desc.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
spec_version: 2
app_version: "1.11.2"
app_version: "1.12.0"
app:
region: default
bk_app_code: &APP_CODE bk_flow_engine
Expand Down
3 changes: 1 addition & 2 deletions bkflow/admin/models.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -20,7 +19,7 @@
from enum import Enum

from django.db import models
from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _


class ModuleType(Enum):
Expand Down
6 changes: 3 additions & 3 deletions bkflow/admin/urls.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -19,7 +18,8 @@
"""


from django.conf.urls import include, url
from django.conf.urls import include
from django.urls import re_path
from rest_framework.routers import DefaultRouter

from bkflow.admin.views import ModuleInfoAdminViewSet
Expand All @@ -28,5 +28,5 @@
router.register(r"^module_info", ModuleInfoAdminViewSet, basename="module_info")

urlpatterns = [
url(r"^", include(router.urls)),
re_path(r"^", include(router.urls)),
]
3 changes: 1 addition & 2 deletions bkflow/apigw/exceptions.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -17,7 +16,7 @@

to the current version of the project delivered to anyone in the future.
"""
from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _

from bkflow.exceptions import BKFLOWException

Expand Down
3 changes: 1 addition & 2 deletions bkflow/apigw/serializers/credential.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -17,7 +16,7 @@

to the current version of the project delivered to anyone in the future.
"""
from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _
from rest_framework import serializers

from bkflow.space.credential import BkAppCredential
Expand Down
3 changes: 1 addition & 2 deletions bkflow/apigw/serializers/space.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -18,7 +17,7 @@
to the current version of the project delivered to anyone in the future.
"""

from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _
from rest_framework import serializers

from bkflow.exceptions import ValidationError
Expand Down
3 changes: 1 addition & 2 deletions bkflow/apigw/serializers/space_config.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -17,7 +16,7 @@

to the current version of the project delivered to anyone in the future.
"""
from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _
from rest_framework import serializers

from bkflow.exceptions import ValidationError
Expand Down
3 changes: 1 addition & 2 deletions bkflow/apigw/serializers/task.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -17,7 +16,7 @@

to the current version of the project delivered to anyone in the future.
"""
from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _
from pipeline.exceptions import PipelineException
from rest_framework import serializers

Expand Down
2 changes: 1 addition & 1 deletion bkflow/apigw/serializers/template.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"""
import logging

from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _
from pipeline.validators import validate_pipeline_tree
from rest_framework import serializers

Expand Down
3 changes: 1 addition & 2 deletions bkflow/apigw/serializers/token.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -19,7 +18,7 @@
"""
import logging

from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _
from rest_framework import serializers

from bkflow.apigw.exceptions import CreateTokenException
Expand Down
55 changes: 28 additions & 27 deletions bkflow/apigw/urls.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -18,7 +17,7 @@
to the current version of the project delivered to anyone in the future.
"""
from django.conf import settings
from django.conf.urls import url
from django.urls import re_path

from module_settings import BKFLOWModuleType

Expand Down Expand Up @@ -56,35 +55,37 @@
from bkflow.apigw.views.validate_pipeline_tree import validate_pipeline_tree

urlpatterns += [
url(r"^create_space/$", create_space),
url(r"^grant_apigw_permissions_to_app/$", grant_apigw_permissions_to_app),
url(r"^space/(?P<space_id>\d+)/apply_token/$", apply_token),
url(r"^space/(?P<space_id>\d+)/revoke_token/$", revoke_token),
url(r"^space/(?P<space_id>\d+)/create_template/$", create_template),
url(r"^space/(?P<space_id>\d+)/get_template_list/$", get_template_list),
url(r"^space/(?P<space_id>\d+)/template/(?P<template_id>\d+)/get_template_detail/$", get_template_detail),
url(r"^space/(?P<space_id>\d+)/template/(?P<template_id>\d+)/get_template_mock_data/$", get_template_mock_data),
url(r"^space/(?P<space_id>\d+)/renew_space_config/$", renew_space_config),
url(r"^space/(?P<space_id>\d+)/get_space_configs/$", get_space_configs),
url(r"^space/(?P<space_id>\d+)/update_template/(?P<template_id>\d+)/$", update_template),
url(r"^space/(?P<space_id>\d+)/delete_template/(?P<template_id>\d+)/$", delete_template),
url(r"^space/(?P<space_id>\d+)/create_task/$", create_task),
url(r"^space/(?P<space_id>\d+)/create_mock_task/$", create_mock_task),
url(r"^space/(?P<space_id>\d+)/create_task_without_template/$", create_task_without_template),
url(r"^space/(?P<space_id>\d+)/validate_pipeline_tree/$", validate_pipeline_tree),
url(r"^space/(?P<space_id>\d+)/create_credential/$", create_credential),
url(r"^space/(?P<space_id>\d+)/get_task_list/$", get_task_list),
url(r"^space/(?P<space_id>\d+)/task/(?P<task_id>\d+)/get_task_detail/$", get_task_detail),
url(r"^space/(?P<space_id>\d+)/task/(?P<task_id>\d+)/get_task_states/$", get_task_states),
url(r"^space/(?P<space_id>\d+)/get_tasks_states/$", get_tasks_states),
url(
re_path(r"^create_space/$", create_space),
re_path(r"^grant_apigw_permissions_to_app/$", grant_apigw_permissions_to_app),
re_path(r"^space/(?P<space_id>\d+)/apply_token/$", apply_token),
re_path(r"^space/(?P<space_id>\d+)/revoke_token/$", revoke_token),
re_path(r"^space/(?P<space_id>\d+)/create_template/$", create_template),
re_path(r"^space/(?P<space_id>\d+)/get_template_list/$", get_template_list),
re_path(r"^space/(?P<space_id>\d+)/template/(?P<template_id>\d+)/get_template_detail/$", get_template_detail),
re_path(
r"^space/(?P<space_id>\d+)/template/(?P<template_id>\d+)/get_template_mock_data/$", get_template_mock_data
),
re_path(r"^space/(?P<space_id>\d+)/renew_space_config/$", renew_space_config),
re_path(r"^space/(?P<space_id>\d+)/get_space_configs/$", get_space_configs),
re_path(r"^space/(?P<space_id>\d+)/update_template/(?P<template_id>\d+)/$", update_template),
re_path(r"^space/(?P<space_id>\d+)/delete_template/(?P<template_id>\d+)/$", delete_template),
re_path(r"^space/(?P<space_id>\d+)/create_task/$", create_task),
re_path(r"^space/(?P<space_id>\d+)/create_mock_task/$", create_mock_task),
re_path(r"^space/(?P<space_id>\d+)/create_task_without_template/$", create_task_without_template),
re_path(r"^space/(?P<space_id>\d+)/validate_pipeline_tree/$", validate_pipeline_tree),
re_path(r"^space/(?P<space_id>\d+)/create_credential/$", create_credential),
re_path(r"^space/(?P<space_id>\d+)/get_task_list/$", get_task_list),
re_path(r"^space/(?P<space_id>\d+)/task/(?P<task_id>\d+)/get_task_detail/$", get_task_detail),
re_path(r"^space/(?P<space_id>\d+)/task/(?P<task_id>\d+)/get_task_states/$", get_task_states),
re_path(r"^space/(?P<space_id>\d+)/get_tasks_states/$", get_tasks_states),
re_path(
r"^space/(?P<space_id>\d+)/task/(?P<task_id>\d+)/node/(?P<node_id>\w+)/get_task_node_detail/$",
get_task_node_detail,
),
url(
re_path(
r"^space/(?P<space_id>\d+)/task/(?P<task_id>\d+)/node/(?P<node_id>\w+)/operate_node/(?P<operation>\w+)/$",
operate_task_node,
),
url(r"^space/(?P<space_id>\d+)/task/(?P<task_id>\d+)/operate_task/(?P<operation>\w+)/$", operate_task),
url(r"^space/(?P<space_id>\d+)/apply_webhook_configs/$", apply_webhook_configs),
re_path(r"^space/(?P<space_id>\d+)/task/(?P<task_id>\d+)/operate_task/(?P<operation>\w+)/$", operate_task),
re_path(r"^space/(?P<space_id>\d+)/apply_webhook_configs/$", apply_webhook_configs),
]
3 changes: 1 addition & 2 deletions bkflow/apigw/views/apply_token.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -24,7 +23,7 @@
from apigw_manager.apigw.decorators import apigw_require
from blueapps.account.decorators import login_exempt
from django.utils import timezone
from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _
from django.views.decorators.csrf import csrf_exempt
from django.views.decorators.http import require_POST
from pytimeparse import parse
Expand Down
2 changes: 1 addition & 1 deletion bkflow/apigw/views/create_mock_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

from apigw_manager.apigw.decorators import apigw_require
from blueapps.account.decorators import login_exempt
from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _
from django.views.decorators.csrf import csrf_exempt
from django.views.decorators.http import require_POST

Expand Down
2 changes: 1 addition & 1 deletion bkflow/apigw/views/create_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

from apigw_manager.apigw.decorators import apigw_require
from blueapps.account.decorators import login_exempt
from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _
from django.views.decorators.csrf import csrf_exempt
from django.views.decorators.http import require_POST

Expand Down
2 changes: 1 addition & 1 deletion bkflow/apigw/views/update_template.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import json

from blueapps.account.decorators import login_exempt
from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _
from django.views.decorators.csrf import csrf_exempt
from django.views.decorators.http import require_POST

Expand Down
3 changes: 1 addition & 2 deletions bkflow/bk_plugin/models.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -22,7 +21,7 @@

from django.db import models, transaction
from django.utils.timezone import localtime
from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _

import env
from bkflow.constants import ALL_SPACE, WHITE_LIST
Expand Down
3 changes: 1 addition & 2 deletions bkflow/bk_plugin/urls.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -23,6 +22,6 @@

router = DefaultRouter()
router.register(r"manager", views.BKPluginManagerViewSet)
router.register(r"", views.BKPluginViewSet)
router.register(r"", views.BKPluginViewSet, "bkplugin_base")

urlpatterns = router.urls
2 changes: 1 addition & 1 deletion bkflow/constants.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import re
from enum import Enum

from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _

MAX_LEN_OF_TASK_NAME = 128
MAX_LEN_OF_TEMPLATE_NAME = 128
Expand Down
3 changes: 1 addition & 2 deletions bkflow/contrib/operation_record/models.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -18,7 +17,7 @@
to the current version of the project delivered to anyone in the future.
"""
from django.db import models
from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _


class BaseOperateRecord(models.Model):
Expand Down
6 changes: 2 additions & 4 deletions bkflow/decision_table/urls.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -17,8 +16,7 @@

to the current version of the project delivered to anyone in the future.
"""
from django.conf.urls import url
from django.urls import include
from django.urls import include, re_path
from rest_framework.routers import DefaultRouter

from bkflow.decision_table.views import (
Expand All @@ -34,5 +32,5 @@


urlpatterns = [
url(r"", include(drf_router.urls)),
re_path(r"", include(drf_router.urls)),
]
6 changes: 2 additions & 4 deletions bkflow/interface/task/urls.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -17,8 +16,7 @@

to the current version of the project delivered to anyone in the future.
"""
from django.conf.urls import url
from django.urls import include
from django.urls import include, re_path
from rest_framework.routers import DefaultRouter

from bkflow.interface.task.view import (
Expand All @@ -32,4 +30,4 @@
drf_router.register(r"task_admin", TaskInterfaceAdminViewSet, basename="task_admin")
drf_router.register(r"task_system_superuser", TaskInterfaceSystemSuperuserViewSet, basename="task_system_superuser")

urlpatterns = [url(r"", include(drf_router.urls))]
urlpatterns = [re_path(r"", include(drf_router.urls))]
2 changes: 1 addition & 1 deletion bkflow/interface/task/view.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import logging

from django.utils import timezone
from django.utils.translation import ugettext_lazy as _
from django.utils.translation import gettext_lazy as _
from drf_yasg.utils import swagger_auto_schema
from rest_framework.decorators import action
from rest_framework.response import Response
Expand Down
20 changes: 9 additions & 11 deletions bkflow/interface/urls.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# -*- coding: utf-8 -*-
"""
TencentBlueKing is pleased to support the open source community by making
蓝鲸流程引擎服务 (BlueKing Flow Engine Service) available.
Expand All @@ -17,8 +16,7 @@

to the current version of the project delivered to anyone in the future.
"""
from django.conf.urls import url
from django.urls import include
from django.urls import include, re_path

from .itsm.itsm import itsm_approve
from .views import (
Expand All @@ -31,12 +29,12 @@
)

urlpatterns = [
url(r"^$", home),
url(r"^logout/$", user_exit),
url(r"^is_admin_user/$", is_admin_or_space_superuser),
url(r"^is_current_space_admin/$", is_admin_or_current_space_superuser),
url(r"^callback/(?P<token>.+)/$", callback),
url(r"^get_msg_types/$", get_msg_types),
url(r"^itsm_approve/$", itsm_approve),
url(r"", include("bkflow.interface.task.urls")),
re_path(r"^$", home),
re_path(r"^logout/$", user_exit),
re_path(r"^is_admin_user/$", is_admin_or_space_superuser),
re_path(r"^is_current_space_admin/$", is_admin_or_current_space_superuser),
re_path(r"^callback/(?P<token>.+)/$", callback),
re_path(r"^get_msg_types/$", get_msg_types),
re_path(r"^itsm_approve/$", itsm_approve),
re_path(r"", include("bkflow.interface.task.urls")),
]
Loading
Loading