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

Bill::create silently failing #506

Open
hyphen81 opened this issue Dec 6, 2023 · 0 comments
Open

Bill::create silently failing #506

hyphen81 opened this issue Dec 6, 2023 · 0 comments

Comments

@hyphen81
Copy link

hyphen81 commented Dec 6, 2023

I'm calling the Bill and/or VendorCredit facade like so:

Bill::create([
[
      'DocNumber' => '12345678',
      'TxnDate' => 2023-12-06,
      'Line' => [
        'DetailType' => 'AccountBasedExpenseLineDetail',
        'Amount' => 23.12,
        'AccountBasedExpenseLineDetail' => [
          'AccountRef' => [
            'value' => 150
          ]
        ]
      ],
      'VendorRef' => [
        'value' => 175
      ]
    ]
])

However, nothing gets returned. I added some logging to the bill class, and I can see the data that's passed in is correct, but it never gets to the second log statement. It seems to be silently failing somewhere and I can't figure out where.

Seems to be something in the FacadeHelper::reflectArrayToObject method.

 Log::debug($data);
        $BillObject = FacadeHelper::reflectArrayToObject("Bill", $data, $throwException);
        Log::debug($BillObject); <-- never gets here

Has anyone else run into this?

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

1 participant