-
Notifications
You must be signed in to change notification settings - Fork 1
/
bpe_pass.erl
32 lines (31 loc) · 1.24 KB
/
bpe_pass.erl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
-module(bpe_pass).
-copyright('Maxim Sokhatsky').
-include_lib("form/include/meta.hrl").
-include("bank/phone.hrl").
-export([doc/0,id/0,new/3]).
doc() -> "One-time password PIN control used in banks,".
id() -> #phone{}.
new(Name,_Phone,_) ->
#document { name = form:atom([otp,Name]),
sections = [ #sec { name=[<<"Input the credentials: "/utf8>> ] } ],
buttons = [ #but { id=decline,
name=decline,
title= <<"Cancel"/utf8>>,
class=[cancel],
postback={'Close',[]} },
#but { id=proceed,
name=proceed,
title = <<"Proceed"/utf8>>,
class = [button,sgreen],
sources = [user,otp],
postback = {'Next',form:atom([otp,otp,Name])}}],
fields = [ #field { id=number,
name=number,
type=string,
title= <<"Login:"/utf8>>,
labelClass=label},
#field { id=auth,
name=auth,
type=string,
title= <<"Pass:"/utf8>>,
labelClass=label}]}.