---
title: "miscellaneous (angularjs, extjs, spring security, etc)"
author: "chenss"
date: "2015-02-28T16:20:50Z"
tags: []
categories: ["Web前端"]
slug: "miscellaneous-angularjs-extjs-spring-security-etc"
draft: false
lastmod: "2015-02-28T16:20:50Z"
id: 2187585
url: "https://chenss.iteye.com/blog/2187585"
---

--&gt;angularjs: highlight table rows on hover: &lt;table class="table-hover"&gt;

--&gt;extjs: update element content at another iframe, and add listener:

      var ele = parent.frames\["banner"].document.getElementById('userdiv');  
      //alert(ele);  
      ele.innerHTML=obj.name+'('+obj.details\[0]+')';//ws/loadData: obj.username  
      Ext.get(ele).addListener("click",function(){alert(RegReport.security.user.name);});

--&gt;extjs: global constant:

    Ext.define('RegReport.security', {  
        singleton : true  
    });

 

        Ext.Ajax.request({  
           url: '/web/ws/loadUserinfo',  
           method:'get',  
           params: {name:'css'},  
           success: function(response, opts) {  
              var obj = Ext.decode(response.responseText);  
              RegReport.security.user=obj;  
           }  
        });

--&gt;spring security:

    extends AbstractSecurityWebApplicationInitializer  
      
    @Configuration  
    @EnableWebSecurity  
    public class SecurityConfig extends WebSecurityConfigurerAdapter  
      
    http.csrf().disable();  
    http.headers().disable();  
    http.authorizeRequests().antMatchers("/logout", "/login\*\*","/login\*").permitAll();