Statistiques

Compteur d'affichages des articles
1040044

06 - Modification du fichier administrator/components/com_prestalegals/models/forms/prestalegal.xml

Il faut supprimer les définitions des champs qui ne sont plus utilisés.

		<field
            name="subtitle"
            type="text"
            label="COM_CATS_FIELD_SUBTITLE_LABEL"
			description="COM_CATS_FIELD_SUBTITLE_DESC"
            class="inputbox"
            size="30" />

		<field
            name="snippet"
            type="editor"
            class="inputbox"
			label="COM_CATS_FIELD_SNIPPET_LABEL"
            description="COM_CATS_FIELD_SNIPPET_DESC"
            filter="CatsHelper::filterText"
			buttons="false" />

		<field
            name="fulltext"
            type="editor"
            class="inputbox"
			label="COM_CATS_FIELD_CATTEXT_LABEL"
            description="COM_CATS_FIELD_CATTEXT_DESC"
			filter="CatsHelper::filterText"
            buttons="true" />
    <fields name="custom_fields">

        <fieldset
            name="jfields"
            label="COM_CATS_CUSTOM_FIELDS"
            >

            <field
			    name="imagespacer"
                label="COM_CATS_IMAGE_LABEL"
			    description="COM_CATS_IMAGE_DESC"
			    type="spacer"
			    />

            <field
                name="image1"
                type="media"
                hide_none="1"
                label="COM_CATS_FIELD_IMAGE1_LABEL"
                description="COM_CATS_FIELD_IMAGE1_DESC"
                />

            <field
                name="image1_caption"
                type="text"
                label="COM_CATS_FIELD_IMAGE1_CAPTION_LABEL"
                description="COM_CATS_FIELD_IMAGE1_CAPTION_DESC"
                class="inputbox"
                size="30"
                />

            <field
                name="image1_credit"
                type="text"
                label="COM_CATS_FIELD_IMAGE1_CREDIT_LABEL"
                description="COM_CATS_FIELD_IMAGE1_CREDIT_DESC"
                class="inputbox"
                size="30"
                />

            <field
                name="image2"
                type="media"
                hide_none="2"
                label="COM_CATS_FIELD_IMAGE2_LABEL"
                description="COM_CATS_FIELD_IMAGE2_DESC"
                />

            <field
                name="image2_caption"
                type="text"
                label="COM_CATS_FIELD_IMAGE2_CAPTION_LABEL"
                description="COM_CATS_FIELD_IMAGE2_CAPTION_DESC"
                class="inputbox"
                size="30"
                />

            <field
                name="image2_credit"
                type="text"
                label="COM_CATS_FIELD_IMAGE2_CREDIT_LABEL"
                description="COM_CATS_FIELD_IMAGE2_CREDIT_DESC"
                class="inputbox"
                size="30"
                />

           <field
			    type="spacer"
			    hr="true"
                />

		    <field
			    name="link_label"
			    type="spacer"
                label="COM_CATS_LINK_LABEL"
			    description="COM_CATS_LINK_DESC"
                />

            <field
                name="link1"
                type="url"
                label="COM_CATS_FIELD_LINK1_LABEL"
                description="COM_CATS_FIELD_LINK1_DESC"
                class="inputbox"
                size="30"
                />

            <field
                name="link1_text"
                type="text"
                label="COM_CATS_FIELD_LINK1_NAME_LABEL"
                description="COM_CATS_FIELD_LINK1_NAME_DESC"
                class="inputbox"
                size="30"
            />

            <field
                name="link2"
                type="url"
                label="COM_CATS_FIELD_LINK2_LABEL"
                description="COM_CATS_FIELD_LINK2_DESC"
                class="inputbox"
                size="30"
                />

            <field
                name="link2_text"
                type="text"
                label="COM_CATS_FIELD_LINK2_NAME_LABEL"
                description="COM_CATS_FIELD_LINK2_NAME_DESC"
                class="inputbox"
                size="30"
            />

            <field
                name="link3"
                type="url"
                label="COM_CATS_FIELD_LINK3_LABEL"
                description="COM_CATS_FIELD_LINK3_DESC"
                class="inputbox"
                size="30"
                />

            <field
                name="link3_text"
                type="text"
                label="COM_CATS_FIELD_LINK3_NAME_LABEL"
                description="COM_CATS_FIELD_LINK3_NAME_DESC"
                class="inputbox"
                size="30"
            />

           <field
			    type="spacer"
			    hr="true"
                />

		    <field
			    name="video_label"
			    type="spacer"
                label="COM_CATS_VIDEO_LABEL"
			    description="COM_CATS_VIDEO_DESC"
                />

            <field
                name="video1"
                type="url"
                label="COM_CATS_FIELD_VIDEO1_LABEL"
                description="COM_CATS_FIELD_VIDEO1_DESC"
                class="inputbox"
                size="30"
                />

            <field
                name="video1_text"
                type="text"
                label="COM_CATS_FIELD_VIDEO1_NAME_LABEL"
                description="COM_CATS_FIELD_VIDEO1_NAME_DESC"
                class="inputbox"
                size="30"
            />

        </fieldset>
	</fields>

Puis ajouter les définitions des nouveaux champs.

            <field
                name="company_status"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_COMPANY_STATUS_LABEL"
                description="COM_PRESTALEGALS_FIELD_COMPANY_STATUS_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_name"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_COMPANY_NAME_LABEL"
                description="COM_PRESTALEGALS_FIELD_COMPANY_NAMES_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_director"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_COMPANY_DIRECTOR_LABEL"
                description="COM_PRESTALEGALS_FIELD_COMPANY_DIRECTOR_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_address"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_CONTACT_ADRESS_LABEL"
                description="COM_PRESTALEGALS_FIELD_CONTACT_ADRESS_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_address_complement"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_CONTACT_ADRESS_COMPLEMENT_LABEL"
                description="COM_PRESTALEGALS_FIELD_CONTACT_ADRESS_COMPLEMENT_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_postbox"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_CONTACT_POSTBOX_LABEL"
                description="COM_PRESTALEGALS_FIELD_CONTACT_POSTBOX_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_postcode"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_CONTACT_POSTCODE_LABEL"
                description="COM_PRESTALEGALS_FIELD_CONTACT_POSTCODE_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_town"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_CONTACT_TOWN_LABEL"
                description="COM_PRESTALEGALS_FIELD_CONTACT_TOWN_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_state"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_CONTACT_STATE_LABEL"
                description="COM_PRESTALEGALS_FIELD_CONTACT_STATE_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_country"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_CONTACT_COUNTRY_LABEL"
                description="COM_PRESTALEGALS_FIELD_CONTACT_COUNTRY_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_phone"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_CONTACT_PHONE_LABEL"
                description="COM_PRESTALEGALS_FIELD_CONTACT_PHONE_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_fax"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_CONTACT_FAX_LABEL"
                description="COM_PRESTALEGALS_FIELD_CONTACT_FAX_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_mobile"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_CONTACT_MOBILE_LABEL"
                description="COM_PRESTALEGALS_FIELD_CONTACT_MOBILE_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_email"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_CONTACT_EMAIL_LABEL"
                description="COM_PRESTALEGALS_FIELD_CONTACT_EMAIL_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_url"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_CONTACT_URL_LABEL"
                description="COM_PRESTALEGALS_FIELD_CONTACT_URL_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_siren"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_COMPANY_SIREN_LABEL"
                description="COM_PRESTALEGALS_FIELD_COMPANY_SIREN_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_siret"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_COMPANY_SIRET_LABEL"
                description="COM_PRESTALEGALS_FIELD_COMPANY_SIRET_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_ape"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_COMPANY_APE_LABEL"
                description="COM_PRESTALEGALS_FIELD_COMPANY_APE_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_tva"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_COMPANY_TVA_LABEL"
                description="COM_PRESTALEGALS_FIELD_COMPANY_TVA_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_capital"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_COMPANY_CAPITAL_LABEL"
                description="COM_PRESTALEGALS_FIELD_COMPANY_CAPITAL_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="company_cnil"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_COMPANY_CNIL_LABEL"
                description="COM_PRESTALEGALS_FIELD_COMPANY_CNIL_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />

            <field
                name="editor_name"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_EDITOR_NAME_LABEL"
                description="COM_PRESTALEGALS_FIELD_EDITOR_NAME_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="editor_address"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_EDITOR_ADRESS_LABEL"
                description="COM_PRESTALEGALS_FIELD_EDITOR_ADRESS_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="editor_address_complement"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_EDITOR_ADRESS_COMPLEMENT_LABEL"
                description="COM_PRESTALEGALS_FIELD_EDITOR_ADRESS_COMPLEMENT_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="editor_postbox"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_EDITOR_POSTBOX_LABEL"
                description="COM_PRESTALEGALS_FIELD_EDITOR_POSTBOX_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="editor_postcode"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_EDITOR_POSTCODE_LABEL"
                description="COM_PRESTALEGALS_FIELD_EDITOR_POSTCODE_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="editor_city"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_EDITOR_CITY_LABEL"
                description="COM_PRESTALEGALS_FIELD_EDITOR_CITY_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="editor_country"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_EDITOR_COUNTRY_LABEL"
                description="COM_PRESTALEGALS_FIELD_EDITOR_COUNTRY_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="editor_email"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_EDITOR_EMAIL_LABEL"
                description="COM_PRESTALEGALS_FIELD_EDITOR_EMAIL_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="editor_phone"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_EDITOR_PHONE_LABEL"
                description="COM_PRESTALEGALS_FIELD_EDITOR_PHONE_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="editor_fax"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_EDITOR_FAX_LABEL"
                description="COM_PRESTALEGALS_FIELD_EDITOR_FAX_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="editor_url"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_EDITOR_URL_LABEL"
                description="COM_PRESTALEGALS_FIELD_EDITOR_URL_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />


            <field
                name="host_name"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_HOST_NAME_LABEL"
                description="COM_PRESTALEGALS_FIELD_HOST_NAME_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="host_address"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_HOST_ADRESS_LABEL"
                description="COM_PRESTALEGALS_FIELD_HOST_ADRESS_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="host_address_complement"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_HOST_ADRESS_COMPLEMENT_LABEL"
                description="COM_PRESTALEGALS_FIELD_HOST_ADRESS_COMPLEMENT_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="host_postbox"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_HOST_POSTBOX_LABEL"
                description="COM_PRESTALEGALS_FIELD_HOST_POSTBOX_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="host_postcode"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_HOST_POSTCODE_LABEL"
                description="COM_PRESTALEGALS_FIELD_HOST_POSTCODE_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="host_city"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_HOST_CITY_LABEL"
                description="COM_PRESTALEGALS_FIELD_HOST_CITY_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="host_country"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_HOST_COUNTRY_LABEL"
                description="COM_PRESTALEGALS_FIELD_HOST_COUNTRY_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="host_email"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_HOST_EMAIL_LABEL"
                description="COM_PRESTALEGALS_FIELD_HOST_EMAIL_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="host_phone"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_HOST_PHONE_LABEL"
                description="COM_PRESTALEGALS_FIELD_HOST_PHONE_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="host_fax"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_HOST_FAX_LABEL"
                description="COM_PRESTALEGALS_FIELD_HOST_FAX_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />
            <field
                name="host_url"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_HOST_URL_LABEL"
                description="COM_PRESTALEGALS_FIELD_HOST_URL_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />

            <field
                name="bank_name"
                type="texte"
                label="COM_PRESTALEGALS_FIELD_BANK_NAME_LABEL"
                description="COM_PRESTALEGALS_FIELD_BANK_NAME_DESC"
                extension="com_prestalegals"
                view="prestalegal"
                useglobal="true"
            />

            <field
                name="use_terms"
                type="editor"
				class="inputbox"
                label="COM_PRESTALEGALS_FIELD_USETERMS_CONTENT_LABEL"
                description="COM_PRESTALEGALS_FIELD_USETERMS_CONTENT_DESC"
				filter="JComponentHelper::filterText" 
				buttons="true" 
				/>
            <field
                name="use_policy"
                type="editor"
 				class="inputbox"
				label="COM_PRESTALEGALS_FIELD_POLICY_CONTENT_LABEL"
                description="COM_PRESTALEGALS_FIELD_POLICY_CONTENT_DESC"
				filter="JComponentHelper::filterText" 
				buttons="true" 
            />
            <field
                name="use_delivery"
                type="editor"
 				class="inputbox"
				label="COM_PRESTALEGALS_FIELD_DELIVERY_CONTENT_LABEL"
                description="COM_PRESTALEGALS_FIELD_DELIVERY_CONTENT_DESC"
				filter="JComponentHelper::filterText" 
				buttons="true" 
            />

07 - Modifications des fichiers de langue

Vous devez créer les fichiers pour le français. Il ne faut pas oublier de supprimer dans les 2 langues les définitions qui ne sont plus nécessaires et de créer les définitions pour les nouveaux champs.

 

Suite au prochain article.