• Mahmoud Aglan's avatar
    fix(expenses): let a phone photo of a receipt actually attach and display · 32e52a04
    Mahmoud Aglan authored
    Three things stood between the desk and an attached receipt:
    
    - The picker on the create form listed extensions (.jpg,.png,…), which on
      iOS greys out the camera roll; and both components validated
      mimes:jpg,jpeg,png,pdf,webp, so a HEIC photo — the iPhone default —
      was refused after the picker had accepted it. Both now accept image/*
      plus heic/heif, and validate the same set.
    - The attachment stream built Content-Disposition by hand with
      addslashes(). Receipt names here are Arabic, and an Arabic filename is
      not a legal header value: the inline preview came back broken and the
      download came back mangled. Symfony builds the header now, via
      Storage::response() for inline and download() for the save.
    - HEIC is an image no browser but Safari paints, so it falls back to the
      file card instead of a broken <img> (attachmentIsViewableImage()).
    
    Also: the create form advertised a 5MB ceiling while the real one is
    config('uploads.max_kb') (150MB), and its uploaded-file chip called
    getClientOriginalName() on whatever sat in the property.
    Co-Authored-By: 's avatarClaude Opus 5 (1M context) <noreply@anthropic.com>
    32e52a04
Name
Last commit
Last update
..
activities Loading commit data...
admin Loading commit data...
assignments Loading commit data...
attendance Loading commit data...
audit Loading commit data...
auth Loading commit data...
branches Loading commit data...
cash-sessions Loading commit data...
components Loading commit data...
dashboard Loading commit data...
documents Loading commit data...
enrollments Loading commit data...
evaluations Loading commit data...
events Loading commit data...
facilities Loading commit data...
financial Loading commit data...
groups Loading commit data...
guardian Loading commit data...
hr Loading commit data...
inventory Loading commit data...
invoices Loading commit data...
messaging Loading commit data...
notifications Loading commit data...
parent Loading commit data...
participants Loading commit data...
people Loading commit data...
portal Loading commit data...
pos Loading commit data...
pricing Loading commit data...
profile Loading commit data...
programs Loading commit data...
public Loading commit data...
receptionist Loading commit data...
reports Loading commit data...
requests Loading commit data...
roles Loading commit data...
schedule Loading commit data...
settings Loading commit data...
trainer Loading commit data...
training Loading commit data...
users Loading commit data...
wallets Loading commit data...
website Loading commit data...
whatsapp Loading commit data...
wizards Loading commit data...
branch-switcher.blade.php Loading commit data...
dashboard.blade.php Loading commit data...
global-search.blade.php Loading commit data...