- Add "Mis cortes de caja" report for cashiers/counters with sales detail. - Cash register history scoped to own cuts for non-admin roles; new /register/<id>/sales endpoint. - Remove dashboard from cashier menu; add Reports to cashier/counter. - Service orders: assign mechanic, budget field, invoice flag, counter/cashier can add items/remissions, convert to remission. - Remission notes module (UI, CSS, courier, counter remissions). - Customer hard-delete and vehicle/customer linkage in workshop. - POS: always show search results, compact payment grid, credit validation, tier pricing (5%/10%), ticket with customer/folio. - Inventory: CSV template with sku_secondary, alias import. - Rached migration scripts and DB migrations. - Version-bump cached JS/CSS query strings. Excludes local Rached session tokens/captures (rached_*.json / rached_*.txt).
33 lines
1.4 KiB
JavaScript
33 lines
1.4 KiB
JavaScript
const { chromium } = require('playwright');
|
|
const fs = require('fs');
|
|
|
|
(async () => {
|
|
const browser = await chromium.launch({ headless: true });
|
|
const page = await browser.newPage();
|
|
await page.goto('http://app.flechasyventiladores-rached.com/', { waitUntil: 'networkidle' });
|
|
await page.waitForTimeout(2000);
|
|
await page.evaluate(() => {
|
|
document.getElementById('correo').removeAttribute('pattern');
|
|
document.getElementById('password').removeAttribute('pattern');
|
|
});
|
|
await page.fill('#correo', 'IVAN@flechasyventiladores-rached.com');
|
|
await page.fill('#password', 'Nexus01');
|
|
await page.evaluate(() => {
|
|
['correo','password'].forEach(id => {
|
|
const el = document.getElementById(id);
|
|
el.dispatchEvent(new Event('input', { bubbles: true }));
|
|
el.dispatchEvent(new Event('change', { bubbles: true }));
|
|
});
|
|
});
|
|
await page.waitForTimeout(1000);
|
|
await page.screenshot({ path: '/home/Autopartes/data/rached_import/login_filled.png', fullPage: true });
|
|
fs.writeFileSync('/home/Autopartes/data/rached_import/login_filled.html', await page.content());
|
|
// click enabled submit button if any
|
|
await page.click('button[color="primary"]');
|
|
await page.waitForTimeout(8000);
|
|
await page.screenshot({ path: '/home/Autopartes/data/rached_import/after_login.png', fullPage: true });
|
|
fs.writeFileSync('/home/Autopartes/data/rached_import/after_login.html', await page.content());
|
|
console.log('done');
|
|
await browser.close();
|
|
})();
|