chore: 🤖 Update user breadcrumb display name
This commit is contained in:
3 files changed
+12
-2
No files matched your search
@@ -1,5 +1,6 @@
|
||||
import { module, test } from 'qunit';
|
||||
import { setupTest } from 'ember-qunit';
|
||||
import config from 'ember-get-config';
|
||||
|
||||
module('Unit | Adapter | user', function(hooks) {
|
||||
setupTest(hooks);
|
||||
@@ -8,4 +9,13 @@ module('Unit | Adapter | user', function(hooks) {
|
||||
let adapter = this.owner.lookup('adapter:user');
|
||||
assert.ok(adapter);
|
||||
});
|
||||
|
||||
test('it generates URL prefixes without project scope', function (assert) {
|
||||
assert.expect(1);
|
||||
const service = this.owner.lookup('service:scope');
|
||||
service.org = { id: 1 };
|
||||
service.project = { id: 2 };
|
||||
const adapter = this.owner.lookup('adapter:user');
|
||||
assert.equal(adapter.urlPrefix(), `${config.api.namespace}/orgs/1`);
|
||||
});
|
||||
});
|
||||
@@ -2,7 +2,7 @@
|
||||
@onSubmit={{@submit}}
|
||||
@cancel={{@cancel}}
|
||||
@disabled={{@model.isSaving}}
|
||||
@error={{true}}
|
||||
@error={{@model.errors.base}}
|
||||
as |form|
|
||||
>
|
||||
|
||||
|
||||
@@ -7,5 +7,5 @@ export default class OrgsOrgUsersUserController extends Controller {
|
||||
/**
|
||||
* @type {string}
|
||||
*/
|
||||
@alias('model.name') breadCrumb;
|
||||
@alias('model.displayName') breadCrumb;
|
||||
}
|
||||
Reference in new issue
Block a user