We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 10226
    • 412 Posts
    I am building an intranet site to manage my breeding birds and clutch data and so forth. I planned it out extensively so that I would be able to scale in the future but I have one little issue, here is a diagram (menu structure).

    Summary Page *working - shows in house ref# and breed of bird
    Pair1*stuck on this one - shows details on the pair and has a list of clutches with links
    Cock *working - has bird specific data, band #, value, health notes and such
    Hen *working - same as above
    ClutchX *working - new page per clutch, simple date and band #

    I have a tv [*breeder_sex*] as a list box for cock / hen but on the PairX page. I need to pull the first two pages and determine what one is the cock and hen, and make a link to those respectively. I have yet to enter much of the data but what I have so far is working. Not sure how to get this done... Really I guess I can make sure to create the cock and hen pages in the same order every time that way child one will allways be the cock. But since they are tagged with the above tv I should be able to set this up right so I don’t have to worry about that.
      • 10226
      • 412 Posts
      ok it looks like I need to use filtering. I sat down and tried to figure it out using filters. Still confused.

      So I have ...

      Pair1
      Cock
      Hen

      On the PairX pages, I am only using TV’s so far. Do I need to call a chunk to execute and return the filtered item, or do I do it inline?
        • 18397
        • 3,250 Posts
        Are you saying you would like the Pair#### pages to have two links, one for each gender?
          • 10226
          • 412 Posts
          indeed... that is the issue. I need to get the page for the cock and hen, then make it a link. I have run into a few more as well but that would be a different post. I might be able to solve my problems with the solution to this one though. All these pages call on chunks that return the TV’s. Except the summary page - that uses Ditto.

          I’m a bit stumped lol.
            • 18397
            • 3,250 Posts
            You should just be able to use a normal Ditto call on the PairXX page that uses the following template:
            <a href="[~[+id+]~]" title="[+pagetitle+]">[+pagetitle+]</a>
            

            This would return two links, one for each gender. If the pagetitle is not the gender, replace pagetitle with your tv’s name.
              • 10226
              • 412 Posts
              [+breeder_sex+] is the gender TV, and it is not entered on the Pair## page, it is in the first two child pages. I am starting to think I took the wrong approach to this whole idea.

              The summary page is created by a ditto call as the content of the page. - works
              The pair## page is (now) created by a chunk that calls ditto - this doesn’t work that well. the links return me to the previous page and it doesn’t parse the second ditto call, just shows the code.

              Th rest of the site is primarily driven by Ditto and I have not run into anything like this.
                • 18397
                • 3,250 Posts
                The Ditto call on the Pair## should be returning the two child pages so therefore it would display a link for each gender.
                  • 10226
                  • 412 Posts
                  Mark, on my pair## page, I have the info summarized for the pair, not a list of details for each. I guess I could list both of them. On each pair## page, I call the chunk {{pull_breeder_pair}}, which formats the TV’s and makes the ditto call for the clutch data;

                  [[Ditto?parents=`[~[+id+]~]`&tpl=`clutch_list`&display=`all`]]

                  Tried it cached, returns blank, tried it uncached, returns no documents. So I think there is a confusion of what the parents id is. Am I thinking big and going about this the wrong way?

                  Thanks!
                    • 18397
                    • 3,250 Posts
                    1. [~[+id+]~] will return the processed pages URL only in Ditto.
                    2. Parents will default to the current document if none is passed.
                      • 10226
                      • 412 Posts
                      ok I have put on the big noob hat...

                      since I want the two items formatted in a summary...

                      (and my ill informed logic is below)

                      Do I need to pull that info into an ’invisible’ chunk and somehow feed that to some new placeholders only valid for the actual rendered document.

                      Thanks