Fix status calculation form xml card index
Merge pull request #1029 from nlegoff/fix1713

[3.8] Fix status calculation form xml card index for stories as well
Merge branch '3.8'

Conflicts:
	lib/classes/task/period/archive.php