Record Picker not working in Modal

Vikram3
Giga Guru

Hello,

I am creating a widget with Record picker. But it is not showing in modal window. Below is the code.

<div class="panel panel-primary">       
  <div class="panel-heading">       
    <h4 class="panel-title pull-left">       
      ${Watch list}       
    </h4>       
    <div class="clearfix"></div>       
  </div>                   
  <div class="panel-body">
    <form ng-submit="save()">
      <div class="text-center text-italic text-muted">
        <div>
          <sn-record-picker field="watch_list" sn-disabled="!data.canWrite" table="'sys_user'" display-field="'email'" display-fields="'name'" search-fields="'email'" value-field="'sys_id'" default-query="'active=true^web_service_access_only=false^user_nameISNOTEMPTY^emailISNOTEMPTY'" page-size="10" multiple="true"></sn-record-picker>
        </div>
        <div style="margin-top:15px; float: right;">
          <button type="submit" class="btn btn-success btn-sm">${Update}</button>
        </div>
      </div>
    </form>
  </div>
</div>

Below is the screenshot

find_real_file.png

Record picker is showing as a textbox.

1 ACCEPTED SOLUTION

Vikram3
Giga Guru

Thanks for the inputs. This is resolved. Below is the code

find_real_file.png

View solution in original post

12 REPLIES 12

Omkar Mone
Mega Sage

Hi 

This is happening because of multiple=true. When you pass that to record-picker it works as a glidelist where you can select multiple entries. I removed the multiple tag and it worked.

Hi Omkar,

I need multiple entries to be added in watchlist. Is there any other way to get this thing work? Thanks.

Hi Vikram,

I've actually made something similar in the past. It wasn't a modal, but just a widget on the page. Shouldn't be much different. I've attached it here for you.

Thanks Josh. I will try this and let you know. 

Hi Josh,

I just tried your widget. It is the same issue I am facing. Below is the screenshot. Can you please assist me in displaying the widget in Modal.

find_real_file.png