You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/Data/EntryObjectMutation.php
+6-6Lines changed: 6 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -94,12 +94,12 @@ public static function get_field_value_input( array $args, array $form, bool $is
94
94
*
95
95
* Useful for adding mutation support for custom fields.
96
96
*
97
-
* @param string $field_value_input_class The FieldValueInput class to use. The referenced class must extend AbstractFieldValueInput.
98
-
* @param array $args The GraphQL input args for the form field.
99
-
* @param \GF_Field $field The current Gravity Forms field object.
100
-
* @param array<string,mixed> $form The current Gravity Forms form object.
101
-
* @param array|null $entry The current Gravity Forms entry object. Only available when using update (`gfUpdateEntry`, `gfUpdateDraftEntry`) mutations.
102
-
* @param bool $is_draft_mutation Whether the mutation is handling a Draft Entry (`gfUpdateDraftEntry`, or `gfSubmitForm` when `saveAsDraft` is `true`).
97
+
* @param string $field_value_input_class The FieldValueInput class to use. The referenced class must extend AbstractFieldValueInput.
98
+
* @param array $args The GraphQL input args for the form field.
99
+
* @param \GF_Field $field The current Gravity Forms field object.
100
+
* @param array<string,mixed> $form The current Gravity Forms form object.
101
+
* @param ?array<int|string,mixed> $entry The current Gravity Forms entry object. Only available when using update (`gfUpdateEntry`, `gfUpdateDraftEntry`) mutations.
102
+
* @param bool $is_draft_mutation Whether the mutation is handling a Draft Entry (`gfUpdateDraftEntry`, or `gfSubmitForm` when `saveAsDraft` is `true`).
Copy file name to clipboardExpand all lines: src/Data/FieldValueInput/AbstractFieldValueInput.php
+19-19Lines changed: 19 additions & 19 deletions
Original file line number
Diff line number
Diff line change
@@ -21,7 +21,7 @@ abstract class AbstractFieldValueInput {
21
21
/**
22
22
* The GraphQL field input args provided to the mutation.
23
23
*
24
-
* @var array|string
24
+
* @var mixed[]|string
25
25
*/
26
26
protected$args;
27
27
@@ -70,7 +70,7 @@ abstract class AbstractFieldValueInput {
70
70
/**
71
71
* The field value for submission.
72
72
*
73
-
* @var array|string
73
+
* @var mixed[]|string
74
74
*/
75
75
public$value;
76
76
@@ -124,12 +124,12 @@ public function __construct( array $input_args, array $form, bool $is_draft, ?GF
124
124
/**
125
125
* Filters the GraphQL input args for the field value input.
126
126
*
127
-
* @param array|string $args Field value input args.
128
-
* @param \GF_Field $field The current Gravity Forms field object.
129
-
* @param array<string,mixed> $form The current Gravity Forms form object.
130
-
* @param array|null$entry The current Gravity Forms entry object. Only available when using update (`gfUpdateEntry`, `gfUpdateDraftEntry`) mutations.
131
-
* @param bool $is_draft_mutation Whether the mutation is handling a Draft Entry (`gfUpdateDraftEntry`, or `gfSubmitForm` when `saveAsDraft` is `true`).
132
-
* @param string $field_name The GraphQL input field name. E.g. `nameValues`.
127
+
* @param array<string,mixed>|string $args Field value input args.
128
+
* @param \GF_Field $field The current Gravity Forms field object.
129
+
* @param array<string,mixed> $form The current Gravity Forms form object.
130
+
* @param ?array<int|string,mixed>$entry The current Gravity Forms entry object. Only available when using update (`gfUpdateEntry`, `gfUpdateDraftEntry`) mutations.
131
+
* @param bool $is_draft_mutation Whether the mutation is handling a Draft Entry (`gfUpdateDraftEntry`, or `gfSubmitForm` when `saveAsDraft` is `true`).
132
+
* @param string $field_name The GraphQL input field name. E.g. `nameValues`.
133
133
*/
134
134
$this->args = apply_filters(
135
135
'graphql_gf_field_value_input_args',
@@ -144,13 +144,13 @@ public function __construct( array $input_args, array $form, bool $is_draft, ?GF
144
144
/**
145
145
* Filters the prepared field value to be submitted to Gravity Forms.
146
146
*
147
-
* @param array|string $prepared_field_value The field value formatted in a way Gravity Forms can understand.
148
-
* @param array|string $args Field value input args.
149
-
* @param \GF_Field $field The current Gravity Forms field object.
150
-
* @param array<string,mixed> $form The current Gravity Forms form object.
151
-
* @param array|null $entry The current Gravity Forms entry object. Only available when using update (`gfUpdateEntry`, `gfUpdateDraftEntry`) mutations.
152
-
* @param bool $is_draft_mutation Whether the mutation is handling a Draft Entry (`gfUpdateDraftEntry`, or `gfSubmitForm` when `saveAsDraft` is `true`).
153
-
* @param string $field_name The GraphQL input field name. E.g. `nameValues`.
147
+
* @param array|string $prepared_field_value The field value formatted in a way Gravity Forms can understand.
148
+
* @param array<string,mixed>|string $args Field value input args.
149
+
* @param \GF_Field $field The current Gravity Forms field object.
150
+
* @param array<string,mixed> $form The current Gravity Forms form object.
151
+
* @param ?array<int|string,mixed> $entry The current Gravity Forms entry object. Only available when using update (`gfUpdateEntry`, `gfUpdateDraftEntry`) mutations.
152
+
* @param bool $is_draft_mutation Whether the mutation is handling a Draft Entry (`gfUpdateDraftEntry`, or `gfSubmitForm` when `saveAsDraft` is `true`).
153
+
* @param string $field_name The GraphQL input field name. E.g. `nameValues`.
154
154
*/
155
155
$this->value = apply_filters(
156
156
'graphql_gf_field_value_input_prepared_value',
@@ -189,7 +189,7 @@ protected function is_valid_input_type(): bool {
189
189
/**
190
190
* Gets the input args for the specified field value input.
191
191
*
192
-
* @return string|array
192
+
* @return string|mixed[]
193
193
*/
194
194
publicfunctionget_args() {
195
195
$key = $this->field_name;
@@ -200,7 +200,7 @@ public function get_args() {
200
200
/**
201
201
* Converts the field value args to a format GravityForms can understand.
202
202
*
203
-
* @return string|array the sanitized value.
203
+
* @return string|mixed[] the sanitized value.
204
204
*/
205
205
protectedfunctionprepare_value() {
206
206
// You probably want to replace this.
@@ -210,7 +210,7 @@ protected function prepare_value() {
210
210
/**
211
211
* Manually runs GF_Field::validate, and grabs any validation errors.
212
212
*
213
-
* @param array $errors .
213
+
* @param array{id:int,message:string}[] $errors the array of validation errors.
0 commit comments