Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

167
Visualizações
How to show the dropdown list based on the picklist values

I have an angular application in that I have to show the dropdown list based on the picklist values.

.service.ts

 public getLists() {
    let baseUrl = `/endpoint`;
    this._restfulService
      .restfulGetData(baseUrl)
      
      .subscribe(
        (LookupData: LookupData) => {
          if (LookupData) {
            this.option1data = LookupData.option1Data;
            this.option2data = LookupData.option2Data;
            this.option3data = LookupData.option3Data;
            this.option4data = LookupData.option4Data;
            
 }
        },
        (err) => {
          console.error(err);
        }
      );
  }

.component.html

 <div class="row">
          <div class="form-group">
            <div class="col-sm-3">
              <label for="action"> <b>Category</b></label>
            </div>
            <div class="col-sm-7">
              <select>
               
                <option value="" disabled [selected]="true"></option>
                <option>option1</option>
                <option>option2</option>
                <option>option3</option>
                <option>option4</option>
        </select>
            </div>
          </div>
        </div>

 <div class="row>
          <div class="form-group">
            <div class="col-sm-3>
              <label for="action"> <b>Lists</b></label>
            </div>
            <div class="col-sm-7">
              <select>
               <option value="" disabled [selected]="true"></option>
                <option>
                 
              //In this dropdown I have to show the lists based on the selection of picklists
                </option>
              </select>
            </div>
          </div>
        </div>

So In tha above code if I select option1 from the picklist I have to show the option1Data dropdownlist etc..

can anyone helpme on this

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

<div class="row">
  <div class="form-group">
    <div class="col-sm-3">
      <label for="action"> <b>Lists</b></label>
    </div>
    <div class="col-sm-7">
      <select>
        <option disabled selected="true">Select pick</option>
        <option *ngFor="let items of LookupData" [ngValue]="items.name">
          {{ items.name }}
        </option>
      </select>
    </div>
  </div>
</div>

please put the above code in the HTML file. Hope this code will helpful to you

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda