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

Get Payslip returns same EarningsRateID for all LeaveEarningsLines (AU Payroll) #575

Closed
humphrey opened this issue Nov 6, 2024 · 5 comments

Comments

@humphrey
Copy link

humphrey commented Nov 6, 2024

SDK you're using (please complete the following information):

  • Version 9.2.0

Describe the bug
API returns the same EarningsRateID (Id in the SDK) for all LeaveEarningsLines. This is not an issue with the SDK as the API Explorer returns these same Id's also. This means that it is impossible to determine the leave type from a PaySlip.

Example output from API explorer:

{
  // ...
  "Payslip": {
     // ...
    "LeaveEarningsLines": [
      {
        "EarningsRateID": "12345678-1234-1234-1234-123456789012",
        "RatePerUnit": 30.72,
        "NumberOfUnits": 30.4,
        "PayOutType": "DEFAULT"
      },
      {
        "EarningsRateID": "12345678-1234-1234-1234-123456789012",
        "RatePerUnit": 5.376,
        "NumberOfUnits": 30.4,
        "PayOutType": "DEFAULT"
      },
      {
        "EarningsRateID": "12345678-1234-1234-1234-123456789012",
        "RatePerUnit": 30.72,
        "NumberOfUnits": 7.6,
        "PayOutType": "DEFAULT"
      }
    ],
    // ...
  }
}

To Reproduce
Create a payslip with mulitple leave earnings lines items or different leave types and call the API. They will all have the same EarningsRateId

Expected behavior
EarningsRateId's that correlate to the leave type

Copy link

github-actions bot commented Nov 6, 2024

PETOSS-669

Copy link

github-actions bot commented Nov 6, 2024

Thanks for raising an issue, a ticket has been created to track your request

@Sallyhornet
Copy link

This is not an issue with the SDK, it is a limitation of the API itself.

At the moment the leave type id is not surfaced in the payslips. All you see is the earnings rate id and this relates to the ordinary earnings rate for the employee as the leave amount is based on the ordinary earnings rate of pay.

@humphrey
Copy link
Author

humphrey commented Nov 7, 2024

Yeah, so basically there is no way of determining the leave type id reliabily. You could compare these values to the leave applications, but this would be ambigous if a leave application spanned over multiple pays. What is the process of requesting this being fixed in the API itself?

@Sallyhornet
Copy link

You could raise a feature request on Uservoice here http://xero.uservoice.com/forums/250567-xero-payroll-api

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

No branches or pull requests

2 participants