1
0
mirror of https://github.com/lxsang/antd-web-apps synced 2025-04-19 01:56:44 +02:00

fix system controller

This commit is contained in:
Xuan Sang LE 2020-06-05 19:55:49 +02:00
parent cecbb230d1
commit 41e32d2730
3 changed files with 12 additions and 12 deletions

View File

@ -1,4 +1,4 @@
// Generated by CoffeeScript 2.4.1 // Generated by CoffeeScript 2.5.1
(function() { (function() {
var APIManager, BaseObject, MarkOn, WebVNC, require; var APIManager, BaseObject, MarkOn, WebVNC, require;
@ -21,14 +21,14 @@
/* /*
window.require = (lib) -> window.require = (lib) ->
return new Promise (r, e) -> return new Promise (r, e) ->
return r() if window.libraries[lib] return r() if window.libraries[lib]
$.getScript window.myuri + lib $.getScript window.myuri + lib
.done (d) -> .done (d) ->
window.libraries[lib] = true window.libraries[lib] = true
r() r()
.fail (m, s) -> .fail (m, s) ->
e(m, s) */ e(m, s) */
// private function // private function
require = function(lib) { require = function(lib) {
return new Promise(function(r, e) { return new Promise(function(r, e) {

View File

@ -101,8 +101,8 @@ function SystemController:apigateway(...)
-- override the global echo command -- override the global echo command
echo = std.ws.swrite echo = std.ws.swrite
use_ws = true use_ws = true
else --else
std.json() -- std.json()
end end
local exec_with_user_priv = function(data) local exec_with_user_priv = function(data)
local uid = ulib.uid(SESSION.user) local uid = ulib.uid(SESSION.user)

View File

@ -61,7 +61,7 @@ end
vfs.mkdir = function(path) vfs.mkdir = function(path)
local file = std.basename(path) local file = std.basename(path)
local folder = string.gsub(path, utils.escape_pattern(file),"") local folder = string.gsub(path, utils.escape_pattern(file).."$","")
local r,m = vfs.checkperm(folder,"write") local r,m = vfs.checkperm(folder,"write")
if r then if r then