• 根据选择的关键字类型查询


    <select id="getDnOrder" resultType="com.shinho.dc3.order.dto.doOrder.DnOrderRes" parameterType="com.shinho.dc3.order.dto.doOrder.DnOrderSearch" >
    SELECT
    A.VBELN,
    A.VBELN VBELNCOPY,
    A.VBELN AS VBELN1,
    A.DO_VBELN,
    A.ERDAT,
    A.SHDAT,
    A.NAME,
    A.GROSS_BOX I_COUNT,
    A.GROSS_AMT G_PRICE,
    A.GROSS_AMT,
    A.ADDR,
    A.PERSON_NAME,
    A.SFA_CAR_NUM,
    SFA_NAME,
    A.INSDT,
    A.REMARK,
    A.KUNNR,
    A.LINKMAN,
    A.LINKTEL,
    A.SALE_TYPE,
    A.STATUS,
    A.SOURCE,
    A.GROSS_ZK_AMT,
    A.WAREHOUSE_ID,
    A.ATX,
    A.ZK_TYPE,
    A.ZK_AMT,
    A.UPDATEDT,
    A.DID,
    A.VL02N_DAT,
    A.SFA_STATUS,
    A.PRINT_COUNT,
    A.dn_type AS dnType,
    A.userid
    from dn_order A -- 交货单
    where A.fyfs in (60001,60003)
    <if test="did != null" >
    and A.did = #{did,jdbcType=VARCHAR}
    </if>
    <if test="dateStart != null and dateStart != ''" >
    and SUBSTR(A.erdat FROM 0 FOR 10) &gt; #{dateStart}
    </if>
    <if test="dateEnd != null and dateEnd!='' " >
    and SUBSTR(A.erdat FROM 0 FOR 10) &lt; #{dateEnd}
    </if>
    <if test="statusList != null" >
    and A.STATUS in
    <foreach collection="statusList" item="status" index="index" open="(" close=")" separator=",">
    #{status}
    </foreach>
    </if>
    <if test="wOrderType != null" >
    and A.dn_type =#{wOrderType}
    </if>
    <if test="key == '交货单号'" >
    AND A.vbeln like CONCAT('%',#{keyWord},'%')
    </if>
    <if test="key == '创建人'" >
    AND A.name like CONCAT('%',#{keyWord},'%')
    </if>
    <if test="key == '业务员'" >
    AND A.person_name like CONCAT('%',#{keyWord},'%')
    </if>
    <if test="key == '业务员'" >
    AND (A.vbeln like CONCAT('%',#{keyWord},'%')
    OR A.name like CONCAT('%',#{keyWord},'%')
    OR A.person_name like CONCAT('%',#{keyWord},'%')
    )
    </if>
    <if test="sfaStatus != null and sfaStatus!=''" >
    and A.SFA_STATUS=#{sfaStatus}
    </if>
    <if test="sfaStatus eq 'B'" >
    order by A.insdt,B.warehouse_name,BA.name
    </if>
    <if test="sfaStatus neq 'B'" >
    order by A.insdt desc
    </if>
    </select>
  • 相关阅读:
    H5 坑
    小程序上传图片
    小程序瀑布流
    vue 使用插件
    fastclick:处理移动端click事件300毫秒延迟
    h5知识总结
    vue 瀑布流实现
    vue组件 $children,$refs,$parent的使用详解
    vue轮播插件vue-awesome-swiper
    JS判断是否在微信浏览器打开
  • 原文地址:https://www.cnblogs.com/pan-my/p/10775330.html
Copyright © 2020-2023  润新知