A pineapple is 7 times as heavy as an orange. The pineapple also weighs 870 grams more than the orange. What is the total weight in grams for the pineapple and orange?