si un commercial crée un client il lui est attribué automatiquement
This commit is contained in:
parent
7fced7fe57
commit
ab41bc3e93
@ -159,6 +159,12 @@ class Societe {
|
|||||||
|
|
||||||
$ret = $this->update($this->id,$user,0);
|
$ret = $this->update($this->id,$user,0);
|
||||||
|
|
||||||
|
// si un commercial crée un client il lui est affecté automatiquement
|
||||||
|
if (!$user->rights->commercial->client->voir)
|
||||||
|
{
|
||||||
|
$this->add_commercial($user, $user->id);
|
||||||
|
}
|
||||||
|
|
||||||
if ($ret >= 0)
|
if ($ret >= 0)
|
||||||
{
|
{
|
||||||
$this->use_webcal=($conf->global->PHPWEBCALENDAR_COMPANYCREATE=='always'?1:0);
|
$this->use_webcal=($conf->global->PHPWEBCALENDAR_COMPANYCREATE=='always'?1:0);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user