- Categorie dei Gruppi aggiornate. - Email ora compare sul profilo se non hai telegram e anche sugli annunci.
1076 lines
37 KiB
Vue
Executable File
1076 lines
37 KiB
Vue
Executable File
<template>
|
||
<div v-if="contact">
|
||
<q-item class="q-my-sm" clickable>
|
||
<q-item-section avatar @click="actionType === costanti.ACTIONTYPE.SEND_RIS ? naviga(`/my/` + contact.username + '?sr=0') : naviga(`/my/` + contact.username)">
|
||
<q-avatar size="60px">
|
||
<q-img
|
||
:src="getImgUser(contact)"
|
||
:alt="contact.username"
|
||
img-class="imgprofile"
|
||
height="60px"
|
||
/>
|
||
</q-avatar>
|
||
</q-item-section>
|
||
|
||
<q-item-section @click="actionType === costanti.ACTIONTYPE.SEND_RIS ? naviga(`/my/` + contact.username + '?sr=0') : naviga(`/my/` + contact.username)">
|
||
<q-item-label v-if="labelextra && labelextra !== contact.username"
|
||
><strong>{{ labelextra }}</strong></q-item-label
|
||
>
|
||
<q-item-label v-if="contact.name"
|
||
><span class="username"
|
||
>{{ contact.name }}
|
||
<span v-if="contact.surname">{{ contact.surname }}</span></span
|
||
>
|
||
({{ contact.username }})
|
||
</q-item-label>
|
||
<q-item-label v-else
|
||
><span class="username">{{ contact.username }}</span>
|
||
<span v-if="contact.name"
|
||
>({{ contact.name }} {{ contact.surname }})</span
|
||
>
|
||
</q-item-label>
|
||
<q-item-label v-if="contact.reported" caption lines="1"
|
||
><em style="color: red; font-weight: bold">{{
|
||
$t('db.reporteduser', {
|
||
date_report: tools.getstrDateTimeShort(contact.date_report),
|
||
})
|
||
}}</em></q-item-label
|
||
>
|
||
<q-item-label v-if="contact.profile" caption lines="3"
|
||
>
|
||
<em>{{ contact.profile.qualifica }}</em>
|
||
<span v-if="tools.isFacil() && contact.profile.note"><span v-if="contact.profile.qualifica"><br></span><em style="color: blue;">Note: {{ contact.profile.note }}</em></span>
|
||
<span v-if="tools.isFacil() && contact.profile.da_contattare"><br><em style="color: red;">Da Contattare</em></span>
|
||
<!--<span v-if="tools.isBitActive(contact.perm, shared_consts.Permissions.Facilitatore.value)"><br><em style="color: blue;">⭐️ Facilitatore RISO</em></span>-->
|
||
</q-item-label
|
||
>
|
||
<q-item-label caption lines="1"></q-item-label>
|
||
<div v-if="visu === costanti.ASK_TRUST">
|
||
<span class="text-italic"
|
||
>Reg: {{ tools.getstrDateShort(contact.date_reg) }}</span
|
||
>
|
||
</div>
|
||
|
||
<q-item-label v-if="labelFooter" lines="1"
|
||
><em>{{ labelFooter }}</em></q-item-label
|
||
>
|
||
<span
|
||
v-if="contact.profile && contact.profile.resid_province"
|
||
class="show_province_title"
|
||
>Prov:
|
||
<span class="show_province">{{
|
||
contact.profile.resid_province
|
||
}}</span></span
|
||
>
|
||
<q-item-label v-if="contact.account" caption lines="2">
|
||
<div class="row">
|
||
<CSaldo
|
||
:small="true"
|
||
:account="contact.account"
|
||
:symbol="tools.getSymbolByCircuit(circuit)"
|
||
:color="tools.getColorByCircuit(circuit)"
|
||
:saldo="contact.account.saldo_pend"
|
||
:valueextra="
|
||
contact.account.saldo_pend !== contact.account.saldo ? '*' : ''
|
||
"
|
||
>
|
||
</CSaldo>
|
||
</div>
|
||
</q-item-label>
|
||
</q-item-section>
|
||
|
||
<q-item-section side v-if="visu === costanti.FRIENDS">
|
||
<q-item-label>
|
||
<q-btn rounded icon="fas fa-ellipsis-h">
|
||
<q-menu>
|
||
<q-list
|
||
style="min-width: 150px"
|
||
v-if="!userStore.IsHandShakeByMe(contact.username)"
|
||
>
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
tools.addToMyHandShake(
|
||
$q,
|
||
userStore.my.username,
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="positive" name="fas fa-handshake" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('handshake.accept_handshake')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
<q-list style="min-width: 150px">
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.REMOVE_FROM_MYFRIENDS,
|
||
userStore.my.username,
|
||
'',
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-minus" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('friends.remove_from_myfriends')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
<q-list style="min-width: 150px">
|
||
<q-item
|
||
clickable
|
||
icon="fas fa-ban"
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.BLOCK_USER,
|
||
userStore.my.username,
|
||
'',
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-ban" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('friends.block_user')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
<q-list style="min-width: 150px">
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.REPORT_USER,
|
||
userStore.my.username,
|
||
'',
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-flag" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('friends.report_user')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
</q-menu>
|
||
</q-btn>
|
||
</q-item-label>
|
||
</q-item-section>
|
||
<q-item-section side v-else-if="visu === costanti.REQ_FRIENDS">
|
||
<q-item-label>
|
||
<q-btn rounded icon="fas fa-ellipsis-h">
|
||
<q-menu>
|
||
<q-list v-if="true" style="min-width: 150px">
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.SETFRIEND,
|
||
userStore.my.username,
|
||
'',
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section>{{
|
||
$t('friends.accept_friend')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
<q-list style="min-width: 150px">
|
||
<q-item
|
||
clickable
|
||
icon="fas fa-user-minus"
|
||
outline
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.REQFRIEND,
|
||
userStore.my.username,
|
||
false,
|
||
contact.username,
|
||
false
|
||
)
|
||
"
|
||
>
|
||
<q-item-section>{{
|
||
$t('friends.reject_ask_friend')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
</q-menu>
|
||
</q-btn>
|
||
</q-item-label>
|
||
</q-item-section>
|
||
<q-item-section side v-else-if="visu === costanti.HANDSHAKE">
|
||
<q-item-label>
|
||
<q-btn rounded icon="fas fa-ellipsis-h">
|
||
<q-menu>
|
||
<q-list v-if="true" style="min-width: 150px">
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.SETHANDSHAKE,
|
||
userStore.my.username,
|
||
'',
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section>{{
|
||
$t('friends.accept_handshake')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
</q-menu>
|
||
</q-btn>
|
||
</q-item-label>
|
||
</q-item-section>
|
||
<q-item-section side v-else-if="visu === costanti.REQ_ADD_USER_TO_GROUP">
|
||
<q-item-label>
|
||
<q-btn rounded icon="fas fa-ellipsis-h">
|
||
<q-menu>
|
||
<q-list v-if="true" style="min-width: 150px">
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="tools.addToMyGroups($q, contact.username, groupname)"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="positive" name="fas fa-user-plus" />
|
||
</q-item-section>
|
||
<q-item-section>
|
||
{{ $t('groups.accept_group') }}
|
||
</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
v-if="circuit"
|
||
clickable
|
||
v-close-popup
|
||
@click="showAccountInfo = true"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon name="fas fa-info" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('groups.infoaccount')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
<q-list style="min-width: 200px">
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="tools.refuseReqGroup($q, contact.username, groupname)"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-minus" />
|
||
</q-item-section>
|
||
|
||
<q-item-section>{{ $t('shared.refuse_ask') }}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
tools.cancelReqGroups($q, contact.username, groupname)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-minus" />
|
||
</q-item-section>
|
||
|
||
<q-item-section>{{
|
||
$t('shared.cancel_ask_short')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
</q-menu>
|
||
</q-btn>
|
||
</q-item-label>
|
||
</q-item-section>
|
||
<q-item-section
|
||
side
|
||
v-else-if="visu === costanti.REQ_REMOVE_USER_TO_GROUP"
|
||
>
|
||
<q-item-label v-if="contact.username !== userStore.my.username">
|
||
<q-btn rounded icon="fas fa-ellipsis-h">
|
||
<q-menu>
|
||
<q-list style="min-width: 150px">
|
||
<q-item
|
||
clickable
|
||
v-if="!tools.isUserAdminGroup(groupname, contact.username, true)"
|
||
v-close-popup
|
||
@click="
|
||
tools.addtoAdminOfMyGroup($q, contact.username, groupname)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="positive" name="fas fa-user-shield" />
|
||
</q-item-section>
|
||
<q-item-section>{{ $t('groups.addasadmin') }}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-if="
|
||
tools.isUserAdminGroup(groupname, contact.username, true) &&
|
||
tools.iAmTheCreatorOfTheGroup(groupname)
|
||
"
|
||
v-close-popup
|
||
@click="
|
||
tools.removeAdminOfMyGroup($q, contact.username, groupname)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-times" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('groups.remove_as_admin')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-if="
|
||
!tools.isUserTheCreatorOfTheGroup(
|
||
groupname,
|
||
contact.username
|
||
)
|
||
"
|
||
v-close-popup
|
||
@click="
|
||
tools.removeFromMyGroups($q, contact.username, groupname)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-minus" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('groups.remove_from_mygroups')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
tools.reportUser(
|
||
$q,
|
||
userStore.my.username,
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-flag" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('friends.report_user')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
</q-menu>
|
||
</q-btn>
|
||
</q-item-label>
|
||
</q-item-section>
|
||
<q-item-section
|
||
side
|
||
v-else-if="visu === costanti.REQ_ADD_USER_TO_CIRCUIT"
|
||
>
|
||
<q-item-label>
|
||
<q-btn rounded icon="fas fa-ellipsis-h">
|
||
<q-menu>
|
||
<q-list v-if="true" style="min-width: 150px">
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
dense
|
||
@click="naviga(`/my/` + contact.username)"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="primary" name="fas fa-user" />
|
||
</q-item-section>
|
||
<q-item-section>{{ $t('shared.profile') }}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
v-if="
|
||
userStore.showButtonSendCoin(contact) &&
|
||
(contact.username !== userStore.my.username ||
|
||
userStore.hoContiCollettiviDaAmministrare() ||
|
||
userStore.hoContiComunitariDaAmministrare())
|
||
"
|
||
clickable
|
||
v-close-popup
|
||
dense
|
||
@click="naviga(`/my/` + contact.username + '?sr=0')"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon
|
||
color="positive"
|
||
name="img: images/1ris_rosso_100.png"
|
||
/>
|
||
</q-item-section>
|
||
<q-item-section>{{ $t('circuit.sendcoins') }}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
tools.addToMyCircuits($q, contact.username, circuitname)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="positive" name="fas fa-user-plus" />
|
||
</q-item-section>
|
||
<q-item-section>
|
||
{{ $t('circuit.add_to_circuit') }}
|
||
</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
v-if="
|
||
contact.account ? contact.account.fidoConcesso <= 0 : true
|
||
"
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
tools.addFidoToMyCircuits($q, contact.username, circuitname)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon
|
||
color="positive"
|
||
name="img: images/1ris_rosso_100.png"
|
||
/>
|
||
</q-item-section>
|
||
<q-item-section>
|
||
{{ $t('circuit.enablefido') }}
|
||
</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
v-if="circuit"
|
||
clickable
|
||
v-close-popup
|
||
@click="showAccountInfo = true"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon name="fas fa-info" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('groups.infoaccount')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
<q-list style="min-width: 200px">
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
tools.refuseReqCircuit($q, contact.username, circuitname)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-minus" />
|
||
</q-item-section>
|
||
|
||
<q-item-section>{{ $t('shared.refuse_ask') }}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
tools.cancelReqCircuit($q, contact.username, circuitname)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-minus" />
|
||
</q-item-section>
|
||
|
||
<q-item-section>{{
|
||
$t('shared.cancel_ask_short')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-if="
|
||
!tools.isUserAdminCircuit(circuitname, contact.username, true)
|
||
"
|
||
v-close-popup
|
||
@click="
|
||
tools.addtoAdminOfCircuit($q, contact.username, circuitname)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="positive" name="fas fa-user-shield" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('circuit.addasadmin')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-if="
|
||
tools.isUserAdminCircuit(circuitname, contact.username, true) &&
|
||
tools.iAmTheCreatorOfTheCircuit(circuitname)
|
||
"
|
||
v-close-popup
|
||
@click="
|
||
tools.removeAdminOfCircuit(
|
||
$q,
|
||
contact.username,
|
||
circuitname
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-times" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('circuit.remove_as_admin')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-if="
|
||
!tools.isUserTheCreatorOfTheCircuit(
|
||
circuitname,
|
||
contact.username
|
||
)
|
||
"
|
||
v-close-popup
|
||
@click="
|
||
tools.removeFromMyCircuits(
|
||
$q,
|
||
contact.username,
|
||
circuitname,
|
||
''
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-minus" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('circuit.remove_from_mycircuit')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
</q-menu>
|
||
</q-btn>
|
||
</q-item-label>
|
||
</q-item-section>
|
||
<q-item-section
|
||
side
|
||
v-else-if="visu === costanti.REQ_REMOVE_USER_TO_CIRCUIT"
|
||
>
|
||
<q-item-label v-if="contact.username !== userStore.my.username">
|
||
<q-btn rounded icon="fas fa-ellipsis-h">
|
||
<q-menu>
|
||
<q-list style="min-width: 150px">
|
||
<q-item
|
||
clickable
|
||
v-if="
|
||
!tools.isUserAdminCircuit(circuitname, contact.username, true)
|
||
"
|
||
v-close-popup
|
||
@click="
|
||
tools.addtoAdminOfCircuit($q, contact.username, circuitname)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="positive" name="fas fa-user-shield" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('circuit.addasadmin')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-if="
|
||
tools.isUserAdminCircuit(circuitname, contact.username, true) &&
|
||
tools.iAmTheCreatorOfTheCircuit(circuitname)
|
||
"
|
||
v-close-popup
|
||
@click="
|
||
tools.removeAdminOfCircuit(
|
||
$q,
|
||
contact.username,
|
||
circuitname
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-times" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('circuit.remove_as_admin')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-if="
|
||
!tools.isUserTheCreatorOfTheCircuit(
|
||
circuitname,
|
||
contact.username
|
||
)
|
||
"
|
||
v-close-popup
|
||
@click="
|
||
tools.removeFromMyCircuits(
|
||
$q,
|
||
contact.username,
|
||
circuitname,
|
||
''
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-minus" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('circuit.remove_from_mycircuit')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
</q-menu>
|
||
</q-btn>
|
||
</q-item-label>
|
||
</q-item-section>
|
||
<q-item-section side v-else-if="visu === costanti.ASK_SENT_FRIENDS">
|
||
<q-item-label>
|
||
<q-btn rounded icon="fas fa-ellipsis-h">
|
||
<q-menu>
|
||
<q-list style="min-width: 150px">
|
||
<q-item
|
||
clickable
|
||
icon="fas fa-user-minus"
|
||
outline
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.CANCEL_REQ_FRIEND,
|
||
userStore.my.username,
|
||
'',
|
||
contact.username,
|
||
''
|
||
)
|
||
"
|
||
>
|
||
<q-item-section>{{
|
||
$t('friends.cancel_ask_friend')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
</q-menu>
|
||
</q-btn>
|
||
</q-item-label>
|
||
</q-item-section>
|
||
<q-item-section side v-else-if="visu === costanti.ASK_TRUST">
|
||
<q-item-label>
|
||
<q-btn
|
||
color="positive"
|
||
:label="$t('friends.accept_trust')"
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.SETTRUST,
|
||
userStore.my.username,
|
||
true,
|
||
contact.username
|
||
)
|
||
"
|
||
/>
|
||
</q-item-label>
|
||
<q-item-label>
|
||
<q-btn
|
||
color="negative"
|
||
:label="$t('friends.refuse_trust')"
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.SETTRUST,
|
||
userStore.my.username,
|
||
false,
|
||
contact.username
|
||
)
|
||
"
|
||
/>
|
||
</q-item-label>
|
||
</q-item-section>
|
||
<q-item-section side v-else-if="visu === costanti.TRUSTED">
|
||
<q-item-label>
|
||
<q-btn rounded icon="fas fa-ellipsis-h">
|
||
<q-menu>
|
||
<q-list style="min-width: 200px">
|
||
<q-item
|
||
v-if="
|
||
costanti.ENABLE_FRIENDS &&
|
||
!userStore.IsMyFriendByUsername(contact.username)
|
||
"
|
||
clickable
|
||
icon="fas fa-user-plus"
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.REQFRIEND,
|
||
userStore.my.username,
|
||
true,
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section>{{
|
||
$t('friends.ask_friend')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
v-if="!userStore.IsHandShakeByMe(contact)"
|
||
clickable
|
||
icon="far fa-handshake"
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.SETHANDSHAKE,
|
||
userStore.my.username,
|
||
true,
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section>{{
|
||
$t('handshake.ask_handshake')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
<q-list style="min-width: 200px">
|
||
<q-item
|
||
clickable
|
||
icon="fas fa-user-minus"
|
||
outline
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.SETTRUST,
|
||
userStore.my.username,
|
||
false,
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section>{{
|
||
$t('friends.reject_trust')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
</q-menu>
|
||
</q-btn>
|
||
</q-item-label>
|
||
</q-item-section>
|
||
<q-item-section
|
||
side
|
||
v-else-if="visu === costanti.FIND_PEOPLE || visu === costanti.HANDSHAKE"
|
||
>
|
||
<div v-if="actionType === costanti.ACTIONTYPE.SEND_RIS">
|
||
<q-icon
|
||
name="img: images/1ris_rosso_100.png"
|
||
:size="`lg`"
|
||
/>
|
||
</div>
|
||
<div v-else>
|
||
<q-item-label>
|
||
<q-btn
|
||
v-if="contact.username !== userStore.my.username"
|
||
rounded
|
||
dense
|
||
icon="fas fa-ellipsis-h"
|
||
>
|
||
<!-- </q-btn></q-btn>:icon="
|
||
userStore.IsMyFriendByUsername(contact.username)
|
||
? `fas fa-ellipsis-h`
|
||
: `fas fa-user`
|
||
"-->
|
||
<q-menu>
|
||
<q-list style="min-width: 200px">
|
||
<q-item
|
||
v-if="
|
||
userStore.showButtonSendCoin(contact) &&
|
||
(contact.username !== userStore.my.username ||
|
||
userStore.hoContiCollettiviDaAmministrare() ||
|
||
userStore.hoContiComunitariDaAmministrare())
|
||
"
|
||
clickable
|
||
v-close-popup
|
||
dense
|
||
@click="naviga(`/my/` + contact.username + '?sr=0')"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon
|
||
color="positive"
|
||
name="img: images/1ris_rosso_100.png"
|
||
/>
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('circuit.sendcoins')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
dense
|
||
@click="naviga(`/my/` + contact.username)"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="primary" name="fas fa-user" />
|
||
</q-item-section>
|
||
<q-item-section>{{ $t('shared.profile') }}</q-item-section>
|
||
</q-item>
|
||
|
||
<q-item
|
||
v-if="
|
||
costanti.ENABLE_FRIENDS &&
|
||
!userStore.IsMyFriendByUsername(contact.username) &&
|
||
!userStore.IsAskedFriendByUsername(contact.username)
|
||
"
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.REQFRIEND,
|
||
userStore.my.username,
|
||
true,
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="positive" name="fas fa-user-plus" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('friends.ask_friend')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
v-else-if="
|
||
costanti.ENABLE_FRIENDS &&
|
||
!userStore.IsMyFriendByUsername(contact.username) &&
|
||
userStore.IsAskedFriendByUsername(contact.username)
|
||
"
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.REQFRIEND,
|
||
userStore.my.username,
|
||
false,
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-minus" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('friends.cancel_ask_friend')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
v-else-if="
|
||
costanti.ENABLE_FRIENDS &&
|
||
userStore.IsMyFriendByUsername(contact.username)
|
||
"
|
||
style="min-width: 200px"
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.REMOVE_FROM_MYFRIENDS,
|
||
userStore.my.username,
|
||
'',
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-user-minus" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('friends.remove_from_myfriends')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
|
||
<q-item
|
||
v-if="!userStore.IsHandShakeByMe(contact)"
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.SETHANDSHAKE,
|
||
userStore.my.username,
|
||
true,
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="positive" name="far fa-handshake" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('handshake.ask_handshake')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
v-else
|
||
style="min-width: 200px"
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.REMOVE_FROM_MYHANDSHAKE,
|
||
userStore.my.username,
|
||
'',
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-handshake-slash" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('handshake.remove_from_myhandshake')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
v-if="circuit"
|
||
clickable
|
||
v-close-popup
|
||
@click="showAccountInfo = true"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon name="fas fa-info" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('groups.infoaccount')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
<q-item
|
||
clickable
|
||
v-close-popup
|
||
@click="
|
||
tools.reportUser(
|
||
$q,
|
||
userStore.my.username,
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section avatar>
|
||
<q-icon color="negative" name="fas fa-flag" />
|
||
</q-item-section>
|
||
<q-item-section>{{
|
||
$t('friends.report_user')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
</q-menu>
|
||
</q-btn>
|
||
</q-item-label>
|
||
</div>
|
||
</q-item-section>
|
||
<q-item-section side v-else-if="visu === costanti.REJECTED">
|
||
<q-item-label>
|
||
<q-btn rounded icon="fas fa-ellipsis-h">
|
||
<q-menu>
|
||
<q-list style="min-width: 200px">
|
||
<q-item
|
||
clickable
|
||
icon="fas fa-user-minus"
|
||
outline
|
||
v-close-popup
|
||
@click="
|
||
setCmd(
|
||
$q,
|
||
shared_consts.FRIENDSCMD.SETTRUST,
|
||
userStore.my.username,
|
||
true,
|
||
contact.username
|
||
)
|
||
"
|
||
>
|
||
<q-item-section>{{
|
||
$t('friends.accept_trust')
|
||
}}</q-item-section>
|
||
</q-item>
|
||
</q-list>
|
||
</q-menu>
|
||
</q-btn>
|
||
</q-item-label>
|
||
</q-item-section>
|
||
</q-item>
|
||
</div>
|
||
<div v-if="contact">
|
||
<CSendCoins
|
||
v-if="showsendCoinTo"
|
||
:showprop="showsendCoinTo"
|
||
:to_user="contact"
|
||
:circuitname="circuitname"
|
||
@close="showsendCoin(false)"
|
||
>
|
||
</CSendCoins>
|
||
</div>
|
||
<q-dialog v-model="showAccountInfo" full-height full-width>
|
||
<q-card v-if="circuit">
|
||
<q-toolbar class="bg-primary text-white">
|
||
<q-toolbar-title class="text-h7">
|
||
{{ tools.getNomeUtenteByRecUser(contact) }}
|
||
</q-toolbar-title>
|
||
<q-btn flat round color="white" icon="close" v-close-popup></q-btn>
|
||
</q-toolbar>
|
||
<CUserInfoAccount
|
||
:user="contact"
|
||
:circuitname="circuitname"
|
||
:admin="tools.iAmAdminCircuit(circuitname)"
|
||
/>
|
||
</q-card>
|
||
</q-dialog>
|
||
</template>
|
||
|
||
<script lang="ts" src="./CMyUser.ts">
|
||
</script>
|
||
|
||
<style lang="scss" scoped>
|
||
@import './CMyUser.scss';
|
||
</style>
|