3

I'm trying to create a new unlocked package that adds some custom fields to the Quote object. If I deploy the source to a scratch org everything works as expected.

I created the package running:

sfdx force:package:create -n PackageName -d "desc.." -r force-app -t Unlocked -v devHubOrg

When I run the following command to the create package version

sfdx force:package:version:create -p PackageName -d force-app -k "xxxx" -v devHubOrg --wait 10

I receive the following Error:

ERROR running force:package:version:create:  Quote.Opportunity_Owner_Name__c: Entity 'Quote' not found.,Quote.Opportunity_Owner_Email__c: Entity

Is there something special I have to do to create a unlocked package that uses the Quote and QuoteLineItem sObjects?

  • 1
    Does your sfdx-project.json file specify a definition file with the IsQuoteEnabled org preference enabled? – John Towers Jun 26 '19 at 16:24
  • @JohnTowers, was in the process of updating my answer to include that after doing a bit more digging on unlocked packages – Jason Hardy Jun 26 '19 at 16:32
3

You have to enable quotes.

The sfdx-project.json file has to have IsQuoteEnabled set.

  • Thank you, I added: "definitionFile": "./config/project-scratch-def.json" to the packageDirectories and it seem to have fixed it! – warbio Jun 26 '19 at 16:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.