title: Use custom function inside eloquent orderBy() method
body: <p>I have a list or products in my database that needs to be ordered based on their <code>updated_at</code> field. But I also want to view the products at the beginning that are missing some attributes.</p>
  
  <p>For example, I want to list those products at first that are missing description or colors and then order them based on their update date. Also I want to paginate them so I cannot sort them after I retrieve all the products from database.</p>
  
  <p>So is there a way to achieve this using eloquent in Laravel?</p>
  
  <p>This is how my <code>products</code> table looks like,</p>
  
  <pre><code>products
      -id
      -style
      -title
      -description
      -colors
      -sizes
      -cost
      -weight
      -created_at
      -updated_at
  </code></pre>