| 
						
						
							
								
							
						
						
					 | 
					 | 
					@ -42,33 +42,33 @@ const auth = function(authConfig, permission, role, permissions, roles) { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					  return false | 
					 | 
					 | 
					 | 
					  return false | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					} | 
					 | 
					 | 
					 | 
					} | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					
 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					/** | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 * 阻止的 click 事件监听 | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 * @param event | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 * @returns {boolean} | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 */ | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					const preventClick = function (event) { | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					  event.preventDefault() | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					  event.stopPropagation() | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					  return false | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					} | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					
 | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					const checkInject = function (el, binding,vnode) { | 
					 | 
					 | 
					 | 
					const checkInject = function (el, binding,vnode) { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					  const type = binding.arg | 
					 | 
					 | 
					 | 
					  const type = binding.arg | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					  const check = binding.value | 
					 | 
					 | 
					 | 
					  const check = binding.value | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					  const instance = vnode.context | 
					 | 
					 | 
					 | 
					  const instance = vnode.context | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					  const $auth = instance.$auth | 
					 | 
					 | 
					 | 
					  const $auth = instance.$auth | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					  if (!$auth || !$auth(check, type)) { | 
					 | 
					 | 
					 | 
					  if (!$auth || !$auth(check, type)) { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    el.classList.add('disabled') | 
					 | 
					 | 
					 | 
					    addDisabled(el) | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    el.setAttribute('title', '无此权限') | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    el.addEventListener('click', preventClick, true) | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					  } else { | 
					 | 
					 | 
					 | 
					  } else { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    el.classList.remove('disabled') | 
					 | 
					 | 
					 | 
					    removeDisabled(el) | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    el.removeAttribute('title') | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    el.removeEventListener('click', preventClick, true) | 
					 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					  } | 
					 | 
					 | 
					 | 
					  } | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					} | 
					 | 
					 | 
					 | 
					} | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					
 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					const addDisabled = function (el) { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					  if (el.tagName === 'BUTTON') { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					    el.setAttribute('disabled', 'disabled') | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					  } else { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					    el.classList.add('disabled') | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					  } | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					  el.setAttribute('title', '无此权限') | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					} | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					const removeDisabled = function (el) { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					  el.classList.remove('disabled') | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					  el.removeAttribute('disabled') | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					  el.removeAttribute('title') | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					} | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					const AuthorityPlugin = { | 
					 | 
					 | 
					 | 
					const AuthorityPlugin = { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					  install(Vue) { | 
					 | 
					 | 
					 | 
					  install(Vue) { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    Vue.directive('auth', { | 
					 | 
					 | 
					 | 
					    Vue.directive('auth', { | 
				
			
			
		
	
	
		
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
					 | 
					@ -77,6 +77,9 @@ const AuthorityPlugin = { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					      }, | 
					 | 
					 | 
					 | 
					      }, | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					      update(el, binding,vnode) { | 
					 | 
					 | 
					 | 
					      update(el, binding,vnode) { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					        checkInject(el, binding, vnode) | 
					 | 
					 | 
					 | 
					        checkInject(el, binding, vnode) | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					      }, | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					      unbind(el) { | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					 | 
					        removeDisabled(el) | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					      } | 
					 | 
					 | 
					 | 
					      } | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    }) | 
					 | 
					 | 
					 | 
					    }) | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					 | 
					    Vue.mixin({ | 
					 | 
					 | 
					 | 
					    Vue.mixin({ | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
					 | 
					
  |