mirror of
https://github.com/friendica/friendica
synced 2025-04-26 05:10:11 +00:00
Store the push/pull direction in the conversation table
This commit is contained in:
parent
6f0d40c6c0
commit
af6db65961
5 changed files with 27 additions and 11 deletions
|
@ -41,6 +41,19 @@ class Conversation
|
|||
const PARCEL_TWITTER = 67;
|
||||
const PARCEL_UNKNOWN = 255;
|
||||
|
||||
/**
|
||||
* Unknown message direction
|
||||
*/
|
||||
const UNKNOWN = 0;
|
||||
/**
|
||||
* The message had been pushed to this sytem
|
||||
*/
|
||||
const PUSH = 1;
|
||||
/**
|
||||
* The message had been fetched by our system
|
||||
*/
|
||||
const PULL = 2;
|
||||
|
||||
public static function getByItemUri($item_uri)
|
||||
{
|
||||
return DBA::selectFirst('conversation', [], ['item-uri' => $item_uri]);
|
||||
|
@ -79,6 +92,10 @@ class Conversation
|
|||
$conversation['protocol'] = $arr['protocol'];
|
||||
}
|
||||
|
||||
if (isset($arr['direction'])) {
|
||||
$conversation['direction'] = $arr['direction'];
|
||||
}
|
||||
|
||||
if (isset($arr['source'])) {
|
||||
$conversation['source'] = $arr['source'];
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue