生成容器拖放Angular7

时间:2019-04-10 15:03:58

标签: html angular typescript angular7

我需要能够创建容器以能够拖动项目,以便创建组。

例如,该网站:http://marceljuenemann.github.io/angular-drag-and-drop-lists/demo/#/nested

查找新元素(容器)

<div class="card-top">
  <div class="card-header">
    <span><i class="fas fa-users"></i> GroupUser1</span>
    <div class="card-header-actions save-button">
    <a href="#" class="card-header-action" target="_blank">
    <small class="text-muted"><i class="far fa-check-circle"></i> Save</small>
    </a>
    </div>
  </div>
  <div class="card-body" cdkDropList #pendingList="cdkDropList" [cdkDropListData]="todo" [cdkDropListConnectedTo]="[pendingList2, pendingList3]" (cdkDropListDropped)="drop($event)">
    <div class="grupo-paciente" *ngFor="let item of todo" [cdkDragData]="item" cdkDrag>{{item}}</div>
  </div>
</div>

0 个答案:

没有答案