您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Clicks "Switch to classic view" button when it appears
// ==UserScript== // @name QBO Automatic Classic Reports // @namespace http://tampermonkey.net/ // @version 2025-07-03 // @description Clicks "Switch to classic view" button when it appears // @author You // @match https://qbo.intuit.com/* // @icon data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw== // @grant none // ==/UserScript== (function() { 'use strict'; const clickButton = () => { const buttons = document.querySelectorAll('button.idsF.qbdsLinkActionButton.LinkActionButton-button-66c8d46.LinkActionButton-right-325b00e.medium'); for (const button of buttons) { const span = button.querySelector('span'); if ( span && span.textContent.trim() === 'Switch to classic view' && !button.hasAttribute('data-clicked') ) { button.setAttribute('data-clicked', 'true'); button.click(); break; // Stop after the first matching button } } }; // Initial check in case the button is already there clickButton(); // Observe any changes in the body to catch dynamic content const observer = new MutationObserver(() => { clickButton(); }); observer.observe(document.body, { childList: true, subtree: true }); })();