Commit 7609556a authored by zhuangxinwei's avatar zhuangxinwei

Merge remote-tracking branch 'origin/master' into master

parents 559af62b 6480899b
......@@ -118,27 +118,27 @@ public class YxryController extends BaseController
public void importTemplate(HttpServletResponse response) throws Exception {
ExcelUtil<Yxry> util = new ExcelUtil<Yxry>(Yxry.class);
Class<? extends Yxry> clazz = new Yxry().getClass();
List<SysDictData> isYzs = DictUtils.getDictCache("yz_status");
// List<SysDictData> isYzs = DictUtils.getDictCache("yz_status");
List<SysDictData> isYins = DictUtils.getDictCache("yin_status");
List<SysDictData> areas = DictUtils.getDictCache("residential_area");
List<SysDictData> streets = DictUtils.getDictCache("street_town");
List<SysDictData> isControls = DictUtils.getDictCache("control_status");
// List<SysDictData> isControls = DictUtils.getDictCache("control_status");
List<SysDictData> isHomes = DictUtils.getDictCache("home_status");
List<SysDictData> glPlaces = DictUtils.getDictCache("isolation_status");
String[] isYz=isYzs.stream().map(SysDictData::getDictLabel).toArray(String[]::new);
// List<SysDictData> glPlaces = DictUtils.getDictCache("isolation_status");
// String[] isYz=isYzs.stream().map(SysDictData::getDictLabel).toArray(String[]::new);
String[] isYin=isYins.stream().map(SysDictData::getDictLabel).toArray(String[]::new);
String[] area=areas.stream().map(SysDictData::getDictLabel).toArray(String[]::new);
String[] street=streets.stream().map(SysDictData::getDictLabel).toArray(String[]::new);
String[] isControl=isControls.stream().map(SysDictData::getDictLabel).toArray(String[]::new);
// String[] isControl=isControls.stream().map(SysDictData::getDictLabel).toArray(String[]::new);
String[] isHome=isHomes.stream().map(SysDictData::getDictLabel).toArray(String[]::new);
String[] glPlace=glPlaces.stream().map(SysDictData::getDictLabel).toArray(String[]::new);
ExcelUtil.setClassExcelAttribute( clazz,"isYz","combo",isYz);
// String[] glPlace=glPlaces.stream().map(SysDictData::getDictLabel).toArray(String[]::new);
// ExcelUtil.setClassExcelAttribute( clazz,"isYz","combo",isYz);
ExcelUtil.setClassExcelAttribute( clazz,"isYin","combo",isYin);
ExcelUtil.setClassExcelAttribute( clazz,"area","combo",area);
ExcelUtil.setClassExcelAttribute( clazz,"street","combo",street);
ExcelUtil.setClassExcelAttribute( clazz,"isControl","combo",isControl);
// ExcelUtil.setClassExcelAttribute( clazz,"isControl","combo",isControl);
ExcelUtil.setClassExcelAttribute( clazz,"isHome","combo",isHome);
ExcelUtil.setClassExcelAttribute( clazz,"glPlace","combo",glPlace);
// ExcelUtil.setClassExcelAttribute( clazz,"glPlace","combo",glPlace);
util.importTemplateExcel(response, "阳性人员");
}
......
......@@ -26,7 +26,7 @@ public class Yxry extends BaseEntity
private Date sbDate;
/** 流调人员 */
@Excel(name = "流调人员姓名")
// @Excel(name = "流调人员姓名")
private String ldry;
/** 姓名 */
......@@ -34,11 +34,11 @@ public class Yxry extends BaseEntity
private String userName;
/** 身份证号码 */
@Excel(name = "患者身份证号码",cellType= Excel.ColumnType.STRING)
@Excel(name = "身份证号码",cellType= Excel.ColumnType.STRING)
private String cardNo;
/** 联系方式 */
@Excel(name = "患者联系方式")
@Excel(name = "联系电话")
private String phone;
/** 联系方式 */
......@@ -46,11 +46,11 @@ public class Yxry extends BaseEntity
private String userType;
/** 联系方式 */
@Excel(name = "风险来源")
@Excel(name = "风险")
private String riskSource;
/** 是否重症 */
@Excel(name = "是否重症", dictType = "yz_status",combo = "")
// @Excel(name = "是否重症", dictType = "yz_status",combo = "")
private String isYz;
/** 是否转阴 */
......@@ -86,13 +86,17 @@ public class Yxry extends BaseEntity
private String house;
/** 是否已管控 */
@Excel(name = "是否已管控", dictType = "control_status",combo = "")
// @Excel(name = "是否已管控", dictType = "control_status",combo = "")
private String isControl;
/** 是否符合居家隔离 */
@Excel(name = "是否符合居家隔离", dictType = "home_status",combo = "")
private String isHome;
/** 转运状态 */
@Excel(name = "转运状态")
private String hasAcid;
/** 转运时间 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Excel(name = "转运时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
......@@ -100,7 +104,7 @@ public class Yxry extends BaseEntity
/** 隔离位置 */
@Excel(name = "隔离位置", dictType = "isolation_status",combo = "")
// @Excel(name = "隔离位置", dictType = "isolation_status",combo = "")
private String glPlace;
/** 备注 */
......@@ -111,9 +115,6 @@ public class Yxry extends BaseEntity
// @Excel(name = "隔离状态")
private String isolationStatus;
/** 转运状态 */
// @Excel(name = "转运状态")
private String hasAcid;
/** 状态(0正常 1停用) */
......
......@@ -125,7 +125,7 @@ public class YxryServiceImpl implements IYxryService
for (Yxry zlqk : list) {
if (StringUtils.isNotEmpty(zlqk.getCardNo()) && StringUtils.isNotEmpty(zlqk.getUserName())
&&StringUtils.isNotEmpty(zlqk.getPhone())
&&StringUtils.isNotEmpty(zlqk.getIsYin()) && StringUtils.isNotEmpty(zlqk.getGlPlace())){
&&StringUtils.isNotEmpty(zlqk.getIsYin())){
//校验身份证是否重复
List<Yxry> zlqks = yxryMapper.selectYxryByCard(zlqk.getCardNo());
if (!zlqks.isEmpty())
......@@ -148,7 +148,7 @@ public class YxryServiceImpl implements IYxryService
}
} else if (StringUtils.isEmpty(zlqk.getCardNo()) && StringUtils.isEmpty(zlqk.getUserName())
&&StringUtils.isEmpty(zlqk.getPhone())
&&StringUtils.isEmpty(zlqk.getIsYin()) && StringUtils.isEmpty(zlqk.getGlPlace())) {
&&StringUtils.isEmpty(zlqk.getIsYin()) ) {
continue;
} else {
failureList.add(zlqk);
......
......@@ -9,6 +9,26 @@ export function listYxry(query) {
})
}
// 下载治疗情况导入模板
export function importTemplate(params) {
return request({
url: '/system/yxry/importTemplate',
method: 'post',
responseType: 'blob',
params
})
}
// 导入用户信息
export function importExcel(data) {
return request({
url: '/system/yxry/importData',
method: 'post',
responseType: 'blob',
data
})
}
// 查询阳性人员详细
export function getYxry(id) {
return request({
......
......@@ -435,9 +435,8 @@
</template>
<script>
import { listYxry, getYxry, delYxry, addYxry, updateYxry } from "@/api/system/yxry";
import { listYxry, getYxry, delYxry, addYxry, updateYxry, importTemplate, importExcel } from "@/api/system/yxry";
import { getToken } from '@/utils/auth'
import { importTemplate, importExcel } from "@/api/system/zlqk";
export default {
name: "Yxry",
......@@ -459,7 +458,7 @@ export default {
// 设置上传的请求头部
headers: { Authorization: "Bearer " + getToken() },
// 上传的地址
url: process.env.VUE_APP_BASE_API + "/system/zlqk/importTemplate"
url: process.env.VUE_APP_BASE_API + "/system/yxry/importTemplate"
},
// 遮罩层
loading: true,
......
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