Commit 55f203ee96d71ba38c8cb3eecbe4a4eff4f3c668

Authored by Adhidarma Hadiwinoto
1 parent e40d51df36
Exists in master

kelas kwh

Showing 1 changed file with 3 additions and 2 deletions Side-by-side Diff

partner-simplepay.js
... ... @@ -377,12 +377,13 @@ function _createSnFromReverseReport(qs) {
377 377 const info = _parseInfoFromReverseReport(qs.info);
378 378 if (info) {
379 379 const cust_name = (typeof info.cust_name === 'string') ? info.cust_name.replace(/\W+/g, '-').replace(/^\W+/, '').replace(/\W+$/, '') : '-';
380   - const kelas = (typeof info.kelas === 'string') ? info.kelas.replace(/\W+/g, '-').replace(/^\W+/, '').replace(/\W+$/, '') : '-';
381   - const kwh = (typeof info.size === 'string') ? info.size.replace(/\W+/g, '-').replace(/^\W+/, '').replace(/\W+$/, '') : '-';
  380 + const kelas = (typeof info.kelas === 'string') ? info.kelas.trim() : '-';
  381 + const kwh = (typeof info.size === 'string') ? info.size.trim() : '-';
382 382  
383 383 sn = [
384 384 token || '-',
385 385 cust_name || '-',
  386 + kelas || '-',
386 387 kwh || '-'
387 388 ].join('/');
388 389 }