예제 #1
0
파일: locks.py 프로젝트: Redkobra/catus
async def _(event):
    if event.fwd_from:
        return
    res = ""
    current_db_locks = get_locks(event.chat_id)
    if not current_db_locks:
        res = "There are no DataBase locks in this chat"
    else:
        res = "Following are the DataBase locks in this chat: \n"
        res += "👉 `bots`: `{}`\n".format(current_db_locks.bots)
        res += "👉 `commands`: `{}`\n".format(current_db_locks.commands)
        res += "👉 `email`: `{}`\n".format(current_db_locks.email)
        res += "👉 `forward`: `{}`\n".format(current_db_locks.forward)
        res += "👉 `url`: `{}`\n".format(current_db_locks.url)
    current_chat = await event.get_chat()
    try:
        current_api_locks = current_chat.default_banned_rights
    except AttributeError as e:
        logger.info(str(e))
    else:
        res += "\nFollowing are the API locks in this chat: \n"
        res += "👉 `msg`: `{}`\n".format(current_api_locks.send_messages)
        res += "👉 `media`: `{}`\n".format(current_api_locks.send_media)
        res += "👉 `sticker`: `{}`\n".format(current_api_locks.send_stickers)
        res += "👉 `gif`: `{}`\n".format(current_api_locks.send_gifs)
        res += "👉 `gamee`: `{}`\n".format(current_api_locks.send_games)
        res += "👉 `ainline`: `{}`\n".format(current_api_locks.send_inline)
        res += "👉 `gpoll`: `{}`\n".format(current_api_locks.send_polls)
        res += "👉 `adduser`: `{}`\n".format(current_api_locks.invite_users)
        res += "👉 `cpin`: `{}`\n".format(current_api_locks.pin_messages)
        res += "👉 `changeinfo`: `{}`\n".format(
            current_api_locks.change_info)
    await event.edit(res)
예제 #2
0
파일: locks_IQ.py 프로젝트: d3s44/IQTHON
async def _(event):
    if event.fwd_from:
        return
    res = ""
    current_db_locks = get_locks(event.chat_id)
    if not current_db_locks:
        res = "لاتوجد اقفال من قبل حسابك شخصي في هل مجموعه"
    else:
        res = "🕷🇮🇶انت قافل من حسابك الشخصي: \n"
        res += "🕷🇮🇶 بوتات : `{}`\n".format(current_db_locks.bots)
        res += "🕷🇮🇶 تعليقات : `{}`\n".format(current_db_locks.commands)
        res += "🕷🇮🇶 ايميل : `{}`\n".format(current_db_locks.email)
        res += "🕷🇮🇶 توجيه : `{}`\n".format(current_db_locks.forward)
        res += "🕷🇮🇶 روابط : `{}`\n".format(current_db_locks.url)
    current_chat = await event.get_chat()
    try:
        current_api_locks = current_chat.default_banned_rights
    except AttributeError as e:
        logger.info(str(e))
    else:
        res += "🕷🇮🇶صلاحيات المجموعه للارسال: \n"
        res += "🕷🇮🇶 الرسائل : `{}`\n".format(current_api_locks.send_messages)
        res += "🕷🇮🇶 ميديا : `{}`\n".format(current_api_locks.send_media)
        res += "🕷🇮🇶 ملصقات: `{}`\n".format(current_api_locks.send_stickers)
        res += "🕷🇮🇶 متحركات : `{}`\n".format(current_api_locks.send_gifs)
        res += "🕷🇮🇶 العاب : `{}`\n".format(current_api_locks.send_games)
        res += "🕷🇮🇶 الانلاين : `{}`\n".format(current_api_locks.send_inline)
        res += "🕷🇮🇶 الجميع : `{}`\n".format(current_api_locks.send_polls)
        res += "🕷🇮🇶 اضافه : `{}`\n".format(current_api_locks.invite_users)
        res += "🕷🇮🇶 التثبيت : `{}`\n".format(current_api_locks.pin_messages)
        res += "🕷🇮🇶 معلومات : `{}`\n".format(current_api_locks.change_info)
    await event.edit(res)
예제 #3
0
async def _(event):
    if event.fwd_from:
        return
    res = ""
    current_db_locks = get_locks(event.chat_id)
    if not current_db_locks:
        res = "Bu sohbette DataBase kilidi yok"
    else:
        res = "Bu sohbette DataBase kilitleri aşağıdadır: \n"
        res += "👉 `botlar`: `{}`\n".format(current_db_locks.bots)
        res += "👉 `komutlar`: `{}`\n".format(current_db_locks.commands)
        res += "👉 `email`: `{}`\n".format(current_db_locks.email)
        res += "👉 `forward`: `{}`\n".format(current_db_locks.forward)
        res += "👉 `url`: `{}`\n".format(current_db_locks.url)
    current_chat = await event.get_chat()
    try:
        current_api_locks = current_chat.default_banned_rights
    except AttributeError as e:
        logger.info(str(e))
    else:
        res += "\nBu sohbette API kilitleri aşağıdadır: \n"
        res += "👉 `msg`: `{}`\n".format(current_api_locks.send_messages)
        res += "👉 `media`: `{}`\n".format(current_api_locks.send_media)
        res += "👉 `sticker`: `{}`\n".format(current_api_locks.send_stickers)
        res += "👉 `gif`: `{}`\n".format(current_api_locks.send_gifs)
        res += "👉 `gamee`: `{}`\n".format(current_api_locks.send_games)
        res += "👉 `ainline`: `{}`\n".format(current_api_locks.send_inline)
        res += "👉 `gpoll`: `{}`\n".format(current_api_locks.send_polls)
        res += "👉 `adduser`: `{}`\n".format(current_api_locks.invite_users)
        res += "👉 `cpin`: `{}`\n".format(current_api_locks.pin_messages)
        res += "👉 `changeinfo`: `{}`\n".format(current_api_locks.change_info)
    await event.edit(res)