help to better help you:
Please: add always Joomla / JEM version and details to your posts, so we can try to reproduce your issue!
Eventslist-View | modifying template (w.i.p.)
Eventslist-View | modifying template (w.i.p.)
9 years 1 month ago - 9 years 1 month ago
Joomla: 3.4.5
JEM: 2.1.5
Maybe usefull or not but am going to modify the layout of the default "eventslist" view.
Basicly i do want to have a filter, but i don't want to have it in the current table layout.
The thing i'm thinking of will be more in the the way it's displayed in the topic.
www.joomlaeventmanager.net/forum/tutorials/9439-module-wide-icomoon-font-for-clock-display-label-for-date#20224
When modifying the file in the component folder it will be overwritten by an update so using the override folder would be good. Am thinking of adding a new tmpl file so there can be a choice between default / other layout. And yep in my case i do know how to modify the files.
Won't go into detail, but if there is anything to post i'll try to do so
Also good to know: changes won't be committed to Github
as stated "work in progress...."
Greetings,
Blue
JEM: 2.1.5
Maybe usefull or not but am going to modify the layout of the default "eventslist" view.
Basicly i do want to have a filter, but i don't want to have it in the current table layout.
The thing i'm thinking of will be more in the the way it's displayed in the topic.
www.joomlaeventmanager.net/forum/tutorials/9439-module-wide-icomoon-font-for-clock-display-label-for-date#20224
When modifying the file in the component folder it will be overwritten by an update so using the override folder would be good. Am thinking of adding a new tmpl file so there can be a choice between default / other layout. And yep in my case i do know how to modify the files.
Won't go into detail, but if there is anything to post i'll try to do so
Also good to know: changes won't be committed to Github
as stated "work in progress...."
Greetings,
Blue
Last edit: 9 years 1 month ago by Bluefox.
Please Log in or Create an account to join the conversation.
Re: Eventslist - modifying template - (w.i.p.)
9 years 1 month ago - 9 years 1 month ago
perhaps it would be better to say - the simplelist view . eventslist gives sometimes misunderstandings in my brain.
I am wondering. Could this be in a form of a template? So admin can choose?
I am wondering. Could this be in a form of a template? So admin can choose?
Last edit: 9 years 1 month ago by jojo12.
Please Log in or Create an account to join the conversation.
Re: Eventslist - modifying template - (w.i.p.)
9 years 1 month agoYou are right it was better to rename the title of the topic..perhaps it would be better to say - the simplelist view . eventslist gives sometimes misunderstandings in my brain.
Yes, but it will require a change in the eventslist-view default.xml file.I am wondering. Could this be in a form of a template? So admin can choose?
Did add a custom field of type "componentlayout" to it and doing so it was possible to select the file needed.
That file was located in the templates/protostar/html/com_jem/eventslist folder.
But did also remove the common folder and changed the view.html.php
Please Log in or Create an account to join the conversation.
Re: Eventslist - modifying template - (w.i.p.)
9 years 1 month ago - 9 years 1 month ago
changes in the component folder..
and yep there are probably better ways.
default.xml
Added this in the default.xml
view.html.php
and that means you have to copy the default_event_table.php from the "common" folder. The reason for me to alter it as i don't like to have the files seperated from the view. It will mean that if you want to have the layout in the other views too you have to copy/edit things for the individual views. and yep can also remove the lines but decided to disable the lines first so it's easier to revert.
...to be continued...
and yep there are probably better ways.
default.xml
Added this in the default.xml
Code:
<field name="mylayout" type="componentlayout" extension="com_jem" view="eventslist" label="JFIELD_ALT_LAYOUT" useglobal="true" description="JFIELD_ALT_COMPONENT_LAYOUT" />
view.html.php
Code:
defined('_JEXEC') or die;
// require JPATH_COMPONENT_SITE.'/classes/view.class.php';
/**
* Eventslist-View
*/
class JemViewEventslist extends JViewLegacy
{
function __construct($config = array())
{
parent::__construct($config);
// additional path for common templates + corresponding override path
// $this->addCommonTemplatePath();
}
.................
....................
/**
* Adds a row to data indicating even/odd row number
*
* @return object $rows
*/
public function getRows($rowname = "rows")
{
if (!isset($this->$rowname) || !count($this->$rowname)) {
return;
}
$k = 0;
foreach($this->$rowname as $row) {
$row->odd = $k;
$k = 1 - $k;
}
return $this->$rowname;
}
and that means you have to copy the default_event_table.php from the "common" folder. The reason for me to alter it as i don't like to have the files seperated from the view. It will mean that if you want to have the layout in the other views too you have to copy/edit things for the individual views. and yep can also remove the lines but decided to disable the lines first so it's easier to revert.
...to be continued...
Last edit: 9 years 1 month ago by Bluefox.
Please Log in or Create an account to join the conversation.
Re: Eventslist - modifying template - (w.i.p.)
9 years 1 month ago
you're right - I remember - when there came this common way, I was wondering. But for me it was always a bit strange to search it in common
Please Log in or Create an account to join the conversation.
Re: Eventslist - modifying template - (w.i.p.)
9 years 1 month ago
about the layout
there are all kind of ways possible to display the events but was wondering if you (or others) do have suggestions of how you like it to be displayed? Maybe it can be usefull in the future and maybe some of it can be added to Github. It would be nice if you have screenshots/live links as it will be better to get the picture then words.
there are all kind of ways possible to display the events but was wondering if you (or others) do have suggestions of how you like it to be displayed? Maybe it can be usefull in the future and maybe some of it can be added to Github. It would be nice if you have screenshots/live links as it will be better to get the picture then words.
Please Log in or Create an account to join the conversation.
Time to create page: 0.545 seconds