How to trigger copy function to display a drawer with the parent values on the drawer after save on sidecar ?

What I am trying here is to replicate  copy function that run from the click on copy. is that possible ?

  • Fullscreen
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    //
    var self = this,
    prefill = app.data.createBean(this.model.module);
    prefill.copy(this.model);
    app.drawer.open({
    layout: 'create',
    context : {
    module: '',
    lockedFieldsWarning: false ,
    action: 'edit',
    model: prefill
    }
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    Rodrigo Manara

    Sr. Developer