Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1

TOPIC:

Bug on the CREATION DATE / MODIFICATION DATE?! 31 Jan 2013 07:39 #6578

If I select UNIX time, in the option of the field, the FORMAT data is stored correctly into the DB, BUT the value is WRONG.

the following code (in the model or table, it depends by the config of your component in the jcook builder):
			// New item.
			if (!intval($this->creation_date))
				$this->creation_date = $date->toSql();

and
			// Existing item
			$this->modification_date = $date->toSql();

should be simply replaced with:
			// New item.
			if (!intval($this->creation_date))
				$this->creation_date = time();

and
			// Existing item
			$this->modification_date = time();

Please Log in or Create an account to join the conversation.

Re: Bug on the CREATION DATE / MODIFICATION DATE?! 31 Jan 2013 08:19 #6582

Because then I have to add more code to make it to check if the item is new or old, etc. etc.

But I guess you are replying here to my other post :huh: :

CREATION DATE / MODIFICATION DATE with TIME

Because on this post I'm just saying that if I select an option on the builder, the feature is not working.

Please Log in or Create an account to join the conversation.

Re: Bug on the CREATION DATE / MODIFICATION DATE?! 31 Jan 2013 08:45 #6583

  • JoomGuy
  • JoomGuy's Avatar
  • Offline
  • Moderator
  • Moderator
  • Joomla Enthusiast, Lover of Cooking
  • Posts: 1115
  • Thank you received: 195
Sorry @Tomaselli,

you are correct, I was replying to the other topic, not this one...

Post moved!

G
Need help with your Cook/Joomla Project? . PM me to find out what I can help with. NO time wasters please!!!

Please Log in or Create an account to join the conversation.

Re: Bug on the CREATION DATE / MODIFICATION DATE?! 07 Aug 2013 16:42 #10713

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 986
Fixed now.

There was still an issue with unix dates.
Coding is now a piece of cake
The following user(s) said Thank You: Tomaselli

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
Time to create page: 0.083 seconds

I jumped and started to work on a demo component... but 2 days later this demo component became the real component. I just showed today the end result to my customer and he turned to me and said... "this is more than I expected"... All of this is because Cook did cut about 70% of my work and provided me more ways to improve the usability of the component. The end result was 17 tables all related between than to generate a full dashboard for the travel agents. Thanks for Cook developers for such great tool. This component would not be possible to be done at short time with all the features in it
Griiettner (Forum)  

Get Started