is there a way to change item numbers in bom table to level numbers?

hi,

i'm wondering whether there is a way to change indentende item numbers to stage levels as follows:

  

ITEMPART NUMBER
1bomtest1.1
2bomtest2
2.1  bomtest3
2.1.1    bomtest1.2
2.1.2    bomtest1.3
2.2  bomtest1.4

TO

LEVELPART NUMBER
1bomtest1.1
1bomtest2
2  bomtest3
3    bomtest1.2
3    bomtest1.3
2  bomtest1.4

thanks all.

SolidworksDrawings And Detailing