Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include ember-api-store addon in the code base #5184

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/initializers/cluster-store.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import initializer from '@rancher/ember-api-store/initializers/store';
import initializer from 'ember-api-store/initializers/store';

export default {
name: 'cluster-store',
Expand Down
2 changes: 1 addition & 1 deletion app/initializers/extend-resource.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import CattleTransitioningResource from 'ui/mixins/cattle-transitioning-resource';

export function initialize(/* application */) {
Expand Down
2 changes: 1 addition & 1 deletion app/initializers/global-store.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import initializer from '@rancher/ember-api-store/initializers/store';
import initializer from 'ember-api-store/initializers/store';

export default {
name: 'global-store',
Expand Down
2 changes: 1 addition & 1 deletion app/initializers/session.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Serializable from '@rancher/ember-api-store/mixins/serializable';
import Serializable from 'ember-api-store/mixins/serializable';

// Don't serialize the injected session
Serializable.reopen({ reservedKeys: ['session'], });
Expand Down
2 changes: 1 addition & 1 deletion app/initializers/webhook-store.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import initializer from '@rancher/ember-api-store/initializers/store';
import initializer from 'ember-api-store/initializers/store';

export default {
name: 'webhook-store',
Expand Down
2 changes: 1 addition & 1 deletion app/models/activedirectoryconfig.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';

var ActiveDirectoryConfig = Resource.extend({ type: 'activeDirectoryConfig', });

Expand Down
4 changes: 2 additions & 2 deletions app/models/app.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';
import { computed, get } from '@ember/object';
import { parseHelmExternalId } from 'ui/utils/parse-externalid';
import StateCounts from 'ui/mixins/state-counts';
Expand Down
2 changes: 1 addition & 1 deletion app/models/azurekubernetesserviceconfig.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';

export default Resource.extend({ type: 'azureKubernetesServiceConfig', });
2 changes: 1 addition & 1 deletion app/models/catalog.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { inject as service } from '@ember/service';
import { computed, get, set } from '@ember/object';
import { ucFirst } from 'shared/utils/util';
Expand Down
2 changes: 1 addition & 1 deletion app/models/catalogtemplate.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { inject as service } from '@ember/service';
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { parseExternalId } from 'ui/utils/parse-externalid';
import C from 'ui/utils/constants';
import { computed } from '@ember/object';
Expand Down
2 changes: 1 addition & 1 deletion app/models/certificate.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { inject as service } from '@ember/service';
import { get } from '@ember/object';
import { computed } from '@ember/object'
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';

export default Resource.extend({
router: service(),
Expand Down
4 changes: 2 additions & 2 deletions app/models/cloudcredential.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { computed } from '@ember/object';
import { notEmpty } from '@ember/object/computed';
import { inject as service } from '@ember/service';
import { hasMany } from '@rancher/ember-api-store/utils/denormalize';
import { hasMany } from 'ember-api-store/utils/denormalize';

const cloudCredential = Resource.extend({
modal: service(),
Expand Down
4 changes: 2 additions & 2 deletions app/models/cluster.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { get, set, computed, observer } from '@ember/object';
import { on } from '@ember/object/evented';
import { inject as service } from '@ember/service';
import Resource from '@rancher/ember-api-store/models/resource';
import { hasMany, reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { hasMany, reference } from 'ember-api-store/utils/denormalize';
import ResourceUsage from 'shared/mixins/resource-usage';
import Grafana from 'shared/mixins/grafana';
import { equal, alias } from '@ember/object/computed';
Expand Down
2 changes: 1 addition & 1 deletion app/models/clusteralertgroup.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import Alert from 'ui/mixins/model-alert';

export default Resource.extend(Alert, { type: 'clusteralertgroup', });
2 changes: 1 addition & 1 deletion app/models/clusteralertrule.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { get, computed } from '@ember/object';
import { inject as service } from '@ember/service';
import Alert from 'ui/mixins/model-alert';
Expand Down
2 changes: 1 addition & 1 deletion app/models/clustercatalog.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Catalog from 'ui/models/catalog';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import { reference } from 'ember-api-store/utils/denormalize';

export default Catalog.extend({
level: 'cluster',
Expand Down
2 changes: 1 addition & 1 deletion app/models/clusterlogging.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import modelMixin from 'ui/mixins/logging-model';

export default Resource.extend(modelMixin, { type: 'clusterlogging', });
4 changes: 2 additions & 2 deletions app/models/clusterroletemplatebinding.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';
import { get, computed } from '@ember/object';
import C from 'ui/utils/constants';
import PrincipalReference from 'ui/mixins/principal-reference';
Expand Down
2 changes: 1 addition & 1 deletion app/models/clusterscan.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { alias, equal } from '@ember/object/computed';
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { computed, get, set, observer } from '@ember/object';
import moment from 'moment';
import { downloadFile } from 'shared/utils/download-files';
Expand Down
4 changes: 2 additions & 2 deletions app/models/clustertemplate.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Resource from '@rancher/ember-api-store/models/resource';
import { hasMany } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { hasMany } from 'ember-api-store/utils/denormalize';
import { computed, get } from '@ember/object';
import { inject as service } from '@ember/service';

Expand Down
4 changes: 2 additions & 2 deletions app/models/clustertemplaterevision.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';
import { inject as service } from '@ember/service';
import { computed, get, set } from '@ember/object';
import { alias } from '@ember/object/computed';
Expand Down
4 changes: 2 additions & 2 deletions app/models/configmap.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { inject as service } from '@ember/service';
import { alias } from '@ember/object/computed';
import { computed, get } from '@ember/object';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { isEmpty } from '@ember/utils';

export default Resource.extend({
Expand Down
4 changes: 2 additions & 2 deletions app/models/container.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';
import DisplayImage from 'shared/mixins/display-image';
import { get, computed } from '@ember/object';
import { inject as service } from '@ember/service';
Expand Down
2 changes: 1 addition & 1 deletion app/models/credential.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { inject as service } from '@ember/service';

export default Resource.extend({
Expand Down
4 changes: 2 additions & 2 deletions app/models/destinationrule.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';
import { inject as service } from '@ember/service';
import { computed } from '@ember/object';

Expand Down
2 changes: 1 addition & 1 deletion app/models/dockercredential.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { get, computed } from '@ember/object';
import { alias } from '@ember/object/computed'
import { inject as service } from '@ember/service';
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';

export const PRESETS = {
'index.docker.io': 'dockerhub',
Expand Down
2 changes: 1 addition & 1 deletion app/models/etcdbackup.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { computed, get } from '@ember/object';
import { inject as service } from '@ember/service';

Expand Down
2 changes: 1 addition & 1 deletion app/models/feature.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { computed, set } from '@ember/object';
import { inject as service } from '@ember/service';

Expand Down
2 changes: 1 addition & 1 deletion app/models/fluentServers.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';

export default Resource.extend({ type: 'fluentServer', });
4 changes: 2 additions & 2 deletions app/models/gateway.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';
import { inject as service } from '@ember/service';
import { computed } from '@ember/object';

Expand Down
2 changes: 1 addition & 1 deletion app/models/githubconfig.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { inject as service } from '@ember/service';

var GithubConfig = Resource.extend({
Expand Down
4 changes: 2 additions & 2 deletions app/models/globaldns.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { get, set, computed, setProperties } from '@ember/object';
import { inject as service } from '@ember/service';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import { reference } from 'ember-api-store/utils/denormalize';
import { next } from '@ember/runloop';

export default Resource.extend({
Expand Down
2 changes: 1 addition & 1 deletion app/models/globaldnsprovider.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { get, computed, setProperties } from '@ember/object';
import { inject as service } from '@ember/service';
import { alias } from '@ember/object/computed';
Expand Down
4 changes: 2 additions & 2 deletions app/models/globalrole.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { not } from '@ember/object/computed';
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { computed } from '@ember/object';
import { inject as service } from '@ember/service';
import { hasMany } from '@rancher/ember-api-store/utils/denormalize';
import { hasMany } from 'ember-api-store/utils/denormalize';

const BASE = 'user-base';
const USER = 'user';
Expand Down
4 changes: 2 additions & 2 deletions app/models/globalrolebinding.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';
import { computed } from '@ember/object';
import { isEmpty } from '@ember/utils';
import { inject as service } from '@ember/service';
Expand Down
2 changes: 1 addition & 1 deletion app/models/googlekubernetesengineconfig.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';

export default Resource.extend({
type: 'googleKubernetesEngineConfig',
Expand Down
2 changes: 1 addition & 1 deletion app/models/googleoauthconfig.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';

var GoogleOauthConfig = Resource.extend({ type: 'googleOauthConfig', });

Expand Down
2 changes: 1 addition & 1 deletion app/models/groupglobalrolebindings.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { computed, set } from '@ember/object';
import { isEmpty } from '@ember/utils';
import { inject as service } from '@ember/service';
Expand Down
4 changes: 2 additions & 2 deletions app/models/horizontalpodautoscaler.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';
import { inject as service } from '@ember/service';
import { get, computed } from '@ember/object';
const VALUE = 'Value';
Expand Down
4 changes: 2 additions & 2 deletions app/models/httpingresspath.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';

var HttpIngressPath = Resource.extend({ service: reference('serviceId'), });

Expand Down
2 changes: 1 addition & 1 deletion app/models/image.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';

export default Resource.extend({ type: 'image' });
4 changes: 2 additions & 2 deletions app/models/ingress.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { computed, get } from '@ember/object';
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';
import { inject as service } from '@ember/service';

export default Resource.extend({
Expand Down
2 changes: 1 addition & 1 deletion app/models/kontainerdriver.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { computed, get } from '@ember/object';
import { inject as service } from '@ember/service';

Expand Down
2 changes: 1 addition & 1 deletion app/models/launchconfig.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { computed } from '@ember/object';
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';

var LaunchConfig = Resource.extend({
displayEnvironmentVars: computed('launchConfig.environment', function() {
Expand Down
2 changes: 1 addition & 1 deletion app/models/localauthconfig.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';

var LocalAuthConfig = Resource.extend({ type: 'localauthConfig', });

Expand Down
4 changes: 2 additions & 2 deletions app/models/member.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { inject as service } from '@ember/service';
import { get, computed } from '@ember/object';
// import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from '@rancher/ember-api-store/models/resource';
// import { reference } from 'ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';

export default Resource.extend({
globalStore: service(),
Expand Down
4 changes: 2 additions & 2 deletions app/models/mountentry.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { computed } from '@ember/object';
import { equal } from '@ember/object/computed';
import { inject as service } from '@ember/service';
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';

export default Resource.extend({
intl: service(),
Expand Down
4 changes: 2 additions & 2 deletions app/models/multiclusterapp.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Resource from '@rancher/ember-api-store/models/resource';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import Resource from 'ember-api-store/models/resource';
import { reference } from 'ember-api-store/utils/denormalize';
import { computed, get } from '@ember/object';
import { parseHelmExternalId } from 'ui/utils/parse-externalid';
import { inject as service } from '@ember/service';
Expand Down
4 changes: 2 additions & 2 deletions app/models/namespace.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import { computed, get, set } from '@ember/object';
import { inject as service } from '@ember/service';
import Resource from '@rancher/ember-api-store/models/resource';
import Resource from 'ember-api-store/models/resource';
import { parseExternalId } from 'ui/utils/parse-externalid';
import { convertToMillis } from 'shared/utils/util';
import { parseSi } from 'shared/utils/parse-unit';
import C from 'ui/utils/constants';
import { hasMany, reference } from '@rancher/ember-api-store/utils/denormalize';
import { hasMany, reference } from 'ember-api-store/utils/denormalize';
import StateCounts from 'ui/mixins/state-counts';
const ISTIO_INJECTION = 'istio-injection'
const ENABLED = 'enabled';
Expand Down
2 changes: 1 addition & 1 deletion app/models/namespacedcertificate.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Certificate from './certificate';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import { reference } from 'ember-api-store/utils/denormalize';
import { inject as service } from '@ember/service';

export default Certificate.extend({
Expand Down
2 changes: 1 addition & 1 deletion app/models/namespaceddockercredential.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import DockerCredential from './dockercredential';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import { reference } from 'ember-api-store/utils/denormalize';
import { inject as service } from '@ember/service';

export default DockerCredential.extend({
Expand Down
2 changes: 1 addition & 1 deletion app/models/namespacedsecret.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Secret from './secret';
import { reference } from '@rancher/ember-api-store/utils/denormalize';
import { reference } from 'ember-api-store/utils/denormalize';
import { inject as service } from '@ember/service';

export default Secret.extend({
Expand Down
Loading
Loading