Commit 235b34bb authored by Stephane Bouvry's avatar Stephane Bouvry
Browse files

Status :

 - Fix : Pas de code distinctif entre les statuts "Résilié" et "En cours de clôture"
parent 7214a7cb
Loading
Loading
Loading
Loading
Loading
+117 −111
Original line number Diff line number Diff line
@@ -42,7 +42,7 @@ class Activity implements ResourceInterface
                self::STATUS_PROGRESS => 'Brouillon',
                self::STATUS_FENCED => 'Clôturé',
                self::STATUS_DEPOSIT => 'Déposé',
                self::STATUS_TERMINATED       => 'En cours de clôture',
                self::STATUS_PENDING_FENCED => 'En cours de clôture',
                self::STATUS_PENDING_ACCEPTED => 'En cours de conventionnement',
                self::STATUS_IDENTIFY => 'Identifié',
                self::STATUS_JUSTIFY => 'Justifié',
@@ -73,6 +73,7 @@ class Activity implements ResourceInterface
    const STATUS_IDENTIFY = 107;    // Identifié
    const STATUS_PENDING_ACCEPTED = 108;    // En cours de conventionnement
    const STATUS_ACCEPTED_2 = 109;    // Accepté en phase 2
    const STATUS_PENDING_FENCED = 110;    // En cours de clôture


    // 200 : Terminées / Abandonnées
@@ -770,7 +771,8 @@ class Activity implements ResourceInterface
        \DateTime $cache_at = new \DateTime(),
        bool      $cache_lock = false,
        string    $cache_lock_reason = self::CACHE_REASON_DEFAULT
    ): self {
    ): self
    {
        $this->cache = $cache_content;
        $this->dateCached = $cache_at;
        if ($cache_lock === true) {
@@ -815,7 +817,8 @@ class Activity implements ResourceInterface
        ?string $value,
        bool    $diplayCurrency = true,
        bool    $displayPercentInfo = true
    ): string {
    ): string
    {
        $percent = '';
        $currency = '';
        $data = '';
@@ -856,7 +859,8 @@ class Activity implements ResourceInterface
    public function getFraisDeGestionPartGestionnaireDisplay(
        bool $diplayCurrency = true,
        bool $displayPercentInfo = true
    ) {
    )
    {
        return $this->getFraisDisplay($this->getFraisDeGestionPartGestionnaire());
    }

@@ -1167,7 +1171,8 @@ class Activity implements ResourceInterface

    public function getActivityTypeChain(
        ActivityTypeService $activityTypeService
    ) {
    )
    {
        return $activityTypeService->getActivityTypeChain($this->getActivityType());
    }

@@ -1343,8 +1348,7 @@ class Activity implements ResourceInterface
    {
        if ($this->getDateNegociation()) {
            return $this->getDateNegociation()->format($format);
        }
        else {
        } else {
            return "";
        }
    }
@@ -1827,7 +1831,8 @@ class Activity implements ResourceInterface
                     $role,
                     $start = null,
                     $to = null
    ) {
    )
    {
        if (!$this->hasOrganization($organization, $role)) {
            $partner = new ActivityOrganization();
            $partner->setOrganization($organization)
@@ -2074,7 +2079,8 @@ class Activity implements ResourceInterface
        ?\DateTime $dateStart = null,
        ?\DateTime $dateEnd = null,
        bool       $deep = true
    ) {
    )
    {
        $found = false;
        /** @var ActivityPerson $activityPerson */
        foreach ($this->persons as $activityPerson) {
@@ -2396,8 +2402,7 @@ class Activity implements ResourceInterface
        /** @var ActivityPayment $payment */
        foreach ($this->getPayments() as $payment) {
            if (
                $payment->getDatePayment() == $datePayment && $payment->getAmount(
                ) == $amount && $payment->getDatePredicted() == $datePredicted
                $payment->getDatePayment() == $datePayment && $payment->getAmount() == $amount && $payment->getDatePredicted() == $datePredicted
            ) {
                return true;
            }
@@ -2416,7 +2421,8 @@ class Activity implements ResourceInterface
        Organization $organization,
                     $role = null,
                     $deep = true
    ) {
    )
    {
        $found = false;
        /** @var ActivityOrganization $relation */
        foreach ($this->organizations as $relation) {