소스 검색

show action errors

pull/1/head
Jonathan Cobb 4 년 전
부모
커밋
3244ea3346
2개의 변경된 파일19개의 추가작업 그리고 9개의 파일을 삭제
  1. +18
    -9
      src/account/AppConfigPage.vue
  2. +1
    -0
      src/account/AppDataViewPage.vue

+ 18
- 9
src/account/AppConfigPage.vue 파일 보기

@@ -2,6 +2,8 @@
<div>
<h3 v-if="app">{{messages['app_'+app.name+'_config_view_'+viewId]}}</h3>

<div v-if="errors.has(lastAction)" class="invalid-feedback d-block"><h5>{{ errors.first(lastAction) }}</h5></div>

<div v-if="loading()">
{{messages.loading_app_config_data}}
</div>
@@ -112,7 +114,8 @@
itemActions: null,
appActions: null,
itemActionParams: {},
appActionParams: {}
appActionParams: {},
lastAction: 'no_action'
};
},
computed: {
@@ -146,6 +149,8 @@
return safeEval(action.when, {'item': row}) === true;
},
itemAction(action, itemId) {
this.lastAction = action.name;
this.errors.clear();
this.takeConfigItemAction({
userId: this.user.name,
appId: this.appId,
@@ -158,6 +163,8 @@
});
},
appAction(action) {
this.lastAction = action.name;
this.errors.clear();
this.takeConfigAppAction({
userId: this.user.name,
appId: this.appId,
@@ -208,16 +215,18 @@
},
actionResult (ar) {
if (ar) {
console.log('clearing form fields...');
for (let action in this.itemActionParams) {
if (this.itemActionParams.hasOwnProperty(action)) {
this.itemActionParams[action] = {};
if (this.itemActionParams) {
for (let action in this.itemActionParams) {
if (this.itemActionParams.hasOwnProperty(action)) {
this.itemActionParams[action] = {};
}
}
}

for (let action in this.appActionParams) {
if (this.appActionParams.hasOwnProperty(action)) {
this.appActionParams[action] = {};
if (this.appActionParams) {
for (let action in this.appActionParams) {
if (this.appActionParams.hasOwnProperty(action)) {
this.appActionParams[action] = {};
}
}
}



+ 1
- 0
src/account/AppDataViewPage.vue 파일 보기

@@ -228,6 +228,7 @@
return safeEval(action.when, {'data': row}) === true;
},
dataAction(action, dataId) {
this.errors.clear();
this.takeDataAction({
userId: this.user.name,
appId: this.appId,


불러오는 중...
취소
저장