change icon & edit plant
This commit is contained in:
@@ -1,6 +1,10 @@
|
||||
import App from './components/App';
|
||||
import './style';
|
||||
|
||||
Number.prototype.pad = function(n) {
|
||||
return (new Array(n).join('0') + this).slice(-n)
|
||||
}
|
||||
|
||||
Date.prototype.addDays = function (days) {
|
||||
let date = new Date(this.valueOf());
|
||||
date.setDate(date.getDate() + days);
|
||||
@@ -12,4 +16,8 @@ Date.prototype.toFrDate = function() {
|
||||
return `${this.getDate()}/${month}/${this.getFullYear()}`
|
||||
}
|
||||
|
||||
Date.prototype.toSQLDate = function() {
|
||||
return `${this.getFullYear()}-${Number(this.getMonth() + 1).pad(2)}-${Number(this.getDate()).pad(2)}`
|
||||
}
|
||||
|
||||
export default App;
|
||||
|
||||
Reference in New Issue
Block a user