We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 37042
    • 384 Posts

    With the right development skills, would the following be possible with Revo 2.x or is such a fundamental data model change more suitable to upcoming MODX 3?

    * Create a new type of Resource called an 'entry'.
    * An entry is a single piece of content consisting of one or more TVs but is free from Template assignment.
    * A bunch of related entries ( EG Mazda, Volvo, Ford) could be displayed in the MODX Tree as children of a normal Resource Container titled 'Car'
    * The entries stored under 'Cars' can be displayed, managed and edited with in the Manager within a grid

    Obviously, it's a very similar data-model to some other CMSs but was curious how achievable it is / can be in Revo.
      ...
      • 4172
      • 5,888 Posts
      Is there a reason, you want them to be Resources and you want them to be in the Resource-Tree?

      Can't the entries just be entries in a Custom-table, which you manage within a CMP (Custom-Manager-Page), for example created with help of MIGXdb?
        -------------------------------

        you can buy me a beer, if you like MIGX

        http://webcmsolutions.de/migx.html

        Thanks!
        • 8274 ☆ A M B ☆
        • 222 Posts
        You could look into a Custom Resource Class:
        http://rtfm.modx.com/revolution/2.x/developing-in-modx/advanced-development/custom-resource-classes/creating-a-resource-class

        It allows you to extend the Resource class, and possibly hide the template field (you'll need to set it to "0" which equals empty template), as well as any other you don't want. It still save the data to the mod_site_content table (in case you were planning on using something like getResources to collect the items).

        Brunos suggestion of a migxdb cmp is a good one as well (just used that to create a product catalog manager).
          • 37042
          • 384 Posts
          Quote from: Bruno17 at Dec 29, 2013, 07:15 AM
          Is there a reason, you want them to be Resources and you want them to be in the Resource-Tree?

          Can't the entries just be entries in a Custom-table, which you manage within a CMP (Custom-Manager-Page), for example created with help of MIGXdb?

          Hi Bruno.
          No, I suppose the children don't need to be in the tree but the parent container should be.
          BTW I know and use MIGX across a few sites and am aware it works almost identically to the requirements above. Was just wondering about other options or even plans for native entry types in Revo 2.X or 3
            ...
            • 4172
            • 5,888 Posts
            I didn't try that, but I think it shouldn't be that difficult to create a custom resource-class as your containers, where you have just a MIGXdb - TV - grid to manage your entries, which can be stored in a custom-table, connected with a resource_id - field to the container-resource.
              -------------------------------

              you can buy me a beer, if you like MIGX

              http://webcmsolutions.de/migx.html

              Thanks!
              • 8274 ☆ A M B ☆
              • 222 Posts
              If you just want to clean up your resource tree, and need something simple, you could look at the extra Collections, which hides the children from the tree and puts them into a grid on the parent page tab. Sort of depends on how custom you need this to be (using the modx_site_content table vs a custom table).