<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body>
    <p>Hi Alexandre, Ross,<br>
    </p>
    <p>Denis recently wrote a plugin that also handles batch management
      of relations.
      <a class="moz-txt-link-freetext" href="https://github.com/opengisch/qgis-relation-batchinsert">https://github.com/opengisch/qgis-relation-batchinsert</a></p>
    <p>He is not reading the qgis user list but would be happy to share
      his thoughts if you get in touch with him.<br>
    </p>
    <p>Best regards</p>
    <p>Matthias</p>
    <div class="moz-cite-prefix">On 3/17/20 2:19 AM, Alexandre Neto
      wrote:<br>
    </div>
    <blockquote type="cite"
cite="mid:CA+H0G_GHgisn+G4DCA2FR+91StpCgiUFQjxAaCUGUsb6my=7xw@mail.gmail.com">
      <meta http-equiv="content-type" content="text/html; charset=UTF-8">
      <div dir="ltr">Hi,
        <div><br>
        </div>
        <div>I have been looking for the same myself. I think I would be
          able to create a "replicate relations" plugin but I am missing
          a step... this one:</div>
        <div><br>
        </div>
        <div><a
href="https://gis.stackexchange.com/questions/353309/open-feature-form-in-multi-edit-mode-using-pyqgis"
            moz-do-not-send="true">https://gis.stackexchange.com/questions/353309/open-feature-form-in-multi-edit-mode-using-pyqgis</a><br>
        </div>
        <div><br>
        </div>
        <div>The idea would be to, for each selected feature, create an
          row in the related table, then open them all with the multi
          editing form.</div>
        <div><br>
        </div>
        <div>Alexandre Neto</div>
      </div>
      <br>
      <div class="gmail_quote">
        <div dir="ltr" class="gmail_attr">On Wed, Oct 2, 2019 at 11:35
          AM McDonaldR <<a href="mailto:McDonaldR@angus.gov.uk"
            moz-do-not-send="true">McDonaldR@angus.gov.uk</a>> wrote:<br>
        </div>
        <blockquote class="gmail_quote" style="margin:0px 0px 0px
          0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
          <div lang="EN-GB">
            <div class="gmail-m_-1013735454861474632WordSection1">
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif">Hi list,</span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif">I’ve got a project set up in
                  QGIS 3.4.x with a parent polygon layer and a child
                  attribute layer.  Each site polygon represents a piece
                  of land and can have multiple tasks associated with it
                  (grass cutting, weeding, pruning, etc.).  Sites can be
                  made up of multiple polygons.</span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif">With relations set up in the
                  project it is easy to select a polygon feature and
                  update attributes.  It is easy to add or edit
                  associated tasks.  See screenshots below.  With
                  multiple site polygons selected I can use the “modify
                  selected attributes simultaneously” to update
                  information.
                </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif">I need to find a way to be
                  able to select site polygons and add the same
                  associated task to each one.  For example, select all
                  site polygons that need grass cutting task associated
                  with them, assign the task and maintain the parent
                  child relationship.  It would be great if there was a
                  way to do this through the form.</span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif">One solution I have been
                  toying with is using a SQL query to select the site
                  polygons and insert into the associated tasks table a
                  new record associated with each polygon.  The query
                  works but I need a way to tie it into the form. 
                  Anyone got any pointers?  Some python to call the SQL
                  and get the selected feature IDs from QGIS?</span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif">Thanks</span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif">Ross</span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif">Screenshot 1:
                  <a
                    href="https://nextcloud.mixedbredie.net/s/D7DFjs2PrcnEf7t"
                    target="_blank" moz-do-not-send="true"><span
                      style="color:windowtext">https://nextcloud.mixedbredie.net/s/D7DFjs2PrcnEf7t</span></a></span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif">Screenshot 2:
                  <a
                    href="https://nextcloud.mixedbredie.net/s/EBzeTopsBcZBSJc"
                    target="_blank" moz-do-not-send="true"><span
                      style="color:windowtext">https://nextcloud.mixedbredie.net/s/EBzeTopsBcZBSJc</span></a>
                </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><span
                  style="font-family:"Century
                  Gothic",sans-serif"> </span></p>
              <p class="MsoNormal"><b><span
                    style="font-size:10pt;font-family:"Century
                    Gothic",sans-serif;color:rgb(79,98,40)">Ross
                    McDonald |
                  </span></b><span
                  style="font-size:10pt;font-family:"Century
                  Gothic",sans-serif;color:rgb(79,98,40)">Geo-evangelist
                  | Angus Council, Digital Enablement and IT | Angus
                  House, Orchardbank Business Park, Sylvie Way, Forfar
                  DD8 1AT<b> | t: 01307 49 22 39</b></span></p>
              <p class="MsoNormal"> </p>
            </div>
            <div> </div>
            <div>
              <p class="MsoNormal" style="margin:0cm 0cm 0pt"><span
                  style="font-size:7.5pt;font-family:Arial,sans-serif"><font
                    size="2">This message is strictly confidential. If
                    you have received this in error, please inform the
                    sender and remove it from your system. If received
                    in error you may not copy, print, forward or use it
                    or any attachment in any way. This message is not
                    capable of creating a legal contract or a binding
                    representation and does not represent the views of
                    Angus Council. Emails may be monitored for security
                    and network management reasons.<span>
                    </span>Messages containing inappropriate content may
                    be intercepted. Angus Council does not accept any
                    liability for any harm that may be caused to the
                    recipient system or data on it by this message or
                    any attachment.
                  </font></span></p>
            </div>
          </div>
          _______________________________________________<br>
          Qgis-user mailing list<br>
          <a href="mailto:Qgis-user@lists.osgeo.org" target="_blank"
            moz-do-not-send="true">Qgis-user@lists.osgeo.org</a><br>
          List info: <a
            href="https://lists.osgeo.org/mailman/listinfo/qgis-user"
            rel="noreferrer" target="_blank" moz-do-not-send="true">https://lists.osgeo.org/mailman/listinfo/qgis-user</a><br>
          Unsubscribe: <a
            href="https://lists.osgeo.org/mailman/listinfo/qgis-user"
            rel="noreferrer" target="_blank" moz-do-not-send="true">https://lists.osgeo.org/mailman/listinfo/qgis-user</a></blockquote>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <pre class="moz-quote-pre" wrap="">_______________________________________________
Qgis-user mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Qgis-user@lists.osgeo.org">Qgis-user@lists.osgeo.org</a>
List info: <a class="moz-txt-link-freetext" href="https://lists.osgeo.org/mailman/listinfo/qgis-user">https://lists.osgeo.org/mailman/listinfo/qgis-user</a>
Unsubscribe: <a class="moz-txt-link-freetext" href="https://lists.osgeo.org/mailman/listinfo/qgis-user">https://lists.osgeo.org/mailman/listinfo/qgis-user</a></pre>
    </blockquote>
  </body>
</html>