为了账号安全,请及时绑定邮箱和手机立即绑定
  • <?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE configuration PUBLIC "-//mybatis.org//DTD Config 3.0//EN" "http://mybatis.org/dtd/mybatis-3-config.dtd"> <configuration> <!-- 配置全局属性 --> <settings> <!-- 使用jdbc的getGeneratedKeys获取数据库的自增主键值 --> <setting name="useGeneratedKeys" value="true" /> <!--使用列标签替换别名 默认:true--> <setting name="useColumnLabel" value="true"/> <!--开启驼峰命名转换:Table{create_time} -> Entity{createTime} --> <setting name="mapUnderscoreToCamelCase" value="true"/> </settings>
    查看全部
  • CREATE TABLE tb_area (

    area_id int(2) NOT NULL auto_increment,

    area_name varchar(200) NOT NULL,

    priority int(2) NOT NULL DEFAULT'0',

    create_time datetime DEFAULT NULL,

    last_edit_time datetime DEFAULT NULL,

    PRIMARY KEY(area_id),

    UNIQUE KEY UK_AREA(area_name)

    )ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8;


    查看全部
  • .container{

    padding: 1rem;

    font-size: 0.9rem;

    line-height: 1.56rem;

    }

    .row{

    display: flex;

    align-items: center;

    margin-bottom: 0.8rem;

    }

    .row text{

    flex-grow: 1;

    text-align: right;

    }

    .row input{

    font-size: 0.7rem;

    flex-grow: 3;

    border: 1px solid #0099CC;

    display: inline-block;

    border-radius: 0.3rem;

    box-shadow: 0 0 0.15rem #aaa;

    padding: 0.3rem;

    }

    .row button{

    padding: 0 2rem;

    margin: 3rem 1rem;

    }


    查看全部
  • /* pages/list/list.wxss */


    .widget {

    position: relative;

    margin-top: 5rpx;

    margin-bottom: 5rpx;

    padding-top: 10rpx;

    padding-bottom: 10rpx;

    padding-left: 40rpx;

    padding-right: 40rpx;

    border: #ddd 1px solid;

    }


    .container {

    height: 100%;

    display: table;

    align-items: center;

    justify-content: space-between;

    box-sizing: border-box;

    padding-top: 10rpx;

    padding-bottom: 10rpx;

    text-align: center;

    }


    .column {

    width: 4rem;

    display: table-cell;

    }


    .link-column {

    width: 6rem;

    display: table-cell;

    }


    .link {

    color: blue;

    display: inline-table;

    }


    查看全部
  • mybatis-config.xml:
    
    
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE configuration
            PUBLIC "-//mybatis.org//DTD Config 3.0//EN"
            "http://mybatis.org/dtd/mybatis-3-config.dtd">
    <configuration>
        <!-- 配置全局属性 -->
        <settings>
            <!-- 使用jdbc的getGeneratedKeys获取数据库自增主键值 -->
            <setting name="useGeneratedKeys" value="true" />
    
            <!-- 使用列标签替换列别名 默认:true -->
            <setting name="useColumnLabel" value="true" />
    
            <!-- 开启驼峰命名转换:Table{create_time} -> Entity{createTime} -->
            <setting name="mapUnderscoreToCamelCase" value="true" />
        </settings>
    </configuration>


    查看全部
  • CREATE TABLE tb_area (

    area_id int(2) NOT NULL auto_increment,

    area_name varchar(200) NOT NULL,

    priority int(2) NOT NULL DEFAULT'0',

    create_time datetime DEFAULT NULL,

    last_edit_time datetime DEFAULT NULL,

    PRIMARY KEY(area_id),

    UNIQUE KEY UK_AREA(area_name)

    )ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8;


    查看全部
  • /* pages/operation/operation.wxss */


    .container {

    padding: 1rem;

    font-size: 0.9rem;

    line-height: 1.5rem;

    }


    .row {

    display: flex;

    align-items: center;

    margin-bottom: 0.8rem;

    }


    .row text {

    flex-grow: 1;

    text-align: right;

    }


    .row input {

    font-size: 0.7rem;

    flex-grow: 3;

    border: 1px solid #09c;

    display: inline-block;

    border-radius: 0.3rem;

    box-shadow: 0 0 0.15rem #aaa;

    padding: 0.3rem;

    }


    .row button {

    padding: 0 2rem;

    margin: 3rem 1rem;

    }



    查看全部
  • DROP TABLE IF EXISTS `tb_area`; CREATE TABLE `tb_area` ( `area_id` INT (2) NOT NULL AUTO_INCREMENT COMMENT '自增id', `area_name` VARCHAR (200) NOT NULL COMMENT '区域名称', `priority` INT (2) NOT NULL DEFAULT '0' COMMENT '优先级', `create_time` DATETIME DEFAULT NULL COMMENT '创建时间', `last_modify_time` DATETIME DEFAULT NULL COMMENT '最后修改时间', PRIMARY KEY (`area_id`), UNIQUE KEY `UK_AREA` (`area_name`) ) ENGINE = INNODB AUTO_INCREMENT = 1 DEFAULT CHARSET = utf8 ;
    查看全部
  • 加载不出ComboPoolDataSource。maven下载没有该包。解决方法:修改settings.xml使用阿里云镜像仓库下载JAR包,并强制更新maven

    查看全部
  • 表的设计与创建

    CREATE TABLE `tb_area` (  `area_id` int(2) NOT NULL AUTO_INCREMENT,  `area_name` varchar(200) NOT NULL,  `priority` int(2) NOT NULL DEFAULT '0',  `create_time` datetime DEFAULT NULL,  `last_edit_time` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,  PRIMARY KEY (`area_id`),  UNIQUE KEY `UK_AREA` (`area_name`)) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8;

    查看全部
  • CREATE TABLE `tb_area` (
      `area_id` int(2) NOT NULL AUTO_INCREMENT,
      `area_name` varchar(200) NOT NULL,
      `priority` int(2) NOT NULL DEFAULT '0',
      `create_time` datetime DEFAULT NULL,
      `last_edit_time` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
      PRIMARY KEY (`area_id`),
      UNIQUE KEY `UK_AREA` (`area_name`)
    ) ENGINE=InnoDB AUTO_INCREMENT=4 DEFAULT CHARSET=utf8;


    查看全部
  • @Bean(name = "sqlSessionFactory")
    public SqlSessionFactoryBean createSqlSessionFactoryBean() throws IOException {
        SqlSessionFactoryBean sqlSessionFactoryBean = new SqlSessionFactoryBean();
        //扫描mybatis-config.xml配置文件
        sqlSessionFactoryBean.setConfigLocation(new ClassPathResource(mybatisConfigFilePath));
        //读取jar文件信息
        PathMatchingResourcePatternResolver resolver = new PathMatchingResourcePatternResolver();
        //指定mapper文件的扫描路径
        String packagSearchPath = PathMatchingResourcePatternResolver.CLASSPATH_ALL_URL_PREFIX + mapperPath;//读取路径
        sqlSessionFactoryBean.setMapperLocations(resolver.getResources(packagSearchPath));//设置路径
        //指定数据源
        sqlSessionFactoryBean.setDataSource(dataSource);
        //指定映射实体类package的扫描路径
        sqlSessionFactoryBean.setTypeAliasesPackage(entityPackage);
        return sqlSessionFactoryBean;
    }


    查看全部
  • --DROP TABLE IF EXISTS `tb_area`;

    CREATE TABLE `tb_area`(

    `area_id` int(2) NOT NULL AUTO_INCREMENT,

    `area_name` VARCHAR(200) NOT NULL,

    `priority` int(2) NOT NULL DEFAULT 0,

    `create_time` datetime DEFAULT NULL,

    `last_edit_time` datetime DEFAULT NULL,

    PRIMARY KEY(`area_id`),

    UNIQUE KEY `UK_AREA` (`area_name`)

    ) ENGINE=INNODB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8;


    查看全部
  • creata table tb_area(

    area_id int (2) not null auto_increment,

    area_name varchar(200) not null,

    priority int(2) not null default '0',

    create_time datetime default null,

    last_edit_time datetime default null,

    primary key(area_id),

    unique key uk_area(area_name))

    engine=innoDB auto_increment=1 default charset=utf8;

    查看全部
  • <?xml version="1.0" encoding="UTF-8" ?>
    <!DOCTYPE configuration
            PUBLIC "-//mybatis.org//DTD Config 3.0//EN"
            "http://mybatis.org/dtd/mybatis-3-config.dtd">
    <configuration>
        <!-- 配置全局属性 -->
        <settings>
            <!--,使用jdbc的getGeneratedKeys获取数据库自增主键值-->
            <setting name="useGeneratedKeys" value="true"/>
            <!--让列支持别名.使用列标签替换列别名 默认:true-->
            <setting name="useColumnLabel" value="true"/>
            <!--开启驼峰命名转换:Table{create_time}->Entity{createTime}-->
            <setting name="mapUnderscoreToCamelCase" value="true"/>
        </settings>
    </configuration>


    查看全部
首页上一页1234567下一页尾页

举报

0/150
提交
取消
课程须知
1、SpringBoot和Mybatis的非常基础的知识。 2、Jdk、Maven、Mysql、Intellij Idea的安装与配置。 3、非常基础的前端开发知识(HTML、Jquery)
老师告诉你能学到什么?
1、SpringBoot + Mybatis框架的搭建 2、单元测试 3、分层设计 4、微信小程序的基本知识及本地开发 5、前后分离及联调 6、写出健壮的程序

微信扫码,参与3人拼团

意见反馈 帮助中心 APP下载
官方微信
友情提示:

您好,此课程属于迁移课程,您已购买该课程,无需重复购买,感谢您对慕课网的支持!