问题
class Client
include Neo4j::ActiveNode
end
> client = Client.new
=> #<Client uuid: nil, bot_client_id: nil, created_at: nil, email: nil, first_name: nil, last_name: nil, sms: nil, telegram_id: nil, updated_at: nil>
My expectation is that the uuid would be populated.
回答1:
The uuid
is only populated once the node object has been saved. So you could either do:
client = Client.create
Or:
client = Client.new
client.save
来源:https://stackoverflow.com/questions/43535208/neo4j-uuid-is-not-created