Last active
December 6, 2018 07:24
-
-
Save feanor07/84a4311290e71f8fba86d6cca77e3204 to your computer and use it in GitHub Desktop.
so53643322
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Days from 'ember-power-calendar/components/power-calendar/days' | |
export default Days.extend({ | |
// eliminate monday and sunday from the weekdays already constructed ad power-calendar-days | |
weekdaysWithoutMondayAndSunday: Ember.computed('weekdays', function() { | |
return this.get('weekdays').slice(2,7) | |
}) | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName: 'Ember Twiddle', | |
actions: { | |
selectDate(value) { | |
this.set('fixedDummyDate', value) | |
} | |
} | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Ember from 'ember'; | |
export function mondaySundayChecker(params/*, hash*/) { | |
console.log(params[0]) | |
const day = Ember.get(params[0], 'moment').format('dddd') | |
return day !== 'Monday' && day !== 'Sunday'; | |
} | |
export default Ember.Helper.helper(mondaySundayChecker); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"version": "0.15.1", | |
"EmberENV": { | |
"FEATURES": {} | |
}, | |
"options": { | |
"use_pods": false, | |
"enable-testing": false | |
}, | |
"dependencies": { | |
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.js", | |
"ember": "3.4.3", | |
"ember-template-compiler": "3.4.3", | |
"ember-testing": "3.4.3" | |
}, | |
"addons": { | |
"ember-data": "3.4.2", | |
"ember-power-calendar": "0.8.1", | |
"ember-moment": "7.7.0" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment