mirror of
https://github.com/Qortal/qortal-ui.git
synced 2025-07-31 14:11:45 +00:00
Added qortal requests
This commit is contained in:
@@ -20,7 +20,9 @@ import {
|
||||
setSideEffectAction,
|
||||
setTabNotifications,
|
||||
allowQAPPAutoBalance,
|
||||
removeQAPPAutoBalance
|
||||
removeQAPPAutoBalance,
|
||||
allowQAPPAutoTransactions,
|
||||
removeQAPPAutoTransactions
|
||||
} from '../../redux/app/app-actions'
|
||||
import settings from '../../functional-components/settings-page'
|
||||
import './welcome-page'
|
||||
@@ -56,7 +58,9 @@ window.reduxAction = {
|
||||
allowShowSyncIndicator: allowShowSyncIndicator,
|
||||
removeShowSyncIndicator: removeShowSyncIndicator,
|
||||
allowQAPPAutoBalance: allowQAPPAutoBalance,
|
||||
removeQAPPAutoBalance: removeQAPPAutoBalance
|
||||
removeQAPPAutoBalance: removeQAPPAutoBalance,
|
||||
allowQAPPAutoTransactions: allowQAPPAutoTransactions,
|
||||
removeQAPPAutoTransactions: removeQAPPAutoTransactions
|
||||
}
|
||||
|
||||
const animationDuration = 0.7 // Seconds
|
||||
|
@@ -10,7 +10,9 @@ import {
|
||||
removeQAPPAutoLists,
|
||||
setIsOpenDevDialog,
|
||||
allowQAPPAutoBalance,
|
||||
removeQAPPAutoBalance
|
||||
removeQAPPAutoBalance,
|
||||
allowQAPPAutoTransactions,
|
||||
removeQAPPAutoTransactions
|
||||
} from '../../redux/app/app-actions'
|
||||
import { securityViewStyles } from '../../styles/core-css'
|
||||
import FileSaver from 'file-saver'
|
||||
@@ -87,6 +89,12 @@ class SecurityView extends connect(store)(LitElement) {
|
||||
</label>
|
||||
<mwc-checkbox style="margin-right: -15px;" id="balanceButton" @click=${(e) => this.checkForBalance(e)} ?checked=${store.getState().app.qAPPAutoBalance}></mwc-checkbox>
|
||||
</div>
|
||||
<div class="checkbox-row">
|
||||
<label for="transactionsButton" id="transactionsButtonLabel" style="color: var(--black);">
|
||||
Always allow wallet txs to be retrieved automatically
|
||||
</label>
|
||||
<mwc-checkbox style="margin-right: -15px;" id="transactionsButton" @click=${(e) => this.checkForTransactions(e)} ?checked=${store.getState().app.qAPPAutoTransactions}></mwc-checkbox>
|
||||
</div>
|
||||
<div class="checkbox-row">
|
||||
<label for="authButton" id="authButtonLabel" style="color: var(--black);">
|
||||
${get('browserpage.bchange39')}
|
||||
@@ -124,6 +132,14 @@ class SecurityView extends connect(store)(LitElement) {
|
||||
}
|
||||
}
|
||||
|
||||
checkForTransactions(e) {
|
||||
if (e.target.checked) {
|
||||
store.dispatch(removeQAPPAutoTransactions(false))
|
||||
} else {
|
||||
store.dispatch(allowQAPPAutoTransactions(true))
|
||||
}
|
||||
}
|
||||
|
||||
checkForLists(e) {
|
||||
if (e.target.checked) {
|
||||
store.dispatch(removeQAPPAutoLists(false))
|
||||
|
@@ -26,7 +26,9 @@ import {
|
||||
ALLOW_SHOW_SYNC_INDICATOR,
|
||||
REMOVE_SHOW_SYNC_INDICATOR,
|
||||
ALLOW_QAPP_AUTO_BALANCE,
|
||||
REMOVE_QAPP_AUTO_BALANCE
|
||||
REMOVE_QAPP_AUTO_BALANCE,
|
||||
ALLOW_QAPP_AUTO_TRANSACTIONS,
|
||||
REMOVE_QAPP_AUTO_TRANSACTIONS
|
||||
} from '../app-action-types'
|
||||
|
||||
export const doUpdateBlockInfo = (blockObj) => {
|
||||
@@ -136,6 +138,20 @@ export const removeQAPPAutoBalance = (payload) => {
|
||||
}
|
||||
}
|
||||
|
||||
export const allowQAPPAutoTransactions = (payload) => {
|
||||
return {
|
||||
type: ALLOW_QAPP_AUTO_TRANSACTIONS,
|
||||
payload
|
||||
}
|
||||
}
|
||||
|
||||
export const removeQAPPAutoTransactions = (payload) => {
|
||||
return {
|
||||
type: REMOVE_QAPP_AUTO_TRANSACTIONS,
|
||||
payload
|
||||
}
|
||||
}
|
||||
|
||||
export const allowQAPPAutoLists = (payload) => {
|
||||
return {
|
||||
type: ALLOW_QAPP_AUTO_LISTS,
|
||||
|
@@ -41,3 +41,5 @@ export const ALLOW_SHOW_SYNC_INDICATOR = 'ALLOW_SHOW_SYNC_INDICATOR'
|
||||
export const REMOVE_SHOW_SYNC_INDICATOR = 'REMOVE_SHOW_SYNC_INDICATOR'
|
||||
export const ALLOW_QAPP_AUTO_BALANCE = 'ALLOW_QAPP_AUTO_BALANCE'
|
||||
export const REMOVE_QAPP_AUTO_BALANCE = 'REMOVE_QAPP_AUTO_BALANCE'
|
||||
export const ALLOW_QAPP_AUTO_TRANSACTIONS = 'ALLOW_QAPP_AUTO_TRANSACTIONS'
|
||||
export const REMOVE_QAPP_AUTO_TRANSACTIONS = 'REMOVE_QAPP_AUTO_TRANSACTIONS'
|
||||
|
@@ -42,7 +42,9 @@ import {
|
||||
ALLOW_SHOW_SYNC_INDICATOR,
|
||||
REMOVE_SHOW_SYNC_INDICATOR,
|
||||
ALLOW_QAPP_AUTO_BALANCE,
|
||||
REMOVE_QAPP_AUTO_BALANCE
|
||||
REMOVE_QAPP_AUTO_BALANCE,
|
||||
ALLOW_QAPP_AUTO_TRANSACTIONS,
|
||||
REMOVE_QAPP_AUTO_TRANSACTIONS
|
||||
} from './app-action-types'
|
||||
import { initWorkersReducer } from './reducers/init-workers'
|
||||
import { loginReducer } from './reducers/login-reducer'
|
||||
@@ -92,6 +94,7 @@ const INITIAL_STATE = {
|
||||
qAPPFriendsList: loadStateFromLocalStorage('qAPPFriendsList') || false,
|
||||
showSyncIndicator: loadStateFromLocalStorage('showSyncIndicator') || false,
|
||||
qAPPAutoBalance: loadStateFromLocalStorage('qAPPAutoBalance') || false,
|
||||
qAPPAutoTransactions: loadStateFromLocalStorage('qAPPAutoTransactions') || false,
|
||||
chatLastSeen: [],
|
||||
newTab: null,
|
||||
tabInfo: {},
|
||||
@@ -270,6 +273,22 @@ export default (state = INITIAL_STATE, action) => {
|
||||
}
|
||||
}
|
||||
|
||||
case ALLOW_QAPP_AUTO_TRANSACTIONS: {
|
||||
saveStateToLocalStorage("qAPPAutoTransactions", true)
|
||||
return {
|
||||
...state,
|
||||
qAPPAutoTransactions: action.payload
|
||||
}
|
||||
}
|
||||
|
||||
case REMOVE_QAPP_AUTO_TRANSACTIONS: {
|
||||
saveStateToLocalStorage("qAPPAutoTransactions", false)
|
||||
return {
|
||||
...state,
|
||||
qAPPAutoTransactions: action.payload
|
||||
}
|
||||
}
|
||||
|
||||
case ALLOW_QAPP_AUTO_LISTS: {
|
||||
saveStateToLocalStorage("qAPPAutoLists", true)
|
||||
return {
|
||||
|
Reference in New Issue
Block a user