updated delivery-note dms path
gitea/salix/master This commit looks good
Details
gitea/salix/master This commit looks good
Details
This commit is contained in:
parent
2ca78d5916
commit
e94dbfe189
|
@ -24,5 +24,8 @@
|
|||
"rejectUnauthorized": false
|
||||
},
|
||||
"pool": true
|
||||
},
|
||||
"storage": {
|
||||
"root": "./e2e/dms"
|
||||
}
|
||||
}
|
|
@ -1,6 +1,8 @@
|
|||
const strftime = require('strftime');
|
||||
const database = require(`${appPath}/lib/database`);
|
||||
const config = require(`${appPath}/lib/config.js`);
|
||||
const UserException = require(`${appPath}/lib/exceptions/userException`);
|
||||
const md5 = require('md5');
|
||||
|
||||
module.exports = {
|
||||
name: 'rpt-delivery-note',
|
||||
|
@ -30,7 +32,9 @@ module.exports = {
|
|||
},
|
||||
computed: {
|
||||
dmsPath() {
|
||||
const hostPath = 'http://windows.verdnatura.es/signatures/tickets';
|
||||
const pathHash = md5(this.signature.id.toString()).substring(0, 3);
|
||||
const hostPath = `file:///${config.storage.root}/${pathHash}`;
|
||||
|
||||
if (this.signature && this.signature.id)
|
||||
return `${hostPath}/${this.signature.id}.png`;
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue