Page MenuHomePhabricator

[MVVM] Model Insertion Features
Open, TODOPublic

Description

current Model interface only support Add() and there are no way to insert data in specific index.
we need more insertion ways in basic model interface.

  • Append : Insert model child after last child of model index. same as add
  • Prepend : Insert model child before the first child of model index.
  • Insert_At / Before / After : Insert model child before / after given index.
SanghyeonLee triaged this task as TODO priority.
SanghyeonLee added a subscriber: larryolj.

We're in agreement here. Need to add that to model and implement it in all models.

What do you think Eo model should do, since append, prepend and insert_at/before/after can't guarantee the ordering? Should we return an error or insert it in any order?

SanghyeonLee added a comment.EditedOct 24 2018, 10:03 PM

I can't understand the issue cases. which case may not guarantee the ordering?
I think if we cannot guarantee the order that we requested,
we should let the user know the failure of inserting by returning errors and do nothing further.

cedric added a subscriber: cedric.Nov 16 2018, 11:11 AM

I agree with @SanghyeonLee no silent work around solution for users. This create trouble. What is the status of this task ?

@felipealmeida ping, any update on this task?

zmike moved this task from Backlog to Felipe on the efl: mvvm board.