Comments

dasjo’s picture

Assigned: dasjo » Unassigned
Issue summary: View changes
Status: Active » Needs work
dasjo’s picture

dasjo’s picture

dermario’s picture

I did some progress here.

https://github.com/scuts/rules/commits/admin_ui

The following features are implemented now:

  • The rules collection (listing) is accessible via admin/config in the "workflow" - section.
  • The rules collection has 2 operation-links now: "edit" & "delete"
  • The rules collection has a "add a new rules component" link
  • Rules components can be Created, Edited and Deleted

This is a very basic implementation. In fact its my first try to work with d8 - entities. As fubhy mentioned in IRC he wanted to create a common ui - branch.

dasjo’s picture

As discussed with fago, for this patch we should
- add tabs "Reaction Rules", "Rules components"
- Reaction Rules don't need to be implemented yet (can be greyed out/disabled), as we don't have events
- make sure that paths make sense. i would suggest /rules to list the reaction rules but as we don't implement them yet, we could display /rules/components by default
- add validation, currently adding the same Rules component just fails with an exception
- make sure that breadcrumbs are properly in place
- after adding a component, currently you remain on the add dialog. we should return to the components list instead.

dasjo’s picture

Issue tags: +drupaldevdays
ndf’s picture

Assigned: Unassigned » ndf
Status: Needs work » Active

Gonna work on this one this afternoon.

ndf’s picture

Talked with klausi and dasjo. Baseline with routers and stubs for rules-reactions are there and pushed.

Couple of things todo before pull-request:
- Define access permissions
- Find a way to supplement MENU_DEFAULT_LOCAL_TASK
This should be done tomorrow.

After that we probably want to separate the admin interface to a 'rules_ui' sub-module.

dasjo’s picture

Title: Create a Rules Component admin ui » Create a Rules UI skeleton & allow to manage components
ndf’s picture

ndf’s picture

Rules UI (rules_ui) : 'Administration interface for Rules.' is now a submodule in Rules.

dasjo’s picture

ndf’s picture

Assigned: ndf » Unassigned
Status: Active » Needs review
StatusFileSize
new196.22 KB

PR: https://github.com/fago/rules/pull/163

has:
- permissions
- overview page so crumbs, tabs are handled well. This page uses systemAdminMenuBlockPage and renders all menu-items one level deeper
- crud for components (was my starting-point, thank scuts)
- stub for settings page

Permissions are implemented in Rules
All other things are implemented in submodule Rules UI

dasjo’s picture

Cool stuff! I have tested it a bit and works really nice. Tabs & breadcrumbs make sense.

These component edit form related tasks haven't been addressed. Let's create a follow-up branch for them.

- add validation, currently adding the same Rules component just fails with an exception
- after adding a component, currently you remain on the add dialog. we should return to the components list instead.

Leaving it on needs review for code review.

fago’s picture

Status: Needs review » Needs work

Thanks - that's already a great start! Reviewed it and mostly commented on output strings - please work them in.

ndf’s picture

Thanks for reviewing. I'll follow up this afternoon.

ndf’s picture

Assigned: Unassigned » ndf

Thanks for reviewing. I'll follow up this afternoon.

ndf’s picture

Assigned: ndf » Unassigned
Status: Needs work » Needs review

PR https://github.com/fago/rules/pull/163

Fixed fago's comments, except

We actually have multiple tags. I think that's broken right now, but let's do already a proper method names -> getTags() which returns string[].

Don't know howto do this.
Klausi commented on protected $tag (in class RulesComponent line ~70)

  /**
   * The "tags" of a Rules component.
   *
   * The tags are stored as a single string, though it is used as multiple tags
   * for example in the rules overview.
   *
   * @var string
   */
  protected $tag = '';

Prefer to move to follow up ticket.

fago’s picture

Sounds good. Let's create an ticket for it then and link in the code. Also the code should add an @todo.

  • a384e4c committed on 8.x-3.x
    Issue #2409239 by nielsdefeyter, scuts, dermario: Create a Rules UI...
fago’s picture

Status: Needs review » Fixed

Thanks, merged live during drupal dev days d8rules session.!

Status: Fixed » Closed (fixed)

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