|
@@ -633,14 +633,14 @@ module.exports = app => {
|
|
|
}
|
|
|
const fileInfo = path.parse(stream.filename);
|
|
|
// const filepath = path.join('public/upload', this.ctx.tender.id.toString(), 'tc', 'fujian_' + create_time + fileInfo.ext);
|
|
|
- const filepath = `public/upload/${this.ctx.tender.id.toString()}/tc/fujian_${create_time + idx + fileInfo.ext}`;
|
|
|
+ const filepath = `public/upload/${this.ctx.tender.id.toString()}/tc/fujian_${create_time + idx.toString() + fileInfo.ext}`;
|
|
|
await ctx.helper.saveStreamFile(stream, path.join(this.app.baseDir, 'app', filepath));
|
|
|
|
|
|
if (stream) {
|
|
|
await sendToWormhole(stream);
|
|
|
}
|
|
|
files.push({ filepath, name: stream.filename });
|
|
|
- idx++;
|
|
|
+ ++idx;
|
|
|
}
|
|
|
const upload_time = this.ctx.helper.dateTran(new Date());
|
|
|
const payload = files.map(file => {
|