<commit_before><?php

/*
 * This file is part of the Incipio package.
 *
 * (c) <NAME>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace mgate\SuiviBundle\Entity;

use Doctrine\ORM\Mapping as ORM;
use Gedmo\Mapping\Annotation as Gedmo;
use Symfony\Component\Validator\Constraints as Assert;

/**
 * mgate\SuiviBundle\Entity\Phase.
 *
 * @ORM\Table()
 * @ORM\Entity
 */
class Phase
{
    /**
     * @var int
     *
     * @ORM\Column(name="id", type="integer")
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="AUTO")
     */
    private $id;

    /**
     * Gedmo\SortableGroup.
     *
     * @ORM\ManyToOne(targetEntity="Etude", inversedBy="phases", cascade={"persist"})
     * @ORM\JoinColumn(nullable=true)
     */
    protected $etude;

    /**
     * @ORM\ManyToOne(targetEntity="GroupePhases", inversedBy="phases")
     * @ORM\OrderBy({"numero" = "ASC"})
     */
    private $groupe;

    /**
     * Gedmo\SortablePosition.
     *
     * @ORM\Column(name="position", type="integer", nullable=true)
     * todo enlever le nullable=true
     */
    private $position;

    /**
     * @var int
     *
     * @ORM\Column(name="nbrJEH", type="integer", nullable=true)
     */
    private $nbrJEH;

    /**
     * @var int
     *
     * @ORM\Column(name="prixJEH", type="integer", nullable=true)
     */
    private $prixJEH;

    /**
     * @var string
     *
     * @ORM\Column(name="titre", type="text", nullable=true)
     */
    private $titre;

    /**
     * @var string
     *
     * @ORM\Column(name="objectif", type="text", nullable=true)
     */
    private $objectif;

    /**
     * @var string
     *
     * @ORM\Column(name="methodo", type="text", nullable=true)
     */
    private $methodo;

    /**
     * @var \DateTime
     *
     * @ORM\Column(name="dateDebut", type="datetime", nullable=true)
     */
    private $dateDebut;

    /**
     * @var int
     *
     * @ORM\Column(name="delai", type="integer", nullable=true)
     */
    private $delai;

    /**
     * @var int
     *
     * @ORM\Column(name="validation", type="integer", nullable=true)
     * @Assert\Choice(callback = "getValidationChoiceAssert")
     */
    private $validation;

    /**
     * @ORM\ManyToOne(targetEntity="Av", inversedBy="phases")
     */
    private $avenant;

    /**
     * @var int 0 : modifiée, 1:ajoutée -1 : supprimée
     *
     * @ORM\Column(name="etatSurAvenant", type="integer", nullable=true)
     */
    private $etatSurAvenant;

    /**
     * ADDITIONAL GETTERS/SETTERS.
     */
    public function getMontantHT()
    {
        return $this->nbrJEH * $this->prixJEH;
    }

    public function getDateFin()
    {
        if ($this->dateDebut) {
            $date = clone $this->dateDebut;
            $date->modify('+ '.$this->delai.' day');

            return $date;
        } else {
            return new \DateTime('now');
        }
    }

    public function __construct()
    {
        $this->voteCount = 0;
        $this->createdAt = new \DateTime('now');
        $this->prixJEH = 300;
        $this->validation = 0;
        $this->avenantStatut = 0;
    }

    /**
     * Get id.
     *
     * @return int
     */
    public function getId()
    {
        return $this->id;<commit_msg>Update PrixJEH to 320€<commit_after><?php

/*
 * This file is part of the Incipio package.
 *
 * (c) <NAME>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace mgate\SuiviBundle\Entity;

use Doctrine\ORM\Mapping as ORM;
use Gedmo\Mapping\Annotation as Gedmo;
use Symfony\Component\Validator\Constraints as Assert;

/**
 * mgate\SuiviBundle\Entity\Phase.
 *
 * @ORM\Table()
 * @ORM\Entity
 */
class Phase
{
    /**
     * @var int
     *
     * @ORM\Column(name="id", type="integer")
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="AUTO")
     */
    private $id;

    /**
     * Gedmo\SortableGroup.
     *
     * @ORM\ManyToOne(targetEntity="Etude", inversedBy="phases", cascade={"persist"})
     * @ORM\JoinColumn(nullable=true)
     */
    protected $etude;

    /**
     * @ORM\ManyToOne(targetEntity="GroupePhases", inversedBy="phases")
     * @ORM\OrderBy({"numero" = "ASC"})
     */
    private $groupe;

    /**
     * Gedmo\SortablePosition.
     *
     * @ORM\Column(name="position", type="integer", nullable=true)
     * todo enlever le nullable=true
     */
    private $position;

    /**
     * @var int
     *
     * @ORM\Column(name="nbrJEH", type="integer", nullable=true)
     */
    private $nbrJEH;

    /**
     * @var int
     *
     * @ORM\Column(name="prixJEH", type="integer", nullable=true)
     */
    private $prixJEH;

    /**
     * @var string
     *
     * @ORM\Column(name="titre", type="text", nullable=true)
     */
    private $titre;

    /**
     * @var string
     *
     * @ORM\Column(name="objectif", type="text", nullable=true)
     */
    private $objectif;

    /**
     * @var string
     *
     * @ORM\Column(name="methodo", type="text", nullable=true)
     */
    private $methodo;

    /**
     * @var \DateTime
     *
     * @ORM\Column(name="dateDebut", type="datetime", nullable=true)
     */
    private $dateDebut;

    /**
     * @var int
     *
     * @ORM\Column(name="delai", type="integer", nullable=true)
     */
    private $delai;

    /**
     * @var int
     *
     * @ORM\Column(name="validation", type="integer", nullable=true)
     * @Assert\Choice(callback = "getValidationChoiceAssert")
     */
    private $validation;

    /**
     * @ORM\ManyToOne(targetEntity="Av", inversedBy="phases")
     */
    private $avenant;

    /**
     * @var int 0 : modifiée, 1:ajoutée -1 : supprimée
     *
     * @ORM\Column(name="etatSurAvenant", type="integer", nullable=true)
     */
    private $etatSurAvenant;

    /**
     * ADDITIONAL GETTERS/SETTERS.
     */
    public function getMontantHT()
    {
        return $this->nbrJEH * $this->prixJEH;
    }

    public function getDateFin()
    {
        if ($this->dateDebut) {
            $date = clone $this->dateDebut;
            $date->modify('+ '.$this->delai.' day');

            return $date;
        } else {
            return new \DateTime('now');
        }
    }

    public function __construct()
    {
        $this->voteCount = 0;
        $this->createdAt = new \DateTime('now');
        $this->prixJEH = 320;
        $this->validation = 0;
        $this->avenantStatut = 0;
    }

    /**
     * Get id.
     *
     * @return int
     */
    public function getId()
    {
        return $this->id;
{'fraction_non_alphanumeric': 0.16417910447761194, 'fraction_numerical': 0.003165988240615106, 'mean_word_length': 2.120413922859831, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 29, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '511105', 'n_tokens_mistral': 2337, 'n_tokens_neox': 2247, 'n_words': 406}