Sorry, it took me a while to look at this with the holidays and all.
The relevant code is in extensions_pluto_dial.conf
When someone selects the "Call everybody in the house" option in the ivr menu, there is simply a dial command without any conditions that dials any phone in the house. I think this behavior is wrong for the reasons stated in my initial post, however I'm not exactly sure what the best solution is.
In my case, if I replace the Dial statement by:
exten => 0,1,AGI(pluto-gethousemode.agi)
exten => 0,2,Goto(from-pluto-custom,103-hm${HOUSEMODE},1)
Then instead of ringing all phones, it will only ring those configured for the housemode, for the duration entered in the admin (# of seconds to ring before IVR) and then return to the IVR (basically it does the same as it just did before getting to the IVR). For me this behavior is acceptable, but I don't know if it is for everyone. I have a "# of seconds to ring before IVR" set to 25 in my system. My idea is that when someone calls, the phones ring, like normal phones, and if someone is there, they will pickup. The IVR is only supposed to be used if nobody is home.
So before opening a trac ticket to provide this change/patch, we need to understand if this solution is suitable for everyone. For example, does everyone have a "# of seconds to ring before IVR" > 0, or are there people who go immediately to the IVR, and expect callers to be able to choose the option "call everyone in the one" if they want to ring all phones versus calling one particular user?
Another possible solution, which I could try to implement, would be to make the "call everybody in the house" option of the IVR optional. It could be enabled or disabled in the admin. In my case I would disable it, and that would suit me as well.
Please let me know your thoughts.
Jean
PS: can anyone tell me where the code is that generates extensions_pluto_dial.conf based on the config entered in the admin?