mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-11-01 03:29:33 +00:00
Update frontend.
This commit is contained in:
@@ -825,19 +825,18 @@ export default {
|
||||
* Get API value.
|
||||
*/
|
||||
getAllowedOpposingTypes: function () {
|
||||
axios.get('./api/v1/configuration/static/firefly.allowed_opposing_types')
|
||||
axios.get('./api/v1/configuration/firefly.allowed_opposing_types')
|
||||
.then(response => {
|
||||
this.allowedOpposingTypes = response.data['firefly.allowed_opposing_types'];
|
||||
// console.log('Set allowedOpposingTypes');
|
||||
this.allowedOpposingTypes = response.data.data.value;
|
||||
});
|
||||
},
|
||||
/**
|
||||
* Get API value.
|
||||
*/
|
||||
getAccountToTransaction: function () {
|
||||
axios.get('./api/v1/configuration/static/firefly.account_to_transaction')
|
||||
axios.get('./api/v1/configuration/firefly.account_to_transaction')
|
||||
.then(response => {
|
||||
this.accountToTransaction = response.data['firefly.account_to_transaction'];
|
||||
this.accountToTransaction = response.data.data.value;
|
||||
});
|
||||
},
|
||||
/**
|
||||
|
||||
@@ -69,15 +69,34 @@ import {debounce} from 'lodash';
|
||||
export default {
|
||||
name: "TransactionAccount",
|
||||
components: {VueTypeaheadBootstrap},
|
||||
props: [
|
||||
'index',
|
||||
'direction',
|
||||
'value',
|
||||
'errors',
|
||||
'sourceAllowedTypes',
|
||||
'destinationAllowedTypes',
|
||||
'allowedOpposingTypes'
|
||||
],
|
||||
props: {
|
||||
index: {
|
||||
type: Number,
|
||||
},
|
||||
direction: {
|
||||
type: String,
|
||||
},
|
||||
value: {
|
||||
type: Object,
|
||||
default: () => ({})
|
||||
},
|
||||
errors: {
|
||||
type: Array,
|
||||
default: () => ([])
|
||||
},
|
||||
sourceAllowedTypes: {
|
||||
type: Array,
|
||||
default: () => ([])
|
||||
},
|
||||
destinationAllowedTypes: {
|
||||
type: Array,
|
||||
default: () => ([])
|
||||
},
|
||||
allowedOpposingTypes: {
|
||||
type: Object,
|
||||
default: () => ({})
|
||||
},
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
query: '',
|
||||
|
||||
@@ -80,12 +80,12 @@ export default {
|
||||
},
|
||||
created() {
|
||||
if (null === this.value || typeof this.value === 'undefined') {
|
||||
axios.get('./api/v1/configuration/static/firefly.default_location').then(response => {
|
||||
this.zoom = parseInt(response.data['firefly.default_location'].zoom_level);
|
||||
axios.get('./api/v1/configuration/firefly.default_location').then(response => {
|
||||
this.zoom = parseInt(response.data.data.value.zoom_level);
|
||||
this.center =
|
||||
[
|
||||
parseFloat(response.data['firefly.default_location'].latitude),
|
||||
parseFloat(response.data['firefly.default_location'].longitude),
|
||||
parseFloat(response.data.data.value.latitude),
|
||||
parseFloat(response.data.data.value.longitude),
|
||||
]
|
||||
;
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user