HEX
Server: LiteSpeed
System: Linux sv4.hami.host 5.14.0-611.54.3.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Thu May 7 16:31:24 EDT 2026 x86_64
User: armgroup (1008)
PHP: 8.2.32
Disabled: show_source, system, shell_exec, passthru, exec, popen, proc_open, mail, socket_create, socket_create_listen, socket_create_pair, link, dl, openlog, syslog, stream_socket_server, curl_multi_init
Upload Files
File: //home/armgroup/libs/resources/views/livewire/admin/ticket/edit.blade.php
<div>
    @include('layouts.errors')
    <form role="form" wire:submit.prevent="update">
        <div class="form-row">
            <div class="form-group col-md-12">
                <label for="ticketMessage">پاسخ *</label>
                <textarea class="form-control" id="ticketMessage" required wire:model.defer="ticketMessage" rows="5"></textarea>
            </div>
        </div>
        <table class="table table-hover mt-2">
            <small class="text-muted">* شما می‌توانید با زدن دکمه افزودن پیوست حداکثر ۵ فایل با فرمت‌های doc, pdf, docx, zip, jpg, png, jpeg و تا حجم ۲ مگابایت آپلود کنید.</small>
            <thead>
            <tr>
                <th>عنوان فایل *</th>
                <th>فایل *</th>
                <th>عملیات</th>
            </tr>
            </thead>
            <tbody>
            @if(count($items))
                @foreach($items as $index => $item)
                    <tr>
                        <td>
                            <input type="text" class="form-control" wire:model.defer="items.{{$index}}.name" required>
                        </td>
                        <td>
                            <input type="file" class="form-control" wire:model.defer="items.{{$index}}.path" required>
                        </td>
                        <td>
                            <button type="button" class="btn btn-danger btn-sm" wire:click="removeItem({{ $index }})">
                                <span class="fa fa-trash"></span> حذف
                            </button>
                        </td>
                    </tr>
                @endforeach
            @endif
            </tbody>
            @if(count($items) < 5)
                <tfoot>
                <tr>
                    <td colspan="2"></td>
                    <td>
                        <button type="button" id="add-item" class="btn btn-success btn-sm" wire:click="addItem"><span class="fa fa-plus"></span> افزودن پیوست</button>
                    </td>
                </tr>
                </tfoot>
            @endif
        </table>
        <button class="btn btn-primary" type="submit">
            {{ $ticket->status->is(\App\Enums\TicketStatus::CLOSED) ? 'باز کردن تیکت و افزودن پاسخ' : 'افزودن پاسخ' }}
        </button>
    </form>
</div>