mirror of
https://github.com/friendica/friendica
synced 2024-12-23 07:20:15 +00:00
Merge pull request #6613 from MrPetovan/task/6238-add-delivery-done
Add "delivery done" label
This commit is contained in:
commit
fecfcd5025
5 changed files with 2218 additions and 2178 deletions
|
@ -432,6 +432,7 @@ class Post extends BaseObject
|
|||
'delivery_pending' => L10n::t('Delivery to remote servers is pending'),
|
||||
'delivery_underway' => L10n::t('Delivery to remote servers is underway'),
|
||||
'delivery_almost' => L10n::t('Delivery to remote servers is mostly done'),
|
||||
'delivery_done' => L10n::t('Delivery to remote servers is done'),
|
||||
],
|
||||
];
|
||||
|
||||
|
|
|
@ -41,10 +41,9 @@ class APDelivery extends BaseObject
|
|||
$data = ActivityPub\Transmitter::createCachedActivityFromItem($target_id);
|
||||
if (!empty($data)) {
|
||||
$success = HTTPSignature::transmit($data, $inbox, $uid);
|
||||
}
|
||||
|
||||
if ($success && in_array($cmd, [Delivery::POST, Delivery::COMMENT])) {
|
||||
ItemDeliveryData::incrementQueueDone($target_id);
|
||||
if ($success && in_array($cmd, [Delivery::POST, Delivery::COMMENT])) {
|
||||
ItemDeliveryData::incrementQueueDone($target_id);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -11,8 +11,10 @@
|
|||
{{$delivery.delivery_pending}} {{$item.delivery.queue_done}}/{{$item.delivery.queue_count}}
|
||||
{{elseif $delivery.queue_done / $delivery.queue_count < 0.75}}
|
||||
{{$delivery.delivery_underway}} {{$item.delivery.queue_done}}/{{$item.delivery.queue_count}}
|
||||
{{else}}
|
||||
{{elseif $delivery.queue_done < $delivery.queue_count}}
|
||||
{{$delivery.delivery_almost}} {{$item.delivery.queue_done}}/{{$item.delivery.queue_count}}
|
||||
{{else}}
|
||||
{{$delivery.delivery_done}} {{$item.delivery.queue_done}}/{{$item.delivery.queue_count}}
|
||||
{{/if}}
|
||||
</span>
|
||||
{{/if}}
|
||||
|
|
|
@ -10,9 +10,12 @@
|
|||
{{elseif $delivery.queue_done / $delivery.queue_count < 0.75}}
|
||||
<i class="fa fa-paper-plane-o" aria-hidden="true" title="{{$delivery.delivery_underway}} {{$item.delivery.queue_done}}/{{$item.delivery.queue_count}}"></i>
|
||||
<span class="sr-only">{{$delivery.delivery_underway}}</span>
|
||||
{{else}}
|
||||
{{elseif $delivery.queue_done < $delivery.queue_count}}
|
||||
<i class="fa fa-paper-plane" aria-hidden="true" title="{{$delivery.delivery_almost}} {{$item.delivery.queue_done}}/{{$item.delivery.queue_count}}"></i>
|
||||
<span class="sr-only">{{$delivery.delivery_almost}}</span>
|
||||
{{else}}
|
||||
<i class="fa fa-paper-plane" aria-hidden="true" title="{{$delivery.delivery_done}} {{$item.delivery.queue_done}}/{{$item.delivery.queue_count}}"></i>
|
||||
<span class="sr-only">{{$delivery.delivery_done}}</span>
|
||||
{{/if}}
|
||||
</span>
|
||||
{{/if}}
|
||||
|
|
Loading…
Reference in a new issue