我的控制器:
package com.market;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
@Controller
public class Controllerx {
@Autowired
private View frame;
/*
private void init() {
this.frame.addWindowListener(this);
registerAction(frame.getbEnter(), new AbstractAction() {
private List<Funcionarios> list;
@Override
public void action() {
if (!frame.getjLogin().getText().trim().isEmpty() || !frame.getjPassword().getText().trim().isEmpty()) {
}else {
JOptionPane.showMessageDialog(frame, null, "Campo vázio", JOptionPane.INFORMATION_MESSAGE);
}
}
@Override
public void posAction() {
cleanUp();
}
});
}
*/
public void show() {
frame.setVisible(true);
}
}
我的主要:
@SpringBootApplication
@EnableAutoConfiguration
public class Market1Application {
public static void main(String[] args) {
ConfigurableApplicationContext context = new SpringApplicationBuilder(Market1Application.class).headless(false).run(args);
Controllerx appLogin = context.getBean(Controllerx.class);
}
}
我的看法:
package com.market;
import java.awt.FlowLayout;
import java.awt.GridLayout;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JTextField;
import org.springframework.stereotype.Component;
慕雪6442864
守着一只汪
人到中年有点甜
相关分类