@@ 134,8 134,12 @@ class Plan
def notify_approved
@customer.notify(
"Your JMP account has been approved. To complete " \
- "your signup, click/tap here: xmpp:cheogram.com " \
- "and send register jmp.chat to the bot."
+ "your signup, click/tap this link: xmpp:cheogram.com " \
+ "and send register jmp.chat to the bot.",
+ "Your JMP account has been approved. To complete " \
+ "your signup, click/tap this link: " \
+ "xmpp:cheogram.com/CHEOGRAM%25jabber%3Aiq%3Aregister" \
+ "?command;node=jabber%3Aiq%3Aregister"
)
end
end
@@ 150,10 154,14 @@ class Customer
@customer_id
end
- def notify(body)
+ def notify(body, onboarding_body=nil)
jid = REDIS.get("jmp_customer_jid-#{@customer_id}")
raise "No JID for #{customer_id}" unless jid
+ if jid =~ /onboarding.cheogram.com/ && onboarding_body
+ body = onboarding_body
+ end
+
BlatherNotify.say(
CONFIG[:notify_using][:target].call(jid),
CONFIG[:notify_using][:body].call(jid, body)