title: How to convert Flutter Date to TimeStamp?
body: <p>I need to send a <code>post</code> request to the REST API where it includes a <code>Date</code> value. However the REST API and MySQL accepts a <code>Timestamp</code>. Below is how I prepare my current date</p>
  
  <pre><code>User user = User(
        name: nameTxtController.text,
        email: emailTxtController.text,
        phone: mobileTxtController.text,
        userLanguage: userLanguage,
        userRights: userRight,
        lastUpdated: DateTime.now(),
        dateCreated: DateTime.now()
  
      );
  </code></pre>
  
  <p>How to convert this to <code>Timestamp</code> ?</p>