Added requested tag.
Details
Details
- Reviewers
alex - Commits
- rINP16530: Fixes INP-1547 - Create "promo-block:ImageField" tag
- login to Admin Console
- go to Configuration → Website → Regional section
- create second language
- go to Tools → Query Database section
- run SQL like ALTER TABLE inp_PromoBlocks ADD l1_SecondImage VARCHAR(255) NOT NULL DEFAULT "", ADD l2_SecondImage VARCHAR(255) NOT NULL DEFAULT "" (replace inp_ with your table prefix)
- add test code line $fields['l' . $lang_id . '_SecondImage'] = $a_image; to promo-block:OnAfterConfigRead event after "$fields['l' . $lang_id . '_Image'] = $a_image;" line
- add test code <inp2:promo-block_ImageField/><br /><inp2:promo-block_ImageField name='SecondImage'/> to promo_blocks/promo_block_edit template
- add test code line <inp2:m_RenderElement name="inp_edit_swf_upload" caption_render_as="multilang_field_caption_element" prefix="promo-block" field="l{$langId}_SecondImage" title="la_fld_SecondImage"/> to promo_blocks/promo_block_edit template after <inp2:m_RenderElement name="inp_edit_swf_upload" caption_render_as="multilang_field_caption_element" prefix="promo-block" field="l{$langId}_Image" title="la_fld_Image"/> line
- go to Website & Content → Promo Blocks → Default Group section
- add promo block with primary language images only
- open just added promo block on edit
- confirm that file names, displayed by test tags, are related to primary language
- select another language in the top right corner of the promo block edit form
- confirm that file names, displayed by test tags, are related to primary language
- add images for secondary language and save
- open just edited promo block on edit
- confirm that file names, displayed by test tags, are related to currently selected language
- select another language in the top right corner of the promo block edit form
- confirm that form refreshes and file names, displayed by test tags, are related to just selected language
Diff Detail
Diff Detail
- Repository
- rINP In-Portal
- Branch
- /in-portal/branches/5.3.x
- Lint
Lint OK - Unit
No Unit Test Coverage - Build Status
Buildable 355 Build 355: arc lint + arc unit
Event Timeline
core/units/promo_blocks/promo_block_tp.php | ||
---|---|---|
103–105 | This code isn't covered by test plan at all. To test it you actually need to:
| |
114–120 | This, according to plan from task, should:
Such behavior is also not covered by test plan, where currently image on all languages is uploaded. |