• The default language of any content posted is English.
    Do not create multi-accounts, you will be blocked!
Ultimate POS - Best ERP, Stock Management, Point of Sale and Invoicing system

NULLED Ultimate POS - Best ERP, Stock Management, Point of Sale and Invoicing system 6.4 NULLED

Hello, does anyone know how to modify the "date range" of sales, purchases, etc.? I would like to be able to add an option that allows you to select by years or several years with a single click, because the maximum date range option allows up to the previous year and then the option to select a custom range appears, but to be using that option it is too much waste of time.

View attachment 24634

Hi there - I'll try to update my reply with a code that allows you to make the filter "2 years ago", "3 years ago" and "5 years ago" - maybe this is a solution for you, isn't it?

Ferb
 
Reacted by:
  • Like
Reactions: Mrmaho
Hello! Yes, that would help me a lot and I think it would help others too.
So let's do it, here it is for 3 years, change the '3' with any number of years you want (be careful not to overload your server while requesting 7 or more years)

Go to /public/js/common.js, and search for (around line 327):
Code:
ranges[LANG.last_financial_year] = [
    moment(financial_year.start._i).subtract(1, 'year'),
    moment(financial_year.end._i).subtract(1, 'year'),
];

Replace with: (here you can change the 3 with any number of years you want)
Code:
ranges[LANG.last_financial_year] = [
    moment(financial_year.start._i).subtract(3, 'year'),
    moment(financial_year.end._i).subtract(0, 'year'),
];

Now go to /public/js/lang/en.js (for English, do it for your or all languages) and change:
Code:
'last_financial_year': 'Last financial year',

Replace with: (replace the '3' with your desired number of years)
Code:
'last_financial_year': 'Last 3 years',

This will replace the "Last financial year" option, but you have the option of "Last year" which does the same thing

I hope it's useful :)

Ferb
 
Reacted by:
  • Like
Reactions: ghulamrasool, Xurtan and kandichoco
So let's do it, here it is for 3 years, change the '3' with any number of years you want (be careful not to overload your server while requesting 7 or more years)

Go to /public/js/common.js, and search for (around line 327):
Code:
ranges[LANG.last_financial_year] = [
    moment(financial_year.start._i).subtract(1, 'year'),
    moment(financial_year.end._i).subtract(1, 'year'),
];

Replace with: (here you can change the 3 with any number of years you want)
Code:
ranges[LANG.last_financial_year] = [
    moment(financial_year.start._i).subtract(3, 'year'),
    moment(financial_year.end._i).subtract(0, 'year'),
];

Now go to /public/js/lang/en.js (for English, do it for your or all languages) and change:
Code:
'last_financial_year': 'Last financial year',

Replace with: (replace the '3' with your desired number of years)
Code:
'last_financial_year': 'Last 3 years',

This will replace the "Last financial year" option, but you have the option of "Last year" which does the same thing

I hope it's useful :)

Ferb
good man , thts really nice
 
Reacted by:
  • Like
Reactions: phineas
So let's do it, here it is for 3 years, change the '3' with any number of years you want (be careful not to overload your server while requesting 7 or more years)

Go to /public/js/common.js, and search for (around line 327):
Code:
ranges[LANG.last_financial_year] = [
    moment(financial_year.start._i).subtract(1, 'year'),
    moment(financial_year.end._i).subtract(1, 'year'),
];

Replace with: (here you can change the 3 with any number of years you want)
Code:
ranges[LANG.last_financial_year] = [
    moment(financial_year.start._i).subtract(3, 'year'),
    moment(financial_year.end._i).subtract(0, 'year'),
];

Now go to /public/js/lang/en.js (for English, do it for your or all languages) and change:
Code:
'last_financial_year': 'Last financial year',

Replace with: (replace the '3' with your desired number of years)
Code:
'last_financial_year': 'Last 3 years',

This will replace the "Last financial year" option, but you have the option of "Last year" which does the same thing

I hope it's useful :)

Ferb

Excellent, works well, thank you very much!
 
Reacted by:
  • Like
Reactions: Einstine and phineas
Top