11
Gizmhail
Re: A xoops module generator to test
  • 2006/2/5 20:21

  • Gizmhail

  • Just popping in

  • Posts: 15

  • Since: 2005/2/15


I'm still testing Oryxgen, but the result are really nice ^^

While I'm testing it, I'm keeping track of some possible improvements, I'll update them here if you're interested.

For the moment, here is what I've noticed :

* in the generated class, if 2 attributes point to the same table field, they will generate 2 getter function with the same name : getter name should be defined by class attribute name, not target field name
* the imports shouldn't have the directory name hardcoded, but should use $xoopsModule->getVar("dirname") (for instance in generated classes)
* in generated classes, in the toString fucntion, use include_once instead of include
* generate the mysql.sql file
* use a special prexif for table read by oryxgen in the database, to be able to test a module and, in the meantime, edit it (something like (xoops_prexif)_oryxgen_ ). Practically, this prefix should be removed in the generated code

12
Jharis
Re: A xoops module generator to test
  • 2006/2/9 1:42

  • Jharis

  • Just can't stay away

  • Posts: 488

  • Since: 2005/2/13


This is very interesting how is this project going?

don (el paso)
motto - green chili for everything!

13
V6-Maniac
Re: A xoops module generator to test
  • 2006/2/9 1:52

  • V6-Maniac

  • Just popping in

  • Posts: 86

  • Since: 2005/2/15


I'll will watch this project.
I'm look forward to the end result...

14
script_fu
Re: A xoops module generator to test

Yep this is one to bookmark. Is this going to be anything like NoAh ?

15
oryxvet
Re: A xoops module generator to test
  • 2006/2/9 11:00

  • oryxvet

  • Just popping in

  • Posts: 24

  • Since: 2005/4/22


Oryxgen is a XOOPS module generator. All generated module have the same ergonomics like the oxyxgen module with is a generated module.
The generated form is based on a database row identified by an id (entity). You can add entity, modify entity, and delete entity. You can also Add children entity to the entity and perform functionnales actions.

But not all code is generated. There is several possibility of personalization. Here are the principals:

1 - You can add php code a the end of the form by adding a php file named /personnalize/MyClass directory/form_end_MyClass.php

2 - For each class, a /personnalize/MyClass/action_myClass.php exist. In this class you can use this folowing function.
- $this->getobject() to manipulate the current object
- $this->getobjectId() to manipulate the current id (needed when the object is new
- $this->setforward_url($forward_url) to set the next url called
- $this->setMsg(MyMsg) to set the message print after action
- $this->addError(MyMsg) to add message error

In this class, you can code
- In validate function : the functional constraint code. If a error message is adding, the action is not perform.
- In store_before function : the code to perform before store the entity
- In store_after function the code to perfom after store the entity
- The action defined for a class

3 - For each class you can add states. The advance of these various states can be modelled using UML by the stat chart diagram.
If the status is specified in oryxgen as a "php variable" this variable (a Boolean) must be coded in the /personnalize/MyClass/criteria_myClass.inc.php
In oryxgen, you can define for each status the attribute to show.

4 - For each class and each status.
You can add actions. The code of this action must be coded in the /personnalize/MyClass/action_myClass.php as a function. Once the module generated, this function will perform when the user submit action.

5 - If the attribute type is COMBO_PERSO, a file named as the attribute is generated in /personnalize/MyClass directory. You must code the array [key] [value] of the select combo.

6 - If the attribute type is CALULATED, a file as the attribute is generated in /personnalize/MyClass directory. You must code the value a this attribute.

.....

16
mandava_s
Re: A xoops module generator to test
  • 2006/2/21 3:47

  • mandava_s

  • Just popping in

  • Posts: 1

  • Since: 2006/2/21


Hi,

It looks like this is one of the best module, which I am looking.

But I tried to install this module on XOOPS 2.2.3 and I end up with couple of problems.

It looks like you are using some of the form classes instead of XOOPS form classes. It looks like some thing is broken here.

I fixed these 2 problems. Now I am not getting any php errors, but the popup menu for Record, ADD and other operations doesn't show.

1.Need to include formCalander.php file.

2.setid() method not defined in formelement

Do you have any latest version, which I can use with XOOPS 2.2.3.

Thanks,
Mandava.

17
oryxvet
Re: A xoops module generator to test
  • 2006/2/21 10:10

  • oryxvet

  • Just popping in

  • Posts: 24

  • Since: 2005/4/22


Quote:

It looks like this is one of the best module, which I am looking.


Thank

Quote:
But I tried to install this module on XOOPS 2.2.3 and I end up with couple of problems.

I'm sorry ! I currently work on the permission. I don't have new version. The next version will introduce permission : Each class and each attribute will have a permission for each group.

I focus myself on the 2.0.13 XOOPS version.
I'm waiting a stable version of the 2.2.x to looking at these problem. Do you think 2.2.3 is a stable version ? If it is, i can spend a couple of hour to modify oryxgen...

Quote:
Need to include formCalander.php file.

For the calendar :
In 2.0.13 the XoopsFormTextDateSelect don't work well. In the render() function of the class, you can't set the date format as i need. I hope the 2.2.3 can do that...

You must add the file root\class\xoopsform\formcalendar.php in the root\class\oryxgen\form\formloader.php file.

Quote:
setid() method not defined in formelement

For the setId, you must hack the oryxgen formelement : root\class\oryxgen\form\formelement.php .
Adding the code "getId" and "setId" from the
root\class\xoopsform\formelement.php class.

The next version of oryxgen will integrated this code...

Best regard

18
davidl2
Re: A xoops module generator to test
  • 2006/2/21 12:48

  • davidl2

  • XOOPS is my life!

  • Posts: 4843

  • Since: 2003/5/26


Don't forget that XOOPS 2.3 will be more based on 2.0 code, then 2.2 - so my own suggestion would be to keep development on 2.0 for the moment.

19
avoulvou
Re: A xoops module generator to test
  • 2006/4/1 21:47

  • avoulvou

  • Just popping in

  • Posts: 41

  • Since: 2006/2/23


I'll will watch this project.
I'm look forward to the end result...
http://xoops.gr - XOOPS.gr Greek Support

Login

Who's Online

158 user(s) are online (102 user(s) are browsing Support Forums)


Members: 0


Guests: 158


more...

Donat-O-Meter

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

Latest GitHub Commits