Thanks for your reply Bob.
The default for the TV is blank. I also noticed a similar situation for another Date field (tmplvarid = 54), this also has a default of blank.
The packages I have installed in Package Management are:
- babel-2.2.4-pl
- breadcrumbs-1.1.0-pl
- formit-2.0.1-pl
- getpage-1.1.0-pl
- getresources-1.3.1-pl
- googlesitemap-1.2.1-pl
- if-1.1-pl
- login-1.6.5-pl
- simplesearch-1.4.0-pl
- tinymce-4.3.0-rc2
- ultimateparent-2.0-pl
- wayfinder-2.3.1-pl
From that list, I believe only Babel and TinyMCE are used within the manager?
I should have pointed out that this is a multi-lingual site with two contexts (web, web-fr) for English/French. I know that Babel uses a hidden TV to relate documents belonging to the different contexts. After some testing (below) I'm sure the issue is with Babel.
I've created a reliable way of demonstrating this bug within a development version of the website which I can test and restore repeatedly. The steps are as follows:
- Login to manager
- Delete document #38
- Expunge document #38
After doing this, the value field in two rows of modx_site_tmplvar_contentvalues become blank:
- id: 543, tmplvarid: 33, contentid: 140, value: ""
- id: 1659, tmplvarid: 33, contentid: 310, value: ""
Thoughts/comments:
- This bug only appears when deleting certain documents, I'm not sure why.
- Each time I repeat the above steps (after restoring the database each time) the same two modx_site_tmplvar_contentvalues always become blank.
- I've checked the modx_site_tmplvar_contentvalues after each of the above steps, the tv values only go blank after the expunge (i.e. when document 38 is permenantly removed from the database).
- The TV values which are deleted are related to documents 140 and 310 and have nothing to do with document 38.
- Documents 140 and 310 do not share the same template as document 38. (Docs 140 + 310 have a template id of 9. Doc 38 has a template id of 6).
- Template 9 and 6 share the same four TV's: #9, #19, #28, #56 (they do not share TV #33, the one which goes blank).
- Documents 140 and 310 are related to one another via Babel via the babelLanguageLinks TV (#56) (i.e. doc 310 is the web-fr version of doc 140). This suggests to me that it is a bug with Babel rather than MODX.
To test this bug I've restored the database and tested the following each time:
1. Turn off compress_js/compress_css.
Blank values still appear in modx_site_tmplvar_contentvalues.
2. Uninstall Babel:
Bug doesn't occur.
3. Update Babel to 2.2.5-pl
Blank values still appear in modx_site_tmplvar_contentvalues.
4. Update all packages and MODX (to 2.2.2-pl).
Blank values still appear in modx_site_tmplvar_contentvalues.
Note: the packages are now:
- babel-2.2.5-pl
- breadcrumbs-1.1.0-pl
- formit-2.0.3-pl
- getpage-1.2.2-pl
- getresources-1.4.2-pl
- googlesitemap-1.3.1-pl
- if-1.1-pl
- login-1.7.3-pl
- simplesearch-1.6.0-pl
- tinymce-4.3.2-pl
- ultimateparent-2.0-pl
- wayfinder-2.3.3-pl
I will try digging through Babel to see whats happening. For now I'll avoid expunging anything and only expunge after making a DB backup.
Any other comments/suggestions are welcome.