如何在 Netsuite 中使用 RESTlet 传递枚举值?

How to pass enum value using RESTlet in Netsuite?

当没有状态字段时,我可以通过以下 php 代码在 Netsuite 中使用 RESTlet 创建 phone 调用。

$datastring = array(
       'recordtype' => 'phonecall',
       'gu_action' => 'create',
       'title' => 'test',
       'status'=>'_completed'
);

当我传递带状态的数据串时,出现类似

的错误
Array
(
    [custom_error] => Array
        (
            [code] => INVALID_KEY_OR_REF
            [message] => Invalid status reference key _completed.
        )

)

https://gist.githubusercontent.com/ganeshprabhus/68a9e5b81e53436bb1d684f857a6c31f/raw/67fe03895f1c31d65c1f283dd51584af45d27c59/NS_Script_2016.2004

中可用的 RESTlet 脚本

请尝试使用 COMPLETE 而不是 _completed。