Skip to content

Commit

Permalink
fix naming
Browse files Browse the repository at this point in the history
addresses #330
  • Loading branch information
kjgarza committed Mar 17, 2020
1 parent d2b4980 commit d2914e8
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion app/components/doi-geo-location.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export default Component.extend({
this.fragment.set('geoLocationPlace', value);
},
deleteGeoLocation() {
this.model.get('geoLocationPlaces').removeObject(this.fragment);
this.model.get('geoLocations').removeObject(this.fragment);
},
},
});
3 changes: 2 additions & 1 deletion app/models/geo-location.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import DS from 'ember-data';
import Fragment from 'ember-data-model-fragments/fragment';
import { validator, buildValidations } from 'ember-cp-validations';
import { buildValidations } from 'ember-cp-validations';
// import { validator, buildValidations } from 'ember-cp-validations';
// import { computed } from '@ember/object';

const Validations = buildValidations({
Expand Down
4 changes: 2 additions & 2 deletions app/templates/components/doi-geo-location.hbs
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
<label for="geoLocationPlace" class="subtitle">GeoLocation Place (optional)</label>
{{#if (gt index 0)}}
<div class="input-group">
<input class="form-control geo-location-place-field {{if (not isSeriesInformation) 'no-error'}}" value={{fragment.geo-location-place}}
<input class="form-control geo-location-place-field" value={{fragment.geoLocationPlace}}
oninput={{action "updateGeoLocationPlace" value="target.value"}} data-test-geo-location-place/>
<span class="input-group-addon">
<BsButton @outline={{true}} @onClick={{action "deleteGeoLocation" index}}>{{fa-icon "trash" pull="left" style="margin:0;"}}</BsButton>
</span>
</div>
{{else}}
<input class="form-control geo-location-place-field {{if (not isSeriesInformation) 'no-error'}}" value={{fragment.geo-location-place}}
<input class="form-control geo-location-place-field" value={{fragment.geoLocationPlace}}
oninput={{action "updateGeoLocationPlace" value="target.value"}} data-test-geo-location-place/>
{{/if}}
<div class="help-block help-block-fragment geo-location-place-field">Description of a geographic location. </div>
Expand Down

0 comments on commit d2914e8

Please sign in to comment.