clrghouz/resources/views/system/address-merge.blade.php

70 lines
2.3 KiB
PHP

<!-- $o=Address::class -->
@extends('layouts.app')
@section('htmlheader_title')
Address Merge
@endsection
@section('content')
<div class="row pt-0">
<div class="col-12">
<h2>Merge Address {{ $o->ftn }}</h2>
<p>{{ $o->system->sysop }} : {{ $o->system->name }}</p>
</div>
<div class="col-12">
<form method="POST">
@csrf
<table class="table monotable">
<thead>
<tr>
<th>F</th>
<th>T</th>
<th>ID</th>
<th>FTN</th>
<th>ACTIVE</th>
<th>Messages</th>
</tr>
</thead>
<tbody>
@foreach ($oo as $ao)
<tr>
<td><input type="radio" name="src" value="{{ $ao->id }}"></td>
<td><input type="radio" name="dst" value="{{ $ao->id }}"></td>
<th>{{ $ao->id }} {{ $ao->system_id }}:<a href="{{ url('ftn/system/addedit',$ao->system_id) }}">{{ $ao->system->name }}</a></th>
<th>{{ $ao->ftn }}</th>
<td>
@if($ao->trashed())
<a href="{{ url('ftn/system/recaddress',[$ao->id]) }}" title="Restore Address"><i class="bi bi-bandaid"></i></a>
<a href="{{ url('ftn/system/puraddress',[$ao->id]) }}" title="Purge Address" class="purge"><i class="bi bi-scissors"></i></a>
@else
<a href="{{ url('ftn/system/susaddress',[$ao->id]) }}" title="@if($ao->active)Pause @else Activate @endif Address"><i class="bi @if($ao->active)bi-pause-circle @else bi-play-circle @endif"></i></a>
<a href="{{ url('ftn/system/movaddress',[$ao->system_id,$ao->id]) }}" title="Move Address to another System"><i class="bi bi-arrow-right-square"></i></a>
<a href="{{ url('ftn/system/deladdress',[$ao->id]) }}" title="Delete Address"><i class="bi bi-trash"></i></a>
@endif
</td>
<td>
<ul>
@foreach(\App\Models\Echomail::select(['id','msgid','from','msg'])
->where('fftn_id',$ao->id)
->orderBy('created_at','DESC')
->limit(5)
->get() as $eo)
<li class="pb-4">{{ sprintf('%04d: %s (%s) %s',$eo->id,$eo->from,$eo->msgid,$eo->msg) }}</li>
@endforeach
</ul>
</td>
</tr>
@endforeach
</tbody>
</table>
<button type="submit" name="submit" class="btn btn-success float-end">Merge</button>
</form>
</div>
@include('error')
</div>
@endsection