arjundass Posted February 10, 2011 Share Posted February 10, 2011 I have created a new field in orders table named date_expiration. I have added this line "" $fields['date_expiration'] = pSQL($this->date_add); "" , to populate this field .I want to add 90 days + date_add to date_expiration field .Kindly help. Link to comment Share on other sites More sharing options...
otzy Posted February 10, 2011 Share Posted February 10, 2011 this is php code, not sqlif $this->date_add is unix timestamp you may add the number of seconds 3600*24*90if $this->date_add is string convert it to time with DateTime::createFromFormat() first, then add seconds.Find the similar example in classes/Discount.php at the end of createOrderDiscount function. Link to comment Share on other sites More sharing options...
arjundass Posted February 10, 2011 Author Share Posted February 10, 2011 Thank you Otzy for reply .I also need to create a new table , i have created in prestashop database. but i can,t able to get any values to it .HOw do i register it in prestashop , to fill it with values like order_id , customer_id ?? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now