check box click to add working, code needs refactored