function update & customer type