Defect #27066

issue parents is wrong

Added by Randa Bustami 3 months ago. Updated 3 months ago.

Status:ClosedStart date:
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:-
Target version:-
Resolution: Affected version:

Description

i added a sub task to a task but when i save it appeared under another task
example
under task 69759 i had added task 253921 but it appeared under task 69755 !
pls check screen shots attached.

parents task.PNG (69 KB) Randa Bustami, 2017-09-24 13:35

subtask.PNG (64.3 KB) Randa Bustami, 2017-09-24 13:35

remdine info.PNG - redmine version (32.7 KB) Randa Bustami, 2017-09-25 08:05

2017-09-25_09-48-27.png - line we changed (54.5 KB) Randa Bustami, 2017-09-25 09:51

rebuild tree result.png (34.9 KB) Randa Bustami, 2017-09-25 12:37

single rebuild tree.png (103 KB) Randa Bustami, 2017-09-25 12:39

REBUILD SINGLE TREE.png (33.7 KB) Randa Bustami, 2017-09-25 14:17

REBUILD TREE.png (33.4 KB) Randa Bustami, 2017-09-25 14:17

rebuild tree (2).png (31 KB) Randa Bustami, 2017-09-26 11:12

rebuid single tree2.png (33.6 KB) Randa Bustami, 2017-09-26 11:12

revert changes.png (43 KB) Randa Bustami, 2017-09-26 12:58

History

#1 Updated by Toshi MARUYAMA 3 months ago

  • Status changed from New to Needs feedback

Please see submissions.

#2 Updated by Randa Bustami 3 months ago

attached the redmine version version is this enough to trace the issue ?

#3 Updated by Toshi MARUYAMA 3 months ago

Could you try "Issues#rebuild_tree!" of "Issues#rebuild_single_tree!"?
source:tags/3.4.2/lib/redmine/nested_set/issue_nested_set.rb#L174

#4 Updated by Randa Bustami 3 months ago

we did the following:
1- go to folder /lib/ under the main folder of redmine then to folder / redmine/ then /nested_set/ then we open file named " issue_nested_set.rb" then we go to line #L174
and change rebuild_tree!" to be "rebuild_single_tree!" ( pls see attached screenshot)
2- save file
3- restart redmine
4- check the issue its still in the wrong place
also i want to ask what is the purpose of tags folder we go directly to lib folder

#5 Updated by Toshi MARUYAMA 3 months ago

Sorry for my typo.

Could you try "Issue#rebuild_tree!" of or "Issue#rebuild_single_tree!"?

Please revert your change.

On your console try:

$ RAILS_ENV=production rails runner 'Issue.rebuild_tree!'

or

$ RAILS_ENV=production rails runner 'Issue.rebuild_single_tree!(1)'

Change "1" to your parent issue id.

#6 Updated by Randa Bustami 3 months ago

we revert the changes and restart redmine
we tried the first command $ RAILS_ENV=production rails runner 'Issue.rebuild_tree!' but it give us error message (attached screen shot)
we restart redmine and check still have wrong parents
we tried sencond command with the issue ID itself 253921 but it give us error message (attached screen shot)
we restart redmine and check still have wrong parents
pls advise

#7 Updated by Toshi MARUYAMA 3 months ago

Try:

$ RAILS_ENV=production bundle exec rails runner 'Issue.rebuild_tree!'

or

$ RAILS_ENV=production bundle exec rails runner 'Issue.rebuild_single_tree!(1)'

#8 Updated by Randa Bustami 3 months ago

We executed the new commands but still the same error message
pls check attached screenshots

#9 Updated by Toshi MARUYAMA 3 months ago

Try:

$ RAILS_ENV=production bundle exec ruby bin/rails runner 'Issue.rebuild_tree!'

or

$ RAILS_ENV=production bundle exec ruby bin/rails runner 'Issue.rebuild_single_tree!(1)'

#10 Updated by Randa Bustami 3 months ago

we execute the 2 command and attached the result
the rebuild tree command executed but it give error message
the rebuild single tree still cannot find it
this is critical issue for us where we build the structure of our products and must have the correct tree at view (its correct at the edit !)

#11 Updated by Toshi MARUYAMA 3 months ago

Do you revert your source change?

#12 Updated by Randa Bustami 3 months ago

yes we did.
pls see attached screen for the inside code of the file

#13 Updated by Toshi MARUYAMA 3 months ago

Randa Bustami wrote:

yes we did.

It is wrong.
See source:tags/3.4.2/lib/redmine/nested_set/issue_nested_set.rb#L174

#14 Updated by Randa Bustami 3 months ago

sorry i didn't get your point
what is exactly the wrong ?
i compared the 2 code its different ;the file you send me the link and the picture i sent you, the code it different
so how i can fix it in our file?
many thanks for your help i do appreciated

#15 Updated by Randa Bustami 3 months ago

please note we didn't change any code, we use the standard files remdine team release
how come the code of the file we have different from the code here " source:tags/3.4.2/lib/redmine/nested_set/issue_nested_set.rb#L174"

#16 Updated by Toshi MARUYAMA 3 months ago

  • Status changed from Needs feedback to Closed

Please look your source code carefully. rebuild_tree should be no argument.
Please use forum for question.
We don't provide any technical support for specific environment.
I think your issue tree was broken from long ago.
Recent Redmine prevents it.

#17 Updated by Randa Bustami 3 months ago

we had installed the version again from the redmine and the issue is solved
many thanks for your help

Also available in: Atom PDF