Skip to content

Commit

Permalink
Merge pull request #299 from oneblink/ON-37949
Browse files Browse the repository at this point in the history
ON-37949 # Add `webMapId` and `showLayerPanel` to `FormElement`
  • Loading branch information
aaronroworth authored Feb 7, 2024
2 parents 3cc84d5 + e25f7b9 commit b01a536
Show file tree
Hide file tree
Showing 3 changed files with 65 additions and 44 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

## Unreleased

### Added

- `webMapId` and `showLayerPanel` to `FormElement`

## [5.4.0] - 2024-02-07

### Added
Expand Down
97 changes: 53 additions & 44 deletions OneBlink.SDK/models/FormElement.cs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#pragma warning disable IDE1006 // Names are from OneBlink Types
using System;
using System.Collections.Generic;

Expand All @@ -18,31 +19,31 @@ public string label
get; set;
}

public Boolean conditionallyShow
public bool conditionallyShow
{
get; set;
}
public Boolean requiresAllConditionallyShowPredicates
public bool requiresAllConditionallyShowPredicates
{
get; set;
}
public string type
{
get; set;
}
public Boolean required
public bool required
{
get; set;
}
public Boolean requiredAll
public bool requiredAll
{
get; set;
}
public string requiredMessage
{
get; set;
}
public Boolean readOnly
public bool readOnly
{
get; set;
}
Expand All @@ -58,15 +59,15 @@ public long? defaultValueDaysOffset
{
get; set;
}
public Boolean buttons
public bool buttons
{
get; set;
}
public Boolean multi
public bool multi
{
get; set;
}
public Boolean isSlider
public bool isSlider
{
get; set;
}
Expand Down Expand Up @@ -130,7 +131,7 @@ public List<FormElementAttributeMapping> attributesMapping
{
get; set;
}
public Boolean conditionallyShowOptions
public bool conditionallyShowOptions
{
get; set;
}
Expand Down Expand Up @@ -158,7 +159,7 @@ public List<FormElement> elements
{
get; set;
}
public Boolean restrictBarcodeTypes
public bool restrictBarcodeTypes
{
get; set;
}
Expand All @@ -174,15 +175,15 @@ public string preCalculationDisplay
{
get; set;
}
public Boolean isDataLookup
public bool isDataLookup
{
get; set;
}
public long? dataLookupId
{
get; set;
}
public Boolean isElementLookup
public bool isElementLookup
{
get; set;
}
Expand All @@ -206,7 +207,7 @@ public string searchQuerystringParameter
{
get; set;
}
public Boolean restrictFileTypes
public bool restrictFileTypes
{
get; set;
}
Expand Down Expand Up @@ -259,11 +260,11 @@ public List<string> addressTypeFilter
{
get; set;
}
public Boolean? isInteger
public bool? isInteger
{
get; set;
}
public Boolean? displayAsCurrency
public bool? displayAsCurrency
{
get; set;
}
Expand All @@ -283,15 +284,15 @@ public string regexMessage
{
get; set;
}
public Boolean? canToggleAll
public bool? canToggleAll
{
get; set;
}
public Boolean? useGeoscapeAddressing
public bool? useGeoscapeAddressing
{
get; set;
}
public Boolean? isCollapsed
public bool? isCollapsed
{
get; set;
}
Expand All @@ -307,71 +308,71 @@ public string givenName1Label
{
get; set;
}
public Boolean? givenName1IsRequired
public bool? givenName1IsRequired
{
get; set;
}
public Boolean? givenName1IsHidden
public bool? givenName1IsHidden
{
get; set;
}
public string emailAddressLabel
{
get; set;
}
public Boolean? emailAddressIsRequired
public bool? emailAddressIsRequired
{
get; set;
}
public Boolean? emailAddressIsHidden
public bool? emailAddressIsHidden
{
get; set;
}
public string homePhoneLabel
{
get; set;
}
public Boolean? homePhoneIsRequired
public bool? homePhoneIsRequired
{
get; set;
}
public Boolean? homePhoneIsHidden
public bool? homePhoneIsHidden
{
get; set;
}
public string businessPhoneLabel
{
get; set;
}
public Boolean? businessPhoneIsRequired
public bool? businessPhoneIsRequired
{
get; set;
}
public Boolean? businessPhoneIsHidden
public bool? businessPhoneIsHidden
{
get; set;
}
public string mobilePhoneLabel
{
get; set;
}
public Boolean? mobilePhoneIsRequired
public bool? mobilePhoneIsRequired
{
get; set;
}
public Boolean? mobilePhoneIsHidden
public bool? mobilePhoneIsHidden
{
get; set;
}
public string faxPhoneLabel
{
get; set;
}
public Boolean? faxPhoneIsRequired
public bool? faxPhoneIsRequired
{
get; set;
}
public Boolean? faxPhoneIsHidden
public bool? faxPhoneIsHidden
{
get; set;
}
Expand Down Expand Up @@ -415,6 +416,14 @@ public string meta
{
get; set;
}
public string webMapId
{
get; set;
}
public bool showLayerPanel
{
get; set;
}
private static Guid initialiseId(Guid? id)
{
if (!id.HasValue)
Expand Down Expand Up @@ -681,27 +690,27 @@ public static FormElement CreateCivicaNameRecordElement(
bool readOnly = false,
dynamic defaultValue = null,
string hint = null,
Boolean useGeoscapeAddressing = false,
bool useGeoscapeAddressing = false,
string titleLabel = null,
string familyNameLabel = null,
string givenName1Label = null,
Boolean givenName1IsRequired = false,
Boolean givenName1IsHidden = false,
bool givenName1IsRequired = false,
bool givenName1IsHidden = false,
string emailAddressLabel = null,
Boolean emailAddressIsRequired = false,
Boolean emailAddressIsHidden = false,
bool emailAddressIsRequired = false,
bool emailAddressIsHidden = false,
string homePhoneLabel = null,
Boolean homePhoneIsRequired = false,
Boolean homePhoneIsHidden = false,
bool homePhoneIsRequired = false,
bool homePhoneIsHidden = false,
string businessPhoneLabel = null,
Boolean businessPhoneIsRequired = false,
Boolean businessPhoneIsHidden = false,
bool businessPhoneIsRequired = false,
bool businessPhoneIsHidden = false,
string mobilePhoneLabel = null,
Boolean mobilePhoneIsRequired = false,
Boolean mobilePhoneIsHidden = false,
bool mobilePhoneIsRequired = false,
bool mobilePhoneIsHidden = false,
string faxPhoneLabel = null,
Boolean faxPhoneIsRequired = false,
Boolean faxPhoneIsHidden = false,
bool faxPhoneIsRequired = false,
bool faxPhoneIsHidden = false,
string streetAddressesLabel = null,
string address1Label = null,
string address2Label = null,
Expand Down Expand Up @@ -761,7 +770,7 @@ public static FormElement CreateSectionElement(
bool requiresAllConditionallyShowPredicates = false,
List<ConditionallyShowPredicate> conditionallyShowPredicates = null,
string hint = null,
Boolean isCollapsed = false,
bool isCollapsed = false,
List<FormElement> elements = null,
List<string> customCssClasses = null,
string meta = null
Expand Down
8 changes: 8 additions & 0 deletions docs/models/FormElement.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,14 @@ Only a default constructor is provided, instead it is recommended to create a Fo
| `address1Label` | No | `string` | The label that will be set for this field when the element is rendered. | |
| `address2Label` | No | `string` | The label that will be set for this field when the element is rendered. | |
| `postcodeLabel` | No | `string` | The label that will be set for this field when the element is rendered. | |
| `subCategoryLabel` | No | `string` | Display text presented to the user above the sub category input by default. | |
| `subCategoryHint` | No | `string` | A hint triggered by an icon tooltip to be displayed when hovering beside the sub category label. | |
| `itemLabel` | No | `string` | Display text presented to the user above the item input by default. | |
| `itemHint` | No | `string` | A hint triggered by an icon tooltip to be displayed when hovering beside the item label. | |
| `customCssClasses` | No | `List<string>` | Custom CSS classes that will be added to the form during rendering | |
| `meta` | No | `string` | JSON metadata associated with the form element. This field is for primarily for developer use. | |
| `webMapId` | No | `string` | ArcGIS Web map Id. | |
| `showLayerPanel` | No | `bool` | Show layer panel to user when rendering ArcGIS web map. | |

### Static Functions

Expand Down

0 comments on commit b01a536

Please sign in to comment.