added error detection to add product

added a bunch of error detection functions for add product such as if
the product already exists, if the 3 letter code is already taken and if
the 3 letter code is valid. also created the message alerts for these
checks which pop up in the add product modal