Switchless TEST

Click button on the screen in bulk

  • keywords: #pattern
  • author: #alex

	var buttons = $('.create_invoice:not(.disabled)');
			// console.log(i) 
		}, i*50);

This is a simple situation where you have created an atomic functionality that can be initiated by clicking a button in the UI. Clicking through each one of them manually if there are 100 of them on the screen is a pain.

if you do $(selector).click() this will click all buttons simultaniously which can create a peak load on the server. The above code help helps you click all the buttons in the screen with a 50ms delay.

Example usage

  1. Create invoices from portal data in Mr Albert

  2. Run all checks in Mr Albert