Example #1
0
File: san.py Project: HudaJr/TAFA
def unreact_submenu():
	banner()
	menu_ = list_menu["unreact"]
	pilih = show_select_menu(menu_)
	show_target = True

	if pilih == 0:
		deleter_menu()
		exit()

	banner()
	print(f"   {C}Pilih:{W} {menu_[pilih - 1]}\n")

	# if pilih == 1:
	# 	func = lambda: fb.like_post_home(ses)
	# 	show_target = False

	if pilih == 1:
		target = input_("Id Orang: ")
		func = lambda: fb.react_post_people(ses, target)

	# elif pilih == 3:
	# 	target = input_("Id Group: ")
	# 	func = lambda: fb.react_post_group(ses, target)

	elif pilih == 2:
		target = input_("Username Fanspage: ")
		func = lambda: fb.react_post_fanspage(ses, target)

	limit = select(1, 350, text = "Limit: ", error_msg = "min: 1, max: 350", que = True)
	confirm_execute()
	data = dump(func, limit, show_target = show_target)
	procces(lambda url: action.status.react(ses, url, type = "unreact"), data)
Example #2
0
File: sandi.py Project: HudaJr/TAFA
def react_menu():
    banner()
    menu_ = list_menu["react"]
    type_react = ["love", "care", "haha", "wow", "sad", "angry"]
    pilih = show_select_menu(menu_)
    show_target = True

    if pilih == 0:
        menu()
        exit()

    banner()
    print(f"   {C}Selected:{W} {menu_[pilih - 1]}\n")

    if pilih == 1:

        func = lambda: fb.react_post_home(ses)
        show_target = False

    elif pilih == 2:
        target = input_("Id People: ")
        func = lambda: fb.react_post_people(ses, target)

    elif pilih == 3:
        target = input_("Id Group: ")
        func = lambda: fb.react_post_group(ses, target)

    elif pilih == 4:
        target = input_("Username Fanspage: ")
        func = lambda: fb.react_post_fanspage(ses, target)

    limit = select(1,
                   350,
                   text="Limit: ",
                   error_msg="min: 1, max: 350",
                   que=True)
    react = show_select_menu(list(map(lambda x: x.capitalize(), type_react)))
    react = type_react[react - 1]
    confirm_execute()
    data = dump(func, limit, show_target=show_target)
    procces(lambda url: action.status.react(ses, url, type=react), data)