Cannot add image to template pages
Bug #1397110 reported by
Kristina Hoeppner
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Mahara |
Fix Released
|
High
|
Son Nguyen | ||
16.04 |
Fix Released
|
High
|
Son Nguyen | ||
16.10 |
Fix Released
|
High
|
Unassigned |
Bug Description
Mahara 1.10+
When you change the template in Admin -> Config site -> Pages, you cannot add an image to either of the three templates. You can put the block there and select an image, but it is not going to be displayed.
The file that you upload does not sit in the site files, but somewhere that is not accessible. They seem to be stored under the "System user" (also for group homepage), but you don't have access to those on the front-end.
The only image that you can display is the default user profile icon.
no longer affects: | mahara/1.10 |
no longer affects: | mahara/15.04 |
no longer affects: | mahara/15.10 |
Changed in mahara: | |
milestone: | 16.04.0 → 16.10.0 |
summary: |
- Cannot add image to template files + Cannot add image to template pages |
Changed in mahara: | |
status: | In Progress → Fix Released |
To post a comment you must log in.
Functionally, the outcome we want is this:
1. You should be able to add files from the Site Files area into blocks for these templates.
2. Those files should get copied to the user or group files area when the templates are copied. (And ideally, it should retain the underlying link to the same physical file, in order to reduce disk usage. I think the copy logic does this already?)
3. You should be able to place the same blocktypes in these templates, as in a normal page of that page type. I.e. the same blocks in the "Group Home Page" template, as you could place in any group home page. I think we're already fine on that front, because it's based on Blocktype: :allowed_ in_view( ), and the page's page type, and the template pages have the right page type.
I understand that probably the reason why you can't put any images in these pages currently, is because they technically have the root user (id 0) as their page author. Changing them to be site pages may be the solution. It doesn't really matter, so long as the above stuff remains true.
It's also worth noting, that these pages *don't* necessarily need to have the "view.template" flag set to 1 in the database. That flag indicates whether they should show up in the list of pages users can manually make copies of. Users will not be manually making copies of these.
Cheers,
Aaron