Commit 233ebbfc by liuguorong93

keepAlive 的 添加

parent e468f1ba
...@@ -98,6 +98,7 @@ export default [ ...@@ -98,6 +98,7 @@ export default [
meta: { meta: {
title: '技术单位管理', title: '技术单位管理',
isOneMenu: false, isOneMenu: false,
keepAlive: true,
oneMenuName: 'jqjsgzgl', oneMenuName: 'jqjsgzgl',
paixu: 1, paixu: 1,
routeNames: ['teUnitManageEdit', 'teUnitManageAdd'], routeNames: ['teUnitManageEdit', 'teUnitManageAdd'],
...@@ -158,6 +159,7 @@ export default [ ...@@ -158,6 +159,7 @@ export default [
title: '警犬技术人员管理', title: '警犬技术人员管理',
iconfont: 'icon-renyuanguanli_jingquan', iconfont: 'icon-renyuanguanli_jingquan',
isOneMenu: true, isOneMenu: true,
keepAlive: true,
routeNames: ['artisanManageEdit', 'artisanManageAdd'] routeNames: ['artisanManageEdit', 'artisanManageAdd']
} }
}, },
...@@ -217,6 +219,7 @@ export default [ ...@@ -217,6 +219,7 @@ export default [
meta: { meta: {
title: '警用工作犬信息管理', title: '警用工作犬信息管理',
isOneMenu: false, isOneMenu: false,
keepAlive: true,
oneMenuName: 'poDogManage', oneMenuName: 'poDogManage',
paixu: 2, paixu: 2,
routeNames: ['poDogJobManageEdit', 'poDogJobManageAdd'], routeNames: ['poDogJobManageEdit', 'poDogJobManageAdd'],
......
...@@ -148,7 +148,7 @@ var rules = { ...@@ -148,7 +148,7 @@ var rules = {
}, },
// 身份证号码(必填) // 身份证号码(必填)
sfzhRulesRequired: (rule, value, callback) => { sfzhRulesRequired: (rule, value, callback) => {
let myreg = /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/ let myreg = /^([1-6][1-9]|50)\d{4}(18|19|20)\d{2}((0[1-9])|10|11|12)(([0-2][1-9])|10|20|30|31)\d{3}[0-9Xx]$/
if (!value) { if (!value) {
callback(new Error('请输入身份证号码')) callback(new Error('请输入身份证号码'))
} else { } else {
......
...@@ -91,7 +91,10 @@ ...@@ -91,7 +91,10 @@
</span> </span>
</div> </div>
</div> </div>
<router-view></router-view> <keep-alive>
<router-view v-if="$route.meta.keepAlive"></router-view>
</keep-alive>
<router-view v-if="!$route.meta.keepAlive"></router-view>
</div> </div>
</div> </div>
</div> </div>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment