小编use*_*588的帖子

如何让时间以24小时时间格式显示?

如何让时间以24小时时间格式显示?目前,我的时间以 12 小时格式显示。如何解决这个问题,同时又不会极大地改变我的安装格式?

date:'d/MM/yyyy h:mm'
Run Code Online (Sandbox Code Playgroud)

angular

6
推荐指数
1
解决办法
2万
查看次数

How to download images from the database?

I need to upload files and images no larger than 2 megabytes in the database. But there is a problem downloading images. All images that are downloaded break and do not open. No such problems with text files.

Result of the downloaded image:

file 2.png

2.png: data
Run Code Online (Sandbox Code Playgroud)

Uploading images this way:

module.exports.upload = async function (req, res) {
  const sysFileObj = {
    COMMENTS: req.body.COMMENTS,
    NAME: req.file.originalname,
    MIMETYPE: req.file.mimetype,
    FILE_CONTENT: req.file.buffer
  };
  try {
    await SysFiles.create(sysFileObj);
    res.status(201).json(sysFileObj);
  } catch (e) { …
Run Code Online (Sandbox Code Playgroud)

node.js express multer

5
推荐指数
1
解决办法
331
查看次数

标签 统计

angular ×1

express ×1

multer ×1

node.js ×1