Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature][admin] Task submit support approval #4061

Open
3 tasks done
MactavishCui opened this issue Dec 17, 2024 · 9 comments
Open
3 tasks done

[Feature][admin] Task submit support approval #4061

MactavishCui opened this issue Dec 17, 2024 · 9 comments
Assignees
Labels
New Feature New feature Waiting for reply Waiting for reply

Comments

@MactavishCui
Copy link
Contributor

MactavishCui commented Dec 17, 2024

Search before asking

  • I had searched in the issues and found no similar feature requirement.

Description

Currently, Dinky has implemented the features including auth management, task version control to support team development cooperation. In my opinion task review is also an important feature for team development .The code and configuration review before deployment can help teams make a better data ware house quality. As a result, l proposed this task approval feature.

Use case

In order to implement task approval, l think dinky should have following abilities:

Approval configuration center

It has following options:

  • Enable task approval: When this option is disabled, there's nothing different of task submit process between previous and new dinky version, otherwise, a task cannot be submitted unless it has been approved.
  • Enforce cross review: Reviewer and submitter cannot be the same user in one approval when this option is enabled.
  • Reviewer roles: Roles who can approve or reject an approval.
    The following pics list my attempts, mentioned options can be changed in configuration center:
    0adfcd68eb3912fab90dab6fccb9fec

Task submit aspect

The pic below shows the process of task submit with approval.

  • Front end: When a task need to be approved first(Enable task approval and no approved process exists for current version), user need to publish the task first and then submit an approval. Only when the task has been approved, users can request the TaskController.submit interface by dinky-web.
  • Back end: An approval aspect is designed to check if approval is needed and whether it has been approved before submit. If the task is not allowed to be submitted, an exception will be thrown
    image
    c70548cea83c2c88cb10343bfb72dfb

Approval Center

In this page ,users can get the approvals they submitted or required for review. Like what has been implemented below, users can do some operations including withdraw, reject and approve. The different between previous and current version can also be reviewed Approval search is also supported.

pic task approval list
1bb8206efdcd356b12ee517ae3bfb05

pic task info
fbc900508a31a26fc42742c55c9a25f

pic reject or approve
8fffe22620bf6f1d59af710cc6231ae

pic approval status and handle event
image

Of course, when enable task approval configuration is disabled, this page is also not available:
6fce989b371002b19cdb505ad4025d9

All mentioned above is my new attempt about task approval. What is your opinion about this feature and my scheme?
Looking forward to your reply and discussion!

Related issues

No

Are you willing to submit a PR?

  • Yes I am willing to submit a PR!

Code of Conduct

@MactavishCui MactavishCui added New Feature New feature Waiting for reply Waiting for reply labels Dec 17, 2024
Copy link

Hello @MactavishCui, this issue is about web, so I assign it to @Zzm0809. If you have any questions, you can comment and reply.

你好 @MactavishCui, 这个 issue 是关于 web 的,所以我把它分配给了 @Zzm0809。如有任何问题,可以评论回复。

@MactavishCui MactavishCui changed the title [Feature]admin] Task submit support approval [Feature][admin] Task submit support approval Dec 17, 2024
@Zzm0809
Copy link
Contributor

Zzm0809 commented Dec 18, 2024

If you need to implement such a function, whether you need to add the function of on-site notification to remind the corresponding approver for approval, and at the same time, you can generate the corresponding approval form link for quick approval

@aiwenmo
Copy link
Contributor

aiwenmo commented Dec 18, 2024

Thank you very much for your suggestion on the approval function.

I think the approval management page should be in the authentication center (or other center) instead of adding a new approval center.

@gaoyan1998
Copy link
Contributor

If you need to implement such a function, whether you need to add the function of on-site notification to remind the corresponding approver for approval, and at the same time, you can generate the corresponding approval form link for quick approval

I think this can be considered later. It is an optimization and does not affect the existing logic. You can continue to add such functions after the current task is completed.

@MactavishCui
Copy link
Contributor Author

MactavishCui commented Dec 18, 2024

If you need to implement such a function, whether you need to add the function of on-site notification to remind the corresponding approver for approval, and at the same time, you can generate the corresponding approval form link for quick approval

If you need to implement such a function, whether you need to add the function of on-site notification to remind the corresponding approver for approval, and at the same time, you can generate the corresponding approval form link for quick approval

I think this can be considered later. It is an optimization and does not affect the existing logic. You can continue to add such functions after the current task is completed.

Thx for your reply. Firstly, thanks for your suggestion, I agree with @Zzm0809 it will be helpful to remind users and generate an approval link. And I also agree with what @gaoyan1998 said, I think after finishing current task maybe an alert instance can be build or other methods can be used to notify users, which can improve this function better. And I'm willing to continue working on it.

@MactavishCui
Copy link
Contributor Author

MactavishCui commented Dec 18, 2024

Thank you very much for your suggestion on the approval function.

I think the approval management page should be in the authentication center (or other center) instead of adding a new approval center.

@aiwenmo Thanks for your suggestion! The reason I add a new approval center page is that I think in the future, more process can be controlled by approval like datasource register, document management and so on. I agree with your idea that in current version, it will be better to put approval page into auth center. I'll update codes today based on the new page layout.

@MactavishCui
Copy link
Contributor Author

MactavishCui commented Dec 18, 2024

Besides, may I divide this function implement into several small PRs and submit them step by step? I think it can be divided into these steps:

  1. Approval configuration.
  2. Approval handle back end part implement and test cases.
  3. Approval management page front end part implement.
  4. Task submit aspect

Looking forward to your reply

@aiwenmo
Copy link
Contributor

aiwenmo commented Dec 18, 2024

@MactavishCui OK.

Besides, in the future, when more processes are controlled by approval, an approval center should not be added either, because approval is an auxiliary function and it should be classified into one center.

Looking forward to your PR

@MactavishCui
Copy link
Contributor Author

MactavishCui commented Dec 18, 2024

@MactavishCui OK.

Besides, in the future, when more processes are controlled by approval, an approval center should not be added either, because approval is an auxiliary function and it should be classified into one center.

Looking forward to your PR

@aiwenmo Thanks a lot! Your reply helps me understand the page layout design better, and that can surely helps me a lot in further contribution to dinky!
I'll submit the first PR this week!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
New Feature New feature Waiting for reply Waiting for reply
Projects
None yet
Development

No branches or pull requests

4 participants