Coder Social home page Coder Social logo

akeneo-e3's People

Contributors

a-ast avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Forkers

a-ast

akeneo-e3's Issues

Refactor extractors

  • find better API for extractor construction
  • implement Query to unify access to conditions
  • implement common methods - work with Query

[TD] Rework PersistGroupRepository

  • Inroduce an interface like ParentAwareReppsitory or SubitemRepository or ComplexRepository or ParentChild or
    with the method getParentFields(): array like family_cdoe for family options

  • replace PersistRepository::$groupFieldNames with that

  • Consider renaming x_code to x because it is how already used in Akeneo, see attribute field in the option API

  • [] RepositoryFactory::createWriteRepository - wrap API automatically base on its supported interfaces

Order reference entities by duplicating records

Problem

Duplicating ref.entity colours must happen after duplicating main colours otherwise it fails on finding main colours.

Possible solution

Try to order entities by their deps first which might be a hard task.

Workaround

Duplicate entities one-by-one: first main colours, then colours.

Implement an `add` action

See Akeneo Rules add.
This action adds new items to arrays, like categories or multi-selects.

Create a doc example for add attribute to a family, link it to a main page if needed.

Implement `apply_if` action property

Actions will be more powerful if we add additional condition

actions:
    -
        type: set
        field: name
        locale: en_GB
        scope: null
        expression: 'trim(value("name", null, "en_GB"))'
        apply_if: 'hasValue("name", null, "en_GB"))'

apply_if is an expression.
Action is applied only if apply_if is evaluated as true.

What Action::execute() should return

Problem

At the moment it returns an array that contain a data patch.

Using arrays - not good approach. Value array, patch - not clear terminology.

Ideas

Option 1. Return patch resource

public function  execute(Resource $resource): ?Resource

As same concept as now, but returns an object.

Pro:

  1. Similar approach.
  2. Can be used in loader as Resource - so it allows to get rid of arrays also there.

Con:

  1. Patch - the concept is still not 100% clear.

Option 2. Return void, all changes inside the $resource.

public function  execute(Resource $resource): void

Pro:

  1. Resource changed by ref.
  2. CopyAll (migration) doesn't need any actions - it is just same object as in the beginning, so patch will be an empty array.

Con:

  1. It needs another approach for creating patches for loader - perhaps as array_diff between initial and result of transformations.

How to make a decision

  1. Find examples

Refactor loaders

  • Extract common part of all loaders
  • Return Response/LoadResult list directly from implementations
  • Implement ResourceCollection to replace loader buffer and add meaningful methods like getResourceType(), get('reference_entity_code')

Rebrand, change profile and command options

Akeneo users are familiar with the concepts of the Rules Engine.
In order to make the tool more understandable for them, it is better to use same terms and same config.

Additionally, change --etl-profile to --rules-profile (or profile or rules)?

Rename main command from transform to "run-rules" or "run"?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.