Prefill webform with civicrm activity dataHow do I setup a webform so that an existing activity in a case is updated?How to set up the filtering in Drupal Views to target the correct CiviCRM ActivityAny best practices/tips for creating a query view against contacts to used with webforms?How do you create a new custom table tied to case type?Removing Membership Status Message on Front End WebformUpdating Civicrm Activities with Drupal WebformsShould the link between an Activity and any Follow Up activity be visible through the UIHow to recover deleted (?) activityDrupal Webform for Activities - CiviCRM Permissions

Was Wayne Brady considered a guest star on the original "Whose Line Is It Anyway?"

Is having your hand in your pocket during a presentation bad?

Self-learning Calculus. Where does Lang's First Course in Calculus stay when compared to Apostol/Spivak/Courant

A goat is tied to the corner of a shed

Why has Donald Trump's popularity remained so stable over a rather long period of time?

How much money should I save in order to generate $1000/month for the rest of my life?

Does the Flixbus N770 from Antwerp to Copenhagen go by ferry to Denmark

What if you can't publish in very high impact journal or top conference during your PhD?

Does permanent loss of castling rights reset three fold repetition

3x3 self-descriptive squares

Which accidental continues through the bar?

Would we have more than 8 minutes of light, if the sun "went out"?

A sentient carnivorous species trying to preserve life. How could they find a new food source?

Why is there no logical not operator (!!) in C-style languages?

Why didn't Snape ask Dumbledore why he let "Moody" search his office?

This fell out of my toilet when I unscrewed the supply line. What is it?

What if a quote contains an error

Should I reveal productivity tricks to peers, or keep them to myself in order to be more productive than the others?

Why do previous versions of Debian packages vanish in the package repositories? (highly relevant for version-controlled system configuration)

Rat proofing compost bin but allowing worms in

Is cloning illegal in the Star Trek: TNG continuity?

Meaning/translation of title "The Light Fantastic" By Terry Pratchett

one-liner vs script

Should I be able to see patterns in a HS256 encoded JWT?



Prefill webform with civicrm activity data


How do I setup a webform so that an existing activity in a case is updated?How to set up the filtering in Drupal Views to target the correct CiviCRM ActivityAny best practices/tips for creating a query view against contacts to used with webforms?How do you create a new custom table tied to case type?Removing Membership Status Message on Front End WebformUpdating Civicrm Activities with Drupal WebformsShould the link between an Activity and any Follow Up activity be visible through the UIHow to recover deleted (?) activityDrupal Webform for Activities - CiviCRM Permissions






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty
margin-bottom:0;









3















I want to prefill a webform with data from a specific CiviCRM activity in order to edit the activity using the webform. I want to do this by having an "Edit" link in a Drupal View of CiviCRM activities. These activities may or may not be associated with a case, so let's assume they aren't. I've turned on "Update Existing Activity" in the webform for all of the statuses.



Can someone confirm that I can do this, and if so, what is the proper form of the URL for the link in the view? I've tried a bunch of different ones and can't seem to get it.










share|improve this question
































    3















    I want to prefill a webform with data from a specific CiviCRM activity in order to edit the activity using the webform. I want to do this by having an "Edit" link in a Drupal View of CiviCRM activities. These activities may or may not be associated with a case, so let's assume they aren't. I've turned on "Update Existing Activity" in the webform for all of the statuses.



    Can someone confirm that I can do this, and if so, what is the proper form of the URL for the link in the view? I've tried a bunch of different ones and can't seem to get it.










    share|improve this question




























      3












      3








      3








      I want to prefill a webform with data from a specific CiviCRM activity in order to edit the activity using the webform. I want to do this by having an "Edit" link in a Drupal View of CiviCRM activities. These activities may or may not be associated with a case, so let's assume they aren't. I've turned on "Update Existing Activity" in the webform for all of the statuses.



      Can someone confirm that I can do this, and if so, what is the proper form of the URL for the link in the view? I've tried a bunch of different ones and can't seem to get it.










      share|improve this question
















      I want to prefill a webform with data from a specific CiviCRM activity in order to edit the activity using the webform. I want to do this by having an "Edit" link in a Drupal View of CiviCRM activities. These activities may or may not be associated with a case, so let's assume they aren't. I've turned on "Update Existing Activity" in the webform for all of the statuses.



      Can someone confirm that I can do this, and if so, what is the proper form of the URL for the link in the view? I've tried a bunch of different ones and can't seem to get it.







      drupal webform-civicrm activities






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited 3 hours ago









      KarinG - Semper IT

      11.6k1 gold badge8 silver badges39 bronze badges




      11.6k1 gold badge8 silver badges39 bronze badges










      asked 8 hours ago









      guyiacguyiac

      3051 silver badge7 bronze badges




      3051 silver badge7 bronze badges























          2 Answers
          2






          active

          oldest

          votes


















          2
















          Below please find some screenshots to illustrate how to do this:



          1. This is a View of Activities. Each Activity has an Update button [that's a Global: Custom Text field -> Text Update; Rewrite results: Output this field as a link -> to the webform URL with case-worker-form?cid2=[contact_id]&aid=[id] and bootstrap classes btn to make it a button] -> the URL that is constructed is case-worker-form?cid2=41218&aid=19153



          enter image description here



          2. The webform case-worker-form -> receives this data. That form is set up such that cid1 = the logged in user (the social worker); cid2 = the client; aid = activity id of the activity to be updated;



          enter image description here



          3. Let's edit the subject e.g. ->



          enter image description here



          4. Result:



          enter image description here



          5. Note the Webform just has Update Existing Activity set to None (as we're matching by aid)
          enter image description here






          share|improve this answer
































            2
















            Having "Update Existing Activity" setting turned on, prefills the form with the matching activity based on Type and Status. In case of multiple activities, it prefills/updates the first one.



            Adding '&activity1=activityID' in your webform url, irrespective of the 'Update Existing Activity' setting, will prefill and update the activity (with id=activityID).



            In case of revisioning you might need to provide latest activity ID in url or it might not work. Think you could have some custom code or configuration in view to fetch the latest activity id for a contact, to make it work.






            share|improve this answer




























              Your Answer








              StackExchange.ready(function()
              var channelOptions =
              tags: "".split(" "),
              id: "605"
              ;
              initTagRenderer("".split(" "), "".split(" "), channelOptions);

              StackExchange.using("externalEditor", function()
              // Have to fire editor after snippets, if snippets enabled
              if (StackExchange.settings.snippets.snippetsEnabled)
              StackExchange.using("snippets", function()
              createEditor();
              );

              else
              createEditor();

              );

              function createEditor()
              StackExchange.prepareEditor(
              heartbeatType: 'answer',
              autoActivateHeartbeat: false,
              convertImagesToLinks: false,
              noModals: true,
              showLowRepImageUploadWarning: true,
              reputationToPostImages: null,
              bindNavPrevention: true,
              postfix: "",
              imageUploader:
              brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
              contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/4.0/"u003ecc by-sa 4.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
              allowUrls: true
              ,
              noCode: true, onDemand: true,
              discardSelector: ".discard-answer"
              ,immediatelyShowMarkdownHelp:true
              );



              );














              draft saved

              draft discarded
















              StackExchange.ready(
              function ()
              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fcivicrm.stackexchange.com%2fquestions%2f33201%2fprefill-webform-with-civicrm-activity-data%23new-answer', 'question_page');

              );

              Post as a guest















              Required, but never shown

























              2 Answers
              2






              active

              oldest

              votes








              2 Answers
              2






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes









              2
















              Below please find some screenshots to illustrate how to do this:



              1. This is a View of Activities. Each Activity has an Update button [that's a Global: Custom Text field -> Text Update; Rewrite results: Output this field as a link -> to the webform URL with case-worker-form?cid2=[contact_id]&aid=[id] and bootstrap classes btn to make it a button] -> the URL that is constructed is case-worker-form?cid2=41218&aid=19153



              enter image description here



              2. The webform case-worker-form -> receives this data. That form is set up such that cid1 = the logged in user (the social worker); cid2 = the client; aid = activity id of the activity to be updated;



              enter image description here



              3. Let's edit the subject e.g. ->



              enter image description here



              4. Result:



              enter image description here



              5. Note the Webform just has Update Existing Activity set to None (as we're matching by aid)
              enter image description here






              share|improve this answer





























                2
















                Below please find some screenshots to illustrate how to do this:



                1. This is a View of Activities. Each Activity has an Update button [that's a Global: Custom Text field -> Text Update; Rewrite results: Output this field as a link -> to the webform URL with case-worker-form?cid2=[contact_id]&aid=[id] and bootstrap classes btn to make it a button] -> the URL that is constructed is case-worker-form?cid2=41218&aid=19153



                enter image description here



                2. The webform case-worker-form -> receives this data. That form is set up such that cid1 = the logged in user (the social worker); cid2 = the client; aid = activity id of the activity to be updated;



                enter image description here



                3. Let's edit the subject e.g. ->



                enter image description here



                4. Result:



                enter image description here



                5. Note the Webform just has Update Existing Activity set to None (as we're matching by aid)
                enter image description here






                share|improve this answer



























                  2














                  2










                  2









                  Below please find some screenshots to illustrate how to do this:



                  1. This is a View of Activities. Each Activity has an Update button [that's a Global: Custom Text field -> Text Update; Rewrite results: Output this field as a link -> to the webform URL with case-worker-form?cid2=[contact_id]&aid=[id] and bootstrap classes btn to make it a button] -> the URL that is constructed is case-worker-form?cid2=41218&aid=19153



                  enter image description here



                  2. The webform case-worker-form -> receives this data. That form is set up such that cid1 = the logged in user (the social worker); cid2 = the client; aid = activity id of the activity to be updated;



                  enter image description here



                  3. Let's edit the subject e.g. ->



                  enter image description here



                  4. Result:



                  enter image description here



                  5. Note the Webform just has Update Existing Activity set to None (as we're matching by aid)
                  enter image description here






                  share|improve this answer













                  Below please find some screenshots to illustrate how to do this:



                  1. This is a View of Activities. Each Activity has an Update button [that's a Global: Custom Text field -> Text Update; Rewrite results: Output this field as a link -> to the webform URL with case-worker-form?cid2=[contact_id]&aid=[id] and bootstrap classes btn to make it a button] -> the URL that is constructed is case-worker-form?cid2=41218&aid=19153



                  enter image description here



                  2. The webform case-worker-form -> receives this data. That form is set up such that cid1 = the logged in user (the social worker); cid2 = the client; aid = activity id of the activity to be updated;



                  enter image description here



                  3. Let's edit the subject e.g. ->



                  enter image description here



                  4. Result:



                  enter image description here



                  5. Note the Webform just has Update Existing Activity set to None (as we're matching by aid)
                  enter image description here







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered 3 hours ago









                  KarinG - Semper ITKarinG - Semper IT

                  11.6k1 gold badge8 silver badges39 bronze badges




                  11.6k1 gold badge8 silver badges39 bronze badges


























                      2
















                      Having "Update Existing Activity" setting turned on, prefills the form with the matching activity based on Type and Status. In case of multiple activities, it prefills/updates the first one.



                      Adding '&activity1=activityID' in your webform url, irrespective of the 'Update Existing Activity' setting, will prefill and update the activity (with id=activityID).



                      In case of revisioning you might need to provide latest activity ID in url or it might not work. Think you could have some custom code or configuration in view to fetch the latest activity id for a contact, to make it work.






                      share|improve this answer































                        2
















                        Having "Update Existing Activity" setting turned on, prefills the form with the matching activity based on Type and Status. In case of multiple activities, it prefills/updates the first one.



                        Adding '&activity1=activityID' in your webform url, irrespective of the 'Update Existing Activity' setting, will prefill and update the activity (with id=activityID).



                        In case of revisioning you might need to provide latest activity ID in url or it might not work. Think you could have some custom code or configuration in view to fetch the latest activity id for a contact, to make it work.






                        share|improve this answer





























                          2














                          2










                          2









                          Having "Update Existing Activity" setting turned on, prefills the form with the matching activity based on Type and Status. In case of multiple activities, it prefills/updates the first one.



                          Adding '&activity1=activityID' in your webform url, irrespective of the 'Update Existing Activity' setting, will prefill and update the activity (with id=activityID).



                          In case of revisioning you might need to provide latest activity ID in url or it might not work. Think you could have some custom code or configuration in view to fetch the latest activity id for a contact, to make it work.






                          share|improve this answer















                          Having "Update Existing Activity" setting turned on, prefills the form with the matching activity based on Type and Status. In case of multiple activities, it prefills/updates the first one.



                          Adding '&activity1=activityID' in your webform url, irrespective of the 'Update Existing Activity' setting, will prefill and update the activity (with id=activityID).



                          In case of revisioning you might need to provide latest activity ID in url or it might not work. Think you could have some custom code or configuration in view to fetch the latest activity id for a contact, to make it work.







                          share|improve this answer














                          share|improve this answer



                          share|improve this answer








                          edited 1 hour ago

























                          answered 5 hours ago









                          Deepak SrivastavaDeepak Srivastava

                          2211 silver badge6 bronze badges




                          2211 silver badge6 bronze badges































                              draft saved

                              draft discarded















































                              Thanks for contributing an answer to CiviCRM Stack Exchange!


                              • Please be sure to answer the question. Provide details and share your research!

                              But avoid


                              • Asking for help, clarification, or responding to other answers.

                              • Making statements based on opinion; back them up with references or personal experience.

                              To learn more, see our tips on writing great answers.




                              draft saved


                              draft discarded














                              StackExchange.ready(
                              function ()
                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fcivicrm.stackexchange.com%2fquestions%2f33201%2fprefill-webform-with-civicrm-activity-data%23new-answer', 'question_page');

                              );

                              Post as a guest















                              Required, but never shown





















































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown

































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown







                              Popular posts from this blog

                              Canceling a color specificationRandomly assigning color to Graphics3D objects?Default color for Filling in Mathematica 9Coloring specific elements of sets with a prime modified order in an array plotHow to pick a color differing significantly from the colors already in a given color list?Detection of the text colorColor numbers based on their valueCan color schemes for use with ColorData include opacity specification?My dynamic color schemes

                              Invision Community Contents History See also References External links Navigation menuProprietaryinvisioncommunity.comIPS Community ForumsIPS Community Forumsthis blog entry"License Changes, IP.Board 3.4, and the Future""Interview -- Matt Mecham of Ibforums""CEO Invision Power Board, Matt Mecham Is a Liar, Thief!"IPB License Explanation 1.3, 1.3.1, 2.0, and 2.1ArchivedSecurity Fixes, Updates And Enhancements For IPB 1.3.1Archived"New Demo Accounts - Invision Power Services"the original"New Default Skin"the original"Invision Power Board 3.0.0 and Applications Released"the original"Archived copy"the original"Perpetual licenses being done away with""Release Notes - Invision Power Services""Introducing: IPS Community Suite 4!"Invision Community Release Notes

                              François Viète Contents Biography Work and thought Bibliography See also Notes Further reading External links Navigation menup. 21Google Bookspp. 75–77Google BooksDe thou (from University of Saint Andrews)ArchivedGoogle BooksGoogle BooksGoogle BooksGoogle booksGoogle Bookscc-parthenay.frL'histoire universelle (fr)Universal History (en)ArchivedAdsabs.harvard.eduPagesperso-orange.frArchive.orgChikara Sasaki. Descartes' mathematical thought p.259Google BooksGoogle BooksGoogle Bookspp. 152 and onwardGoogle BooksGoogle BooksScribd.comGoogle Books1257-7979Google BooksGoogle BooksGoogle BooksGoogle BooksGoogle BooksGoogle BooksGallica.bnf.frGoogle BooksGoogle Books"François Viète"Francois Viète: Father of Modern Algebraic NotationThe Lawyer and the GamblerAbout TarporleySite de Jean-Paul GuichardL'algèbre nouvelle"About the Harmonicon"cb120511976(data)1188044800000 0001 0913 5903n82164680ola2013766880073431702w6vt1sb70287374827140948071409480