Commit 6d1f25e7 authored by daniel's avatar daniel

feat(delivery): 赛包邮寄优化查询

parent 8e5675a7
package com.dlbridge.jadp.plugins.partner.bean;
import com.dlbridge.jadp.common.persistence.JaapRecord;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.*;
import lombok.experimental.Accessors;
import java.sql.Date;
@EqualsAndHashCode(callSuper = false)
@ApiModel(value = "赛包存取实体类", description = "赛包存取实体类")
@Getter
@Setter
@Data
@Accessors(chain = true)
@ToString
public class BagDelivery extends JaapRecord<BagDelivery> {
......@@ -23,6 +25,14 @@ public class BagDelivery extends JaapRecord<BagDelivery> {
@ApiModelProperty(value = "姓名", notes = "姓名")
private String name;
@ApiModelProperty(value = "创建时间", notes = "创建时间")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date createDate;
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@ApiModelProperty(value = "更新时间", notes = "更新时间")
private Date updateDate;
@ApiModelProperty(value = "参赛号", notes = "参赛号")
private String markNo;
......
......@@ -14,4 +14,8 @@ public class BagParam {
@ApiModelProperty(value = "状态(1:提交,2:已处理)", notes = "状态(1:提交,2:已处理)")
private Integer status;
@ApiModelProperty(value = "关键字", notes = "关键字")
private String keyword;
@ApiModelProperty(value = "参赛号", notes = "参赛号")
private String markNo;
}
......@@ -55,6 +55,8 @@
select
id,
cmpt_id cmptId,
create_date createDate,
update_date updateDate,
name,
mark_no markNo,
phone,
......@@ -69,7 +71,7 @@
from bag_delivery
where del_flag = 0
<include refid="bag-where-sql"/>
order by create_date
order by create_date desc
limit #{page.offset},#{page.size}
</select>
......@@ -85,8 +87,12 @@
<if test="param.status != null">
and status=#{param.status}
</if>
<if test="param.keyword != null and param.keyword != ''">
and mark_no like concat('%',#{param.keyword},'%') or name like concat('%',#{param.keyword},'%') or phone like concat('%',#{param.keyword},'%')
</if>
<if test="param.markNo != null and param.markNo != ''">
and mark_no = #{param.markNo}
</if>
</sql>
</mapper>
\ No newline at end of file
......@@ -270,6 +270,16 @@
{{statusOpt.name}}
</button>
</div>
<div class="input-group ml-2 mr-2">
<input type="text" class="form-control" placeholder="请输入搜索关键字"
@keyup.enter="fetchData" v-model="keyword"
aria-label="Input group example" aria-describedby="btnGroupAddon">
</div>
<button class="btn btn-sm ml-auto " :class="{
'btn-danger':keyword
}" @click="fetchData">
搜索
</button>
</div>
</div>
......@@ -285,7 +295,7 @@
</colgroup>
<thead>
<tr>
<th style="text-align: left">选手</th>
<th style="text-align: left;padding-left:5px;">选手</th>
<th style="text-align: left">地址</th>
<th style="text-align: left">物流</th>
<th style="text-align: left">状态</th>
......@@ -305,6 +315,9 @@
<span class="lh-1.2">
手机号:{{item.phone}}
</span>
<span class="lh-1.2">
申请时间:{{item.createDate}}
</span>
<span v-if="item.remark" class="lh-1.2">
备注:{{item.remark}}
</span>
......@@ -460,6 +473,7 @@
dialog: false,
title: '赛包邮寄',
statusIndex: 0,
keyword: '',
statusOptions: [
{
name: "全部",
......@@ -589,7 +603,7 @@
// 查询所有
fetchData() {
if (!getCId()) return
const url = '/gk/bag/delivery/list?status=' + this.statusOptions[this.statusIndex].value + '&cmptId=' + getCId()
const url = '/gk/bag/delivery/list?status=' + this.statusOptions[this.statusIndex].value + '&cmptId=' + getCId() + '&keyword=' + this.keyword
$.ajax({
type: 'GET',
contentType: 'application/json',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment