sqlui 0.1.31 → 0.1.33
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.version +1 -1
- data/app/server.rb +7 -8
- data/app/views/databases.erb +1 -0
- data/client/resources/sqlui.html +57 -56
- metadata +6 -7
- data/client/resources/sqlui.js +0 -24790
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 74792a6ec30f33bb2de8ec064d02b2e7585b7f300071ae92732e5ef03ed0083b
|
4
|
+
data.tar.gz: a316da2c77c494cd337fa65f787722832f2c78519adb80852738083da21e135f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9bff01605958029544e846ca715ba14c4e39ef7bc160768aeb050bc14d8e6e53056051fd71803eedb50a1a6bea02517ca05db257420cb0d4618d9bc166b6a1a9
|
7
|
+
data.tar.gz: 134375ee94808e679eb3da47f0e5a3e7ad8ae122078d1c31f95b608936cc265d3a55a2458d6bf9edbf69c63f1cafe84a8f20ad39ddb02d83df94662b9d9f3181
|
data/.version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.33
|
data/app/server.rb
CHANGED
@@ -40,14 +40,14 @@ class Server < Sinatra::Base
|
|
40
40
|
get "#{database.url_path}/sqlui.css" do
|
41
41
|
@css ||= File.read(File.join(resources_dir, 'sqlui.css'))
|
42
42
|
status 200
|
43
|
-
headers 'Content-Type' => 'text/css'
|
43
|
+
headers 'Content-Type' => 'text/css; charset=utf-8'
|
44
44
|
body @css
|
45
45
|
end
|
46
46
|
|
47
47
|
get "#{database.url_path}/sqlui.js" do
|
48
48
|
@js ||= File.read(File.join(resources_dir, 'sqlui.js'))
|
49
49
|
status 200
|
50
|
-
headers 'Content-Type' => 'text/javascript'
|
50
|
+
headers 'Content-Type' => 'text/javascript; charset=utf-8'
|
51
51
|
body @js
|
52
52
|
end
|
53
53
|
|
@@ -76,7 +76,7 @@ class Server < Sinatra::Base
|
|
76
76
|
}
|
77
77
|
end
|
78
78
|
status 200
|
79
|
-
headers 'Content-Type' => 'application/json'
|
79
|
+
headers 'Content-Type' => 'application/json; charset=utf-8'
|
80
80
|
body metadata.to_json
|
81
81
|
end
|
82
82
|
|
@@ -117,23 +117,22 @@ class Server < Sinatra::Base
|
|
117
117
|
result[:query] = full_sql
|
118
118
|
|
119
119
|
status 200
|
120
|
-
headers 'Content-Type' => 'application/json'
|
120
|
+
headers 'Content-Type' => 'application/json; charset=utf-8'
|
121
121
|
body result.to_json
|
122
122
|
end
|
123
123
|
|
124
124
|
get(%r{#{Regexp.escape(database.url_path)}/(query|graph|structure|saved)}) do
|
125
125
|
@html ||= File.read(File.join(resources_dir, 'sqlui.html'))
|
126
126
|
status 200
|
127
|
-
headers 'Content-Type' => 'text/html'
|
127
|
+
headers 'Content-Type' => 'text/html; charset=utf-8'
|
128
128
|
body @html
|
129
129
|
end
|
130
130
|
end
|
131
131
|
|
132
132
|
error do |e|
|
133
133
|
status 500
|
134
|
-
headers 'Content-Type' => 'application/json'
|
134
|
+
headers 'Content-Type' => 'application/json; charset=utf-8'
|
135
135
|
message = e.message.lines.first&.strip || 'unexpected error'
|
136
|
-
message = "#{message[0..80]}…" if message.length > 80
|
137
136
|
result = {
|
138
137
|
error: message,
|
139
138
|
stacktrace: e.backtrace.map { |b| b }.join("\n")
|
@@ -148,7 +147,7 @@ class Server < Sinatra::Base
|
|
148
147
|
|
149
148
|
def client_error(message, stacktrace: nil)
|
150
149
|
status(400)
|
151
|
-
headers 'Content-Type' => 'application/json'
|
150
|
+
headers 'Content-Type' => 'application/json; charset=utf-8'
|
152
151
|
body({ error: message, stacktrace: stacktrace }.compact.to_json)
|
153
152
|
end
|
154
153
|
|
data/app/views/databases.erb
CHANGED
data/client/resources/sqlui.html
CHANGED
@@ -1,70 +1,71 @@
|
|
1
|
-
<
|
1
|
+
<html lang="en">
|
2
|
+
<head>
|
3
|
+
<meta charset="utf-8">
|
4
|
+
<title>SQLUI</title>
|
5
|
+
<script src="sqlui.js"></script>
|
6
|
+
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
|
7
|
+
<link rel="stylesheet" href="sqlui.css">
|
8
|
+
</head>
|
2
9
|
|
3
|
-
<
|
4
|
-
|
5
|
-
<script src="sqlui.js"></script>
|
6
|
-
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
|
7
|
-
<link rel="stylesheet" href="sqlui.css">
|
8
|
-
</head>
|
9
|
-
|
10
|
-
<body>
|
11
|
-
<div id="loading-box" class="loading-box">
|
12
|
-
</div>
|
13
|
-
|
14
|
-
<div id="main-box" class="main-box" style="display:none">
|
15
|
-
<div class="tabs-box">
|
16
|
-
<h1 class="header"><a id="header-link">SQLUI</a></h1>
|
17
|
-
<h1 id="server-name" class="server-name"></h1>
|
18
|
-
<a id="query-tab-button" class="tab-button">Query</a>
|
19
|
-
<a id="graph-tab-button" class="tab-button">Graph</a>
|
20
|
-
<a id="saved-tab-button" class="tab-button">Saved</a>
|
21
|
-
<a id="structure-tab-button" class="tab-button">Structure</a>
|
10
|
+
<body>
|
11
|
+
<div id="loading-box" class="loading-box">
|
22
12
|
</div>
|
23
13
|
|
24
|
-
<div id="
|
25
|
-
<div
|
26
|
-
|
14
|
+
<div id="main-box" class="main-box" style="display:none">
|
15
|
+
<div class="tabs-box">
|
16
|
+
<h1 class="header"><a id="header-link">SQLUI</a></h1>
|
17
|
+
<h1 id="server-name" class="server-name"></h1>
|
18
|
+
<a id="query-tab-button" class="tab-button">Query</a>
|
19
|
+
<a id="graph-tab-button" class="tab-button">Graph</a>
|
20
|
+
<a id="saved-tab-button" class="tab-button">Saved</a>
|
21
|
+
<a id="structure-tab-button" class="tab-button">Structure</a>
|
22
|
+
</div>
|
27
23
|
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
<input id="submit-current-button" class="submit-button" type="button" value="run selection (ctrl-enter)"></input>
|
32
|
-
<input id="submit-all-button" class="submit-button" type="button" value="run (ctrl-shift-enter)"></input>
|
33
|
-
</div>
|
24
|
+
<div id="query-box" class="query-box tab-content-element graph-element query-element" style="display: none;">
|
25
|
+
<div id="query" class="query"></div>
|
26
|
+
</div>
|
34
27
|
|
35
|
-
|
36
|
-
|
28
|
+
<div id="submit-box" class="submit-box tab-content-element graph-element query-element" style="display: none;">
|
29
|
+
<input id="cancel-button" class="submit-button" type="button" value="cancel"></input>
|
30
|
+
<div class="submit-fill"></div>
|
31
|
+
<input id="submit-current-button" class="submit-button" type="button" value="run selection (ctrl-enter)"></input>
|
32
|
+
<input id="submit-all-button" class="submit-button" type="button" value="run (ctrl-shift-enter)"></input>
|
33
|
+
</div>
|
37
34
|
|
38
|
-
|
39
|
-
|
35
|
+
<div id="result-box" class="result-box tab-content-element query-element" style="display: none;">
|
36
|
+
</div>
|
40
37
|
|
41
|
-
|
42
|
-
|
43
|
-
<p id="result-time" class="result-time"></p>
|
44
|
-
</div>
|
38
|
+
<div id="graph-box" class="graph-box tab-content-element graph-element" style="display: none;">
|
39
|
+
</div>
|
45
40
|
|
46
|
-
|
47
|
-
|
41
|
+
<div id="fetch-sql-box" class="fetch-sql-box tab-content-element graph-element query-element" style="display: none;">
|
42
|
+
<div id="result-loader" class="loader"></div>
|
43
|
+
<p id="result-time" class="result-time"></p>
|
44
|
+
</div>
|
48
45
|
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
<
|
54
|
-
|
55
|
-
|
56
|
-
<
|
57
|
-
</
|
58
|
-
<div id="
|
46
|
+
<div id="saved-box" class="saved-box tab-content-element saved-element" style="display: none;">
|
47
|
+
</div>
|
48
|
+
|
49
|
+
<div id="structure-box" class="structure-box tab-content-element structure-element" style="display: none;">
|
50
|
+
<div style="display: flex; flex: 1; flex-direction: row; align-items: stretch;">
|
51
|
+
<select id="schemas" class="schemas" size="4">
|
52
|
+
</select>
|
53
|
+
<select id="tables" class="tables" size="4">
|
54
|
+
</select>
|
55
|
+
<div id="table-info" class="table-info">
|
56
|
+
<div id="columns" class="columns">
|
57
|
+
</div>
|
58
|
+
<div id="indexes" class="indexes">
|
59
|
+
</div>
|
59
60
|
</div>
|
60
61
|
</div>
|
61
62
|
</div>
|
62
|
-
</div>
|
63
63
|
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
64
|
+
<div id="status-box" class="status-box">
|
65
|
+
<div id="result-status" class="status tab-content-element query-element"></div>
|
66
|
+
<div id="graph-status" class="status tab-content-element graph-element"></div>
|
67
|
+
<div id="saved-status" class="status tab-content-element saved-element"></div>
|
68
|
+
</div>
|
68
69
|
</div>
|
69
|
-
</
|
70
|
-
</
|
70
|
+
</body>
|
71
|
+
</html>
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sqlui
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.33
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nick Dower
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-11-
|
11
|
+
date: 2022-11-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: mysql2
|
@@ -143,13 +143,12 @@ files:
|
|
143
143
|
- bin/sqlui
|
144
144
|
- client/resources/sqlui.css
|
145
145
|
- client/resources/sqlui.html
|
146
|
-
- client/resources/sqlui.js
|
147
146
|
homepage: https://github.com/nicholasdower/sqlui
|
148
147
|
licenses:
|
149
148
|
- MIT
|
150
149
|
metadata:
|
151
150
|
rubygems_mfa_required: 'true'
|
152
|
-
post_install_message:
|
151
|
+
post_install_message:
|
153
152
|
rdoc_options: []
|
154
153
|
require_paths:
|
155
154
|
- lib
|
@@ -164,8 +163,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
164
163
|
- !ruby/object:Gem::Version
|
165
164
|
version: '0'
|
166
165
|
requirements: []
|
167
|
-
rubygems_version: 3.2.
|
168
|
-
signing_key:
|
166
|
+
rubygems_version: 3.2.33
|
167
|
+
signing_key:
|
169
168
|
specification_version: 4
|
170
169
|
summary: A SQL UI.
|
171
170
|
test_files: []
|