fix: 增加查询的时间过滤(暂时未生效)

dev_refactor_0118
Lxy 4 months ago
parent aef00b9b6e
commit b3ed90aa42

@ -191,4 +191,14 @@ public class NewStocksController extends BaseController
List<NewStockBasic> list = newStockBasicService.selectNewStockBasicList(newStockBasic);
return AjaxResult.success(list);
}
/**
*
*/
@GetMapping("/tradeDates")
public AjaxResult getTradeDates()
{
List<String> tradeDates = newStocksService.selectTradeDates();
return AjaxResult.success(tradeDates);
}
}

@ -100,4 +100,11 @@ public interface NewStocksMapper
* @return
*/
public NewStocks selectNewStocksByCodeAndDate(String code, String tradeDate);
/**
*
*
* @return
*/
public List<String> selectTradeDates();
}

@ -108,4 +108,11 @@ public interface INewStocksService
* @return
*/
public Object analyzeNewStocks(NewStocks newStocks);
/**
*
*
* @return
*/
public List<String> selectTradeDates();
}

@ -323,4 +323,10 @@ public class NewStocksServiceImpl implements INewStocksService
result.put("stocksList", stocksList);
return result;
}
@Override
public List<String> selectTradeDates()
{
return newStocksMapper.selectTradeDates();
}
}

@ -40,7 +40,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="code != null and code != ''">
and code = #{code}
</if>
<if test="tradeDate != null and tradeDate != ''">
<if test="tradeDate != null">
and trade_date = #{tradeDate}
</if>
<if test="changeRate != null">
@ -195,4 +195,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<include refid="selectNewStocksVo" />
where code = #{code} and trade_date = #{tradeDate}
</select>
<select id="selectTradeDates" resultType="String">
select distinct trade_date from new_stocks order by trade_date desc
</select>
</mapper>

@ -116,5 +116,13 @@ export default {
method: 'get',
params: { query }
})
},
// 获取交易日期列表
getTradeDates() {
return request({
url: '/newstocksystem/newstocks/tradeDates',
method: 'get'
})
}
}

@ -288,7 +288,7 @@ export default {
pageSize: 10,
code: null,
name: null,
tradeDate: null,
tradeDate: new Date(),
changeRate: null
},
//
@ -317,7 +317,7 @@ export default {
//
updateSupport: 0,
//
tradeDate: new Date().toISOString().split('T')[0],
tradeDate: new Date(),
//
url: '/newstocksystem/newstocks/importData'
},
@ -529,4 +529,4 @@ export default {
.fixed-width {
width: 150px;
}
</style>
</style>

Loading…
Cancel
Save