We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 28554
    • 201 Posts
    Hi Guys,

    There’s a problem that I run into very often. Sometimes clients want to add data sequentially (for example: a client of mine, a bookings-agency), wants to add a list of releases for every artist), but having them add a Page for this (so I can loop through them with getResources) is kind of overkill. What would be perfect for me to have a tab besides "Template Variables" called something like "Resource Items". Fields could be defined in the same way that template-vars could be assigned to templates:

    - Add Item-type
    - Add fields to Item-type
    - Bind Item-type to template

    Then in the "Resource Items" have them be able to add an Item with all the fields associated. Then you’d need a getResources-like architecture to loop through them, like so (warning: aircode ahead)

    loop the items
    [[getItems
      ?type=`Releases`
      &sortby=`releaseDate`
      &sortdir=`ASC`
      &tpl=`releaseRowTpl`
      &outerTpl=`releaseOuterTpl`
    ]]
    


    releaseRowTpl
    <tr><td>[[§releaseTitle]]</td><td>[[§releaseArtist]]</td><td>[[§releaseDate]]</td></tr>
    


    releaseOuterTpl

    <h2>Releases</h2>
    <table>
    [[+row]]
    </table>
    


    I understand the need for pages etc., but they’re just plain overkill for alot of cases, and I think adding this to Revo as standard (or as a 3PC) would make Revo much more flexible for me.
      • 5689
      • 289 Posts
      I’ve had this thought as well.

      In my case, I set up a contact page on a site using eForm that dynamically loaded a list of recipients for the user to choose from in a drop-down. I ended up creating a resource for each recipient, but I used only the pagetitle field and two template variables--no content, nothing. It felt a lot like overkill.

      I’m not sure what the best way to go about this would be, and in Revolution, I’m thinking the best way might just be to make your own database table and do a bit of custom coding, but it’s worth discussing.
        I&#39;m learning more about MODx all the time and loving it.
        • 28554
        • 201 Posts
        Quote from: Compeek at Jul 18, 2010, 01:32 AM

        I’ve had this thought as well.

        In my case, I set up a contact page on a site using eForm that dynamically loaded a list of recipients for the user to choose from in a drop-down. I ended up creating a resource for each recipient, but I used only the pagetitle field and two template variables--no content, nothing. It felt a lot like overkill.

        I’m not sure what the best way to go about this would be, and in Revolution, I’m thinking the best way might just be to make your own database table and do a bit of custom coding, but it’s worth discussing.

        Yeah I know what you mean, I’m currently having the same problem with a list of employees for an in-development project. I understand the custom-coding argument, but I’m a front-ender (HTML, CSS, JS), and having this in some way standardized would make this alot easier for me then setting up a custom table. I understand how I would read them out for the front-end, but writing the code for the back-end administration for stuff like this is just totally beyond me, and I can think of enough use-cases to consider this fair game for core-functionality.
          • 28042 ☆ A M B ☆
          • 24,524 Posts
          I don’t know how closely Quip for Revo corresponds to Jot for Evo, but for simple lists like employee lists, wine lists, anything like that, I find Jot to be very useful. It’s not difficult to load the resource browser into its form so you can upload/select images. It allows for custom fields, so you can save just about any kind of data you want. And you can display it in different places using different output templates. For example, I have one site’s sponsors listed using it, and on the home page there is a sidebar block displaying their logs in a carousel, while in the Our Sponsors page they are listed in more detail. And you can have the choice of using Manager users to manage the list, or create web users for those who don’t want to bother setting up Manager redirects and what-have-you.
            Studying MODX in the desert - http://sottwell.com
            Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
            Join the Slack Community - http://modx.org
            • 28554
            • 201 Posts
            Quote from: sottwell at Jul 18, 2010, 10:32 AM

            I don’t know how closely Quip for Revo corresponds to Jot for Evo, but for simple lists like employee lists, wine lists, anything like that, I find Jot to be very useful. It’s not difficult to load the resource browser into its form so you can upload/select images. It allows for custom fields, so you can save just about any kind of data you want. And you can display it in different places using different output templates. For example, I have one site’s sponsors listed using it, and on the home page there is a sidebar block displaying their logs in a carousel, while in the Our Sponsors page they are listed in more detail. And you can have the choice of using Manager users to manage the list, or create web users for those who don’t want to bother setting up Manager redirects and what-have-you.

            I understand what you mean. I think Quip would "do the trick", but I’d be shoehorning it to do something it isn’t actually meant to do, and I’d fragment management of content to the frontend, instead of keeping everything in the backend...
              • 28554
              • 201 Posts
              I know MODx is MODx, and it has it’s own approach, but I think ExpressionEngine has a rather nice approach to this. You can add channels, which can have entries. Entries aren’t pages per se, but can be showed on pages (basically the same way getResources loops through children of a certain page). Every channel has entry-types, and every entry-type can have custom fields.
                • 28554
                • 201 Posts
                This is basically what I mean:

                http://devot-ee.com/add-ons/matrix/

                :)
                  • 28042 ☆ A M B ☆
                  • 24,524 Posts
                  Isn’t that sort of like custom TVs?
                    Studying MODX in the desert - http://sottwell.com
                    Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
                    Join the Slack Community - http://modx.org
                    • 5689
                    • 289 Posts
                    No, because TV values are tied to a certain resource. The idea here is that we might have data that has nothing to do with specific pages, but we want the freedom to manage it easily.
                      I&#39;m learning more about MODx all the time and loving it.
                      • 28554
                      • 201 Posts
                      Exactly. Say for example you want to manage an Address Book. It doesn’t make any sense using pages + getResources for this, since a page is just overkill, but having someone write a specific plug-in for the exact needs of an Address Book sounds rather ridiculous to me too. Having a mechanism for these sort of listings etc. would mean 3PC-developers don’t have to waste time writing a 3PC for something frivolous like this, and would save front-end developers / implementers the hassle of installing plugins for each and every of these small extras they want in their website. I can think of the following examples for my own clients:

                      - Per artist a listing of released records
                      - Adding artists to the line-up of an event
                      - Adding quotes / testimonials to a frontpage
                      - Adding employees to a company-overview