19 Posts
web2e
9 years ago
Topic

Hello, 

my application is based on two contenttype: 

1) Teachers 

2) Workshops 

In the "Workshops" 

I have the fields: 

- Article Language (Type: content language) 

- Teacher (Type Article (Related)) 

I would like when I switch the language (Article Language), the select "Teacher" reload the values of specific language. 

For this reason, I bought "Select Dynamic Cascade Field Plug-in" - http://www.seblod.com/products/2997, 

but I don't understand how I have to set the field. 

Can you help me to understand if "Select Dynamic Cascade Field Plug-in" is ok for this task or If better another way ? 

----------------------------------------------------------------

Buogiorno,

la mia applicazione si basa su 2 content type:

1) Teachers

2) Workshops

Nel content type "Workshops" ho i seguenti campi:

- Article Language (Type: content language)

- Teacher (Type Article (Related)) 

Vorrei che quando si cambia la lingua nel admin form - campo (Article Language), nella select "Teacher" (campo related) siano visualizzati solo i content della specifica lingua.

Ho quindi comprato il plugin "Select Dynamic Cascade Field Plug-in", ma non capisco come devo impostare il form,

potreste suggerirmi se posso, dopo il cambio della lingua nel form, ricaricare nelle select (Article - related) solo i contenuti della lingua selezionata ?

---------------------------------------------------------------

Thank you 

Enrico

Get a Book for SEBLOD
19 Posts
web2e
9 years ago
6
Level 1

Hi,

I have find a solution.

1) I create a field "Language"  (type : Select - Dynamic Cascade) with:

   Query: construction

   Behavior: start

   Group identifier: lang

   Table: #__languages

   Option name: lang_code

   Option value: lang_code 

and storage:  Standard - Article - language

and so I save the value in #__content table in the same field language of joomla base.

then

2) I create a second field "Teacher" (type : Select - Dynamic Cascade) with:

   Query: construction

Behavior: end

Group identifier: lang  (the same of 1)

Table: #__content

Option name: title

Option value: id

Where:  catid in (39,66)  -> where 39 is a teacher english category and 66 is teacher italian category

Parent: language

and storage: Standard - Article - teacher, in this case is created a new field in the custom table.


In this way, when I switch the language in the first select (language), the values of the second select (teacher) are reload with the correct language.

By

Enrico



19 Posts
web2e
9 years ago
5
Level 2

Hi, 

in my previous answer, I understand how to reload only one "select" (teacher), when I change the language (Language - select) using "Select - Dynamic Cascade", 

but, is it possible, to reload more "select" at the same time ?

for example: 

1) Language  - Select (select "language", in my case English and Italian) 

2) Teacher 1  - Select (first teacher) 

3) Teacher 2  - Select (second teacher) 

4) Room Select  - (the place where is the workshop) 

and so, I would like, when I change 1) Language value, 

reload all the "select" 2), 3), 4) with the contents of specific language. 

Can you give me what I have to study for this ?

Thank you

Enrico

154 Posts
WebOne
9 years ago
4
Level 3

Have you looked at this - hide/show fields depending on language.

www.seblod.com/products/10869

19 Posts
web2e
9 years ago
3
Level 4

Hi WebOne, thank you for your answer. 

I tried the "Joomla! Language" plugin, 

this is my process: 

1) I added tre fields in the "Workshop" content type 

- Article Language (JForm Content) 

- PeopleIT (Joomla!Article) 

- PeopleEN (JForm!Article) 

For PeopleIT I set (4 - Restriction): Language -> IT 

and PeopleEN I set (4 - Restriction): Language -> EN 


Then I created a new Workshop content, clearly in the form, the (1) Language select is not yet set. 

In this case, I am login in the admin with English language and so I see (2) the Teacher En select.


Now, I change the Language, but the Teacher remains always English, and this is a problem.

I would like, for example, if I switch the language field(1) to Italian, the Teacher En field (2) should be hide and should be show Italian select ...

For this reason, I think this plugin for my requirement is not ok.

Do you think about this ?

Thankyou 

9 years ago
2
Level 5

Hi,

In the form if you wish to display some fields in regards of the language selected you need to used conditional fields (read manual). Another solution is to have some language tabs (English, French...) which one with fields related to the language.

Thanks.

19 Posts
web2e
9 years ago
1
Level 6

Hi Bes, thank you

now, I'll read your link and then I'll post here my result 

Enrico

19 Posts
web2e
9 years ago
0
Level 7

The "Condition State" is perfect to solve the problem of this topics.

thank you to Bes 

Get a VIP membership