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

Assign anotther tracker to quto created subtask #332

Open
fabianocruzdf opened this issue Jan 6, 2024 · 2 comments
Open

Assign anotther tracker to quto created subtask #332

fabianocruzdf opened this issue Jan 6, 2024 · 2 comments

Comments

@fabianocruzdf
Copy link

Hello!

I'm using the following script to create new subtasks, but, depending the father task tracker, I need to set another tracker to suto created subtask. Here's is a example:

If tracker is feature then autocreated subtask must have a suport tracker type.

My script:

if @var //populated on before_save
issue = Issue.new
issue.tracker_id = tracker_id
issue.project_id = project_id // <-- Here's my problem, i have to set another id, but everything i put here is ignored, and subtask created has the same tracker_id of father task.
issue.subject = 'Sub-issue'
issue.status_id = status_id
issue.priority_id = priority_id
issue.author_id = author_id
issue.parent_id = id
issue.save
end

can anyone help me with this?

@fabianocruzdf
Copy link
Author

@picman help!

@picman
Copy link
Collaborator

picman commented Jan 8, 2024

Has the given project the tracker enabled? If not, you can't assign it to its issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants