After an uproar concerning the feeding of the widows the Apostles chose seven men to take care of that ministry
KJV Acts 6 : 1
And in those days, when the number of the disciples was multiplied, there arose a murmuring of the Grecians against the Hebrews, because their widows were neglected in the daily ministration.
The Apostles decided to choose men who will undertake this ministry.The criteria laid down for choosing these men was wisdom,faith and full the Holy Spirit.The seven chosen seemed to have these qualities yet the Apostles went on to lay hands on these men
KJV Acts 6 : 5-6
And the saying pleased the whole multitude: and they chose Stephen, a man full of faith and of the Holy Ghost, and Philip, and Prochorus, and Nicanor, and Timon, and Parmenas, and Nicolas a proselyte of Antioch: 6 whom they set before the apostles: and when they had prayed, they laid their hands on them.
Mostly laying on of hands was to impart healing or a gift onto the recipient
KJV Acts 8 : 17
Then laid they their hands on them, and they received the Holy Ghost.
KJV Acts 9 : 17
And Ananias went his way, and entered into the house; and putting his hands on him said, Brother Saul, the Lord, even Jesus, that appeared unto thee in the way as thou camest, hath sent me, that thou mightest receive thy sight, and be filled with the Holy Ghost.
KJV 2 Timothy 1 : 6
Wherefore I put thee in remembrance that thou stir up the gift of God, which is in thee by the putting on of my hands.
What was the purpose of laying hands on the seven who seemed to have these qualities?