mirror of
https://gitee.com/lab1024/smart-admin.git
synced 2025-10-02 02:06:38 +08:00
Error page template added
This commit is contained in:
parent
2f5ef11c15
commit
477d0e8602
9
rc-busness/app.html
Normal file
9
rc-busness/app.html
Normal file
@ -0,0 +1,9 @@
|
||||
<!DOCTYPE html>
|
||||
<html {{ HTML_ATTRS }}>
|
||||
<head {{ HEAD_ATTRS }}>
|
||||
{{ HEAD }}
|
||||
</head>
|
||||
<body {{ BODY_ATTRS }}>
|
||||
{{ APP }}
|
||||
</body>
|
||||
</html>
|
56
rc-busness/app/views/error.html
Normal file
56
rc-busness/app/views/error.html
Normal file
@ -0,0 +1,56 @@
|
||||
<!doctype html>
|
||||
<html class="no-js" lang="" style='font-size:16px;'>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="x-ua-compatible" content="ie=edge">
|
||||
<title></title>
|
||||
<meta name="description" content="">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<style type="text/css">
|
||||
html,body{
|
||||
width:100%;
|
||||
height:100%;
|
||||
overflow:hidden;
|
||||
}
|
||||
.wrapper{
|
||||
width:100%;
|
||||
height:100%;
|
||||
display:flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
text-align: center;
|
||||
}
|
||||
h2{
|
||||
font-size: 2.5rem;
|
||||
line-height: 3.5rem;
|
||||
color:#e2001a;
|
||||
}
|
||||
a{
|
||||
color:#666;
|
||||
text-decoration: none;
|
||||
padding-bottom:.25rem;
|
||||
border-bottom: 1px solid #666;
|
||||
}
|
||||
a:hover {
|
||||
color:#e2001a;
|
||||
border-color: #e2001a;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="wrapper">
|
||||
<img src="./images/default.jpg">
|
||||
<div>
|
||||
<h2>检测到系统错误</h2>
|
||||
<div>
|
||||
请联系管理员或尝试其他操作
|
||||
<br/><br/>
|
||||
<a href="/">回到首页</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
67
rc-busness/layouts/error.vue
Normal file
67
rc-busness/layouts/error.vue
Normal file
@ -0,0 +1,67 @@
|
||||
<template>
|
||||
<div class="wrapper">
|
||||
<img src="/images/default.jpg">
|
||||
<div v-if='error.statusCode==404'>
|
||||
<h2>{{ error.statusCode }} 找不到指定页面</h2>
|
||||
<div>
|
||||
<a href="javascript:history.back()">返回上一页</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div v-if='error.statusCode!=404'>
|
||||
<h2>{{ error.statusCode }} 发现未知错误</h2>
|
||||
<div>
|
||||
<nuxt-link to="/">返回首页</nuxt-link>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
props: ['error'],
|
||||
layout: 'error',
|
||||
created(){
|
||||
|
||||
},
|
||||
method:{
|
||||
backToLastPage(){
|
||||
window.history.back();
|
||||
},
|
||||
backToHome(){
|
||||
window.location.href="/";
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="less" scoped >
|
||||
html,body{
|
||||
width:100%;
|
||||
height:100%;
|
||||
overflow:hidden;
|
||||
}
|
||||
.wrapper{
|
||||
width:100%;
|
||||
height:100%;
|
||||
display:flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
text-align: center;
|
||||
}
|
||||
h2{
|
||||
font-size: 2.5rem;
|
||||
line-height: 3.5rem;
|
||||
color:#e2001a;
|
||||
}
|
||||
a{
|
||||
color:#666;
|
||||
text-decoration: none;
|
||||
padding-bottom:.25rem;
|
||||
border-bottom: 1px solid #666;
|
||||
}
|
||||
a:hover {
|
||||
color:#e2001a;
|
||||
border-color: #e2001a;
|
||||
}
|
||||
</style>
|
@ -321,10 +321,14 @@ export default {
|
||||
stopIndex++;
|
||||
}
|
||||
}
|
||||
productAttachmentList = newlist[0].productAttachmentList;
|
||||
if(curItem.productAttachmentList != undefined)
|
||||
productAttachmentList = curItem.productAttachmentList;
|
||||
if(curItem.productName == undefined)
|
||||
curItem = newlist[0];
|
||||
userbuy = true;
|
||||
}
|
||||
|
||||
if(!curItem || curItem.productName == undefined)
|
||||
throw new Error("The id property is missing.");
|
||||
let crumbs = [
|
||||
{
|
||||
path:'/productdetails/productlist/',
|
||||
|
Loading…
Reference in New Issue
Block a user