Thank you for information,
The leg or feet cramps can be caused by some common reasons like dehydration, fluid and electrolyte imbalance, low serum sodium, potassium, magnesium, calcium, etc.
The other causes are liver cirrhosis, hyperventilation(overbreathing), vitamin D
, poor function of the parathyroid glands,kidney failure etc.
The deep vein thrombosis
may also cause leg pain due to poor circulation of blood and impended venous return.You should also have the venous doppler done of the lower legs to rule out DVT. The correction of electrolytes levels is also advised if there is any abnormality after collecting report.The renal function test should also be done to rule out any kidney disease.
The treatment is according to the underlying cause
Here is the link for more information
causes of leg cramps
Let me know if you have any doubt.