mirror of
https://github.com/fspc/BikeShed-1.git
synced 2025-02-28 08:43:23 -05:00
Attempting to go the proper way to fix dates
Still need to fix the bug/issue in netzke where it renders without the timezone
This commit is contained in:
parent
785e096aea
commit
517950c42c
@ -22,6 +22,7 @@ Ext.define('Ext.ux.form.field.DateTime', {
|
||||
dateSubmitFormat: 'Y-m-d',
|
||||
timeFormat: 'H:i:s',
|
||||
timeSubmitFormat: 'H:i:s',
|
||||
submitFormat: 'c',
|
||||
dateConfig:{},
|
||||
timeConfig:{},
|
||||
|
||||
@ -184,8 +185,10 @@ Ext.define('Ext.ux.form.field.DateTime', {
|
||||
var me = this
|
||||
,format = me.getFormat()
|
||||
,value = me.getValue();
|
||||
|
||||
return value ? Ext.Date.format(value, format) : null;
|
||||
console.log(value);
|
||||
console.log(format);
|
||||
console.log("formatted: " + Ext.Date.format(value, this.submitFormat));
|
||||
return value ? Ext.Date.format(value, this.submitFormat) : null;
|
||||
},
|
||||
|
||||
setValue: function(value){
|
||||
|
15
db/migrate/20140504154355_add_timezones_to_logs.rb
Normal file
15
db/migrate/20140504154355_add_timezones_to_logs.rb
Normal file
@ -0,0 +1,15 @@
|
||||
class AddTimezonesToLogs < ActiveRecord::Migration
|
||||
def up
|
||||
change_table :logs do |t|
|
||||
t.change :start_date, :timestamptz
|
||||
t.change :end_date, :timestamptz
|
||||
end
|
||||
end
|
||||
|
||||
def down
|
||||
change_table :logs do |t|
|
||||
t.change :start_date, :timestamp
|
||||
t.change :end_date, :timestamp
|
||||
end
|
||||
end
|
||||
end
|
@ -11,7 +11,7 @@
|
||||
#
|
||||
# It's strongly recommended to check this file into your version control system.
|
||||
|
||||
ActiveRecord::Schema.define(:version => 20131019170248) do
|
||||
ActiveRecord::Schema.define(:version => 20140504154355) do
|
||||
|
||||
create_table "bike_actions", :force => true do |t|
|
||||
t.string "action", :limit => 128, :null => false
|
||||
|
Loading…
x
Reference in New Issue
Block a user