This does not mean that we should attribute to God the hardships that result from our wrong doings and sins and then agree upon it.
This does not also mean that we should do nothing about this hardship because they result from our wrong doings and so they affect us. If He has allowed pain He only will give its remedy.
If we are negligent or lethargic about it then we have not submitted totally to God and will be responsible to God for it because we are attributing our wrongdoings and lethargy to him. There will be a further discussion about agreeing and submitting later on Inshallah.