add handler for setting and resetting single edits
This commit is contained in:
parent
c565a9dde5
commit
0eb1115e39
@ -124,6 +124,24 @@ func (h *Handlers) SavePin(ctx context.Context, sym string, input []byte) (resou
|
|||||||
return res, nil
|
return res, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (h *Handlers) SetResetSingleEdit(ctx context.Context, sym string, input []byte) (resource.Result, error) {
|
||||||
|
res := resource.Result{}
|
||||||
|
menuOPtion := string(input)
|
||||||
|
|
||||||
|
switch menuOPtion {
|
||||||
|
case "2":
|
||||||
|
res.FlagSet = append(res.FlagSet, models.USERFLAG_SINGLE_EDIT)
|
||||||
|
case "3":
|
||||||
|
res.FlagSet = append(res.FlagSet, models.USERFLAG_SINGLE_EDIT)
|
||||||
|
case "4":
|
||||||
|
res.FlagSet = append(res.FlagSet, models.USERFLAG_SINGLE_EDIT)
|
||||||
|
default:
|
||||||
|
res.FlagReset = append(res.FlagReset, models.USERFLAG_SINGLE_EDIT)
|
||||||
|
}
|
||||||
|
|
||||||
|
return res, nil
|
||||||
|
}
|
||||||
|
|
||||||
func (h *Handlers) VerifyPin(ctx context.Context, sym string, input []byte) (resource.Result, error) {
|
func (h *Handlers) VerifyPin(ctx context.Context, sym string, input []byte) (resource.Result, error) {
|
||||||
res := resource.Result{}
|
res := resource.Result{}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user