玩瞳文档中心


改变资源制作状态

<p><strong>服务:</strong>api-cloud <strong>API: </strong><code>cloud-api1.51wanxue.com/api-cloud/book/updateBookState/{bookId}?state=3</code> <strong>请求方式:</strong>PUT <strong>api开发者:</strong> cgl <strong>是否授权登录:</strong> 是 <strong>请求示例:</strong> cloud-api1.51wanxue.com/api-cloud/book/updateBookState/123?state=1 ,如果不传参数state,则默认更新至已审核,1表示更新状态至资源待编辑,2表示更新状态至资源待审核,3表示更新状态至已审核 <strong>简要描述:</strong> 1.将资源库中资源待编辑、待审核、已审核的书本状态进行改变 2.如果禁用中的书本,无法通过此接口更改书本状态至已审核。如有禁用中书本返回失败时,需提示“该书本状态为禁用中,无法更新为已审核状态”。 3.触发一次打包预计5分钟时间</p> <p><strong>参数:</strong></p> <table> <thead> <tr> <th style="text-align: left;">参数名</th> <th style="text-align: left;">必选</th> <th style="text-align: left;">类型</th> <th>说明</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">bookId</td> <td style="text-align: left;">是</td> <td style="text-align: left;">long</td> <td>在url中,bookId为资源库书本id</td> </tr> <tr> <td style="text-align: left;">state</td> <td style="text-align: left;">否</td> <td style="text-align: left;">int</td> <td>状态:0:待编辑不可读 3:已审核可读(默认值) 7:待审核可读</td> </tr> <tr> <td style="text-align: left;">resourceType</td> <td style="text-align: left;">否</td> <td style="text-align: left;">int</td> <td>资源类型:1:领读 2:点读 3:点读与领读,默认为空 不修改次字段</td> </tr> </tbody> </table> <p><strong>返回示例</strong></p> <pre><code class="language-json">查询成功示例 { &amp;quot;code&amp;quot;: 0, &amp;quot;msg&amp;quot;: &amp;quot;ok&amp;quot;, &amp;quot;data&amp;quot;: null } 查询失败示例 { &amp;quot;code&amp;quot;: 10002, &amp;quot;msg&amp;quot;: &amp;quot;book not found&amp;quot;, &amp;quot;data&amp;quot;: null }</code></pre> <p><strong>返回数据参数说明 </strong></p> <table> <thead> <tr> <th style="text-align: left;">参数名</th> <th style="text-align: left;">类型</th> <th>说明</th> </tr> </thead> <tbody> <tr> <td style="text-align: left;">code</td> <td style="text-align: left;">int</td> <td>请求返回码 0(表示成功)</td> </tr> <tr> <td style="text-align: left;">msg</td> <td style="text-align: left;">String</td> <td>系统返回提示</td> </tr> <tr> <td style="text-align: left;">data</td> <td style="text-align: left;"></td> <td>没有返回数据</td> </tr> </tbody> </table>

页面列表

ITEM_HTML