I got this error:
Notice: Undefined property: stdClass::$has_body in stormorganization_form() (line 406 of E:\wamp\www\sites\all\modules\storm\stormorganization\stormorganization.module).
| Comment | File | Size | Author |
|---|---|---|---|
| #24 | storm-org-body-24.patch | 3.03 KB | juliangb |
| #23 | storm-org-body-23.patch | 2.96 KB | juliangb |
| #21 | storm-1477284-addedbodyfield-comment21.patch | 2.49 KB | esoteric1 |
| #19 | stormorganization-1477284-comment19.patch | 2.62 KB | esoteric1 |
| #16 | stormorganization-1477284-addedbodyfield-comment16.patch | 1.32 KB | esoteric1 |
Comments
Comment #1
DaGenius commentedI would appreciate if someone can help with this issue. Thanks
Comment #2
KarlisK commentedTook Screenshot of errors caught in the logs of my Test enviroment of Drupal.
Comment #3
KarlisK commentedComment #4
juliangb commentedIssues such as these are expected in an early development version, and is actually quite minor compared to the point that the body field doesn't show up at all. They will be fixed as the port progresses.
Comment #5
Chekhov commentedI was looking into the issue and there is in fact no information on whether the stormorganization node type should have a body or not. E.g. something like
has_body => TRUEinhook_node_info().Should it be there, or not?
A
body_label => t("Note")is there, so I assume the answer is 'yes'. Just to be sure...Comment #6
juliangb commentedMoving to task, will leave issue open until fixed.
Comment #7
juliangb commentedThe way we'll need to fix the body with Drupal 7 is to declare as a field:
This is how the core blog module does it.
Then, when we view, we'll have to check whether it exists or has been deleted by the user.
Comment #8
esoteric1 commentedComment #9
esoteric1 commentedThis is my first patch ever.
I added the body field after doing that noticed the comments were enabled. I disabled them and author information programmatically. When the body field is deleted in the manage fields, it does not show up in the add organization form.
Comment #10
esoteric1 commentedAlso, should all of those node attributes be fields?
Comment #12
esoteric1 commentedFixed a typo
Comment #13
juliangb commentedMarc-Andre: Thanks for getting involved - excited that you've made your first patch here for Storm!
A couple of comments:
1) We shouldn't turn off comments or hide the submitted by - because the Drupal 6 version doesn't. At this stage I'm not advocating one way or the other, but with the port as much as possible are trying to make it work, rather than make changes.
2) To better help users who are upgrading a previous version, we should also add the body field as part of an update function.
More minor points - if you can, please try to use the Drupal way of formatting code - http://drupal.org/coding-standards - small points such as spaces each side of = signs, but it means that it is a lot more readable.
Comment #14
esoteric1 commentedokay I will fix all those things and resubmit. Also, are all of the 'attributes' to become fields?
Comment #15
juliangb commentedAttributes -> Fields is optional - we don't need it as part of the port, but it is a change that will happen at some point.
My personal preference is to not to it now, but to focus on getting everything working, then do this as a follow up.
Comment #16
esoteric1 commentedI am not sure how to do the update function part but I made the other changes.
Comment #17
esoteric1 commentedComment #18
esoteric1 commentedI think I missed a lot of things when i did that patch, i would disregard it for now.
Comment #19
esoteric1 commentedHere is another stab at it. I didn't touch the update part though. edited the stormorganization.theme.inc file to be able to display the body if the body was indeed part of the fields.
Comment #20
juliangb commentedLooks like we're still disabling comments and hiding the author info.
Comment #21
esoteric1 commentedjesus, sorry, getting used to git. At the very least I hope this patch doesn't have the same problems.
:(
Comment #22
esoteric1 commentedComment #23
juliangb commentedThanks for this - pretty much what we need.
In the attached, I've added the update function (so that existing users will also get a body field), and renamed it as a Note in the field system.
Comment #24
juliangb commentedThis patch adds a description for the change which is shown on update.php
Comment #25
juliangb commentedCommitted, thanks!