Files
phalapi-pro/public/docs/Platform.Apps.EditMyApp.html
2022-03-21 11:16:38 +08:00

634 lines
24 KiB
HTML
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<style>
.hljs,.ui.attached:not(.message)+.ui.attached.segment:not(.top){
background:#fff!important;
}
body{
background:#F0F2F5!important;
}
.ui.message:last-child{
box-shadow: none;
height:217px;
background:rgba(255,255,255,1);
box-shadow:0px 0px 30px 0px rgba(0,0,0,0.05);
border-radius:10px;
}
.ui.message>:first-child{
border: none;
}
.ui.segment{
background:none!important;
padding: 0!important;
}
.ui.floating.message{
box-shadow: none!important;
background: none;
}
.ui.raised.segment{
box-shadow: none!important;
}
.ui.message p{
margin-bottom: 0!important;
opacity: 1!important;
}
.newDesc__link{
font-size:16px;
font-family:PingFangSC-Medium,PingFang SC;
font-weight:500;
color:rgba(51,51,51,1);
margin-bottom: 10px;
}
.newDesc__desc{
font-size:14px;
font-family:PingFangSC-Regular,PingFang SC;
font-weight:400;
color:rgba(102,102,102,1);
}
.ui.ordered.steps{
margin-top: 30px;
width: 100%;
height:90px;
background:rgba(250,250,250,1);
border-radius:10px;
border:1px solid rgba(233,233,233,1);
overflow: hidden;
}
/* 头标题 */
.newDescTitle{
height:101px;
background:rgba(255,255,255,1);
box-shadow:0px 0px 30px 0px rgba(0,0,0,0.05);
border-radius:10px;
display: flex;
align-items: center;
}
.newDescTitle__box{
padding: 0 30px;
}
.newDescTitle__box__nav{
font-size:14px;
font-family:PingFangSC-Regular,PingFang SC;
font-weight:400;
color:rgba(153,153,153,1);
}
.newDescTitle__box__t{
font-size:20px!important;
font-family:PingFangSC-Semibold,PingFang SC!important;
font-weight:600!important;
color:rgba(51,51,51,1)!important;
margin-top: 15px!important;
}
/* biaoge */
.ui.steps .step:after, .ui.ordered.steps .step.completed:before{
display: none!important;
}
.ui.steps .step .description{
font-size:14px!important;
font-family:PingFangSC-Regular,PingFang SC;
font-weight:400;
color:rgba(102,102,102,1)!important;
margin-bottom: 4px;
text-align: center;
}
.ui.steps .step .title{
font-size:18px!important;
font-family:PingFangSC-Regular,PingFang SC;
font-weight:400!important;
color:rgba(51,51,51,1)!important;
text-align: center;
}
/* biaoge e */
/* 接口参数 */
.parameter, .parameterName, .testing, .clientCode, .errorList{
padding-bottom: 20px;
background:rgba(255,255,255,1);
box-shadow:0px 0px 30px 0px rgba(0,0,0,0.05);
border-radius:10px;
margin-bottom: 20px;
}
.clientCode{
margin-bottom: 0px;
padding-bottom: 0px;
}
.parameter__title, .parameterName__title, .testing__title, .clientCode__title, .errorList__title{
padding: 0 30px;
height: 55px;
display: flex;
align-items: center;
border-bottom: 1px solid #E9E9E9;
}
.parameter__title p, .parameterName__title p, .testing__title p, .clientCode__title p, .errorList__title p{
font-size:16px;
font-family:PingFangSC-Medium,PingFang SC;
font-weight:500;
color:rgba(51,51,51,1);
}
.ui.red.table, .ui.green.table{
border-top: none!important;
margin-top: 20px!important;
border-bottom: none;
border-left: none;
border-right: none;
padding: 0 32px;
}
.ui.table:last-child tbody tr td,.ui.table:last-child thead tr th, .ui.green.table thead tr th, .ui.green.table tbody tr td{
border: none;
height: 53px;
}
.ui.table:last-child tbody tr,.ui.table:last-child thead tr, .ui.green.table thead tr th, .ui.green.table tbody tr td{
border-bottom: 1px solid #E9E9E9;
}
.ui.table:last-child thead tr th, .ui.green.table thead tr th{
font-size:14px;
font-family:PingFangSC-Medium,PingFang SC;
font-weight:500;
border-bottom: 1px solid #E9E9E9;
color:rgba(51,51,51,1);
}
.ui.table:last-child tbody tr td{
font-size:14px;
font-family:PingFangSC-Regular,PingFang SC;
font-weight:400;
color:rgba(102,102,102,1);
border-bottom: 1px solid #E9E9E9;
}
.signRed{
width:7px;
height:7px;
background:rgba(245,34,45,1);
display: inline-block;
border-radius: 50%;
margin-right: 7px;
}
.signGreen{
width:7px;
height:7px;
background:rgba(82,196,26,1);
display: inline-block;
border-radius: 50%;
margin-right: 7px;
}
/* 接口参数 e */
/* 客户示例 */
.ui.tab.active{
margin-top: 0!important;
box-shadow: none;
margin-bottom: 20px;
border: none;
padding-bottom: 20px!important;
}
pre{
margin-top: 0px;
}
/* 底部时间 */
.generatedTime{
display: flex;
height: 80px;
align-items: center;
justify-content: center!important;
}
.generatedTime small{
font-size:12px;
font-family:PingFangSC-Regular,PingFang SC;
font-weight:400;
color:rgba(153,153,153,1);
}
</style>
<!DOCTYPE html>
<html lang="en">
<!--
_____ _ _ _ _____
| __ \ | | | | /\ (_) | __ \
| |__) || |__ __ _ | | / \ _ __ _ | |__) |_ __ ___
| ___/ | '_ \ / _` || | / /\ \ | '_ \ | | | ___/| '__|/ _ \
| | | | | || (_| || | / ____ \ | |_) || | | | | | | (_) |
|_| |_| |_| \__,_||_|/_/ \_\| .__/ |_| |_| |_| \___/
| |
|_|
-->
<head>
<meta charset="utf-8">
<title> 修改应用 - Platform.Apps.EditMyApp - 接口大师 - 在线接口文档</title>
<link rel="stylesheet" href="https://cdn.bootcss.com/semantic-ui/2.2.2/semantic.min.css">
<link rel="stylesheet" href="https://cdn.bootcss.com/semantic-ui/2.2.2/components/table.min.css">
<link rel="stylesheet" href="https://cdn.bootcss.com/semantic-ui/2.2.2/components/container.min.css">
<link rel="stylesheet" href="https://cdn.bootcss.com/semantic-ui/2.2.2/components/message.min.css">
<link rel="stylesheet" href="https://cdn.bootcss.com/semantic-ui/2.2.2/components/label.min.css">
<link rel="icon" href="/favicon.ico" type="image/x-icon" />
<script src="/static/jquery.min.js"></script>
<script src="/static/jquery.cookie.min.js"></script>
</head>
<body>
<style>
.ui.fixed.menu{
height:70px;
background:linear-gradient(170deg,rgba(250,195,83,1) 0%,rgba(249,169,67,1) 100%);
box-shadow:0px 0px 40px 0px rgba(0,0,0,0.05);
}
.ui.message>:last-child{
display: flex;
justify-content: space-between;
width: 100%!important;
}
.ui.menu>.container, .ui.menu>.grid{
width:100%;
padding: 0 24px;
}
.ui.menu .item:before{
width:0px;
}
.contentList__logo{
width: 18%;
display: flex;
justify-content: center;
align-items: center;
}
.contentList__nav{
margin-left: 10%;
display: flex;
justify-content: center;
align-items: center;
height: 100%;
}
.nav__index{
position: relative;
}
.contentList__nav a{
height: 100%;
font-size:20px;
font-family:PingFangSC-Medium,PingFang SC;
font-weight:500;
color:rgba(51,51,51,1)!important;
padding-right: 0!important;
padding-left: 0!important;
margin-left: 20px;
margin-right: 20px;
/* transition: 2s; */
/* transform: 1s; */
}
/* .contentList__nav__i{
position: absolute;
bottom: 0;
display: none;
transition: .5s;
height: 5px;
width: 100px;
background: #333;
border-radius: 8px;
} */
.contentList__nav a:hover{
border-bottom: 5px solid #333;
}
/* .contentList__nav a:hover +.contentList__nav__i{
display: block;
} */
.ui.inverted.menu .dropdown.item:hover, .ui.inverted.menu .link.item:hover, .ui.inverted.menu a.item:hover, .ui.link.inverted.menu .item:hover{
background: none;
color: #333;
}
.ui.inverted.menu .active.item{
background: none!important;
color: #333!important;
}
.ui.inverted.menu .active.item:hover{
color: #333!important;
}
.logo{
object-fit: contain;
}
.register{
padding-right: 0!important;
}
</style>
<div class="ui fixed inverted menu black">
<div class="ui container contentList">
<div class="contentList__logo">
<a href="/docs.php" class="header item">
<img class="logo" alt="pro" src="/favicon.ico">
接口大师 </a>
</div>
<div class="contentList__nav">
<!-- <div class="contentList__nav__index">
<a href="/" class="item" class="nav__index">首页</a>
<span class="contentList__nav__i"></span>
</div> -->
<a href="/" class="item" class="nav__index">首页</a>
<a href="/docs.php" class="item">OpenAPI</a>
<a href="/platform" class="item">开放平台</a>
<a href="/wiki/" target="_blank" class="item">技术文档</a>
<a href="/admin/" target="_blank" class="item">管理后台</a>
</div>
<div class="right menu">
<div class="ui dropdown item" style="color: #333;">
语言 <i class="dropdown icon"></i>
<div class="menu">
<a class="item" href="/docs.php?language=zh_cn" >简体中文</a>
<a class="item" href="/docs.php?language=en" >English</a>
</div>
</div>
</div>
<!-- 欢迎/注册 -->
<div class="item register">
<div class="ui blue button"><a style="color:#fff;" href="/platform" target="_blank">登录</a></div>
&nbsp;
<div class="ui green button"><a style="color:#fff;" href="/platform" target="_blank"><i class="user icon"></i>注册</a></div>
</div>
</div>
</div>
<div class="row"></div>
<div class="ui text container" style="max-width: none !important;padding-top: 70px;">
<div class="ui floating message">
<div class="ui raised segment">
<!-- <span class="ui red ribbon label">
#接口文档 </span> -->
<div class="newDescTitle">
<div class="newDescTitle__box">
<p class="newDescTitle__box__nav">接口大师 / 平台接口 / <span style="color:#333;"> 修改应用</span> </p>
<p class="ui header newDescTitle__box__t">
修改应用 </p>
</div>
</div>
<div class="ui message newDesc">
<p class="newDesc__link">接口地址http://localhost/public/api/platform.php?s=Platform.Apps.EditMyApp</p>
<p class="newDesc__desc">接口描述: 修改应用信息,仅当审核未通过时才可修改</p>
<div class="ui ordered steps">
<div class="completed step">
<div class="content">
<div class="description">HTTP/HTTPS</div>
<div class="title">请求协议</div>
</div>
</div>
<div class="completed step">
<div class="content">
<div class="description">GET/POST</div>
<div class="title">请求方式</div>
</div>
</div>
<div class="completed step">
<div class="content">
<div class="description">UTF-8</div>
<div class="title">编码格式</div>
</div>
</div>
<div class="completed step">
<div class="content">
<div class="description">JSON</div>
<div class="title">返回格式</div>
</div>
</div>
</div>
</div>
</div>
<!-- 接口参数 -->
<div class="parameter">
<div class="parameter__title">
<p>接口参数</p>
</div>
<table class="ui red celled striped table" >
<thead>
<tr><th>参数名字</th><th>类型</th><th>是否必须</th><th>默认值</th><th>其他</th><th>说明</th></tr>
</thead>
<tbody>
<tr><td>access_token</td><td>字符串</td><td><span class="signGreen"></span><font color="#52C41A">可选</font></td><td></td><td></td><td>访问令牌仅当开启签名验证时需要传递生成令牌可使用App.Auth.ApplyToken接口</td></tr>
<tr><td>app_key</td><td>字符串</td><td><span class="signRed"></span><font color="red">必须</font></td><td>-</td><td>最大64</td><td>app_key用于区分客户端应用</td></tr>
<tr><td>appName</td><td>字符串</td><td><span class="signRed"></span><font color="red">必须</font></td><td>-</td><td>最大50</td><td>应用名称</td></tr>
<tr><td>app_owner</td><td>字符串</td><td><span class="signRed"></span><font color="red">必须</font></td><td>-</td><td>最大100</td><td>申请机构</td></tr>
<tr><td>app_icon</td><td>字符串</td><td><span class="signGreen"></span><font color="#52C41A">可选</font></td><td></td><td>最大255</td><td>应用图标</td></tr>
<tr><td>apply_reason</td><td>字符串</td><td><span class="signRed"></span><font color="red">必须</font></td><td>-</td><td>最大2000</td><td>申请说明</td></tr>
</tbody>
</table>
</div>
<!-- 参数名字 -->
<div class="parameterName">
<div class="parameterName__title">
<p>返回字段</p>
</div>
<table class="ui green celled striped table" >
<thead>
<tr><th>返回结果</th><th>类型</th><th>说明</th></tr>
</thead>
<tbody>
<tr><td>ret</td><td>整型</td><td>状态码200表示成功4xx表示客户端非法请求5xx表示服务器错误</td></tr>
<tr><td>data</td><td>对象或混合类型</td><td>业务数据,由各自接口指定,通常为对象</td></tr>
<tr><td>data.is_updated</td><td>bool</td><td>是否更新成功</td></tr> <tr><td>msg</td><td>字符串</td><td>提示信息,失败时的错误提示</td></tr>
</tbody>
</table>
</div>
<!-- 在线测试 -->
<div class="testing">
<div class="testing__title">
<p>在线测试 &nbsp;&nbsp;</p>
</div>
<table class="ui green celled striped table" >
<thead>
<tr><th width="25%">参数</th><th width="10%">是否必须</th><th width="65%"></th></tr>
</thead>
<tbody id="params">
<tr>
<td>service</td>
<td><span class="signRed"></span><font color="red">必须</font></td>
<td><div class="ui fluid input disabled"><input name="service" data-source="get" value="Platform.Apps.EditMyApp" style="width:100%;" class="C_input" /></div></td>
</tr>
<tr>
<td>access_token</td>
<td><span class="signGreen"></span><font color="#52C41A">可选</font></td>
<td><div class="ui fluid input"><input name="access_token" id="access_token_ipt_id" value="" data-source="" placeholder="访问令牌仅当开启签名验证时需要传递生成令牌可使用App.Auth.ApplyToken接口" style="width:100%;" class="C_input" type="text" /> </div></td>
</tr> <tr>
<td>app_key</td>
<td><span class="signRed"></span><font color="red">必须</font></td>
<td><div class="ui fluid input"><input name="app_key" id="app_key_ipt_id" value="" data-source="" placeholder="app_key用于区分客户端应用" style="width:100%;" class="C_input" type="text" /> </div></td>
</tr> <tr>
<td>appName</td>
<td><span class="signRed"></span><font color="red">必须</font></td>
<td><div class="ui fluid input"><input name="appName" id="appName_ipt_id" value="" data-source="" placeholder="应用名称" style="width:100%;" class="C_input" type="text" /> </div></td>
</tr> <tr>
<td>app_owner</td>
<td><span class="signRed"></span><font color="red">必须</font></td>
<td><div class="ui fluid input"><input name="app_owner" id="app_owner_ipt_id" value="" data-source="" placeholder="申请机构" style="width:100%;" class="C_input" type="text" /> </div></td>
</tr> <tr>
<td>app_icon</td>
<td><span class="signGreen"></span><font color="#52C41A">可选</font></td>
<td><div class="ui fluid input"><input name="app_icon" id="app_icon_ipt_id" value="" data-source="" placeholder="应用图标" style="width:100%;" class="C_input" type="text" /> </div></td>
</tr> <tr>
<td>apply_reason</td>
<td><span class="signRed"></span><font color="red">必须</font></td>
<td><div class="ui fluid input"><input name="apply_reason" id="apply_reason_ipt_id" value="" data-source="" placeholder="申请说明" style="width:100%;" class="C_input" type="text" /> </div></td>
</tr> </tbody>
</table>
<div class="ui fluid action input">
<input placeholder="请求的接口链接" type="text" name="request_url" value="http://localhost/public/api/platform.php" >
<button class="ui button green" id="submit" >请求当前接口</button>
</div>
</div>
<div style="display: flex;align-items:center;">
<!--<select name="request_type" style="font-size: 14px; padding: 2px;">
<option value="POST">POST</option>
<option value="GET">GET</option>
</select>-->
</div>
<div class="ui message blue" id="json_output">
</div>
<div class="ui message blue" id="json_output_api_result" style="overflow: auto;">
</div>
<div class="clientCode">
<div class="clientCode__title">
<p>客户端请求示例</p>
</div>
</div>
<div class="ui tab segment active" data-tab="json">
<div class="ui top attached tabular menu">
<a class="active item" data-tab="datatabjson">HTTP通用示例</a>
</div>
<div class="ui bottom attached active tab segment" data-tab="datatabjson"><pre><code># 暂无示例,可添加示例文件:./src/view/docs/demos/Platform.Apps.EditMyApp.json</code></pre></div>
</div>
<!-- 代码高亮 -->
<!--
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.13.1/styles/default.min.css">
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.13.1/highlight.min.js"></script>
-->
<link rel="stylesheet" href="./static/highlight.min.css">
<script src="./static/highlight.min.js"></script>
<script>hljs.initHighlightingOnLoad();</script>
<div class="errorList">
<div class="errorList__title">
<p id="ret_code_list_id">错误列表</p>
</div>
<table class="ui red celled striped table" >
<thead>
<tr><th>错误状态码</th><th>错误描述信息</th>
</thead>
<tbody><tr><td>400</td><td>ret=400客户端参数错误或非法请求</td></tr><tr><td>404</td><td>表示接口服务不存在</td></tr><tr><td>406</td><td>ret=406access_token令牌校验不通过</td></tr><tr><td>407</td><td>ret=407app_key权限不足或未知应用</td></tr><tr><td>408</td><td>ret=408当前用户禁止使用或用户未登录</td></tr><tr><td>500</td><td>表示服务端内部错误</td></tr> </tbody>
</table>
</div>
<!--
<div class="ui blue message">
<strong>温馨提示:</strong> 此接口文档根据接口代码和注释实时自动生成,帮助文档请见<a href="http://docs.phalapi.net/#/v2.0/api-docs" target="_blank">PhalApi 2.x 开发文档</a>。
</div>
-->
<p class="generatedTime"><small>本文档生成时间2021-03-25 15:10:55</small></p>
</div>
</div>
<script src="https://cdn.bootcss.com/semantic-ui/2.2.2/semantic.min.js" ></script>
<script src="https://cdn.bootcss.com/semantic-ui/2.2.2/components/tab.js"></script>
<script type="text/javascript">
$(function(){
$("#json_output").hide();
$("#json_output_api_result").hide();
$("#submit").on("click",function(){
$("#json_output").html('<div class="ui active inverted dimmer"><div class="ui text loader">接口请求中……</div></div>');
$("#json_output").show();
$("#json_output_api_result").html('');
var data = getData();
var url_arr = $("input[name=request_url]").val().split('?');
var url = url_arr.shift();
var param = url_arr.join('?');
param = param.length > 0 ? param + '&' + data.param : data.param;
url = url + '?' + param;
$.ajax({
url: url,
type:'post',
data:data.data,
cache: false,
processData: false,
contentType: false,
success:function(res,status,xhr){
var statu = xhr.status + ' ' + xhr.statusText;
var header = xhr.getAllResponseHeaders();
var json_text = JSON.stringify(res, null, 4); // 缩进4个空格
$("#json_output").html('<pre>' + statu + '<br />' + header + '</pre>');
$("#json_output").show();
if (hljs) {
// var hightLightCode = hljs.highlightAuto(json_text);
var hightLightCode = hljs.highlight('json', json_text);
json_text = hightLightCode.value;
}
$("#json_output_api_result").html('<pre><code>' + json_text + '</code></pre>');
$("#json_output_api_result").show();
},
error:function(error){
$("#json_output").html('接口请求失败:' + error);
}
})
})
fillHistoryData();
//checkLastestVersion();
// 选项卡
$('.tabular.menu .item').tab();
$('.ui.dropdown').dropdown({
// you can use any ui transition
transition: 'drop'
});
})
function getData() {
var data = new FormData();
var param = [];
$("td input").each(function(index,e) {
if ($.trim(e.value)){
if (e.type != 'file'){
if ($(e).data('source') == 'get') {
param.push(e.name + '=' + e.value);
} else {
data.append(e.name, e.value);
}
if (e.name != "service") $.cookie(e.name, e.value, {expires: 30});
} else{
var files = e.files;
if (files.length == 1){
data.append(e.name, files[0]);
} else{
for (var i = 0; i < files.length; i++) {
data.append(e.name + '[]', files[i]);
}
}
}
}
});
param = param.join('&');
return {param:param, data:data};
}
// 填充历史数据
function fillHistoryData() {
$("td input").each(function(index,e) {
var cookie_value = $.cookie(e.name);
if (e.name != "service" && cookie_value !== undefined) {
e.value = cookie_value;
}
});
}
</script>