You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
1.7 KiB
PHP
44 lines
1.7 KiB
PHP
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
|
|
<meta http-equiv="Expires" CONTENT="0"/>
|
|
<meta http-equiv="Cache-Control" CONTENT="no-cache"/>
|
|
<meta http-equiv="Pragma" CONTENT="no-cache"/>
|
|
<title>fast api</title>
|
|
<script type="text/javascript" src="/min/?f=/js/information-system3.min.js,/js/common.js&v=20190128"></script>
|
|
</head>
|
|
<script type="text/javascript">
|
|
function query() {
|
|
$.ajax({
|
|
type: "post",
|
|
dataType: "json",
|
|
url: "<?php echo site_url('apps/fastapi/index/query')?>",
|
|
data: {
|
|
"sql_text": $('#sqltextarea').val(),
|
|
"database": $('#databasename').val(),
|
|
},
|
|
success: function (data, textStatus) {
|
|
$('#resulttextarea').val(JSON.stringify(data, null, 4));
|
|
},
|
|
error: function () {
|
|
$('#resulttextarea').val('查询异常');
|
|
}
|
|
})
|
|
}
|
|
</script>
|
|
<body>
|
|
<h1>fast api</h1>
|
|
<div style="text-align: center">
|
|
<textarea rows="12" cols="120" id="sqltextarea"></textarea>
|
|
<br/>
|
|
<label><input type="radio" value="TOURMANAGER" id="databasename" name="databasename" checked/>Tourmanager</label>
|
|
<label><input type="radio" value="INFOMANAGER" id="databasename" name="databasename"/>Infomanager</label>
|
|
<button onclick="query()"> 提交查询</button>
|
|
<hr/>
|
|
<textarea rows="30" cols="120" style="height: 90%;width: 100%" id="resulttextarea"></textarea>
|
|
</div>
|
|
</body>
|
|
</html>
|