Add label function and update checkbox