chamilo/chamilo-lms

View on GitHub
src/CoreBundle/Entity/TrackEAttempt.php

Summary

Maintainability
A
0 mins
Test Coverage

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\OneToMany(

Missing class doc comment
Open

class TrackEAttempt

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'marks', type: 'float', precision: 6, scale: 2, nullable: false)]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'seconds_spent', type: 'integer')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\OneToMany(

Add a single space around assignment operators
Open

declare(strict_types=1);

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'id', type: 'integer')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[Assert\NotNull]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[Groups(['track_e_attempt:read'])]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'answer', type: 'text', nullable: false)]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[Assert\NotBlank]

Missing function doc comment
Open

    public function getId(): ?int

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\GeneratedValue(strategy: 'IDENTITY')]

Missing function doc comment
Open

    public function setQuestionId(int $questionId): self

Missing function doc comment
Open

    public function setFilename(string $filename): static

Missing function doc comment
Open

    public function setSecondsSpent(int $secondsSpent): self

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'filename', type: 'string', length: 255, nullable: true)]

Missing function doc comment
Open

    public function setPosition(int $position): self

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[ORM\Index(columns: ['question_id'], name: 'question_id')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[ORM\Entity]

Missing function doc comment
Open

    public function getSecondsSpent(): int

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Id]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\ManyToOne(targetEntity: TrackEExercise::class, cascade: ['persist'], inversedBy: 'attempts')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[Groups(['track_e_attempt:read'])]

Missing function doc comment
Open

    public function __construct()

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\ManyToOne(targetEntity: User::class, inversedBy: 'trackEAttempts')]

Missing function doc comment
Open

    public function setUser(User $user): self

Missing function doc comment
Open

    public function getTrackEExercise(): TrackEExercise

Missing function doc comment
Open

    public function addAttemptFeedback(AttemptFeedback $attemptFeedback): self

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\JoinColumn(name: 'user_id', referencedColumnName: 'id', onDelete: 'CASCADE')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'position', type: 'integer', nullable: true)]

Missing function doc comment
Open

    public function getQuestionId(): ?int

Missing function doc comment
Open

    public function getMarks(): float

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[ORM\Index(columns: ['exe_id'], name: 'exe_id')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[ORM\Index(columns: ['tms'], name: 'idx_track_e_attempt_tms')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[ApiFilter(

Missing function doc comment
Open

    public function getAnswer(): string

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[ORM\Index(columns: ['user_id'], name: 'user_id')]

Missing function doc comment
Open

    public function setAnswer(string $answer): self

Missing function doc comment
Open

    public function getTeacherComment(): string

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[Assert\NotNull]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[ApiResource(

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[Assert\NotNull]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'question_id', type: 'integer', nullable: false)]

Missing function doc comment
Open

    public function getTms(): DateTime

Missing function doc comment
Open

    public function setTrackEExercise(TrackEExercise $trackExercise): self

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

#[ORM\Table(name: 'track_e_attempt')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[Groups(['track_e_attempt:read'])]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\JoinColumn(name: 'exe_id', referencedColumnName: 'exe_id', nullable: false, onDelete: 'CASCADE')]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[Groups(['track_e_attempt:read'])]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'teacher_comment', type: 'text', nullable: false)]

Perl-style comments are not allowed. Use "// Comment." or "/* comment */" instead.
Open

    #[ORM\Column(name: 'tms', type: 'datetime', nullable: false)]

Scope keyword "static" must be followed by a single space
Open

    public function setFilename(string $filename): static

Missing function doc comment
Open

    public function getUser(): User

Missing function doc comment
Open

    public function setMarks(float $marks): self

Missing function doc comment
Open

    public function setTms(DateTime $tms): self

Missing function doc comment
Open

    public function getFilename(): ?string

Missing function doc comment
Open

    public function setTeacherComment(string $teacherComment): self

Missing function doc comment
Open

    public function getPosition(): ?int

Missing function doc comment
Open

    public function addAttemptFile(AttemptFile $attemptFile): self

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->marks;

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 4 spaces, found 0
Open

)]

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected ?int $id = null;

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected string $answer;

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected DateTime $tms;

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function setQuestionId(int $questionId): self

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    use UserTrait;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->attemptFeedbacks = new ArrayCollection();

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getQuestionId(): ?int

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function setFilename(string $filename): static

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 16 spaces, found 12
Open

            $this->attemptFeedbacks[] = $attemptFeedback;

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected User $user;

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected Collection $attemptFiles;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->attemptFiles = new ArrayCollection();

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getTrackEExercise(): TrackEExercise

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->attemptFeedbacks;

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected Collection $attemptFeedbacks;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->secondsSpent = 0;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->questionId = $questionId;

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getAnswer(): string

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function setUser(User $user): self

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected ?int $position = null;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->marks = $marks;

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function setSecondsSpent(int $secondsSpent): self

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    )]

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->questionId;

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected ?string $filename = null;

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->filename = $filename;

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getMarks(): float

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->position;

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->trackExercise = $trackExercise;

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getAttemptFiles(): Collection

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->answer;

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getSecondsSpent(): int

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 4 spaces, found 0
Open

)]

Line indented incorrectly; expected 4 spaces, found 0
Open

class TrackEAttempt

Line indented incorrectly; expected at least 4 spaces, found 0
Open

{

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected TrackEExercise $trackExercise;

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected ?int $questionId = null;

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected float $marks;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->teacherComment;

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function __construct()

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->teacherComment = $teacherComment;

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->filename;

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function setAttemptFiles(Collection $attemptFiles): self

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getAttemptFeedbacks(): Collection

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->secondsSpent = $secondsSpent;

Line indented incorrectly; expected 12 spaces, found 8
Open

        if (!$this->attemptFeedbacks->contains($attemptFeedback)) {

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function addAttemptFile(AttemptFile $attemptFile): self

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->attemptFeedbacks = $attemptFeedbacks;

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected string $teacherComment;

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getTeacherComment(): string

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 16 spaces, found 12
Open

            $this->attemptFiles[] = $attemptFile;

Line indented incorrectly; expected 8 spaces, found 4
Open

    protected int $secondsSpent;

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    )]

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->teacherComment = '';

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function setTeacherComment(string $teacherComment): self

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function setTms(DateTime $tms): self

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getId(): ?int

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->secondsSpent;

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function setAttemptFeedbacks(Collection $attemptFeedbacks): self

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->answer = $answer;

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function setMarks(float $marks): self

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->tms;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->trackExercise;

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function addAttemptFeedback(AttemptFeedback $attemptFeedback): self

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getFilename(): ?string

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function setTrackEExercise(TrackEExercise $trackExercise): self

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected 12 spaces, found 8
Open

        if (!$this->attemptFiles->contains($attemptFile)) {

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function setPosition(int $position): self

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->position = $position;

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getTms(): DateTime

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->tms = $tms;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->id;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->user;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->user = $user;

Line indented incorrectly; expected at least 16 spaces, found 12
Open

            $attemptFeedback->setAttempt($this);

Line indented incorrectly; expected 12 spaces, found 8
Open

        }

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getUser(): User

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        $this->attemptFiles = $attemptFiles;

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 12 spaces, found 8
Open

        }

Line indented incorrectly; expected at least 16 spaces, found 12
Open

            $attemptFile->setAttempt($this);

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function setAnswer(string $answer): self

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected 8 spaces, found 4
Open

    public function getPosition(): ?int

Line indented incorrectly; expected at least 8 spaces, found 4
Open

    {

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this->attemptFiles;

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

Line indented incorrectly; expected 8 spaces, found 4
Open

    }

Line indented incorrectly; expected 4 spaces, found 0
Open

}

Line indented incorrectly; expected at least 12 spaces, found 8
Open

        return $this;

There are no issues that match your filters.

Category
Status