11
timgno
Re: Pre-alpha Module Restaurants v1.0
  • 2016/7/25 20:00

  • timgno

  • Module Developer

  • Posts: 1504

  • Since: 2007/6/21


Thanks Mamba!

I will do so, however, the Oledrion module is really outdated, it is worth to change it, when I create a base with tdmcreate 1.91?

This is exactly what I wanted to do with jquery, use for example an add form element to allow customers to add all the dishes and have the end the total expenditure price.



12
timgno
Re: Pre-alpha Module Restaurants v1.0
  • 2016/7/25 8:35

  • timgno

  • Module Developer

  • Posts: 1504

  • Since: 2007/6/21


Quote:
winecard? ;)

This is good ;)

Thank you!

In addition to customer lists, what can we add?



13
timgno
Pre-alpha Module Restaurants v1.0
  • 2016/7/24 16:43

  • timgno

  • Module Developer

  • Posts: 1504

  • Since: 2007/6/21


Hello to all!

I am creating a module restaurants, I have in mind to use the tables for the database: location, menu, ...

What could be more to add?

Thanks for your help

When it is ready, I add it on github.



14
timgno
Re: strtotime in edit mod
  • 2016/6/7 18:59

  • timgno

  • Module Developer

  • Posts: 1504

  • Since: 2007/6/21





15
timgno
Re: strtotime in edit mod
  • 2016/6/6 16:00

  • timgno

  • Module Developer

  • Posts: 1504

  • Since: 2007/6/21


I noticed that even for xoops a part of the class remained unchanged

case 'mysql'
                
$datestring 'Y-m-d H:i:s'
                break;


You could add this constant, right?

case 'mysql'
                
$datestring _DBTIMESTAMPSTRING
                break;


I think that there are too few cases of format, for what it offers php, we should exploit all



16
timgno
Re: strtotime in edit mod
  • 2016/6/5 22:42

  • timgno

  • Module Developer

  • Posts: 1504

  • Since: 2007/6/21


Sorry,

I think have forgotten that I used formatTimeStamp with a new constant

but in reality the function is missing that I created again:

switch ($format) {
            case 
's':
                
$datestring _SHORTDATESTRING;
                break;

            case 
'm':
                
$datestring _MEDIUMDATESTRING;
                break;

            case 
'mysql':
                
$datestring 'Y-m-d H:i:s';
                break;

            case 
'l':
                
$datestring _DATESTRING;
                break;

            case 
'c':
            case 
'custom':
                static 
$current_timestamp$today_timestamp$monthy_timestamp;
                if (!isset(
$current_timestamp)) {
                    
$current_timestamp xoops_getUserTimestamp(time(), $timeoffset);
                }
                if (!isset(
$today_timestamp)) {
                    
$today_timestamp mktime(000date('m'$current_timestamp), date('d'$current_timestamp), date('Y'$current_timestamp));
                }

                if (
abs($elapse_today $usertimestamp $today_timestamp) < 24 60 60) {
                    
$datestring = ($elapse_today 0) ? _TODAY _YESTERDAY;
                } else {
                    if (!isset(
$monthy_timestamp)) {
                        
$monthy_timestamp[0] = mktime(00000date('Y'$current_timestamp));
                        
$monthy_timestamp[1] = mktime(00000date('Y'$current_timestamp) + 1);
                    }
                    
$datestring _YEARMONTHDAY;
                    if (
$usertimestamp >= $monthy_timestamp[0] && $usertimestamp $monthy_timestamp[1]) {
                        
$datestring _MONTHDAY;
                    }
                }
                break;

            default:
                
$datestring _DATESTRING;
                if (
$format != '') {
                    
$datestring $format_copy;
                }
                break;
        }



17
timgno
Re: strtotime in edit mod
  • 2016/6/5 22:18

  • timgno

  • Module Developer

  • Posts: 1504

  • Since: 2007/6/21


Quote:
Mamba wrote:
a) people feel sorry for you?
b) people to help you?


I show you what happens to me...

I modified the constants like this:

https://xoops.org/modules/newbb/viewto ... id=360272#forumpost360272

Today is 06/06/2016

While I get this 05/06/2016 when I use formtextdateselect

Because I want to display the date in this format dd/mm/yyyy with (d/m/Y)

The code of the class formtextdateselect was only replaced the constant _DATESTRING_M

Instead of writing in constant (j/m/Y), I changed to (d/m/Y)

This is a new module events

The variable appears to be correct, I did a lot of testing

$eventsObj->setVar('event_date'strtotime($_POST['event_date']));



18
timgno
Re: strtotime in edit mod
  • 2016/6/5 18:37

  • timgno

  • Module Developer

  • Posts: 1504

  • Since: 2007/6/21


Why, now marks a day before?

Really strange!



19
timgno
TDMCreate GitBook
  • 2016/6/5 10:01

  • timgno

  • Module Developer

  • Posts: 1504

  • Since: 2007/6/21


Created GitBook of this module

I need collaborations

https://www.gitbook.com/book/txmodxoops/tdmcreate/details



20
timgno
Re: strtotime in edit mod
  • 2016/6/5 7:46

  • timgno

  • Module Developer

  • Posts: 1504

  • Since: 2007/6/21


Quote:
Which module (or XOOPS function/method) is having a problem before you change the DATESTRING(s)?


On all modules




TopTop
« 1 (2) 3 4 5 ... 113 »



Login

Who's Online

52 user(s) are online (26 user(s) are browsing Support Forums)


Members: 0


Guests: 52


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Jul 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits