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

TOPIC:

Can not view layout 26 Aug 2013 09:14 #10907

  • teg
  • teg's Avatar Topic Author
  • Offline
  • New Member
  • New Member
  • Posts: 11
  • Thank you received: 0
In project Tour Management
I can not view layout Order Item in backend when running sandbox
It shows a message:
Fatal error: Cannot use object of type JForm as array in /home/cook/sites/www.j-cook.net/public_html/sandbox/cms30/administrator/components/com_demo9509/views/orderitem/view.html.php on line 92
Error : Cannot use object of type JForm as array


Please help me.

How can i fix it?
Thanks

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

Can not view layout 26 Aug 2013 10:44 #10909

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 986
I have checked you project.


This is because you have confusion in the table's names and aliases.
In TABLE ALIAS, the '_' (underscore) is not allowed.
I know, still there is a little issue, and sometimes you can do it.
Please remove all underscores there.

Table : order_item
Alias becomes : 'orderitem'
But this is already used by the 'order' table.
You have a big confusion there.

I suggest you :

Table ORDERS :
Alias table : orders
Alias item : order

Table ITEMS
Alias table : items
Alias item : item

Well, Using 'order(s)' and 'item(s)' is quite confusing also because are developper language, but you can because they are not reserved.

I already answered to you few days (or week) ago.

If you need help, I can do it
Coding is now a piece of cake

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

Can not view layout 27 Aug 2013 02:39 #10915

  • teg
  • teg's Avatar Topic Author
  • Offline
  • New Member
  • New Member
  • Posts: 11
  • Thank you received: 0
Hi,
We had designed database before applied to J-Cook.
1. And we had some tables have to have the '_' (underscore).
But like you said: "In TABLE ALIAS, the '_' (underscore) is not allowed."

That means: we can't not name table that has the underscore, can we?

2. We need to have Order_item table, but this alias have been used by Order table.
so, why J-cook don't use the name of views like Joomla?
Ex: Article: With the collection, it uses: articles
and with the item, it uses: article

As this way, in this project, Order table will have 2 views: orders and order
and Oder_item table have 2 views: orderitems and orderitem.

If, i want to fix that issue, i have to change the alias of table, that's mean i have to change the name of table order_item?

Thanks and
Regards

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

  • Page:
  • 1
Time to create page: 0.081 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