all done by plan - replaced tmp ids
Details
Details
Preparations - make following changes in system files:
- in the /core/units/reviews/reviews_config.php file change ReviewText field declaration in Fields array into:
'type' => 'string', 'default' => null, 'required' => 1, 'formatter' => 'kUploadFormatter', 'file_types' => '*.*', 'upload_dir' => WRITEBALE_BASE . '/reviews/',
- in the /modules/in-commerce/admin_templates/products/review_edit.tpl file:
- change form control for ReviewText field into inp_edit_swf_upload
- and add swf-upload javascript:
<script src="js/swfobject.js" type="text/javascript"></script> <script type="text/javascript" src="<inp2:m_Compress files='js/uploader/upload_manager.js|js/uploader/uploader.js'/>"></script>
Testing
- login into Admin Console as root user
- go to Website & Content → Products section
- open new tangible product creation window
- fill-in required fields on General tab
- go to the Comments tab
- add a new comment
- confirm, that uploaded file, which filename is shown in Comment column has .tmp extension (not a bug, because <inp2:Field name="$field" format='display_name'/> tag should be used for displaying uploaded filename)
- save product
- open created product for editing
- go to Comments tab
- confirm, that Comment value in the Comments grid no longer have .tmp extension
Diff Detail
Diff Detail
- Repository
- rINP In-Portal
- Branch
- /in-portal/branches/5.2.x
- Lint
Lint OK - Unit
No Unit Test Coverage - Build Status
Buildable 827 Build 827: arc lint + arc unit
Event Timeline
core/kernel/db/dbitem.php | ||
---|---|---|
1170–1171 |
old id is hardcoded |