* fix: Display logic that prevents some fields from being displayed. * fix open criteria with uuidpull/3759/head
parent
f700b0341e
commit
df6762578e
|
@ -447,7 +447,7 @@ export default {
|
||||||
containerUuid: this.containerUuid,
|
containerUuid: this.containerUuid,
|
||||||
isAdvancedQuery: route.query.action === 'advancedQuery',
|
isAdvancedQuery: route.query.action === 'advancedQuery',
|
||||||
newValues: this.dataRecords,
|
newValues: this.dataRecords,
|
||||||
isSendToServer: false,
|
isSendToServer: true,
|
||||||
isSendCallout: false,
|
isSendCallout: false,
|
||||||
fieldList: this.fieldList,
|
fieldList: this.fieldList,
|
||||||
panelType: this.panelType
|
panelType: this.panelType
|
||||||
|
@ -489,7 +489,7 @@ export default {
|
||||||
name: this.$route.name,
|
name: this.$route.name,
|
||||||
query: {
|
query: {
|
||||||
...this.$route.query,
|
...this.$route.query,
|
||||||
action: this.dataRecords
|
action: this.dataRecords.UUID
|
||||||
},
|
},
|
||||||
params: {
|
params: {
|
||||||
...this.$route.params,
|
...this.$route.params,
|
||||||
|
|
|
@ -7,6 +7,13 @@ import 'normalize.css/normalize.css' // a modern alternative to CSS resets
|
||||||
import Element from 'element-ui'
|
import Element from 'element-ui'
|
||||||
import './styles/element-variables.scss'
|
import './styles/element-variables.scss'
|
||||||
import VueSplit from 'vue-split-panel'
|
import VueSplit from 'vue-split-panel'
|
||||||
|
/**
|
||||||
|
* TODO: Waiting for PR to:
|
||||||
|
* https://github.com/vue-extend/v-markdown/pull/4
|
||||||
|
* To change:
|
||||||
|
* import VMarkdown from 'v-markdown'
|
||||||
|
*/
|
||||||
|
import VMarkdown from 'v-markdown/src'
|
||||||
|
|
||||||
import '@/styles/index.scss' // global css
|
import '@/styles/index.scss' // global css
|
||||||
|
|
||||||
|
@ -21,7 +28,6 @@ import './utils/error-log' // error log
|
||||||
|
|
||||||
import * as filters from './filters' // global filters
|
import * as filters from './filters' // global filters
|
||||||
import * as globalMethods from '@/utils/ADempiere/globalMethods' // global methods
|
import * as globalMethods from '@/utils/ADempiere/globalMethods' // global methods
|
||||||
import VMarkdown from 'v-markdown/src'
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* If you don't want to use mock-server
|
* If you don't want to use mock-server
|
||||||
|
|
|
@ -24,9 +24,11 @@ const panel = {
|
||||||
payload.panel = payload.newPanel
|
payload.panel = payload.newPanel
|
||||||
},
|
},
|
||||||
changeFieldLogic(state, payload) {
|
changeFieldLogic(state, payload) {
|
||||||
payload.field.isDisplayedFromLogic = Boolean(payload.isDisplayedFromLogic)
|
if (payload.isDisplayedFromLogic !== undefined && payload.isDisplayedFromLogic !== null) {
|
||||||
|
payload.field.isDisplayedFromLogic = Boolean(payload.isDisplayedFromLogic)
|
||||||
|
}
|
||||||
payload.field.isMandatoryFromLogic = Boolean(payload.isMandatoryFromLogic)
|
payload.field.isMandatoryFromLogic = Boolean(payload.isMandatoryFromLogic)
|
||||||
payload.field.isReportFromLogic = Boolean(payload.isReportFromLogic)
|
payload.field.isReadOnlyFromLogic = Boolean(payload.isReadOnlyFromLogic)
|
||||||
payload.field.parsedDefaultValue = payload.parsedDefaultValue
|
payload.field.parsedDefaultValue = payload.parsedDefaultValue
|
||||||
},
|
},
|
||||||
dictionaryResetCache(state) {
|
dictionaryResetCache(state) {
|
||||||
|
|
|
@ -83,7 +83,16 @@ class evaluator {
|
||||||
if (logic === undefined) {
|
if (logic === undefined) {
|
||||||
return _defaultUndefined
|
return _defaultUndefined
|
||||||
}
|
}
|
||||||
let expr = /^(['"@#$a-zA-Z0-9\-_\s]){0,}((<>|<=|<|==|=|>=|>|!=|!|\^){1,2})([\s"'@#$a-zA-Z0-9\-_]){0,}$/i
|
|
||||||
|
/**
|
||||||
|
* fist group: (['"@#\w\d-_\s]{0,}) only values aphabetic (\w), numerics (\d),
|
||||||
|
* space (\d) and '"@#$-_ characters, at least ocurrency to 0 position
|
||||||
|
* second group: (<>|<=|==|>=|!=|<|=|>|!|\^) coincides only with some of the
|
||||||
|
* conditions <>, <=, ==, >=, !=, <, =, >, !, ^
|
||||||
|
* third group: same as the first group
|
||||||
|
* flag: global match (g), insensitive case (i), multiline (m)
|
||||||
|
*/
|
||||||
|
let expr = /^(['"@#$-_\w\d\s]{0,})(<>|<=|==|>=|!=|<|=|>|!|\^)(['"@#$-_\w\d\s]{0,})/gim
|
||||||
let st = expr.test(logic)
|
let st = expr.test(logic)
|
||||||
|
|
||||||
if (!st) {
|
if (!st) {
|
||||||
|
@ -91,7 +100,7 @@ class evaluator {
|
||||||
return _defaultUndefined
|
return _defaultUndefined
|
||||||
}
|
}
|
||||||
|
|
||||||
expr = /(<>|<=|<|==|=|>=|>|!=|!|\^){1,2}/i
|
expr = /(<>|<=|==|>=|!=|<|=|>|!|\^)/gm
|
||||||
st = logic.split(expr)
|
st = logic.split(expr)
|
||||||
|
|
||||||
// First Part (or column name)
|
// First Part (or column name)
|
||||||
|
|
Loading…
Reference in New Issue