【问题标题】:Redmine Rest API error 'Subject can not be blank'Redmine Rest API 错误“主题不能为空”
【发布时间】:2019-05-02 12:12:41
【问题描述】:

我正在使用 kbsali redmine api 创建问题,即使我传递主题,我也会收到主题不能为空白的错误

$result=$client->issue->create([
    'project_id'  => 'projder',
    'subject'     => 'this is subject subject this is subject subject this is subject subject this is subject subject this is subject subject',
    'description' => 'this is subject subject this is subject subject this is subject subject this is subje',
    'assigned_to_id' => '45',
    'priority_id' => $_POST['inputPriority'],
    'uploads'     => array(
        array(
          'token'       => $upload->upload->token,
          'filename'    => $file,
          'description' => 'This is my file description',
          'content_type'=> 'image/png'
        ),
        array(
          'token'       => $uploadoptional->upload->token,
          'filename'    => $optionalUpload,
          'description' => 'Client Attachment',
          'content_type'=> $optionalUploadType
        )
    )
]);



)
SimpleXMLElement Object
(
    [@attributes] => Array
        (
            [type] => array
        )

    [error] => Subject cannot be blank
)

【问题讨论】:

  • 您尝试过什么调试问题?不传输附件可以吗?

标签: php redmine-api


【解决方案1】:

我找到了解决方案,通过使用我发送 API 请求来创建票证,并未将 redmine 主题字段权限授予用户。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-07-04
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多