<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.yunzhi.marketing.mapper.TaMiniappMapper">
    <select id="getAllAvaliableMiniapps" resultType="com.yunzhi.marketing.entity.TaMiniapp">
        SELECT
            s.*
        FROM
            ta_user t
        INNER JOIN ta_miniapp s ON t.org_id = s.org_id
        WHERE
            t.`status` = 1
        and t.is_admin = 1
        AND t.exp_date &gt;= now()
    </select>
</mapper>
