Skip to content

Commit

Permalink
Merge pull request #161 from jlawyerorg/develop
Browse files Browse the repository at this point in the history
support for additional fields when extracting contact / address attri…
j-dimension authored Feb 28, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
2 parents 2628f2b + fd955ff commit ae695a8
Showing 3 changed files with 22 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/2.1.0.0/gravity01_meta.groovy
Original file line number Diff line number Diff line change
@@ -664,6 +664,6 @@ For more information on this, and how to apply and follow the GNU AGPL, see

name = "Gravity Forms"
description = "Uebernimmt Eingaben aus Wordpress Gravity Forms"
version = "2.1.0";
version = "2.2.0";
author = "Jens Kutschke"
updated = "01.02.2024"
updated = "28.02.2024"
20 changes: 19 additions & 1 deletion src/2.1.0.0/gravity01_ui.groovy
Original file line number Diff line number Diff line change
@@ -1473,8 +1473,26 @@ public class grav01_ui implements com.jdimension.jlawyer.client.plugins.form.For
field=AttributeCellEditor.ATTRIBUTE_PLZ;
} else if(key.toUpperCase().contains("STRASSE") || line.toLowerCase().contains("strasse") || line.toLowerCase().contains("straße") || line.toLowerCase().contains("allee")) {
field=AttributeCellEditor.ATTRIBUTE_STRASSE;
} else if(key.toUpperCase().contains("HAUSNR") || line.matches("\\d{1,3}[abc]?")) {
} else if(key.toUpperCase().contains("HAUSNR")) {
field=AttributeCellEditor.ATTRIBUTE_HAUSNR;
} else if(key.toUpperCase().contains("ORT")) {
field=AttributeCellEditor.ATTRIBUTE_ORT;
} else if(key.toUpperCase().contains("VORNAME")) {
field=AttributeCellEditor.ATTRIBUTE_VORNAME;
} else if(key.toUpperCase().contains("NAME")) {
field=AttributeCellEditor.ATTRIBUTE_NAME;
} else if(key.toUpperCase().contains("MOBIL")) {
field=AttributeCellEditor.ATTRIBUTE_MOBIL;
} else if(key.toUpperCase().contains("UNTERNEHMEN")) {
field=AttributeCellEditor.ATTRIBUTE_UNTERNEHMEN;
} else if(key.toUpperCase().contains("BERUF")) {
field=AttributeCellEditor.ATTRIBUTE_BERUF;
} else if(key.toUpperCase().contains("FUNKTION")) {
field=AttributeCellEditor.ATTRIBUTE_FUNKTION;
} else if(key.toUpperCase().contains("ABTEILUNG")) {
field=AttributeCellEditor.ATTRIBUTE_ABTEILUNG;
} else if(key.toUpperCase().contains("LAND")) {
field=AttributeCellEditor.ATTRIBUTE_LAND;
}

String[] rowValues=[key, line, field];
2 changes: 1 addition & 1 deletion src/j-lawyer-forms.xml
Original file line number Diff line number Diff line change
@@ -14,7 +14,7 @@
<form id="famr01" type="plugin" depends="formslib" name="Familienrecht" description="Familienrecht" placeholder="FAMR" version="1.4.0" for="2.2.0.0,2.3.0.1,2.4.0.2,2.5.0.0,2.6.0.0,2.6.0.1" url="https://www.j-lawyer.org/downloads/j-lawyer-plugins/forms/2.0.0.0" files="famr01_meta.groovy,famr01_ui.groovy"/>

<!-- Gravity Forms requires 2.1.0.0 or later -->
<form id="gravity01" type="plugin" depends="formslib" name="Gravity Forms" description="Uebernimmt Eingaben aus Wordpress Gravity Forms" placeholder="FORM" version="2.1.0" for="2.2.0.0,2.3.0.1,2.4.0.2,2.5.0.0,2.6.0.0,2.6.0.1" url="https://www.j-lawyer.org/downloads/j-lawyer-plugins/forms/2.1.0.0" files="gravity01_meta.groovy,gravity01_ui.groovy,GravitySite.groovy,GravityField.groovy,GravityLib.groovy">
<form id="gravity01" type="plugin" depends="formslib" name="Gravity Forms" description="Uebernimmt Eingaben aus Wordpress Gravity Forms" placeholder="FORM" version="2.2.0" for="2.2.0.0,2.3.0.1,2.4.0.2,2.5.0.0,2.6.0.0,2.6.0.1" url="https://www.j-lawyer.org/downloads/j-lawyer-plugins/forms/2.1.0.0" files="gravity01_meta.groovy,gravity01_ui.groovy,GravitySite.groovy,GravityField.groovy,GravityLib.groovy">
<setting key="forms.gravity01.site1.sitename" caption="Bezeichnung Website 1:" default="Irgendeine Website" order="1"/>
<setting key="forms.gravity01.site1.endpoint" caption="API-Endpunkt:" default="https://www.irgendeine-domain-321.de/wp-json/gf/v2/" order="2"/>
<setting key="forms.gravity01.site1.apiuser" caption="Nutzer / API-Key:" default="ck_123123123123123" order="3"/>

0 comments on commit ae695a8

Please sign in to comment.