Simple lottery system based on js