Welcome, Guest
Username: Password: Remember me

TOPIC: [SOLVED] Can not view layout

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

  • teg
  • teg's Avatar
  • Offline
  • New Member
  • Posts: 11
  • Karma: 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
The administrator has disabled public write access.

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

  • admin
  • admin's Avatar
  • Offline
  • Administrator
  • Chef
  • Posts: 3711
  • Thank you received: 987
  • Karma: 140
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
The administrator has disabled public write access.

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

  • teg
  • teg's Avatar
  • Offline
  • New Member
  • Posts: 11
  • Karma: 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
The administrator has disabled public write access.
Time to create page: 0.088 seconds

Get Started