Jump to content
  • 0

successfully added message, but no data inserted in databse


Blesta Addons

Question

today we have found that one of our custom plugin have a strange behavior in v4 . after adding a item, the successfully message appear but no data inserted in database !  , when we left some empty fields it return the error validation for that fields; so the validation pass without any issue, after a search in the forum the same behavior was reported in support manager pro in v4 also, no change made in database.

i was thinking what will be the cause for this behavior ?as no error returned from the Record components or the Input components .

i have added the begin() commit() rollback() fucntion to see what happen but no result, also the error_reporting and the debugger is not catching any error !!!

any idea how to diagnostics the problem ?

Link to comment
Share on other sites

Recommended Posts

  • 0
54 minutes ago, Adam said:

Thats because all the core code uses the dateToUtc function:

http://source-docs.blesta.com/class-AppModel.html#_dateToUtc
 

 

The function basically converts:

2017-04-25T14:43:00+00:00

which as you know is ISO 8601 format (date('c')) to something MySQL understands as explained in their documentation:

2017-04-25 14:43:00

-Adam

I Have opened one file of support manager , and i found they use date('c') in var injected in database.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...