* Reformat code style.

This commit is contained in:
zhujinyong
2021-10-19 13:21:22 +08:00
parent 64af527b27
commit 68e738fdd7
8 changed files with 172 additions and 176 deletions
+40 -40
View File
@@ -10,10 +10,10 @@
* @link http://www.zentao.net
*/
?>
<?php include '../../common/view/header.html.php'; ?>
<?php include '../../common/view/kindeditor.html.php'; ?>
<?php js::set('example', $example); ?>
<?php js::set('libID', $libID); ?>
<?php include '../../common/view/header.html.php';?>
<?php include '../../common/view/kindeditor.html.php';?>
<?php js::set('example', $example);?>
<?php js::set('libID', $libID);?>
<?php
js::set('typeOptions', $typeOptions);
js::set('langField', $lang->struct->field);
@@ -27,7 +27,7 @@ js::set('struct_action', $lang->struct->action);
js::set('struct_required', $lang->struct->required);
js::set('struct_paramsType', $lang->struct->paramsType);
?>
<?php js::import($jsRoot . 'vue/vue.js'); ?>
<?php js::import($jsRoot . 'vue/vue.js');?>
<div class='modal fade' id='filterStruct'>
<div class='modal-dialog mw-500px'>
<div class='modal-content'>
@@ -35,20 +35,20 @@ js::set('struct_paramsType', $lang->struct->paramsType);
<button type='button' class='close' data-dismiss='modal'>
<i class='icon icon-close'></i>
</button>
<h4 class='modal-title'><?php echo $lang->api->struct; ?></h4>
<h4 class='modal-title'><?php echo $lang->api->struct;?></h4>
</div>
<div class='modal-body'>
<table class='table table-form'>
<tbody>
<tr>
<td> <?php echo html::select('filter', $allStruct, '', "class='form-control chosen filterSelect'"); ?> </td>
<td> <?php echo html::select('filter', $allStruct, '', "class='form-control chosen filterSelect'");?> </td>
<td></td>
</tr>
</tbody>
</table>
</div>
<div class="modal-footer">
<?php echo html::submitButton($lang->confirm, '', 'btn btn-wide btn-primary submit-filter'); ?>
<?php echo html::submitButton($lang->confirm, '', 'btn btn-wide btn-primary submit-filter');?>
</div>
</div>
</div>
@@ -56,66 +56,66 @@ js::set('struct_paramsType', $lang->struct->paramsType);
<div id="mainContent" class="main-content">
<div class='center-block' id="apiApp">
<div class='main-header'>
<h2><?php echo $lang->api->create; ?></h2>
<h2><?php echo $lang->api->create;?></h2>
</div>
<form class="load-indicator main-form form-ajax" id="dataform" method='post' enctype='multipart/form-data'>
<table class='table table-form'>
<tbody>
<tr>
<th class='w-110px'><?php echo $lang->api->lib; ?></th>
<td> <?php echo html::select('lib', $libs, $libID, "class='form-control chosen' onchange=loadDocModule(this.value)"); ?> </td>
<th class='w-110px'><?php echo $lang->api->lib;?></th>
<td> <?php echo html::select('lib', $libs, $libID, "class='form-control chosen' onchange=loadDocModule(this.value)");?> </td>
<td></td>
</tr>
<tr>
<th><?php echo $lang->api->module; ?></th>
<th><?php echo $lang->api->module;?></th>
<td>
<span
id='moduleBox'><?php echo html::select('module', $moduleOptionMenu, $moduleID, "class='form-control chosen'"); ?></span>
id='moduleBox'><?php echo html::select('module', $moduleOptionMenu, $moduleID, "class='form-control chosen'");?></span>
</td>
<td></td>
</tr>
<tr>
<th><?php echo $lang->api->formTitle; ?></th>
<td colspan='2'><?php echo html::input('title', '', "class='form-control' required"); ?></td>
<th><?php echo $lang->api->formTitle;?></th>
<td colspan='2'><?php echo html::input('title', '', "class='form-control' required");?></td>
</tr>
<tr>
<th><?php echo $lang->api->path; ?></th>
<th><?php echo $lang->api->path;?></th>
<td colspan='2'>
<div class='table-row'>
<div class='table-col col-prefix'>
<?php echo html::select('protocol', $lang->api->protocalOptions, 'HTTP', "class='form-control chosen'"); ?>
<?php echo html::select('protocol', $lang->api->protocalOptions, 'HTTP', "class='form-control chosen'");?>
</div>
<div class='table-col col-prefix'>
<?php echo html::select('method', $lang->api->methodOptions, 'GET', "class='form-control chosen'"); ?>
<?php echo html::select('method', $lang->api->methodOptions, 'GET', "class='form-control chosen'");?>
</div>
<div class='table-col'>
<?php echo html::input('path', '', "class='form-control'"); ?>
<?php echo html::input('path', '', "class='form-control'");?>
</div>
</div>
</td>
</tr>
<tr>
<th><?php echo $lang->api->requestType; ?></th>
<th><?php echo $lang->api->requestType;?></th>
<td>
<span id='moduleBox'><?php echo html::select('requestType', $lang->api->requestTypeOptions, 'application/json', "class='form-control chosen'"); ?></span>
<span id='moduleBox'><?php echo html::select('requestType', $lang->api->requestTypeOptions, 'application/json', "class='form-control chosen'");?></span>
</td>
</tr>
<tr>
<th><?php echo $lang->api->status; ?></th>
<td><?php echo html::radio('status', $lang->api->statusOptions, apiModel::STATUS_DONE); ?></td>
<th><?php echo $lang->api->status;?></th>
<td><?php echo html::radio('status', $lang->api->statusOptions, apiModel::STATUS_DONE);?></td>
</tr>
<tr>
<th>
<nobr><?php echo $lang->api->owner; ?></nobr>
<nobr><?php echo $lang->api->owner;?></nobr>
</th>
<td>
<div class='input-group'>
<?php echo html::select('owner', $allUsers, $user, "class='form-control chosen'"); ?>
<?php echo html::select('owner', $allUsers, $user, "class='form-control chosen'");?>
</div>
</td>
</tr>
<tr>
<th><?php echo $lang->api->header; ?></th>
<th><?php echo $lang->api->header;?></th>
<td colspan="2">
<table class="table table-data">
<thead>
@@ -150,7 +150,7 @@ js::set('struct_paramsType', $lang->struct->paramsType);
</td>
</tr>
<tr>
<th><?php echo $lang->api->query; ?></th>
<th><?php echo $lang->api->query;?></th>
<td colspan="2">
<table class="table table-data">
<thead>
@@ -185,7 +185,7 @@ js::set('struct_paramsType', $lang->struct->paramsType);
</td>
</tr>
<tr>
<th><?php echo $lang->api->params; ?></th>
<th><?php echo $lang->api->params;?></th>
<td colspan='2'>
<body-field @change="changeAttr"></body-field>
<input type="hidden" name="params" v-model="params">
@@ -193,16 +193,16 @@ js::set('struct_paramsType', $lang->struct->paramsType);
</tr>
<tr>
<th>
<nobr><?php echo $lang->api->paramsExample; ?></nobr>
<nobr><?php echo $lang->api->paramsExample;?></nobr>
</th>
<td>
<div class='input-group'>
<?php echo html::textarea('paramsExample', '', "style='width:100%;height:200px'"); ?>
<?php echo html::textarea('paramsExample', '', "style='width:100%;height:200px'");?>
</div>
</td>
</tr>
<tr>
<th><?php echo $lang->api->response; ?></th>
<th><?php echo $lang->api->response;?></th>
<td colspan='2' id='responseDiv'>
<body-field @change="changeRes" :struct-type="'json'" :show-type="false"></body-field>
<input type="hidden" name="response" v-model="response">
@@ -210,25 +210,25 @@ js::set('struct_paramsType', $lang->struct->paramsType);
</tr>
<tr>
<th>
<nobr><?php echo $lang->api->responseExample; ?></nobr>
<nobr><?php echo $lang->api->responseExample;?></nobr>
</th>
<td>
<div class='input-group'>
<?php echo html::textarea('responseExample', '', "style='width:100%;height:200px'"); ?>
<?php echo html::textarea('responseExample', '', "style='width:100%;height:200px'");?>
</div>
</td>
</tr>
<tr id='contentBox'>
<th><?php echo $lang->api->desc; ?></th>
<th><?php echo $lang->api->desc;?></th>
<td colspan='2'>
<div class='contenthtml'><?php echo html::textarea('desc', '', "style='width:100%;height:200px'"); ?></div>
<div class='contenthtml'><?php echo html::textarea('desc', '', "style='width:100%;height:200px'");?></div>
</td>
</tr>
<tr>
<td colspan='3' class='text-center form-actions'>
<?php echo html::submitButton(); ?>
<?php if(empty($gobackLink)) echo html::backButton($lang->goback, "data-app='{$app->tab}'"); ?>
<?php if(!empty($gobackLink)) echo html::a($gobackLink, $lang->goback, '', "class='btn btn-back btn-wide'"); ?>
<?php echo html::submitButton();?>
<?php if(empty($gobackLink)) echo html::backButton($lang->goback, "data-app='{$app->tab}'");?>
<?php if(!empty($gobackLink)) echo html::a($gobackLink, $lang->goback, '', "class='btn btn-back btn-wide'");?>
</td>
</tr>
</tbody>
@@ -236,5 +236,5 @@ js::set('struct_paramsType', $lang->struct->paramsType);
</form>
</div>
</div>
<?php js::set('noticeAcl', $lang->noticeAcl); ?>
<?php include '../../common/view/footer.html.php'; ?>
<?php js::set('noticeAcl', $lang->noticeAcl);?>
<?php include '../../common/view/footer.html.php';?>