# Backend Plugin (ExtJs) Model Felder Name

**URL:** https://forum.shopware.com/t/backend-plugin-extjs-model-felder-name/59830
**Category:** Programmierung
**Created:** [3. Juni 2019 um 08:09 UTC](https://forum.shopware.com/t/backend-plugin-extjs-model-felder-name/59830 "2019-06-03T08:09:44Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![FloC3](https://avatars.discourse-cdn.com/v4/letter/f/838e76/32.png) [@FloC3](https://forum.shopware.com/u/FloC3)
#### Post date: [3. Juni 2019 um 08:09 UTC](https://forum.shopware.com/t/backend-plugin-extjs-model-felder-name/59830/1 "2019-06-03T08:09:44Z")

</div>

Hallo,

ich habe ein Backend Plugin via ExtJS angelegt. In meiner Model-Datei sind ja die&nbsp; Felder angegeben, zB:

```
 fields: [{ name: 'id', type: 'int' }, { name: 'name', type: 'string' }, { name: 'active', type: 'boolean' }]

```

nun werden mir die Felder in der Maske leider auch mit „Name“ und „Active“ angegeben, ich möchte aber gern „Bezeichnung“ und „Aktiv“ anzeigen lassen. Wie krieg ich das hin?

---

<div class="post-metadata">

### Author: ![Patrick\_Stahl](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/patrick_stahl/32/7679_2.png) [@Patrick\_Stahl](https://forum.shopware.com/u/Patrick_Stahl)
#### Post date: [3. Juni 2019 um 08:19 UTC](https://forum.shopware.com/t/backend-plugin-extjs-model-felder-name/59830/2 "2019-06-03T08:19:12Z")

</div>

Moin @FloC3‍,

schau mal [hier](https://developers.shopware.com/developers-guide/backend-components/detail/)&nbsp;unter dem Punkt „Generating forms“.  
Du kannst dein Fieldset inklusive aller darin liegenden Fields selbst definieren und den Feldern entsprechend anzuzeigende Namen mitgeben.

```
configure: function() {
    return {
        controller: 'SwagProductDetail',
        fieldSets: [{
            title: 'Product data',
            fields: {
                name: 'Product name',
                active: { disabled: true }
            }
        }, {
            title: 'Additional data',
            layout: 'fit',
            fields: {
                description: 'Short description',
                descriptionLong: {
                    fieldLabel: null
                }
            }
        }]
    };
}

```

Gruß,  
Patrick&nbsp; ![Shopware](https://forum.shopware.com/plugins/CKEditor/plugins/smiley/images/shopware.png "Shopware")

---

<div class="post-metadata">

### Author: ![FloC3](https://avatars.discourse-cdn.com/v4/letter/f/838e76/32.png) [@FloC3](https://forum.shopware.com/u/FloC3)
#### Post date: [3. Juni 2019 um 08:22 UTC](https://forum.shopware.com/t/backend-plugin-extjs-model-felder-name/59830/3 "2019-06-03T08:22:20Z")

</div>

Hallo Patrick,

Muss das dann irgendwie mit dem Model übereinstimmen? Das geht ja auch dem Entwicklerhandbuch im Beispiel hervor. Die Felder im Fieldset müssen ja irgendwie mit dem Model verbunden sein zwecks Speicherung und Laden.

&nbsp;

viele Grüße

---

<div class="post-metadata">

### Author: ![Patrick\_Stahl](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/patrick_stahl/32/7679_2.png) [@Patrick\_Stahl](https://forum.shopware.com/u/Patrick_Stahl)
#### Post date: [3. Juni 2019 um 08:26 UTC](https://forum.shopware.com/t/backend-plugin-extjs-model-felder-name/59830/4 "2019-06-03T08:26:35Z")

</div>

Moin @FloC3‍,

der Key in dem&nbsp;_fields_&nbsp;Objekt entspricht dem Feld-Namen im Model.

```
fields: {
   description: 'Short description'
}

```

Entsprechend wäre hier ein Model-Feld&nbsp;_description_&nbsp;gemeint.

Gruß,  
Patrick&nbsp; ![Shopware](https://forum.shopware.com/plugins/CKEditor/plugins/smiley/images/shopware.png "Shopware")

---

<div class="post-metadata">

### Author: ![FloC3](https://avatars.discourse-cdn.com/v4/letter/f/838e76/32.png) [@FloC3](https://forum.shopware.com/u/FloC3)
#### Post date: [3. Juni 2019 um 10:07 UTC](https://forum.shopware.com/t/backend-plugin-extjs-model-felder-name/59830/5 "2019-06-03T10:07:01Z")

</div>

[@Patrick Stahl]([http://forum.shopware.com/profile/1869/Patrick](http://forum.shopware.com/profile/1869/Patrick) Stahl “Patrick Stahl”)‍ danke! Eine Frage hab ich aber noch.

Wie bild ich darin denn eine Hersteller-Auswahl und eine Artikelauswahl ab? Es muss eine Mehrfachauswahl sein.

so wie die in den Einkaufswelten

 ![](https://europe1.discourse-cdn.com/flex013/uploads/shopware/original/2X/1/1e2d464f98cd069ea6013f820859e7ebb30db349.png)

---

<div class="post-metadata">

### Author: ![Patrick\_Stahl](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.shopware.com/patrick_stahl/32/7679_2.png) [@Patrick\_Stahl](https://forum.shopware.com/u/Patrick_Stahl)
#### Post date: [3. Juni 2019 um 10:52 UTC](https://forum.shopware.com/t/backend-plugin-extjs-model-felder-name/59830/6 "2019-06-03T10:52:53Z")

</div>

Moin @FloC3‍,

das wird aus den Backend Komponent bei Many to Many Assoziationen genutzt.  
Die Doku dazu findest du [hier](https://developers.shopware.com/developers-guide/backend-components/associations/#manytomany-associations-products-&-categories).

Gruß,  
Patrick&nbsp; ![Shopware](https://europe1.discourse-cdn.com/flex013/uploads/shopware/original/1X/86c57fbace799dd4eb1f1b8a2d3bdc1733f0aea1.png "Shopware")
