-
-
Notifications
You must be signed in to change notification settings - Fork 264
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pods 3.2.8 #7347
Pods 3.2.8 #7347
Changes from all commits
84b1ff3
3745288
d8259fb
70a0f51
cca714d
2b1cdd5
1ceeb9d
e1e50ee
0e5ea93
ce48433
660d4b4
d129992
1a42d6b
79ee8df
93f6ea9
42e283c
eec817c
af61aca
b6f064e
665f549
672e763
7b79dbb
dba9367
2878205
d78c005
f232f63
8602870
ac8466c
a528ba9
aa7deeb
d2847cc
37244ef
fb14490
7e69cfb
17031cb
1caf45c
17501b3
09a28b0
70628d1
ace098f
385b88d
1a2cebe
ce4b9df
eb17b40
27fcb14
ef7bf11
7b860e0
7b60b23
bc8e42e
41f6d3f
2d94c6b
c1e4ee6
e2599c9
9431767
2a04501
445056e
5287798
620f003
d5af932
0f2fe47
37672cd
9dad299
5887ead
f5884cd
ffba468
caa4ea7
c445492
403e416
b7595ca
9bdfaac
c40e87f
4ccfb0e
7e2fe07
d91a00e
011a845
6b404d4
a780c71
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4017,7 +4017,9 @@ public function save_field( $params, $table_operation = true, $sanitized = false | |
|
||
pods_query( ' | ||
UPDATE `@wp_podsrel` | ||
SET `related_field_id` = 0 | ||
SET | ||
`related_pod_id` = 0, | ||
`related_field_id` = 0 | ||
WHERE `field_id` = %d | ||
', array( | ||
$old_sister_id, | ||
|
@@ -4028,14 +4030,33 @@ public function save_field( $params, $table_operation = true, $sanitized = false | |
update_post_meta( $sister_id, 'sister_id', $params->id ); | ||
|
||
if ( true === $db && pods_podsrel_enabled( $field, 'save' ) ) { | ||
pods_query( ' | ||
UPDATE `@wp_podsrel` | ||
SET `related_field_id` = %d | ||
WHERE `field_id` = %d | ||
', array( | ||
$params->id, | ||
$sister_id, | ||
) ); | ||
$sister_field = $this->load_field( [ 'id' => $sister_id ] ); | ||
|
||
if ( $sister_field ) { | ||
pods_query( ' | ||
UPDATE `@wp_podsrel` | ||
SET | ||
`related_pod_id` = %d, | ||
`related_field_id` = %d | ||
WHERE `field_id` = %d | ||
', [ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 |
||
$pod['id'], | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 |
||
$params->id, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 |
||
$sister_id, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 |
||
] ); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 |
||
|
||
pods_query( ' | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 |
||
UPDATE `@wp_podsrel` | ||
SET | ||
`related_pod_id` = %d, | ||
`related_field_id` = %d | ||
WHERE `field_id` = %d | ||
', [ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 |
||
$sister_field->get_parent_id(), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 |
||
$sister_id, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 |
||
$params->id, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 |
||
] ); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. [phpcs] reported by reviewdog 🐶 |
||
} | ||
} | ||
} elseif ( 0 < $old_sister_id ) { | ||
delete_post_meta( $old_sister_id, 'sister_id' ); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[phpcs] reported by reviewdog 🐶
PEAR.Functions.FunctionCallSignature.ContentAfterOpenBracket
Opening parenthesis of a multi-line function call must be the last content on the line