/
index.js
714 lines (686 loc) · 22.1 KB
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
//
// 数据库驱动::ASP
// 支持数据库:access,sqlserver,mysql
//
const LANG = antSword['language']['database'];
const LANG_T = antSword['language']['toastr'];
class ASP {
constructor(opt) {
this.opt = opt;
this.core = this.opt.core;
this.manager = this.opt.super;
//
// * 数据库驱动列表
//
this.conns = {
'dsn': 'Dsn=DsnName;',
'mysql': 'Driver={MySQL};Server=localhost;database=mysql;UID=root;PWD=',
'access': 'Driver={Microsoft Access Driver(*.mdb)};DBQ=c:\\test.mdb',
'sqlserver': 'Driver={Sql Server};Server=(local);Database=master;Uid=sa;Pwd=',
'sqloledb_1': 'Provider=SQLOLEDB.1;User ID=sa;Password=;Initial Catalog=master;Data Source=(local);',
'sqloledb_1_sspi': 'Provider=SQLOLEDB.1;Initial Catalog=master;Data Source=(local);Integrated Security=SSPI;',
'oracle': 'Provider=OraOLEDB.Oracle;Data Source=test;User Id=sys;Password=;Persist Security Info=True;',
'microsoft_jet_oledb_4_0': 'Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\\test.mdb'
};
// 1. 初始化TREE UI
this.tree = this.manager.list.layout.attachTree();
// 2. 加载数据库配置
this.parse();
// 3. tree单击::设置当前配置&&激活按钮
this.tree.attachEvent('onClick', (id) => {
// 更改按钮状态
id.startsWith('conn::') ? this.enableToolbar() : this.disableToolbar();
// 设置当前配置
const tmp = id.split('::');
const arr = tmp[1].split(':');
// 设置当前数据库
this.dbconf = antSword['ipcRenderer'].sendSync('shell-getDataConf', {
_id: this.manager.opt['_id'],
id: arr[0]
});
if (arr.length > 1) {
this.dbconf['database'] = Buffer.from(arr[1], 'base64').toString();
// 更新SQL编辑器
this.enableEditor();
// manager.query.update(this.currentConf);
}else{
this.disableEditor();
}
});
// 4. tree双击::加载库/表/字段
this.tree.attachEvent('onDblClick', (id) => {
const arr = id.split('::');
if (arr.length < 2) { throw new Error('ID ERR: ' + id) };
switch(arr[0]) {
// 获取数据库列表
case 'conn':
this.getDatabases(arr[1]);
break;
// 获取数据库表名
case 'database':
let _db = arr[1].split(':');
this.getTables(
_db[0],
Buffer.from(_db[1], 'base64').toString()
);
break;
// 获取表名字段
case 'table':
let _tb = arr[1].split(':');
this.getColumns(
_tb[0],
Buffer.from(_tb[1], 'base64').toString(),
Buffer.from(_tb[2], 'base64').toString()
);
break;
// 生成查询SQL语句
case 'column':
let _co = arr[1].split(':');
const db = Buffer.from(_co[1], 'base64').toString();
const table = Buffer.from(_co[2], 'base64').toString();
const column = Buffer.from(_co[3], 'base64').toString();
let sql = "";
switch(this.dbconf['type']){
case 'mysql':
sql = `SELECT \`${column}\` FROM \`${table}\` ORDER BY 1 DESC LIMIT 0,20;`;
break;
case 'oracle':
sql = `SELECT "${table}"."${column}" FROM ${db}.${table} WHERE ROWNUM < 20 ORDER BY 1`;
break;
default:
sql = `SELECT TOP 20 [${column}] FROM [${table}] ORDER BY 1 DESC;`;
break;
}
this.manager.query.editor.session.setValue(sql);
break;
}
});
// 5. tree右键::功能菜单
this.tree.attachEvent('onRightClick', (id, event) => {
if (!id.startsWith('conn::')) { return };
this.tree.selectItem(id);
this.tree.callEvent('onClick', [id]);
bmenu([
{
text: LANG['list']['menu']['add'],
icon: 'fa fa-plus-circle',
action: this.addConf.bind(this)
}, {
divider: true
}, {
text: LANG['list']['menu']['edit'],
icon: 'fa fa-edit',
action: this.editConf.bind(this)
}, {
divider: true
}, {
text: LANG['list']['menu']['del'],
icon: 'fa fa-remove',
action: this.delConf.bind(this)
}
], event);
});
}
// 加载配置列表
parse() {
// 获取数据
const info = antSword['ipcRenderer'].sendSync('shell-findOne', this.manager.opt['_id']);
const conf = info['database'] || {};
// 刷新UI
// 1.清空数据
this.tree.deleteChildItems(0);
// 2.添加数据
let items = [];
for (let _ in conf) {
items.push({
id: `conn::${_}`,
// text: `${conf[_]['type']}:\/\/${conf[_]['user']}@${conf[_]['host']}`,
text: antSword.noxss(conf[_]['type'].toUpperCase()),
im0: this.manager.list.imgs[0],
im1: this.manager.list.imgs[0],
im2: this.manager.list.imgs[0]
});
}
// 3.刷新UI
this.tree.parse({
id: 0,
item: items
}, 'json');
// 禁用按钮
this.disableToolbar();
this.disableEditor();
}
// 添加配置
addConf() {
const hash = (+new Date * Math.random()).toString(16).substr(2, 8);
// 创建窗口
const win = this.manager.win.createWindow(hash, 0, 0, 450, 300);
win.setText(LANG['form']['title']);
win.centerOnScreen();
win.button('minmax').hide();
win.setModal(true);
win.denyResize();
// 工具栏
const toolbar = win.attachToolbar();
toolbar.loadStruct([{
id: 'add',
type: 'button',
icon: 'plus-circle',
text: LANG['form']['toolbar']['add']
}, {
type: 'separator'
}, {
id: 'clear',
type: 'button',
icon: 'remove',
text: LANG['form']['toolbar']['clear']
}, {
type: 'separator'
}, {
id: 'test',
type: 'button',
icon: 'spinner',
text: LANG['form']['toolbar']['test']
}]);
// form
const form = win.attachForm([
{ type: 'settings', position: 'label-left', labelWidth: 80, inputWidth: 280 },
{ type: 'block', inputWidth: 'auto', offsetTop: 12, list: [
{ type: 'combo', label: LANG['form']['type'], readonly: true, name: 'type', options: (() => {
let ret = [];
for (let _ in this.conns) {
ret.push({
text: _.toUpperCase(),
value: _
});
}
return ret;
})() },
{ type: 'input', label: LANG['form']['conn'], name: 'conn', required: true, value: 'Dsn=DsnName;', rows: 9 }
]}
], true);
form.attachEvent('onChange', (_, id) => {
if (_ !== 'type') { return };
form.setFormData({
conn: this.conns[id]
});
});
// 工具栏点击事件
toolbar.attachEvent('onClick', (id) => {
switch(id) {
case 'clear':
form.clear();
break;
case 'add':
if (!form.validate()) {
// return '填写完整!';
return toastr.warning(LANG['form']['warning'], LANG_T['warning']);
};
// 解析数据
let data = form.getValues();
// 验证是否连接成功(获取数据库列表)
const id = antSword['ipcRenderer'].sendSync('shell-addDataConf', {
_id: this.manager.opt['_id'],
data: data
});
win.close();
toastr.success(LANG['form']['success'], LANG_T['success']);
this.tree.insertNewItem(0,
`conn::${id}`,
// `${data['type']}:\/\/${data['user']}@${data['host']}`,
data['type'].toUpperCase(),
null,
this.manager.list.imgs[0],
this.manager.list.imgs[0],
this.manager.list.imgs[0]
);
break;
case 'test':
if (!form.validate()) {
return toastr.warning(LANG['form']['warning'], LANG_T['warning']);
};
// 解析数据
let _data = form.getValues();
win.progressOn();
this.core.request(
this.core[`database_${_data['type']}`].show_databases({
conn: _data['conn']
})
).then((res) => {
if(res['text'].length > 0){
if(res['text'].indexOf("ERROR://") > -1) {
throw res["text"];
}
toastr.success(LANG['form']['test_success'], LANG_T['success']);
}else{
toastr.warning(LANG['form']['test_warning'], LANG_T['warning']);
}
win.progressOff();
}).catch((err)=>{
win.progressOff();
toastr.error(JSON.stringify(err), LANG_T['error']);
});
break;
}
});
}
// 修改配置
editConf() {
const id = this.tree.getSelected().split('::')[1];
// 获取配置
const conf = antSword['ipcRenderer'].sendSync('shell-getDataConf', {
_id: this.manager.opt['_id'],
id: id
});
const hash = (+new Date * Math.random()).toString(16).substr(2, 8);
// 创建窗口
const win = this.manager.win.createWindow(hash, 0, 0, 450, 300);
win.setText(LANG['form']['title']);
win.centerOnScreen();
win.button('minmax').hide();
win.setModal(true);
win.denyResize();
// 工具栏
const toolbar = win.attachToolbar();
toolbar.loadStruct([{
id: 'edit',
type: 'button',
icon: 'edit',
text: LANG['form']['toolbar']['edit']
}, {
type: 'separator'
}, {
id: 'clear',
type: 'button',
icon: 'remove',
text: LANG['form']['toolbar']['clear']
}, {
type: 'separator'
}, {
id: 'test',
type: 'button',
icon: 'spinner',
text: LANG['form']['toolbar']['test']
}]);
// form
const form = win.attachForm([
{ type: 'settings', position: 'label-left', labelWidth: 80, inputWidth: 280 },
{ type: 'block', inputWidth: 'auto', offsetTop: 12, list: [
{ type: 'combo', label: LANG['form']['type'], readonly: true, name: 'type', options: (() => {
let ret = [];
for (let _ in this.conns) {
ret.push({
text: _.toUpperCase(),
value: _,
selected: conf['type'] === _
});
}
return ret;
})() },
{ type: 'input', label: LANG['form']['conn'], name: 'conn', required: true, value: conf['conn'], rows: 9 }
]}
], true);
form.attachEvent('onChange', (_, id) => {
if (_ !== 'type') { return };
form.setFormData({
conn: this.conns[id]
});
});
// 工具栏点击事件
toolbar.attachEvent('onClick', (id) => {
switch(id) {
case 'clear':
form.clear();
break;
case 'edit':
if (!form.validate()) {
return toastr.warning(LANG['form']['warning'], LANG_T['warning']);
};
// 解析数据
let data = form.getValues();
// 验证是否连接成功(获取数据库列表)
const id = antSword['ipcRenderer'].sendSync('shell-editDataConf', {
_id: this.manager.opt['_id'],
id: this.tree.getSelected().split('::')[1],
data: data
});
win.close();
toastr.success(LANG['form']['success'], LANG_T['success']);
// 刷新 UI
this.parse();
break;
case 'test':
if (!form.validate()) {
return toastr.warning(LANG['form']['warning'], LANG_T['warning']);
};
// 解析数据
let _data = form.getValues();
win.progressOn();
this.core.request(
this.core[`database_${_data['type']}`].show_databases({
conn: _data['conn']
})
).then((res) => {
if(res['text'].length > 0){
if(res['text'].indexOf("ERROR://") > -1) {
throw res["text"];
}
toastr.success(LANG['form']['test_success'], LANG_T['success']);
}else{
toastr.warning(LANG['form']['test_warning'], LANG_T['warning']);
}
win.progressOff();
}).catch((err)=>{
win.progressOff();
toastr.error(JSON.stringify(err), LANG_T['error']);
});
break;
}
});
}
// 删除配置
delConf() {
const id = this.tree.getSelected().split('::')[1];
layer.confirm(LANG['form']['del']['confirm'], {
icon: 2, shift: 6,
title: LANG['form']['del']['title']
}, (_) => {
layer.close(_);
const ret = antSword['ipcRenderer'].sendSync('shell-delDataConf', {
_id: this.manager.opt['_id'],
id: id
});
if (ret === 1) {
toastr.success(LANG['form']['del']['success'], LANG_T['success']);
this.tree.deleteItem(`conn::${id}`);
// 禁用按钮
this.disableToolbar();
this.disableEditor();
// ['edit', 'del'].map(this.toolbar::this.toolbar.disableItem);
// this.parse();
}else{
toastr.error(LANG['form']['del']['error'](ret), LANG_T['error']);
}
});
}
// 获取数据库列表
getDatabases(id) {
this.manager.list.layout.progressOn();
// 获取配置
const conf = antSword['ipcRenderer'].sendSync('shell-getDataConf', {
_id: this.manager.opt['_id'],
id: id
});
this.core.request(
this.core[`database_${conf['type']}`].show_databases(
{
conn: conf['conn'],
dbname: ['access', 'microsoft_jet_oledb_4_0'].indexOf(conf['type']) > -1 ? conf['conn'].match(/[\w]+.mdb$/) : 'database'
})
).then((res) => {
let ret = res['text'];
if(ret.indexOf("ERROR://") > -1) {
throw ret;
}
const arr = ret.split('\t');
if (arr.length === 1 && ret === '') {
toastr.warning(LANG['result']['warning'], LANG_T['warning']);
return this.manager.list.layout.progressOff();
};
// 删除子节点
this.tree.deleteChildItems(`conn::${id}`);
// 添加子节点
arr.map((_) => {
if (!_) { return };
const _db = Buffer.from(_).toString('base64');
this.tree.insertNewItem(
`conn::${id}`,
`database::${id}:${_db}`,
antSword.noxss(_), null,
this.manager.list.imgs[1],
this.manager.list.imgs[1],
this.manager.list.imgs[1]);
});
this.manager.list.layout.progressOff();
}).catch((err) => {
toastr.error(LANG['result']['error']['database'](err['status'] || JSON.stringify(err)), LANG_T['error']);
this.manager.list.layout.progressOff();
});
}
// 获取数据库表数据
getTables(id, db) {
this.manager.list.layout.progressOn();
// 获取配置
const conf = antSword['ipcRenderer'].sendSync('shell-getDataConf', {
_id: this.manager.opt['_id'],
id: id
});
this.core.request(
this.core[`database_${conf['type']}`].show_tables(
{
conn: conf['conn'],
dbname: db
})
).then((res) => {
let ret = res['text'];
if(ret.indexOf("ERROR://") > -1) {
throw ret;
}
const arr = ret.split('\t');
const _db = Buffer.from(db).toString('base64');
// 删除子节点
this.tree.deleteChildItems(`database::${id}:${_db}`);
// 添加子节点
arr.map((_) => {
if (!_) { return };
const _table = Buffer.from(_).toString('base64');
this.tree.insertNewItem(
`database::${id}:${_db}`,
`table::${id}:${_db}:${_table}`,
antSword.noxss(_),
null,
this.manager.list.imgs[2],
this.manager.list.imgs[2],
this.manager.list.imgs[2]
);
});
this.manager.list.layout.progressOff();
}).catch((err) => {
toastr.error(LANG['result']['error']['table'](err['status'] || JSON.stringify(err)), LANG_T['error']);
this.manager.list.layout.progressOff();
});
}
// 获取字段
getColumns(id, db, table) {
this.manager.list.layout.progressOn();
// 获取配置
const conf = antSword['ipcRenderer'].sendSync('shell-getDataConf', {
_id: this.manager.opt['_id'],
id: id
});
let sql = "";
switch(conf['type']){
case "oracle":
// sql = `SELECT * FROM ${db}.${table} WHERE ROWNUM=0`;
sql = `SELECT COLUMN_NAME,DATA_TYPE,DATA_LENGTH FROM ALL_TAB_COLUMNS WHERE OWNER='${db}' AND TABLE_NAME='${table}' ORDER BY COLUMN_ID`;
break;
case 'sqlserver':
case 'sqloledb_1':
case 'sqloledb_1_sspi':
sql = `USE [${this.dbconf['database']}];SELECT TOP 0 * FROM ${table}`;
break;
case 'mysql':
sql = `SELECT * FROM ${table} LIMIT 0,0;`;
break;
default:
sql = `SELECT TOP 1 * FROM ${table} ORDER BY 1 DESC`;
break;
}
this.core.request(
this.core[`database_${conf['type']}`].show_columns(
{
conn: conf['conn'],
table: sql
})
).then((res) => {
let ret = res['text'];
if(ret.indexOf("ERROR://") > -1) {
throw ret;
}
const arr = ret.split('\t');
const _db = Buffer.from(db).toString('base64');
const _table = Buffer.from(table).toString('base64');
// 删除子节点
this.tree.deleteChildItems(`table::${id}:${_db}:${_table}`);
// 添加子节点
arr.map((_) => {
if (!_) { return };
const _column = Buffer.from(_.substr(_, _.lastIndexOf(' '))).toString('base64');
this.tree.insertNewItem(
`table::${id}:${_db}:${_table}`,
`column::${id}:${_db}:${_table}:${_column}`,
antSword.noxss(_), null,
this.manager.list.imgs[3],
this.manager.list.imgs[3],
this.manager.list.imgs[3]
);
});
let presql = "";
switch(this.dbconf['type']){
case 'mysql':
presql = `SELECT * FROM \`${table}\` ORDER BY 1 DESC LIMIT 0,20;`;
break;
case 'oracle':
presql = `SELECT * FROM ${db}.${table} WHERE ROWNUM < 20 ORDER BY 1`;
break;
default:
presql = `SELECT TOP 20 * from [${table}] ORDER BY 1 DESC;`;
break;
}
// 更新编辑器SQL语句
this.manager.query.editor.session.setValue(presql);
this.manager.list.layout.progressOff();
}).catch((err) => {
toastr.error(LANG['result']['error']['column'](err['status'] || JSON.stringify(err)), LANG_T['error']);
this.manager.list.layout.progressOff();
});
}
// 执行SQL
execSQL(sql) {
this.manager.query.layout.progressOn();
this.core.request(
this.core[`database_${this.dbconf['type']}`].query({
conn: this.dbconf['conn'],
sql: sql,
dbname: this.dbconf['database'],
})
).then((res) => {
let ret = res['text'];
if(ret.indexOf("ERROR://") > -1) {
throw ret;
}
// 更新执行结果
this.updateResult(ret);
this.manager.query.layout.progressOff();
}).catch((err) => {
toastr.error(LANG['result']['error']['query'](err['status'] || JSON.stringify(err)), LANG_T['error']);
this.manager.query.layout.progressOff();
});
}
// 更新SQL执行结果
updateResult(data) {
// 1.分割数组
const arr = data.split('\n');
// let arr = [];
// _arr.map((_) => {
// arr.push(antSword.noxss(_));
// });
// console.log(_arr, arr);
// 2.判断数据
if (arr.length < 2) {
return toastr.error(LANG['result']['error']['parse'], LANG_T['error']);
};
// 3.行头
let header_arr = antSword.noxss(arr[0]).split('\t|\t');
if (header_arr.length === 1) {
return toastr.warning(LANG['result']['error']['noresult'], LANG_T['warning']);
};
if (header_arr[header_arr.length - 1] === '\r') {
header_arr.pop();
};
arr.shift();
// 4.数据
let data_arr = [];
arr.map((_) => {
let _data = _.split('\t|\t');
data_arr.push(_data);
});
data_arr.pop();
// 5.初始化表格
const grid = this.manager.result.layout.attachGrid();
grid.clearAll();
grid.setHeader(header_arr.join(',').replace(/,$/, ''));
grid.setColTypes("txt,".repeat(header_arr.length).replace(/,$/,''));
grid.setColSorting(('str,'.repeat(header_arr.length)).replace(/,$/, ''));
grid.setColumnMinWidth(100, header_arr.length-1);
grid.setInitWidths(("100,".repeat(header_arr.length-1)) + "*");
grid.setEditable(true);
grid.init();
// 添加数据
let grid_data = [];
for (let i = 0; i < data_arr.length; i ++) {
grid_data.push({
id: i + 1,
data: data_arr[i]
});
}
grid.parse({
'rows': grid_data
}, 'json');
// 启用导出按钮
this.manager.result.toolbar[grid_data.length > 0 ? 'enableItem' : 'disableItem']('dump');
}
// 导出查询数据
dumpResult() {
const grid = this.manager.result.layout.getAttachedObject();
let filename = `${this.core.__opts__.ip}_${new Date().format("yyyyMMddhhmmss")}.csv`;
antSword['test'] = this;
dialog.showSaveDialog({
title: LANG['result']['dump']['title'],
defaultPath: filename
},(filePath) => {
if (!filePath) { return; };
let headerStr = grid.hdrLabels.join(',');
let dataStr = grid.serializeToCSV();
let tempDataBuffer = Buffer.from(headerStr+'\n'+dataStr);
fs.writeFileSync(filePath, tempDataBuffer);
toastr.success(LANG['result']['dump']['success'], LANG_T['success']);
});
}
// 禁用toolbar按钮
disableToolbar() {
this.manager.list.toolbar.disableItem('del');
this.manager.list.toolbar.disableItem('edit');
this.manager.result.toolbar.disableItem('dump');
}
// 启用toolbar按钮
enableToolbar() {
this.manager.list.toolbar.enableItem('del');
this.manager.list.toolbar.enableItem('edit');
}
// 禁用SQL编辑框
disableEditor() {
['exec', 'clear'].map(
this.manager.query.toolbar.disableItem.bind(this.manager.query.toolbar)
);
this.manager.query.editor.setReadOnly(true);
}
// 启用SQL编辑框
enableEditor() {
['exec', 'clear'].map(
this.manager.query.toolbar.enableItem.bind(this.manager.query.toolbar)
);
this.manager.query.editor.setReadOnly(false);
}
}
module.exports = ASP;