Skip to content

Commit

Permalink
Merge branch 'dev' of https://github.com/LCOGT/ptr_ui into update/obs…
Browse files Browse the repository at this point in the history
…erve-page-ui-changes
  • Loading branch information
LTDakin committed Nov 14, 2023
2 parents 9e64f92 + e42cc13 commit e2d255b
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/components/projects/CreateProjectForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -862,6 +862,9 @@ export default {
// set default filter
this.exposures[targets_index].filter = this.default_filter_selection
// loading min_zenith_dist fromt config
this.load_default_zenith_from_mount()
},
watch: {
// This runs any time an existing project is passed into the component.
Expand Down Expand Up @@ -913,6 +916,10 @@ export default {
'resetProjectForm',
'loadProject'
]),
// Set store value for min_zenith_dist if it exists in mount config
load_default_zenith_from_mount () {
this.$store.commit('project_params/min_zenith_dist', this.selected_mount_config?.default_zenith_avoid ?? 0)
},
// Used for changing values in the targets array without losing reactivity
updateTargetsValue (indexToMatch, key, val) {
this.targets = this.targets.map((obj, index) => {
Expand Down Expand Up @@ -1232,7 +1239,8 @@ export default {
'available_sites_real',
'available_sites_simulated',
'filter_wheel_options',
'default_filter_selection'
'default_filter_selection',
'selected_mount_config'
]),
...mapState('site_config', ['global_config']),
...mapState('user_data', [
Expand Down

0 comments on commit e2d255b

Please sign in to comment.