-
-
Notifications
You must be signed in to change notification settings - Fork 824
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
APIv4 - Add
nullable
property to getFields; improve SearchKit edita…
…ble UX Unlike the 'required' field property, which only determines if the API requires a value to Create, the 'nullable' property tells a UI whether a field is allowed to be set to NULL in Create OR Update. SearchKit uses this property during in-place edit and bulk edit operations to determine whether a field can be left blank.
- Loading branch information
Showing
16 changed files
with
83 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 11 additions & 9 deletions
20
ext/search_kit/ang/crmSearchDisplay/crmSearchDisplayEditable.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,11 @@ | ||
<crm-search-input class="form-inline" field="$ctrl.field" ng-model="$ctrl.value"></crm-search-input> | ||
<div class="form-inline crm-search-display-editable-buttons"> | ||
<button type="button" ng-click="$ctrl.save()" class="btn btn-xs btn-success"> | ||
<i class="crm-i fa-check"></i> | ||
</button> | ||
<button type="button" ng-click="$ctrl.cancel()" class="btn btn-xs btn-danger"> | ||
<i class="crm-i fa-times"></i> | ||
</button> | ||
</div> | ||
<form name="crmSearchDisplayEditableForm"> | ||
<crm-search-input class="form-inline" field="$ctrl.field" ng-model="$ctrl.value"></crm-search-input> | ||
<div class="form-inline crm-search-display-editable-buttons"> | ||
<button type="submit" ng-disabled="!crmSearchDisplayEditableForm.$valid" ng-click="$ctrl.save()" class="btn btn-xs btn-success"> | ||
<i class="crm-i fa-check"></i> | ||
</button> | ||
<button type="button" ng-click="$ctrl.cancel()" class="btn btn-xs btn-danger"> | ||
<i class="crm-i fa-times"></i> | ||
</button> | ||
</div> | ||
</form> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
<div class="form-group" ng-if="!$ctrl.multi" > | ||
<input type="number" step="any" class="form-control" ng-model="$ctrl.value"> | ||
<input type="number" step="any" class="form-control" ng-model="$ctrl.value" ng-required="!$ctrl.field.nullable"> | ||
</div> | ||
<div class="form-group" ng-if="$ctrl.multi" > | ||
<input class="form-control" ng-model="$ctrl.value" crm-ui-select="{multiple: true, tags: [], tokenSeparators: [','], formatNoMatches: ''}" ng-list> | ||
<input class="form-control" ng-model="$ctrl.value" ng-required="!$ctrl.field.nullable" crm-ui-select="{multiple: true, tags: [], tokenSeparators: [','], formatNoMatches: ''}" ng-list> | ||
</div> |
4 changes: 2 additions & 2 deletions
4
ext/search_kit/ang/crmSearchTasks/crmSearchInput/integer.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
<div class="form-group" ng-if="!$ctrl.multi" > | ||
<input type="number" step="1" class="form-control" ng-model="$ctrl.value"> | ||
<input type="number" step="1" class="form-control" ng-model="$ctrl.value" ng-required="!$ctrl.field.nullable"> | ||
</div> | ||
<div class="form-group" ng-if="$ctrl.multi" > | ||
<input class="form-control" ng-model="$ctrl.value" crm-ui-select="{multiple: true, tags: [], tokenSeparators: [','], formatNoMatches: ''}" ng-list> | ||
<input class="form-control" ng-model="$ctrl.value" ng-required="!$ctrl.field.nullable" crm-ui-select="{multiple: true, tags: [], tokenSeparators: [','], formatNoMatches: ''}" ng-list> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
<div class="form-group" ng-if="!$ctrl.multi" > | ||
<input type="text" class="form-control" ng-model="$ctrl.value"> | ||
<input type="text" class="form-control" ng-model="$ctrl.value" ng-required="!$ctrl.field.nullable"> | ||
</div> | ||
<div class="form-group" ng-if="$ctrl.multi" > | ||
<input class="form-control" ng-model="$ctrl.value" crm-ui-select="{multiple: true, tags: [], tokenSeparators: [','], formatNoMatches: ''}" ng-list> | ||
<input class="form-control" ng-model="$ctrl.value" ng-required="!$ctrl.field.nullable" crm-ui-select="{multiple: true, tags: [], tokenSeparators: [','], formatNoMatches: ''}" ng-list> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters