Forked from Ivan-Uspensky/controllers.application.js
Last active
November 28, 2018 15:32
-
-
Save cibernox/3215198cfb5897f4f21385ffe08e58a9 to your computer and use it in GitHub Desktop.
New Twiddle
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', | |
translations: [ | |
{ | |
reviewer: "333", | |
sapCode: "!!!", | |
tid: 1, | |
}, | |
{ | |
reviewer: "555", | |
sapCode: "???", | |
tid: 2, | |
}, | |
{ | |
reviewer: "777", | |
sapCode: "&&&", | |
tid: 3, | |
} | |
], | |
reviewers: [ | |
{label: " qwe", value: "000"}, | |
{label: " asd", value: "111"}, | |
{label: " zxc", value: "222"}, | |
{label: " rty", value: "333"}, | |
{label: " fgh", value: "444"}, | |
{label: " vbn", value: "555"}, | |
{label: " uio", value: "666"}, | |
{label: " jkl", value: "777"}, | |
{label: " mop", value: "888"} | |
], | |
actions: { | |
reviewerChange() {} | |
} | |
}); |
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 findBy([attr, value, collection]) { | |
return collection.find(item => Ember.get(item, attr) === value); | |
} | |
export default Ember.Helper.helper(findBy); |
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
body { | |
margin: 12px 16px; | |
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; | |
font-size: 12pt; | |
} | |
.ember-power-select-trigger { | |
min-width:200px | |
} |
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-select": "2.2.0" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment