title: Fill gap between date using resample (multi-index)
body: <p>I have a dataframe with gaps between date.</p>
  
  <p><a href="https://i.stack.imgur.com/QANYn.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/QANYn.png" alt="Dataframe"></a></p>
  
  <p>It`s necessary to groupby the first 2 columns of this dataframe and then fill the gaps.</p>
  
  <p>What I am trying is this:</p>
  
  <pre><code>df.groupby(['cod_interno', 'unidade_lojas', 'data']).apply(lambda x : x.resample('D').ffill()).reset_index(level=0,drop=True)
  </code></pre>
  
  <p>However I got this error message:</p>
  
  <blockquote>
    <p>TypeError: Only valid with DatetimeIndex, TimedeltaIndex or PeriodIndex, but got an instance of 'Int64Index'</p>
  </blockquote>
  
  <p>Is there a better approach to solve this ? </p>
  
  <p>I tried this approach <a href="https://stackoverflow.com/questions/15617496/resampling-a-multi-index-dataframe">Resampling a multi-index DataFrame</a>, but I not so familiar with 'stack()'</p>