File tree Expand file tree Collapse file tree 2 files changed +25
-2
lines changed Expand file tree Collapse file tree 2 files changed +25
-2
lines changed Original file line number Diff line number Diff line change @@ -139,8 +139,13 @@ export default {
139139 this .contentLoading = false ;
140140 })
141141 .catch (err => {
142- this .$SegmentMessage .error (this , ' Problem loading error' );
143- console .log (err);
142+ if (err .request .status === 404 ) {
143+ this .$SegmentMessage .error (this , ' Problem not found' );
144+ } else if (err .request .status === 403 ) {
145+ this .$SegmentMessage .error (this , ' Permission denied' );
146+ } else {
147+ this .$SegmentMessage .error (this , ' Unkown error' );
148+ }
144149 });
145150 },
146151 back () {
Original file line number Diff line number Diff line change @@ -129,6 +129,15 @@ export default {
129129 this .isActive = data .is_active ;
130130 this .lang = String (data .lang );
131131 }
132+ })
133+ .catch (err => {
134+ if (err .request .status === 404 ) {
135+ this .$SegmentMessage .error (this , ' User not found' );
136+ } else if (err .request .status === 403 ) {
137+ this .$SegmentMessage .error (this , ' Permission denied' );
138+ } else {
139+ this .$SegmentMessage .error (this , ' Unkown error' );
140+ }
132141 });
133142 },
134143 submit () {
@@ -154,6 +163,15 @@ export default {
154163 lang: this .lang
155164 });
156165 }
166+ })
167+ .catch (err => {
168+ if (err .request .status === 404 ) {
169+ this .$SegmentMessage .error (this , ' User not found' );
170+ } else if (err .request .status === 403 ) {
171+ this .$SegmentMessage .error (this , ' Permission denied' );
172+ } else {
173+ this .$SegmentMessage .error (this , ' Unkown error' );
174+ }
157175 });
158176 }
159177 },
You can’t perform that action at this time.
0 commit comments