0

I'm trying to package changes (added Received) to the Status picklist field on the Order object. In the package.xml I have added the following:

<types>
    <members>OrderStatus</members>
    <name>StandardValueSet</name>
</types>

I've created a StandardValueSets directory in the package and I've added the following OrderStatus.standardValueSet xml file:

<?xml version="1.0" encoding="UTF-8"?>
<StandardValueSet xmlns="http://soap.sforce.com/2006/04/metadata">
    <fullName>OrderStatus</fullName>
    <standardValue>
       <fullName>Draft</fullName>
    </standardValue>
    <standardValue>
       <fullName>Activated</fullName>
    </standardValue>
    <standardValue>
       <fullName>Received</fullName>
    </standardValue>
</StandardValueSet>

When I attempt to deploy this package via workbench I get the following error:

Grouping string should be set for OrderStatus

I assume this means that values for Order Status need to be grouped as Draft or Activated. Is this correct? Also, I was wondering how this grouping assignment might look in the xml.

Thanks

0

I can't find the documentation on this but Metadata API V47 doesn't support OrderStatus as a StandardValueSet.

When I retrieve all of my StandardValueSet in my org, OrderStatus is not included, OrderType is though.

I think the reason for this is that deploying changes to this metadata into a Production environment could cause havoc with existing Orders that are draft v activated

0

I managed to pull in the OrderStatus StandardValueSet by explicitly defining it in the package.xml:

<types>
    <members>OrderStatus</members>
    <name>StandardValueSet</name>
</types>

It looks like this:

<?xml version="1.0" encoding="UTF-8"?>
<StandardValueSet xmlns="http://soap.sforce.com/2006/04/metadata">
    <groupingStringEnum>OrderStatusCode</groupingStringEnum>
    <sorted>false</sorted>
    <standardValue>
        <fullName>Draft</fullName>
        <default>false</default>
        <label>Draft</label>
        <groupingString>Draft</groupingString>
    </standardValue>
    <standardValue>
        <fullName>Activated</fullName>
        <default>false</default>
        <label>Activated</label>
        <groupingString>Activated</groupingString>
    </standardValue>
    <standardValue>
        <fullName>Received</fullName>
        <default>false</default>
        <label>Received</label>
        <groupingString>Activated</groupingString>
    </standardValue>
</StandardValueSet>

It includes the new value 'Received'. Now to see if I can deploy this to another env as part of a package.

  • Appears to work :) – vshake Oct 16 at 17:14

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.