Skip to content

Conversation

@shadyshoha
Copy link

@shadyshoha shadyshoha commented Oct 29, 2025

Update the Salesforce Update Record action to make the fieldsToUpdate prop optional, allowing users to utilize the additionalFields prop immediately after selecting the SObject Type without needing to manually select fields first.

Changes:

  • Made fieldsToUpdate prop optional in update-record.mjs
  • Updated additionalProps() to handle empty fieldsToUpdate gracefully
  • additionalFields now appears immediately after SObject Type selection

This change maintains backward compatibility with existing workflows that use manual field selection while providing a more flexible workflow for users who prefer to specify all fields via additionalFields.

Behavior

Before:

  • Users had to select at least one field in fieldsToUpdate before additionalFields would appear
  • No way to use only additionalFields without manual field selection

After:

  • additionalFields appears immediately after selecting SObject Type and Record ID
  • Users can choose to:
    • Use only additionalFields (new capability)
    • Use only manual field selection (existing behavior, still works)
    • Use both together (existing behavior, still works)

Testing

  • Tested using only additionalFields to update records
  • Tested using only manual fieldsToUpdate selection (backward compatibility)
  • Tested using both fieldsToUpdate and additionalFields together

Related Issue

Fixes the issue where users could not use additionalFields without first selecting manual fields in the Salesforce Update Record action.

Summary by CodeRabbit

Release Notes

  • New Features
    • Fields selection is now optional when updating Salesforce records, providing greater flexibility in update operations.
    • Improved handling for scenarios where no fields are specified during record updates.

Update the Salesforce Update Record action to make the fieldsToUpdate
prop optional, allowing users to utilize the additionalFields prop
immediately after selecting the SObject Type without needing to
manually select fields first.

Changes:
- Made fieldsToUpdate prop optional in update-record.mjs
- Updated additionalProps() to handle empty fieldsToUpdate gracefully
- additionalFields now appears immediately after SObject Type selection

This change maintains backward compatibility with existing workflows
that use manual field selection while providing a more flexible
workflow for users who prefer to specify all fields via additionalFields.
@vercel
Copy link

vercel bot commented Oct 29, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Preview Comments Updated (UTC)
pipedream-docs-redirect-do-not-edit Ignored Ignored Nov 21, 2025 6:33pm

@adolfo-pd adolfo-pd added the User submitted Submitted by a user label Oct 29, 2025
@pipedream-component-development
Copy link
Collaborator

Thank you so much for submitting this! We've added it to our backlog to review, and our team has been notified.

@pipedream-component-development
Copy link
Collaborator

Thanks for submitting this PR! When we review PRs, we follow the Pipedream component guidelines. If you're not familiar, here's a quick checklist:

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Oct 29, 2025

Caution

Review failed

The head commit changed during the review from 69ada51 to 9f4c5f3.

Walkthrough

The update-record action's fieldsToUpdate property is now optional, and the additionalProps logic is adjusted to conditionally generate selected field properties only when fieldsToUpdate is provided and contains values; otherwise, it returns an empty object.

Changes

Cohort / File(s) Summary
Salesforce REST API update-record action
components/salesforce_rest_api/actions/update-record/update-record.mjs
Made fieldsToUpdate optional by adding optional: true to propDefinition; adjusted additionalProps to skip field prop generation when fieldsToUpdate is absent or empty

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

  • Single file modification with straightforward conditional logic
  • Optional parameter addition with guarded prop generation
  • No complex control-flow changes or multi-pattern refactoring

Poem

🐰 Fields now optional, a lighter load,
No need to pick when none are owed,
The update-record hops with grace,
Conditional props in their rightful place! ✨

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Title Check ✅ Passed The pull request title "Salesforce: Make fieldsToUpdate optional in Update Record action" directly and clearly describes the main change in the changeset. The raw summary confirms that the primary modification is making the fieldsToUpdate property optional and adjusting additionalProps to handle this gracefully. The title is specific, concise, and immediately communicates the purpose of the change without vague language or unnecessary noise.
Description Check ✅ Passed The pull request description addresses the core requirement of the template by clearly explaining the reasoning behind the change in the opening paragraph. While the description doesn't use the exact "## WHY" heading format specified in the template, the content comprehensively covers why the change was made, what was modified, how the behavior changed (with before/after comparison), and includes testing guidance and issue reference. The description is well-structured, complete, and provides sufficient context well beyond the minimal template requirement.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Collaborator

@jcortes jcortes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @shadyshoha thanks for your contribution. Please also increment the patch version in package.json and in the component update-record as well, then I can run the gh action and it will be good for QA thanks.

@jcortes jcortes moved this from Ready for PR Review to Changes Required in Component (Source and Action) Backlog Nov 19, 2025
@michelle0927 michelle0927 moved this from Changes Required to Ready for QA in Component (Source and Action) Backlog Nov 21, 2025
@vunguyenhung vunguyenhung moved this from Ready for QA to Ready for Release in Component (Source and Action) Backlog Nov 23, 2025
@vunguyenhung
Copy link
Collaborator

Hi everyone, all test cases are passed! Ready for release!

Test reports

@michelle0927
Copy link
Collaborator

/approve

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

User submitted Submitted by a user

Projects

Status: Ready for Release

Development

Successfully merging this pull request may close these issues.

6 participants