Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
E
evm-store
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wanli
evm-store
Commits
3fea3144
Commit
3fea3144
authored
Jun 22, 2021
by
wanliofficial
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
dadb89fb
Changes
10
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
144 additions
and
333 deletions
+144
-333
.gitignore
.gitignore
+2
-0
backend/backupData.json
backend/backupData.json
+1
-1
backend/config.ini
backend/config.ini
+1
-1
backend/controller/__init__.py
backend/controller/__init__.py
+1
-0
backend/controller/api_manager.py
backend/controller/api_manager.py
+29
-5
backend/opqcp
backend/opqcp
+0
-0
backend/utils/epk.py
backend/utils/epk.py
+0
-5
backend/view/api.py
backend/view/api.py
+2
-2
opqcp/opqcp
opqcp/opqcp
+0
-0
opqcp/out/new.c
opqcp/out/new.c
+108
-319
No files found.
.gitignore
View file @
3fea3144
...
...
@@ -37,6 +37,8 @@ logs/*.log.*
frontend/node_modules
frontend/dist
backend/*.c
backend/out
backend/logs/*.log
backend/logs/*.log.*
backend/nohup.out
...
...
backend/backupData.json
View file @
3fea3144
{
"lastModifyDateTime"
:
1622539747
}
\ No newline at end of file
{
"lastModifyDateTime"
:
1624346271
}
\ No newline at end of file
backend/config.ini
View file @
3fea3144
...
...
@@ -21,4 +21,4 @@ backup_dir = backup
evueapps_dir
=
evueapps
launcher_dir
=
launcher
host
=
127.0.0.1
port
=
5001
\ No newline at end of file
port
=
5000
\ No newline at end of file
backend/controller/__init__.py
View file @
3fea3144
...
...
@@ -24,6 +24,7 @@ def initConnect():
signalManager
.
actionApplicationBuild
.
connect
(
appsManager
.
build
)
signalManager
.
actionGetConvertString
.
connect
(
apiManager
.
get_escape_text
)
signalManager
.
actionUpdatePassword
.
connect
(
apiManager
.
update_user_password
)
signalManager
.
actionOpqcp
.
connect
(
apiManager
.
opqcp
)
# 登录模块
signalManager
.
actionLogin
.
connect
(
loginManager
.
login
)
...
...
backend/controller/api_manager.py
View file @
3fea3144
...
...
@@ -15,6 +15,7 @@ import json
import
logging
import
traceback
import
subprocess
import
shutil
import
uuid
from
datetime
import
datetime
...
...
@@ -57,21 +58,44 @@ class ApiManager(object):
return
True
,
"success"
def
get_escape_text
(
self
,
data
):
return
convert_string
(
data
[
'string'
])
fname
=
"./a.c"
with
open
(
"./a.c"
,
"w+"
)
as
f
:
f
.
write
(
data
[
'string'
])
result
=
os
.
system
(
"./opqcp {i} ./out"
.
format
(
i
=
fname
))
print
(
result
)
with
open
(
"./out/a.c"
)
as
f
:
result
=
f
.
read
()
return
result
# return convert_string(data['string'])
def
opqcp
(
self
,
params
):
target_file
=
os
.
path
.
normpath
(
os
.
sep
.
join
([
config
.
get
(
"UPLOAD_PATH"
),
params
.
get
(
"filename"
)]))
print
(
"--------->"
,
params
,
target_file
)
print
(
os
.
stat
(
target_file
))
shutil
.
copy
(
target_file
,
os
.
getcwd
())
# dtNowString = datetime.now().strftime("%Y%m%d%H%M%S%f")
# fn, ex = os.path.splitext(params.get("filename"))
output_path
=
os
.
path
.
dirname
(
target_file
)
output_path
=
os
.
sep
.
join
([
os
.
path
.
dirname
(
target_file
),
"out"
])
if
not
os
.
path
.
exists
(
output_path
):
os
.
makedirs
(
output_path
)
print
(
"#######"
,
output_path
)
# print(os.path.dirname(os.getcwd()), os.path.abspath("../opqcp/opqcp"))
result
=
os
.
system
(
"./opqcp {i} ./out"
.
format
(
i
=
os
.
path
.
basename
(
target_file
)))
print
(
result
)
# command = ["./opqcp", target_file, output_path]
command
=
[
"./opqcp"
,
os
.
path
.
basename
(
target_file
),
"./"
]
fname
=
os
.
sep
.
join
([
os
.
getcwd
(),
"out"
,
os
.
path
.
basename
(
target_file
)])
shutil
.
copy
(
fname
,
output_path
)
os
.
remove
(
fname
)
# ret = subprocess.run(command, shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE, encoding="utf-8", timeout=5)
# if ret.returncode == 0:
...
...
@@ -79,8 +103,8 @@ class ApiManager(object):
# else:
# print("error:", ret)
ret
=
target_file
#
ret = target_file
return
True
,
ret
return
True
,
os
.
sep
.
join
([
output_path
.
replace
(
config
.
get
(
"UPLOAD_PATH"
),
""
),
params
.
get
(
"filename"
)])
apiManager
=
ApiManager
()
backend/opqcp
0 → 100755
View file @
3fea3144
File added
backend/utils/epk.py
View file @
3fea3144
...
...
@@ -122,11 +122,6 @@ class EpkApp(object):
files
.
insert
(
0
,
finfo
)
else
:
files
.
append
(
finfo
)
<<<<<<<
HEAD
=======
>>>>>>>
735
d39eb4d0c3134b62bf4fe1b7a2ca0ea8da1ca
if
fext
==
".evue"
:
self
.
fileMD5
(
finfo
)
...
...
backend/view/api.py
View file @
3fea3144
...
...
@@ -35,9 +35,9 @@ def action_opqcp():
print
(
params
)
signalManager
.
actionOpqcp
.
emit
(
params
)
result
,
message
=
signalManager
.
actionOpqcp
.
emit
(
params
)
return
response_result
(
ResponseCode
.
OK
)
return
response_result
(
ResponseCode
.
OK
,
msg
=
message
)
@
api
.
route
(
"/updatePassword"
,
methods
=
[
'POST'
])
@
validate_schema
(
UpdatePasswordSchema
)
...
...
opqcp/opqcp
deleted
100644 → 0
View file @
dadb89fb
File deleted
opqcp/out/new.c
View file @
3fea3144
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment