0
I have discovered a pretty minor issue; however, it results in a fatal error, so fixing it may be a good idea.

Joomla adds " 00:00:00" to the end of the date when opening an item to edit it.. This causes a fatal error because administrator/components/com_finances/models/item.php on line 101 the PHP uses the "Y-m-d" format.

For reference I am running EM 3.0.2, IM 2.0.1, IM/EM Plugin 1.0.2 and Joomla 3.5.1.

Accepted Answer

Wednesday, June 15 2016, 08:59 AM - #Permalink
0
Thanks Dan,

I believe we have been able to stop the error and solve it.

If you download the latest version (3.0.3), and install it, this issue should be gone.
The reply is currently minimized Show
Responses (3)
  • Accepted Answer

    Sunday, June 12 2016, 09:36 AM - #Permalink
    0
    hmm.. that's weird, I am pretty sure that this issue was solved. looks like it's not yet. I'll take a look at this.

    thanks!
    The reply is currently minimized Show
  • Accepted Answer

    Joan Vilà
    Joan Vilà
    Offline
    Monday, June 13 2016, 11:04 AM - #Permalink
    0
    Hello Daniel,

    I'm trying to reporduce the problem you are having. I can see the 00:00:00 in the date field when editting an expense from the backend. However, this isn't causing any problem to me when I save the expense.

    Could you tell me when do you get the fatal error? Which action are you doing when it happens?

    Thank you,
    Joan
    The reply is currently minimized Show
  • Accepted Answer

    Wednesday, June 15 2016, 03:27 AM - #Permalink
    0
    This is how I reproduce the problem.

    1. I create a new item in expense manager. (The date field is filled with the current date by default. The default can be used or the date can be changed.)
    2. Save the item. (Once the page reloads after the save the 00:00:00 is added to the end of the date.)
    3. Click save again. This should result in the following message "Fatal error: Call to a member function format() on a non-object in /home/site/public_html/administrator/components/com_finances/models/item.php on line 101"

    It can also be reproduced by manually typing anything other than a Y-m-d format and attempting to save. However, double digit years and single digit months and days are accepted, but returned after save in the standard Y-m-d format. Manual misentry causes the same error for End and Next recurrency date fields as well (errors on item.php lines 109 and 105 respectively). However, 00:00:00 is not added to the recurrency fields after save when entering the date correctly.

    It can also be reproduced by deleting the date and attempting to save.

    00:00:00 is not added on the frontend. Manually entering 00:00:00 on the frontend does not cause any error.

    EM options are set to use the default date format "%Y-%m-%d".

    I hope this helps.
    Dan
    The reply is currently minimized Show
Your Reply