Problem/Motivation

We have an interface for LocalTask but we don't have one for LocalTaskItem yet, so we have to add it.
Also like in this issue #2650778: Fix and cleanup of LocalTaskInterface of LocalTask, let's move the move the task item constants definitions from tmgmt_local.module to this interface.
And do a general clean up in LocalTaskItem.

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

CommentFileSizeAuthor
#4 add-2650786-4.patch39.48 KBedurenye

Comments

edurenye created an issue. See original summary.

miro_dietiker’s picture

After closing the parent Drupal 8 port issue with the initial commit, we now have it completed, but still followups created that are open now...
That's somehow inconsistent in issue management.

berdir’s picture

They're follow-ups, not child issues I'd say. Problem solved ;)

edurenye’s picture

Status: Active » Needs review
StatusFileSize
new39.48 KB

Added the Interface, moved the constants to this interface and general clean up.

miro_dietiker’s picture

  1. +++ /dev/null
    @@ -1,519 +0,0 @@
    -function tmgmt_local_task_form($form, FormStateInterface $form_state, LocalTask $task, $op = 'edit') {
    -function tmgmt_local_task_form_submit($form, FormStateInterface $form_state) {
    -function tmgmt_local_task_item_view(LocalTaskItem $item) {
    -function tmgmt_local_translation_assign_to_me(TMGMTLocalTask $task) {
    -function tmgmt_local_translation_form($form, FormStateInterface $form_state, TMGMTLocalTaskItem $task_item) {
    -function tmgmt_local_translation_form_save_as_completed_validate($form, FormStateInterface $form_state) {
    -function tmgmt_local_translation_form_save_as_completed_submit($form, FormStateInterface $form_state) {
    -function tmgmt_local_translation_form_save_submit($form, FormStateInterface $form_state) {
    -function tmgmt_local_translation_form_element($data, LocalTaskItem $item, &$zebra) {
    -function tmgmt_local_translation_form_update_state_submit($form, FormStateInterface $form_state) {
    -function tmgmt_local_translation_form_update_state_ajax($form, FormStateInterface $form_state) {
    -function tmgmt_local_translation_assign_form($form, FormStateInterface $form_state, $tasks) {
    -function tmgmt_local_translation_assign_form_submit($form, FormStateInterface $form_state) {
    -function tmgmt_local_translation_reassign_form($form, FormStateInterface $form_state, $tasks) {
    -function tmgmt_local_translation_reassign_form_submit($form, FormStateInterface $form_state) {
    
    +++ /dev/null
    @@ -1,57 +0,0 @@
    -function theme_tmgmt_local_translation_form($variables) {
    -function theme_tmgmt_local_translation_form_element($variables) {
    

    So much stuff dropped? :-) :-7

  2. +++ b/translators/tmgmt_local/src/Entity/LocalTaskItem.php
    @@ -325,35 +276,31 @@ class LocalTaskItem extends ContentEntityBase implements EntityChangedInterface
    -      $this->count_pending = 0;
    ...
    -      $this->count_reviewed = 0;
    
    +++ b/translators/tmgmt_local/src/LocalTaskItemInterface.php
    @@ -0,0 +1,166 @@
    +   * Array of translations.
    

    Why are those skipped now?

miro_dietiker’s picture

Status: Needs review » Fixed

Ah, stale files deleted...
Usually should go into a separate issue to avoid mixing real code changes and unrelated cleanup.

Still committed with some small comment cleanups after some testing.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.