update wizard relation db store procedure parameter(erase _)

This commit is contained in:
2026-01-13 23:25:49 +08:00
parent 720ce95c90
commit 1ce15f3a7c
8 changed files with 88 additions and 28 deletions
+6 -1
View File
@@ -64,7 +64,12 @@ app.post(ormRoutes, async (req, res, next) => {
app.post('/upload/:dbname/:typeid', upload.single('file'), (req, res) => {
if (!req.file) return res.status(400).json({ status: 400, msg: 'No file' });
const fileUrl = `/static/upload/${req.params.dbname}/${req.params.typeid}/${req.file.filename}`;
//const fileUrl = `/static/upload/${req.params.dbname}/${req.params.typeid}/${req.file.filename}`;
// 改為完整的 Server IP
const serverRoot = 'https://api.gex.com.tw:8033/upload';
const fileUrl = `${serverRoot}/${req.params.dbname}/${req.params.typeid}/${req.file.filename}`;
res.json({ status: 0, data: { value: fileUrl, url: fileUrl }, msg: 'success' });
});