AttributeError: 'SalaryStructure' object has no attribute 'set_totals'

I am trying to create a new salary structure. It shows the error - "AttributeError: ‘SalaryStructure’ object has no attribute ‘set_totals’ "

A few minutes back I created another salary structure, it worked fine without this error. What would be the possible reason?

Screenshot