Jump to content

Choose custom repeater template


Sipho
 Share

Recommended Posts

Is there a module or plugin that is like a repeater but you can choose a template? I want something that let's me:

  • choose a template to get fields from,
  • display these fields like a repeater does
  • add new pages without adding a title or name (this might be achievable using other means like ProcessSetupPageName
  • delete pages

I feel like somebody might have already made a module that does just this, however, I haven't found any. Perhaps there is a way of doing this with a standard repeater that I don't know about.

Link to comment
Share on other sites

@bernhard I am aware of PageTable but it doesn't suit my needs. I want it to be editable directly on the page without having to click on a link to open a modal. Like a repeater does it. PageTable is exactly what I want apart from that. Sorry I didn't make that clear.

Link to comment
Share on other sites

@bernhard It won't be just simple text so handsontable is out. ListerPro looks interesting but still inconvenient and not free.

@adrian Can you choose a template for Repeater Matrices? From what I can gather it's the same as a repeater but you can have more than one 'field set'. The reason I wan't to be able to specify the template is because I want them to be actual pages that an end-user can visit. Being able to edit them inside a page without opening a modal is just for convenience. They should still behave as proper unhidden and non-admin pages. I could just use a PageTable but it is such a hassle.

Link to comment
Share on other sites

@Sipho - You can choose different templates for Repeater Matrix fields - that link I provided shows examples and states:

Quote

The types that you see there are configured with the field, and you can create as many different types as you want.

But, as with repeaters, they are not pages with URLs that can be directly visited - you could probably "fake" this by using URL segments on the parent page and use the passed values to determine which repeater item to show.

OT - I completely agree that the PageTable interface is not ideal - seems to me we need the repeater matrix editing interface for PageTable fields as well. When the PageTable field was added, repeaters didn't support ajax loading, hence the modal editing interface to ensure it was scalable with lots of items.

  • Like 4
Link to comment
Share on other sites

9 hours ago, adrian said:

OT - I completely agree that the PageTable interface is not ideal - seems to me we need the repeater matrix editing interface for PageTable fields as well.

+1
PageTable is in desperate need of a big feature upgrade. However, as it is a byproduct of Avoine's need and neither Ryan nor Avoine seems to be interested in pushing it any further, an organized community effort or better yet the very first "crowdfunding" in ProcessWire history could give it boost. I would be happy to join in the fun :) Maybe @teppo could help us by including this feature request in an upcoming poll of weekly.pw, just like he did with Import/Export.

Edited by szabesz
funding :)
  • Like 1
Link to comment
Share on other sites

50 minutes ago, szabesz said:

PageTable is in desperate need of a big feature upgrade

what features are you talking about exactly?

I'm using my DataTables Module/Field for all my Projects recently. It's a little bit more effort in the setup but a lot more powerful regarding display features. Though i have to admit that the mobile support could be improved...

I'm using links to pw-modals a lot for editing. So it's not real ajax-inline editing but i like how simple and versatile everything is.

59896e9e5f60f_2017-08-0809_50_45-Kontakte.thumb.png.83ba504296b9ba3a321f4effa483ae51.png

also a nice example:

but there is still a lot to do, so i'm curious what you guys think is missing for pagetables :) crowdfunding would be nice :)

  • Like 1
Link to comment
Share on other sites

Hi Bernhard,

I have not tried your module yet but I gathered that it does not support Page Reference and Image fields the way PageTable or Lister do. Am I right? Simply inputting non relational data is not what I normally need. Sure, there are lots of use cases for non relational data input but your module seems to be conceptually different from PageTable.

What I'm missing form PageTable is column sorting and Ajax editing. Even ListerPro is rather limited regarding Ajax editing an displaying PageArrays ( = fields of related pages ).

One last thing: for important features like this one, I prefer using core/Ryan's modules to anyone else's just because of possible compatibly issues in the future. Do not get me wrong, I do appreciate all the work you are putting into sharing your module(s), however I do not feel comfortable with relying on third party modules which cannot be removed without a lot of effort, should the module get unsupported in the future for some reason.

Edited by szabesz
typo
  • Like 1
Link to comment
Share on other sites

@szabesz I just want some simple AJAX editing for pages :'(. I don't mind about column sorting as much as this. For now I will just continue using PageTables with modal editing, as inconvenient as it is. I would also join in the crowdfunding to push this forward :)

@adrian I really wanted something that did make pages with actual URLs that can be visited. I don't really feel comfortable using Repeaters in that way. It's just not what they were designed for (I think). 

  • Like 1
Link to comment
Share on other sites

@Sipho adrians BCE could also be an option for you. you can also include the lister as field in the page editor:

@szabesz

totally wrong ;) it supports all fields - you just have to write your own return statement. that's what i was talking about: it's a little more effort to setup but it's a LOT more versatile. and it has column sorting and filtering onboard. also pagination of the results. for now it does only support ajax in one whole dataset. so tha pagination is done client side. that would have to be improved for large scale situations but it's totally doable.

for example an image column would be as simple as this: 

Regarding the core-topic: I totally agree and i think it would be awesome if @ryan could take a look at my module and think about adding this to processwire. For me this has been an invaluable benefit in my last years projects... but it's still too incomplete for public use and would need some tweaking regarding support of mobile devices and - even more important - large scale.

  • Like 2
Link to comment
Share on other sites

6 minutes ago, bernhard said:

totally wrong

Good to hear that! :D

6 minutes ago, bernhard said:

adding this to processwire

When doing so, we should make PageTable deprecated I think, and some migrating aid would be great too. Oh well, I'm just daydreaming I guess...

  • Like 1
Link to comment
Share on other sites

1 minute ago, szabesz said:

When doing so, we should make PageTable deprecated I think, and some migrating aid would be great too. Oh well, I'm just daydreaming I guess...

No reason for that i think. it's more an extended MarkupAdminDatatable + Fieldtype than a replacement of PageTable. PageTable is easier to setup and has it's place for other situations / audience.

Link to comment
Share on other sites

1 minute ago, bernhard said:

No reason for that i think.

Then let's "merge" them! I do not see why we would need two similar core modules. It takes extra time to maintain two. There is not enough time for PageTable to begin with, for example see just his topic. A simple enhancement for PageTable which might never find its way to the module :( I do not have the time and expertise to do it properly, that is why I opted for the JS hack, BTW.

Link to comment
Share on other sites

31 minutes ago, bernhard said:

adrians BCE could also be an option for you

@bernhard I don't quite understand how it matches what I described. Doesn't it only let you edit titles? To edit all the fields don't you still have to open a model like a PageTable? Maybe I am missing something. Could you explain how it could be used for what I described?

Link to comment
Share on other sites

3 hours ago, Sipho said:

@bernhard I don't quite understand how it matches what I described. Doesn't it only let you edit titles? To edit all the fields don't you still have to open a model like a PageTable? Maybe I am missing something. Could you explain how it could be used for what I described?

Here is the post with the Lister Mode screenshots: https://processwire.com/talk/topic/6102-batch-child-editor/?do=findComment&comment=100763

You can set it up to edit any/all fields using the Lister interface. The only problem is that it doesn't allow for adding new items/child pages.

 

3 hours ago, Sipho said:

@bernhard To clarify, I basically want a PageTable but with the repeater matrix editing interface as @adrian said.

Maybe what we actually need is to modify the repeater field to allow it to store pages under a specified parent within the page tree, rather than under Admin > Repeaters

  • Like 4
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...