master
wangshuai 4 years ago
parent e2d5a5f41e
commit 9d8cd4ba44

@ -12,7 +12,7 @@ db = 1
expireTime = 86400
enable = 0
[maria]
[maria_ypt]
ip = 10.10.14.199
port = 22066
database = dsideal_db
@ -20,6 +20,14 @@ user = root
pwd = DsideaL147258369
enable = 0
[maria_xpt]
ip = 10.10.14.175
port = 22066
database = platform_base
user = root
pwd = DsideaL147258369
enable = 0
;ip = 10.10.14.187
;port = 18890
;db = 0

@ -0,0 +1,928 @@
<!DOCTYPE html>
<html>
<head>
<title>My Page</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="http://code.jquery.com/mobile/1.1.0/jquery.mobile-1.1.0.min.css" />
<script src="http://code.jquery.com/jquery-1.7.1.min.js" type="text/javascript"></script>
<script src="http://code.jquery.com/mobile/1.1.0/jquery.mobile-1.1.0.min.js" type="text/javascript"></script>
<script src="jquery.timers-1.2.js" type="text/javascript"></script>
<script type="text/javascript">
$(document).ready(function(){
// 获取市下的行政区划列表
var hyper001 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
200051
],
"query_format": "json",
"query_id": "hyper001",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取市下的单位列表
var hyper002 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
200051, 2
],
"query_format": "json",
"query_id": "hyper002",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取区下的单位列表
var hyper003 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
310041, 2
],
"query_format": "json",
"query_id": "hyper003",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取单位下的组织机构(部门)树
var hyper004 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
200125116
],
"query_format": "json",
"query_id": "hyper004",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取组织机构(部门)下的教师列表
var hyper005 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
3
],
"query_format": "json",
"query_id": "hyper005",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取学校的学段列表
var hyper006 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
3
],
"query_format": "json",
"query_id": "hyper006",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取学校的入学年份列表
var hyper007 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
3
],
"query_format": "json",
"query_id": "hyper007",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取学校的班级列表
var hyper008 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
3, 4, 2018
],
"query_format": "json",
"query_id": "hyper008",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取班级下的学生列表
var hyper009 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
126440
],
"query_format": "json",
"query_id": "hyper009",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取班级下的家长列表
var hyper010 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
126440
],
"query_format": "json",
"query_id": "hyper010",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取单位信息
var hyper011 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"data_id": "3",
"query_cols": [
],
"query_format": "json",
"query_id": "hyper011"
}
// 获取班级信息
var hyper012 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"data_id": "126440",
"query_cols": [
],
"query_format": "json",
"query_id": "hyper012"
}
// 获取教师信息
var hyper013 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"data_id": "69033",
"query_cols": [
],
"query_format": "json",
"query_id": "hyper013"
}
// 获取学生信息
var hyper014 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"data_id": "86202337",
"query_cols": [
],
"query_format": "json",
"query_id": "hyper014"
}
// 获取人员的所有角色列表
var hyper015 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
69033, 7
],
"query_format": "json",
"query_id": "hyper015",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取人员某个业务系统的角色列表
var hyper016 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
"COMMON"
],
"query_format": "json",
"query_id": "hyper016",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取人员某个业务系统的功能菜单
var hyper017 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
"COMMON", 10
],
"query_format": "json",
"query_id": "hyper017",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取学段信息
var hyper018 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
],
"query_format": "json",
"query_id": "hyper018",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取行政区
var hyper019 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
],
"query_format": "json",
"query_id": "hyper019",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取行政区
var hyper020 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
],
"query_format": "json",
"query_id": "hyper020",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取机构(单位)
var hyper021 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
],
"query_format": "json",
"query_id": "hyper021",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取机构(单位)
var hyper022 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
],
"query_format": "json",
"query_id": "hyper022",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取学校
var hyper023 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
2
],
"query_format": "json",
"query_id": "hyper023",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取学校
var hyper024 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
2
],
"query_format": "json",
"query_id": "hyper024",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取部门
var hyper025 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
3, 400001
],
"query_format": "json",
"query_id": "hyper025",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取部门
var hyper026 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
3, 'f98cfdd5de99440d855aafb24ba47b52'
],
"query_format": "json",
"query_id": "hyper026",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取年级
var hyper027 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
400001
],
"query_format": "json",
"query_id": "hyper027",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取年级
var hyper028 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
'097D57445AA54AAC958B8649A44ECEA9'
],
"query_format": "json",
"query_id": "hyper028",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取班级
var hyper029 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
400001, 2017
],
"query_format": "json",
"query_id": "hyper029",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取班级
var hyper030 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
'097D57445AA54AAC958B8649A44ECEA9'
],
"query_format": "json",
"query_id": "hyper030",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取教师(教职工)
var hyper031 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
400001, 5
],
"query_format": "json",
"query_id": "hyper031",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取教师(教职工)
var hyper032 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
5, '097D57445AA54AAC958B8649A44ECEA9'
],
"query_format": "json",
"query_id": "hyper032",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取学生
var hyper033 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
400001
],
"query_format": "json",
"query_id": "hyper033",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取学生
var hyper034 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
6, '097D57445AA54AAC958B8649A44ECEA9'
],
"query_format": "json",
"query_id": "hyper034",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取家长
var hyper035 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
400001
],
"query_format": "json",
"query_id": "hyper035",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取家长
var hyper036 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
7, '097D57445AA54AAC958B8649A44ECEA9'
],
"query_format": "json",
"query_id": "hyper036",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取用户角色
var hyper037 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
1, 1
],
"query_format": "json",
"query_id": "hyper037",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取系统角色
var hyper038 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
'YPT'
],
"query_format": "json",
"query_id": "hyper038",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取用户角色
var hyper039 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
'd704280d17d3480e8e609da36415ce8e'
],
"query_format": "json",
"query_id": "hyper039",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取系统角色
var hyper040 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
],
"query_format": "json",
"query_id": "hyper040",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取权限
var hyper041 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
'JY', '167, 197'
],
"query_format": "json",
"query_id": "hyper041",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取权限
var hyper042 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
"64056dd8421c89e3d0bb8511526a7ace"
],
"query_format": "json",
"query_id": "hyper042",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取权限
var hyper043 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
],
"query_format": "json",
"query_id": "hyper043",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
// 获取权限
var hyper044 = {
"access_token": "system_01##20200102030405##a6ce11eab94df48a6ce11eab",
"query_cols": [
],
"query_combinations": "",
"query_conditions": [
],
"query_format": "json",
"query_id": "hyper044",
"query_order": [
],
"query_page": 1,
"query_perpage": 20
}
$(".button").click(function () {
var queryIds = $('.query_ids').val()
var queryArr = queryIds.split(",")
var selectedOption = $(".query_ids").find("option:selected");
var func = selectedOption.attr("func")
var requestUrl
//var platform = $("input[type='radio']:checked").val()
var platform
var queryId
$("#show_zone").html("")
for (const elem of queryArr) {
var elems = elem.split(":")
platform = elems[0]
queryId = elems[1]
requestUrl = "http://127.0.0.1:9009/dataex/hyper_" + platform + "/" + func
var jsonStr = JSON.stringify(eval(queryId), null, "\t")
//console.log(platform);
$.ajax({
type : "post",
url: requestUrl,
contentType:"application/json",
dataType: "json",
async: false,
data : JSON.stringify(eval(queryId)),
beforeSend : function(result) {
$("#show_zone").append("<p><strong> 平台 - " + platform + "</strong></p>")
$("#show_zone").append("<p>请求URL: </p>" + requestUrl)
$("#show_zone").append("<p>提交参数: </p>" + jsonStr)
},
//请求成功
success : function(result) {
console.log(result);
$("#show_zone").append("<p>执行结果: </p>" + JSON.stringify(result))
},
//请求失败,包含具体的错误信息
error : function(e){
console.log(e.status);
console.log(e.responseText);
},
complete : function (XMLHttpRequest, textStatus) {
// Do something
}
}).done(function() {
$(".print_box").html("ok!")
});
}
// if (queryId == "hyper011" || queryId == "hyper012" || queryId == "hyper013" || queryId == "hyper014") {
// requestUrl = "http://127.0.0.1:9009/dataex/hyper_" + platform + "/QueryByID"
// } else {
// requestUrl = "http://127.0.0.1:9009/dataex/hyper_" + platform + "/Query"
// }
/*
$.ajax({
type : "post",
url: requestUrl,
contentType:"application/json",
dataType: "json",
data : JSON.stringify(eval(queryId)),
beforeSend : function(result) {
$("#tip_zone").html("<p>提交参数: </p>" + jsonStr)
},
//请求成功
success : function(result) {
console.log(result);
$("#show_zone").html("<p>执行结果: </p>" + JSON.stringify(result), null, "\t")
},
//请求失败,包含具体的错误信息
error : function(e){
console.log(e.status);
console.log(e.responseText);
}
}).done(function() {
$(".print_box").html("ok!")
});
*/
})
});
</script>
</head>
<body>
<div data-role="page">
<div data-role="header">
<h1>基础数据超融合</h1>
</div><!-- /header -->
<div data-role="content">
<div id="container">
<div id="control_zone">
<p class="print_box">Hello world</p>
<select name="query_ids" class="query_ids">
<option value="ypt:hyper001" func="Query">获取市下的行政区划列表</option>
<option value="ypt:hyper002" func="Query">获取市下的单位列表</option>
<option value="ypt:hyper003" func="Query">获取区下的单位列表</option>
<option value="ypt:hyper004" func="Query">获取单位下的组织机构(部门)树</option>
<option value="ypt:hyper005" func="Query">获取组织机构(部门)下的教师列表</option>
<option value="ypt:hyper006" func="Query">获取学校的学段列表</option>
<option value="ypt:hyper007" func="Query">获取学校的入学年份列表</option>
<option value="ypt:hyper008" func="Query">获取学校的班级列表</option>
<option value="ypt:hyper009" func="Query">获取班级下的学生列表</option>
<option value="ypt:hyper010" func="Query">获取班级下的家长列表</option>
<option value="ypt:hyper011" func="QueryByID">获取单位信息</option>
<option value="ypt:hyper012" func="QueryByID">获取班级信息</option>
<option value="ypt:hyper013" func="QueryByID">获取教师信息</option>
<option value="ypt:hyper014" func="QueryByID">获取学生信息</option>
<option value="ypt:hyper015" func="Query">获取人员的所有角色列表</option>
<option value="ypt:hyper016" func="Query">获取人员某个业务系统的角色列表</option>
<option value="ypt:hyper017" func="Query">获取人员某个业务系统的功能菜单</option>
<option value="ypt:hyper018" func="Query">获取学段信息</option>
<option value="ypt:hyper019,xpt:hyper020" func="Query">获取行政区</option>
<option value="ypt:hyper021,xpt:hyper022" func="Query">获取机构(单位)</option>
<option value="ypt:hyper023,xpt:hyper024" func="Query">获取学校</option>
<option value="ypt:hyper025,xpt:hyper026" func="Query">获取部门</option>
<option value="ypt:hyper027,xpt:hyper028" func="Query">获取年级</option>
<option value="ypt:hyper029,xpt:hyper030" func="Query">获取班级</option>
<option value="ypt:hyper031,xpt:hyper032" func="Query">获取教师(教职工)</option>
<option value="ypt:hyper033,xpt:hyper034" func="Query">获取学生</option>
<option value="ypt:hyper035,xpt:hyper036" func="Query">获取家长</option>
<option value="ypt:hyper037,xpt:hyper039" func="Query">获取用户角色</option>
<option value="ypt:hyper038,xpt:hyper040" func="Query">获取系统角色</option>
<option value="ypt:hyper041,xpt:hyper042" func="Query">获取权限</option>
<option value="ypt:hyper043,xpt:hyper044" func="Query">获取系统角色</option>
</select>
<button class="button" type='button'>GET IT !</button>
</div>
<!--<div id="tip_zone"></div>-->
<div id="show_zone"></div>
</div>
</div><!-- /content -->
</div><!-- /page -->
</body>
</html>

@ -7,16 +7,16 @@ import (
//Gin 路由配置
func Routers(r *gin.RouterGroup) {
rr := r.Group("/hyper")
rr := r.Group("/hyper_:platform")
{
rr.POST("/Query", DatahyperOpenapi.Query)
rr.POST("/QueryByID", DatahyperOpenapi.QueryByID)
rr.POST("/QueryFE", DatahyperOpenapi.QueryFE)
rr.OPTIONS("/QueryFE", HandleOptions)
rr.POST("/QueryFEByID", DatahyperOpenapi.QueryFEByID)
rr.OPTIONS("/QueryFEByID", HandleOptions)
}
rr.POST("/Query", DatahyperOpenapi.Query)
rr.OPTIONS("/Query", HandleOptions)
rr.POST("/QueryByID", DatahyperOpenapi.QueryByID)
//rr.OPTIONS("/QueryByID", HandleOptions)
rr.POST("/QueryFE", DatahyperOpenapi.QueryFE)
rr.OPTIONS("/QueryFE", HandleOptions)
rr.POST("/QueryFEByID", DatahyperOpenapi.QueryFEByID)
rr.OPTIONS("/QueryFEByID", HandleOptions)
}

@ -6,15 +6,22 @@ import (
"dsDataex/Utils/MariaDbUtil"
"encoding/json"
"fmt"
"github.com/xormplus/xorm"
"strconv"
)
// 基础数据库
var baseDb = DbUtil.Engine
// Maria数据库
var mariaDb = MariaDbUtil.Engine
var mariaYPTDb = MariaDbUtil.EngineYPT
var mariaXPTDb = MariaDbUtil.EngineXPT
func GetQuerySQL(queryID string) (bool, string, string, error) {
sql := "SELECT * FROM t_report_sqlquery WHERE query_code='" + queryID + "'"
func GetQuerySQL(platform string, queryID string) (bool, string, string, error) {
var platforms map[string]int
platforms = map[string]int{"ypt": 3, "xpt": 4}
queryType := platforms[platform]
sql := "SELECT * FROM t_report_sqlquery_old WHERE query_type='" + strconv.Itoa(queryType) + "' AND query_code='" + queryID + "'"
var sqlQuery models.TReportSqlquery
has, _ := baseDb.SQL(sql).Get(&sqlQuery)
@ -30,32 +37,62 @@ func GetQuerySQL(queryID string) (bool, string, string, error) {
}
}
func GetRow(sql string, dataID string) (bool, string, map[string]interface{}, error) {
func SelectDB(db string) *xorm.Engine {
var engin *xorm.Engine
switch db {
case "ypt":
engin = mariaYPTDb
break
case "xpt":
engin = mariaXPTDb
break
default:
engin = mariaYPTDb
}
return engin
}
func GetRow(db string, sql string, dataID string) (bool, string, map[string]interface{}, error) {
mariaDb := SelectDB(db)
result, err := mariaDb.SQL(sql, dataID).Query().List()
//result = result[4 : len(result) - 2]
if err == nil {
if result != nil {
return true, "数据查询成功", result[0], nil
} else {
return false, "数据查询失败", nil, err
if err == nil {
return false, "数据获取失败,数据不存在", nil, nil
} else {
return false, err.Error(), nil, nil
}
}
}
func GetResults(sql string, limit int, offset int) (bool, string, int, []map[string]interface{}, error) {
func GetResults(db string, sql string, params []interface{}, limit int, offset int) (bool, string, int, []map[string]interface{}, error) {
mariaDb := SelectDB(db)
//条件查询语句
conditionSql := fmt.Sprintf("%s", " limit ? offset ? ")
//分页的语句
pageSql := fmt.Sprintf("%s %s", sql, conditionSql)
//数据条数
count, _ := mariaDb.SQL(sql).Query().Count()
count, err := mariaDb.SQL(sql, params...).Query().Count()
if count > 0 {
params = append(params, limit)
params = append(params, offset)
//分页数据
list, err := mariaDb.SQL(pageSql, limit, offset).Query().List()
list, err := mariaDb.SQL(pageSql, params...).Query().List()
if err == nil {
return true, "数据获取成功", count, list, nil
} else {
return false, "数据获取失败,数据不存在", count, nil, nil
}
} else {
return false, "数据获取失败,数据不存在", count, nil, nil
if err == nil {
return false, "数据获取失败,数据不存在", count, nil, nil
} else {
return false, err.Error(), count, nil, nil
}
}
}

@ -3,11 +3,15 @@ package DatahyperOpenapi
import (
"dsDataex/MyHyper/DataHyper/DatahyperService"
"dsDataex/MyHyper/MySwagger"
"dsDataex/Utils/CommonUtil"
"github.com/gin-gonic/gin"
"net/http"
"strings"
)
// 接入系统
var platforms = []string{"xpt", "ypt"}
// @Summary 超融合数据查询(后台)
// @Description 【超融合服务】超融合数据查询接口,使用自定义的查询,返回查询结果数据。
// @Tags hyper
@ -16,9 +20,10 @@ import (
// @Param input body MySwagger.DatahyperQuery true "查询参数"
// @Success 200 {object} MySwagger.DatahyperGetResult
// @Failure 400 {object} MySwagger.DatahyperGetResult
// @Router /dataex/hyper/Query [post]
// @Router /dataex/hyper_ypt/Query [post]
func Query(c *gin.Context) {
var input MySwagger.DatahyperQuery
platform := c.Param("platform")
if err := c.ShouldBindJSON(&input); err != nil {
c.JSON(http.StatusOK, MySwagger.DatahyperGetResult{Success: false, Message: "查询数据JSON格式错误"})
@ -52,8 +57,13 @@ func Query(c *gin.Context) {
// //return
//}
// 接入系统URL后缀校验
if ! CommonUtil.StringArrayContain(platforms, platform) {
c.JSON(http.StatusOK, MySwagger.DatahyperGetResult{Success: false, Message: "接入系统请求URL后缀错误"})
return
}
res, msg, count, data, _ := DatahyperService.GetResults(input)
res, msg, count, data, _ := DatahyperService.GetResults(platform, input)
if res {
c.JSON(http.StatusOK, MySwagger.DatahyperGetResult{
Success: true,
@ -78,9 +88,10 @@ func Query(c *gin.Context) {
// @Param input body MySwagger.DatahyperQueryByID true "查询参数"
// @Success 200 {object} MySwagger.DatahyperGet
// @Failure 400 {object} MySwagger.DatahyperGet
// @Router /dataex/hyper/QueryByID [post]
// @Router /dataex/hyper_ypt/QueryByID [post]
func QueryByID(c *gin.Context) {
var input MySwagger.DatahyperQueryByID
platform := c.Param("platform")
if err := c.ShouldBindJSON(&input); err != nil {
c.JSON(http.StatusOK, MySwagger.DatahyperGetResult{Success: false, Message: "查询数据JSON格式错误"})
@ -114,7 +125,13 @@ func QueryByID(c *gin.Context) {
// //return
//}
res, msg, data, _ := DatahyperService.GetRow(input)
// 接入系统URL后缀校验
if ! CommonUtil.StringArrayContain(platforms, platform) {
c.JSON(http.StatusOK, MySwagger.DatahyperGetResult{Success: false, Message: "接入系统请求URL后缀错误"})
return
}
res, msg, data, _ := DatahyperService.GetRow(platform, input)
if res {
c.JSON(http.StatusOK, MySwagger.DatahyperGet{
Success: true,
@ -137,9 +154,10 @@ func QueryByID(c *gin.Context) {
// @Param input body MySwagger.DatahyperQueryFE true "查询参数"
// @Success 200 {object} MySwagger.DatahyperGetResult
// @Failure 400 {object} MySwagger.DatahyperGetResult
// @Router /dataex/hyper/QueryFE [post]
// @Router /dataex/hyper_ypt/QueryFE [post]
func QueryFE(c *gin.Context) {
var input MySwagger.DatahyperQueryFE
platform := c.Param("platform")
if err := c.ShouldBindJSON(&input); err != nil {
c.JSON(http.StatusOK, MySwagger.DatahyperGetResult{Success: false, Message: "查询数据JSON格式错误"})
@ -173,8 +191,13 @@ func QueryFE(c *gin.Context) {
// //return
//}
// 接入系统URL后缀校验
if ! CommonUtil.StringArrayContain(platforms, platform) {
c.JSON(http.StatusOK, MySwagger.DatahyperGetResult{Success: false, Message: "接入系统请求URL后缀错误"})
return
}
res, msg, count, data, _ := DatahyperService.GetResultsFE(input)
res, msg, count, data, _ := DatahyperService.GetResultsFE(platform, input)
if res {
c.JSON(http.StatusOK, MySwagger.DatahyperGetResult{
Success: true,
@ -199,9 +222,10 @@ func QueryFE(c *gin.Context) {
// @Param input body MySwagger.DatahyperQueryFEByID true "查询参数"
// @Success 200 {object} MySwagger.DatahyperGet
// @Failure 400 {object} MySwagger.DatahyperGet
// @Router /dataex/hyper/QueryFEByID [post]
// @Router /dataex/hyper_ypt/QueryFEByID [post]
func QueryFEByID(c *gin.Context) {
var input MySwagger.DatahyperQueryFEByID
platform := c.Param("platform")
if err := c.ShouldBindJSON(&input); err != nil {
c.JSON(http.StatusOK, MySwagger.DatahyperGetResult{Success: false, Message: "查询数据JSON格式错误"})
@ -235,7 +259,12 @@ func QueryFEByID(c *gin.Context) {
// //return
//}
res, msg, data, _ := DatahyperService.GetRowFE(input)
// 接入系统URL后缀校验
if ! CommonUtil.StringArrayContain(platforms, platform) {
c.JSON(http.StatusOK, MySwagger.DatahyperGetResult{Success: false, Message: "接入系统请求URL后缀错误"})
return
}
res, msg, data, _ := DatahyperService.GetRowFE(platform, input)
if res {
c.JSON(http.StatusOK, MySwagger.DatahyperGet{
Success: true,

@ -4,29 +4,67 @@ import (
"dsDataex/MyHyper/DataHyper/DatahyperDAO"
"dsDataex/MyHyper/MySwagger"
"dsDataex/Utils/CommonUtil"
"regexp"
//"strconv"
"strings"
)
func GetResults(raw MySwagger.DatahyperQuery) (bool, string, int, []map[string]interface{}, error) {
func GetResults(platform string, raw MySwagger.DatahyperQuery) (bool, string, int, []map[string]interface{}, error) {
queryID := raw.QueryID
res, msg, sql, _ := DatahyperDAO.GetQuerySQL(queryID)
var params []interface{}
res, msg, sql, _ := DatahyperDAO.GetQuerySQL(platform, queryID)
if res {
if len(raw.QueryCondition) > 0 {
condition := strings.Join(raw.QueryCondition, " AND ")
sql += " WHERE " + condition
//reg := regexp.MustCompile(`(WHERE|where)`)
//if !reg.MatchString(sql) {
// sql += " WHERE "
//}
for no := 0; no < len(raw.QueryCondition); no++ {
params = append(params, raw.QueryCondition[no])
}
if raw.QueryCombination != "" && len(raw.QueryCondition) > 0 {
sql += " AND " + raw.QueryCombination
/*
if len(raw.QueryCondition) > 0 {
if find := strings.Contains(sql, "?"); find {
for _, v := range raw.QueryCondition {
var new string
switch v.(type) {
case int, int32, int64:
new = strconv.Itoa(int(v.(int64)))
break
case float64:
new = strconv.FormatFloat(v.(float64), 'f', -1, 64)
break
default:
new = v.(string)
}
sql = strings.Replace(sql, `?`, `'` + new + `'`, 1 )
}
}
}
if raw.QueryCombination != "" && len(raw.QueryCondition) == 0 {
sql += " WHERE " + raw.QueryCombination
*/
if raw.QueryCombination != "" {
if find := strings.Contains(strings.ToUpper(sql), "WHERE"); find {
sql += " AND " + raw.QueryCombination
} else {
sql += " WHERE " + raw.QueryCombination
}
}
if len(raw.QueryOrder) > 0 {
orderby := strings.Join(raw.QueryOrder, ", ")
sql += " ORDER BY " + orderby
orderBy := strings.Join(raw.QueryOrder, ", ")
reg2 := regexp.MustCompile(`(ORDER|order)`)
prefix := ""
if !reg2.MatchString(sql) {
prefix = " ORDER BY "
} else {
prefix = ", "
}
sql += prefix + orderBy
}
//接收传入参数
@ -35,7 +73,7 @@ func GetResults(raw MySwagger.DatahyperQuery) (bool, string, int, []map[string]i
switch raw.QueryFormat {
case "json":
res1, msg1, count, data, _ := DatahyperDAO.GetResults(sql, limit, offset)
res1, msg1, count, data, _ := DatahyperDAO.GetResults(platform, sql, params, limit, offset)
if res1 {
if len(raw.QueryCols) > 0 {
for k, v := range data {
@ -45,6 +83,7 @@ func GetResults(raw MySwagger.DatahyperQuery) (bool, string, int, []map[string]i
}
}
}
}
return res1, msg1, count, data, nil
} else {
@ -60,13 +99,13 @@ func GetResults(raw MySwagger.DatahyperQuery) (bool, string, int, []map[string]i
}
}
func GetRow(raw MySwagger.DatahyperQueryByID) (bool, string, map[string]interface{}, error) {
func GetRow(platform string, raw MySwagger.DatahyperQueryByID) (bool, string, map[string]interface{}, error) {
queryID := raw.QueryID
res, msg, sql, _ := DatahyperDAO.GetQuerySQL(queryID)
res, msg, sql, _ := DatahyperDAO.GetQuerySQL(platform, queryID)
if res {
switch raw.QueryFormat {
case "json":
res1, msg1, data, _ := DatahyperDAO.GetRow(sql, raw.DataID)
res1, msg1, data, _ := DatahyperDAO.GetRow(platform, sql, raw.DataID)
if res1 {
if len(raw.QueryCols) > 0 {
for kk, _ := range data {
@ -89,21 +128,47 @@ func GetRow(raw MySwagger.DatahyperQueryByID) (bool, string, map[string]interfac
}
}
func GetResultsFE(raw MySwagger.DatahyperQueryFE) (bool, string, int, []map[string]interface{}, error) {
func GetResultsFE(platform string, raw MySwagger.DatahyperQueryFE) (bool, string, int, []map[string]interface{}, error) {
queryID := raw.QueryID
res, msg, sql, _ := DatahyperDAO.GetQuerySQL(queryID)
var params []interface{}
res, msg, sql, _ := DatahyperDAO.GetQuerySQL(platform, queryID)
if res {
//reg := regexp.MustCompile(`(WHERE|where)`)
//if !reg.MatchString(sql) {
// sql += " WHERE " + sql
//}
for no := 0; no < len(raw.QueryCondition); no++ {
params = append(params, raw.QueryCondition[no])
}
/*
if len(raw.QueryCondition) > 0 {
condition := strings.Join(raw.QueryCondition, " AND ")
sql += " WHERE " + condition
if find := strings.Contains(sql, "?"); find {
for _, v := range raw.QueryCondition {
var new string
switch v.(type) {
case int, int32, int64:
new = strconv.Itoa(int(v.(int64)))
case float64:
new = strconv.FormatFloat(v.(float64), 'f', -1, 64)
default:
new = v.(string)
}
sql = strings.Replace(sql, `?`, `'` + new + `'`, 1 )
}
}
//condition := strings.Join(raw.QueryCondition, " AND ")
}
if raw.QueryCombination != "" && len(raw.QueryCondition) > 0 {
sql += " AND " + raw.QueryCombination
}
*/
if raw.QueryCombination != "" && len(raw.QueryCondition) == 0 {
sql += " WHERE " + raw.QueryCombination
if raw.QueryCombination != "" {
if find := strings.Contains(strings.ToUpper(sql), "WHERE"); find {
sql += " AND " + raw.QueryCombination
} else {
sql += " WHERE " + raw.QueryCombination
}
}
if len(raw.QueryOrder) > 0 {
@ -117,7 +182,7 @@ func GetResultsFE(raw MySwagger.DatahyperQueryFE) (bool, string, int, []map[stri
switch raw.QueryFormat {
case "json":
res1, msg1, count, data, _ := DatahyperDAO.GetResults(sql, limit, offset)
res1, msg1, count, data, _ := DatahyperDAO.GetResults(platform, sql, params, limit, offset)
if res1 {
if len(raw.QueryCols) > 0 {
for k, v := range data {
@ -142,13 +207,13 @@ func GetResultsFE(raw MySwagger.DatahyperQueryFE) (bool, string, int, []map[stri
}
}
func GetRowFE(raw MySwagger.DatahyperQueryFEByID) (bool, string, map[string]interface{}, error) {
func GetRowFE(platform string, raw MySwagger.DatahyperQueryFEByID) (bool, string, map[string]interface{}, error) {
queryID := raw.QueryID
res, msg, sql, _ := DatahyperDAO.GetQuerySQL(queryID)
res, msg, sql, _ := DatahyperDAO.GetQuerySQL(platform, queryID)
if res {
switch raw.QueryFormat {
case "json":
res1, msg1, data, _ := DatahyperDAO.GetRow(sql, raw.DataID)
res1, msg1, data, _ := DatahyperDAO.GetRow(platform, sql, raw.DataID)
if res1 {
if len(raw.QueryCols) > 0 {
for kk, _ := range data { //map[string]interface{}

@ -7,7 +7,7 @@ type DatahyperQuery struct {
// 查询ID
QueryID string `json:"query_id" example:"test002"`
// 条件查询
QueryCondition []string `json:"query_conditions" example:"subject_code='22',subject_name='aa'"`
QueryCondition []interface{} `json:"query_conditions" swaggertype:"array,string" example:"22,33"`
// 组合条件查询
QueryCombination string `json:"query_combinations" example:"subject_code='22' AND a='1' AND b='2'"`
// 每页数量

@ -7,7 +7,7 @@ type DatahyperQueryFE struct {
// 查询ID
QueryID string `json:"query_id" example:"test002"`
// 条件查询
QueryCondition []string `json:"query_conditions" example:"subject_code='22',subject_name='aa'"`
QueryCondition []interface{} `json:"query_conditions" swaggertype:"array,string" example:"22,33"`
// 组合条件查询
QueryCombination string `json:"query_combinations" example:"subject_code='22' AND a='1' AND b='2'"`
// 每页数量

@ -15,12 +15,19 @@ var (
MysqlPwd string
MysqlDataBase string
// maria数据库服务器配置
MariaIp string
MariaPort string
MariaUser string
MariaPwd string
MariaDataBase string
// 云平台maria数据库服务器配置
MariaYPTIp string
MariaYPTPort string
MariaYPTUser string
MariaYPTPwd string
MariaYPTDataBase string
// 新平台maria数据库服务器配置
MariaXPTIp string
MariaXPTPort string
MariaXPTUser string
MariaXPTPwd string
MariaXPTDataBase string
// GreenPlum数据库服务器配置
GreenPlumIp string
@ -127,16 +134,27 @@ func init() {
//密码
MysqlPwd = iniParser.GetString("mysql", "pwd")
//maria主机
MariaIp = iniParser.GetString("maria", "ip")
//端口
MariaPort = iniParser.GetString("maria", "port")
//数据库名称
MariaDataBase = iniParser.GetString("maria", "database")
//用户
MariaUser = iniParser.GetString("maria", "user")
//密码
MariaPwd = iniParser.GetString("maria", "pwd")
// 云平台maria主机
MariaYPTIp = iniParser.GetString("maria_ypt", "ip")
// 端口
MariaYPTPort = iniParser.GetString("maria_ypt", "port")
// 数据库名称
MariaYPTDataBase = iniParser.GetString("maria_ypt", "database")
// 用户
MariaYPTUser = iniParser.GetString("maria_ypt", "user")
// 密码
MariaYPTPwd = iniParser.GetString("maria_ypt", "pwd")
// 新平台maria主机
MariaXPTIp = iniParser.GetString("maria_xpt", "ip")
// 端口
MariaXPTPort = iniParser.GetString("maria_xpt", "port")
// 数据库名称
MariaXPTDataBase = iniParser.GetString("maria_xpt", "database")
// 用户
MariaXPTUser = iniParser.GetString("maria_xpt", "user")
// 密码
MariaXPTPwd = iniParser.GetString("maria_xpt", "pwd")
//主机
GreenPlumIp = iniParser.GetString("greenplum", "ip")

@ -12,28 +12,28 @@ import (
"time"
)
var Engine *xorm.Engine
var EngineYPT, EngineXPT *xorm.Engine
func init() {
host := ConfigUtil.MariaIp
port := ConfigUtil.MariaPort
user := ConfigUtil.MariaUser
dbname := ConfigUtil.MariaDataBase
password := ConfigUtil.MariaPwd
host := ConfigUtil.MariaYPTIp
port := ConfigUtil.MariaYPTPort
user := ConfigUtil.MariaYPTUser
dbname := ConfigUtil.MariaYPTDataBase
password := ConfigUtil.MariaYPTPwd
//mysql
master := fmt.Sprintf("%s:%s@%s(%s:%s)/%s?charset=utf8", user, password, "tcp", host, port, dbname)
var err error
Engine, err = xorm.NewEngine("mysql", master)
EngineYPT, err = xorm.NewEngine("mysql", master)
if err != nil {
fmt.Println(err)
}
//设置数据库连接池
Engine.SetMaxOpenConns(100) //设置打开数据库的最大连接数,包含正在使用的连接和连接池的连接。
Engine.SetMaxIdleConns(10) //设置连接池中的保持连接的最大连接数。
Engine.SetConnMaxLifetime(time.Second * 5)
EngineYPT.SetMaxOpenConns(100) //设置打开数据库的最大连接数,包含正在使用的连接和连接池的连接。
EngineYPT.SetMaxIdleConns(10) //设置连接池中的保持连接的最大连接数。
EngineYPT.SetConnMaxLifetime(time.Second * 5)
//调用第一次
err = Engine.Ping()
err = EngineYPT.Ping()
if err != nil {
fmt.Println("Maria Err :", err.Error())
}
@ -55,14 +55,67 @@ func init() {
//设置数据时区
var location *time.Location
location, err = time.LoadLocation("Asia/Shanghai")
Engine.TZLocation = location
EngineYPT.TZLocation = location
//与 struct的映射方式这里采用蛇型方法默认是蛇形
Engine.SetTableMapper(core.SnakeMapper{})
EngineYPT.SetTableMapper(core.SnakeMapper{})
//显示+记录SQL日志
f, _ := os.Create("./Logs/sql.log")
Engine.SetLogger(log.NewSimpleLogger(f))
EngineYPT.SetLogger(log.NewSimpleLogger(f))
Engine.ShowSQL(true) // 则会在控制台打印出生成的SQL语句
Engine.Logger().SetLevel(log.LOG_DEBUG) //则会在控制台打印info及以上的信息
EngineYPT.ShowSQL(true) // 则会在控制台打印出生成的SQL语句
EngineYPT.Logger().SetLevel(log.LOG_DEBUG) //则会在控制台打印info及以上的信息
}
func init() {
host := ConfigUtil.MariaXPTIp
port := ConfigUtil.MariaXPTPort
user := ConfigUtil.MariaXPTUser
dbname := ConfigUtil.MariaXPTDataBase
password := ConfigUtil.MariaXPTPwd
//mysql
master := fmt.Sprintf("%s:%s@%s(%s:%s)/%s?charset=utf8", user, password, "tcp", host, port, dbname)
var err error
EngineXPT, err = xorm.NewEngine("mysql", master)
if err != nil {
fmt.Println(err)
}
//设置数据库连接池
EngineXPT.SetMaxOpenConns(100) //设置打开数据库的最大连接数,包含正在使用的连接和连接池的连接。
EngineXPT.SetMaxIdleConns(10) //设置连接池中的保持连接的最大连接数。
EngineXPT.SetConnMaxLifetime(time.Second * 5)
//调用第一次
err = EngineXPT.Ping()
if err != nil {
fmt.Println("Maria Err :", err.Error())
}
//这段代码是黄海后加上的 2020-04-16
//通过定时ping保持鲜活
go func() {
for{
//https://studygolang.com/articles/12617
time.Sleep(time.Duration(60)*time.Second)
if err != nil {
fmt.Println("\n[xorm] [error] " + CommonUtil.GetCurrentTime() + err.Error())
} else {
fmt.Println("\n[xorm] [info] "+CommonUtil.GetCurrentTime()+" PING DATABASE Maria")
}
}
}()
//设置数据时区
var location *time.Location
location, err = time.LoadLocation("Asia/Shanghai")
EngineXPT.TZLocation = location
//与 struct的映射方式这里采用蛇型方法默认是蛇形
EngineXPT.SetTableMapper(core.SnakeMapper{})
//显示+记录SQL日志
f, _ := os.Create("./Logs/sql.log")
EngineXPT.SetLogger(log.NewSimpleLogger(f))
EngineXPT.ShowSQL(true) // 则会在控制台打印出生成的SQL语句
EngineXPT.Logger().SetLevel(log.LOG_DEBUG) //则会在控制台打印info及以上的信息
}

@ -273,7 +273,7 @@ var doc = `{
}
}
},
"/dataex/hyper/Query": {
"/dataex/hyper_ypt/Query": {
"post": {
"description": "【超融合服务】超融合数据查询接口,使用自定义的查询,返回查询结果数据。",
"consumes": [
@ -313,7 +313,7 @@ var doc = `{
}
}
},
"/dataex/hyper/QueryByID": {
"/dataex/hyper_ypt/QueryByID": {
"post": {
"description": "【超融合服务】超融合数据详情查询接口,使用自定义的查询,返回查询详情数据。",
"consumes": [
@ -353,7 +353,7 @@ var doc = `{
}
}
},
"/dataex/hyper/QueryFE": {
"/dataex/hyper_ypt/QueryFE": {
"post": {
"description": "【超融合服务】超融合数据查询接口,使用自定义的查询,返回查询结果数据。",
"consumes": [
@ -393,7 +393,7 @@ var doc = `{
}
}
},
"/dataex/hyper/QueryFEByID": {
"/dataex/hyper_ypt/QueryFEByID": {
"post": {
"description": "【超融合服务】超融合数据详情查询接口,使用自定义的查询,返回查询详情数据。",
"consumes": [
@ -914,8 +914,8 @@ var doc = `{
"type": "string"
},
"example": [
"subject_code='22'",
"subject_name='aa'"
"22",
"33"
]
},
"query_format": {
@ -1020,8 +1020,8 @@ var doc = `{
"type": "string"
},
"example": [
"subject_code='22'",
"subject_name='aa'"
"22",
"33"
]
},
"query_format": {

@ -258,7 +258,7 @@
}
}
},
"/dataex/hyper/Query": {
"/dataex/hyper_ypt/Query": {
"post": {
"description": "【超融合服务】超融合数据查询接口,使用自定义的查询,返回查询结果数据。",
"consumes": [
@ -298,7 +298,7 @@
}
}
},
"/dataex/hyper/QueryByID": {
"/dataex/hyper_ypt/QueryByID": {
"post": {
"description": "【超融合服务】超融合数据详情查询接口,使用自定义的查询,返回查询详情数据。",
"consumes": [
@ -338,7 +338,7 @@
}
}
},
"/dataex/hyper/QueryFE": {
"/dataex/hyper_ypt/QueryFE": {
"post": {
"description": "【超融合服务】超融合数据查询接口,使用自定义的查询,返回查询结果数据。",
"consumes": [
@ -378,7 +378,7 @@
}
}
},
"/dataex/hyper/QueryFEByID": {
"/dataex/hyper_ypt/QueryFEByID": {
"post": {
"description": "【超融合服务】超融合数据详情查询接口,使用自定义的查询,返回查询详情数据。",
"consumes": [
@ -899,8 +899,8 @@
"type": "string"
},
"example": [
"subject_code='22'",
"subject_name='aa'"
"22",
"33"
]
},
"query_format": {
@ -1005,8 +1005,8 @@
"type": "string"
},
"example": [
"subject_code='22'",
"subject_name='aa'"
"22",
"33"
]
},
"query_format": {

@ -227,8 +227,8 @@ definitions:
query_conditions:
description: 条件查询
example:
- subject_code='22'
- subject_name='aa'
- "22"
- "33"
items:
type: string
type: array
@ -307,8 +307,8 @@ definitions:
query_conditions:
description: 条件查询
example:
- subject_code='22'
- subject_name='aa'
- "22"
- "33"
items:
type: string
type: array
@ -738,7 +738,7 @@ paths:
summary: 接入系统鉴权
tags:
- dataex
/dataex/hyper/Query:
/dataex/hyper_ypt/Query:
post:
consumes:
- application/json
@ -764,7 +764,7 @@ paths:
summary: 超融合数据查询(后台)
tags:
- hyper
/dataex/hyper/QueryByID:
/dataex/hyper_ypt/QueryByID:
post:
consumes:
- application/json
@ -790,7 +790,7 @@ paths:
summary: 超融合数据详情查询(后台)
tags:
- hyper
/dataex/hyper/QueryFE:
/dataex/hyper_ypt/QueryFE:
post:
consumes:
- application/json
@ -816,7 +816,7 @@ paths:
summary: 超融合数据查询(前端)
tags:
- hyper
/dataex/hyper/QueryFEByID:
/dataex/hyper_ypt/QueryFEByID:
post:
consumes:
- application/json

Loading…
Cancel
Save