I have this issue that I'm currently storing member information as properties on that member.
This works fine. However, I need to store some statistics on each run of a game inside the site. So I need to store multiple child items. Can I have children on a member node? Or can I assign a linkedlist to a property and have it properly serialized? A web/site search turned up little of value
Anyone did anything similar? I'd rather avoid doing my own stat table in the DB, as I want everything in Umbraco if at all possible.
One way this could be achieved is by thinking a bit untraditional I think.
It's not possible to create childnodes under members out of the box. Perhaps this can be customized...I'm not sure.
But what I'm thinking is that you can store the statistics data in the content tree. Create a document type called something like "Member statistics", which will serve as the root/branch for a "Member" document type where you can name the node with the proper member name and place a property, which has the datatype of "member" picker. This creates the relation between the statistic and the member. You can create whatever you like under the "Member" document type in the content tree.
I realise this approach can be a bit cumbersome and maybe there is a better way around it but this is one way it can achieved.
If you know your way around C# it should be a breeze to make sure the new member is created in the content tree when the members is created in the member section using events.
Hope this input makes sense and is usefull to you.
It's a good idea that I've used on other sites, I just hoped for a simpler solution.
Not that it's hard to do. And actually it might be nicer to have statistics in a common node elsewhere in the tree. Yes. I'll probably do this once again.
Well, maybe some of the other wizards in here have another approach for handling this. But I guess that it might involve having statistic in another database, which is probably also the most ideal solution.
But sometimes it's about being pragmatic with what you got, right? And if it's used on minor sites I can't see the harm unless it's something that is going to expand in the near future. Then scalability is of course an issue to think about :-)
Yes. This is a prototype for an online game so it's ok to keep it small. When (or if) we secure funding, I'll move it to another database or possible Azure for greater scalability.
Adding lists or children to member
Hi
I have this issue that I'm currently storing member information as properties on that member.
This works fine. However, I need to store some statistics on each run of a game inside the site.
So I need to store multiple child items. Can I have children on a member node? Or can I assign a linkedlist to a property and have it properly serialized? A web/site search turned up little of value
Anyone did anything similar? I'd rather avoid doing my own stat table in the DB, as I want everything in Umbraco if at all possible.
Thanks in advance
Odin
Hi Odin
One way this could be achieved is by thinking a bit untraditional I think.
It's not possible to create childnodes under members out of the box. Perhaps this can be customized...I'm not sure.
But what I'm thinking is that you can store the statistics data in the content tree. Create a document type called something like "Member statistics", which will serve as the root/branch for a "Member" document type where you can name the node with the proper member name and place a property, which has the datatype of "member" picker. This creates the relation between the statistic and the member. You can create whatever you like under the "Member" document type in the content tree.
I realise this approach can be a bit cumbersome and maybe there is a better way around it but this is one way it can achieved.
If you know your way around C# it should be a breeze to make sure the new member is created in the content tree when the members is created in the member section using events.
Hope this input makes sense and is usefull to you.
/Jan
Hi Jan
It's a good idea that I've used on other sites, I just hoped for a simpler solution.
Not that it's hard to do. And actually it might be nicer to have statistics in a common node elsewhere in the tree.
Yes. I'll probably do this once again.
Thanks for your input :)
/Odin
Hi Odin
Well, maybe some of the other wizards in here have another approach for handling this. But I guess that it might involve having statistic in another database, which is probably also the most ideal solution.
But sometimes it's about being pragmatic with what you got, right? And if it's used on minor sites I can't see the harm unless it's something that is going to expand in the near future. Then scalability is of course an issue to think about :-)
/Jan
Yes. This is a prototype for an online game so it's ok to keep it small. When (or if) we secure funding, I'll move it to another database or possible Azure for greater scalability.
/Odin
is working on a reply...