black list by date

najeh

Member
Joined
Dec 9, 2016
Messages
36
Reaction score
1
hello for all
i want to black a number and remove the number in date for example
i want to put the number in black list and remove it auto after 3 days ow month
thank you for develpment
 

dicko

Still learning but earning
Joined
Oct 30, 2015
Messages
668
Reaction score
248
hello for all
i want to black a number and remove the number in date for example
i want to put the number in black list and remove it auto after 3 days ow month
thank you for develpment

Easiest way is to use now() as the value when bkacklisting, (the key just needs to be there, the value is not used)

You will need modified blacklisting contexts ,
copy them from extensions.conf to extention-override.conf and make your changes there, add a cron job to purge keys where the date value is older than '3 days ow month' ago
 
Last edited:

najeh

Member
Joined
Dec 9, 2016
Messages
36
Reaction score
1
hello thank you for help how to do this give me example? and thank you again
 

dicko

Still learning but earning
Joined
Oct 30, 2015
Messages
668
Reaction score
248
I guess the best way for you to proceed is to read and understand all these contexts

egrep "^\[app-blacklist" extensions_additional.conf

[app-blacklist]
[app-blacklist-check]
[app-blacklist-add]
[app-blacklist-add-invalid]
[app-blacklist-remove]
[app-blacklist-remove-invalid]
[app-blacklist-last]


When you understand them yoy can copy them to the override file and add you requirements , as you can see, it will not be trivial so there aren't any 30 second "examples" available.
 

Members online

PIAF 5 - Powered by 3CX

Forum statistics

Threads
22,460
Messages
138,091
Members
14,621
Latest member
Mac-Gayver