diff --git a/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/controller/VnaRawDataController.java b/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/controller/VnaRawDataController.java deleted file mode 100644 index 955c782e..00000000 --- a/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/controller/VnaRawDataController.java +++ /dev/null @@ -1,170 +0,0 @@ -package com.ruoyi.rfMsg.controller; - -import com.alibaba.fastjson.JSONObject; -import com.fasterxml.jackson.databind.ObjectMapper; -import com.ruoyi.common.annotation.Log; -import com.ruoyi.common.core.controller.BaseController; -import com.ruoyi.common.core.domain.AjaxResult; -import com.ruoyi.common.core.page.TableDataInfo; -import com.ruoyi.common.enums.BusinessType; -import com.ruoyi.common.utils.poi.ExcelUtil; -import com.ruoyi.rfMsg.domain.VnaRawData; -import com.ruoyi.rfMsg.service.IVnaRawDataService; -import org.apache.shiro.authz.annotation.RequiresPermissions; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Controller; -import org.springframework.ui.ModelMap; -import org.springframework.web.bind.annotation.*; - -import java.util.ArrayList; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -/** - * rf测试历史结果Controller - * - * @author ruoyi - * @date 2023-06-28 - */ -@Controller -@RequestMapping("/rfMsg/vnaRawData") -public class VnaRawDataController extends BaseController -{ - private String prefix = "rfMsg/vnaRawData"; - - @Autowired - private IVnaRawDataService vnaRawDataService; - - @RequiresPermissions("rfMsg:vnaRawData:view") - @GetMapping() - public String vnaRawData() - { - return prefix + "/vnaRawData"; - } - - /** - * 查询rf测试历史结果列表 - */ - @RequiresPermissions("rfMsg:vnaRawData:list") - @PostMapping("/list") - @ResponseBody - public TableDataInfo list(VnaRawData vnaRawData) - { - startPage(); - List list = vnaRawDataService.selectVnaRawDataList(vnaRawData); - return getDataTable(list); - } - - @PostMapping("/getDataById/{id}") - @ResponseBody - public List getDataById(@PathVariable("id") Long id) - { - startPage(); - VnaRawData vnaRawData = vnaRawDataService.selectVnaRawDataById(id); - String frequency = vnaRawData.getFrequency(); - System.out.println(frequency); - Map mapObj = JSONObject.parseObject(frequency,Map.class); - List listKey = new ArrayList(); - List listValue = new ArrayList(); - List listValueList = new ArrayList(); -// System.out.println("这个是用JSONObject的parseObject方法并执行返回类型来解析JSON字符串!!!"); -// for (Object map: mapObj.entrySet()){ -// System.out.println(((Map.Entry)map).getKey()+":"+((Map.Entry)map).getValue()); -// listKey.add(((Map.Entry)map).getKey()); -// listValue.add(((Map.Entry)map).getValue()); -// } -// LinkedHashMap map = JSONUtil.toBean(frequency, new TypeReference>() {}, true); -// for (Map.Entry entry : map.entrySet()) { -// System.out.println(entry.getKey() + ": " + entry.getValue()); -// listKey.add((entry.getKey())); -// listValue.add((entry.getValue())); -// } - try { - ObjectMapper objectMapper = new ObjectMapper(); - com.fasterxml.jackson.core.type.TypeReference> typeRef = new com.fasterxml.jackson.core.type.TypeReference>() {}; - LinkedHashMap map = objectMapper.readValue(frequency, typeRef); - for (Map.Entry entry : map.entrySet()) { - System.out.println(entry.getKey() + ": " + entry.getValue()); - listKey.add((entry.getKey())); - listValue.add((entry.getValue())); - } - } catch (Exception e) { - System.out.println("序列化出错"); - } - listValueList.add(listKey); - listValueList.add(listValue); - System.out.println(listValueList); - return listValueList; - } - - /** - * 导出rf测试历史结果列表 - */ - @RequiresPermissions("rfMsg:vnaRawData:export") - @Log(title = "rf测试历史结果", businessType = BusinessType.EXPORT) - @PostMapping("/export") - @ResponseBody - public AjaxResult export(VnaRawData vnaRawData) - { - List list = vnaRawDataService.selectVnaRawDataList(vnaRawData); - ExcelUtil util = new ExcelUtil(VnaRawData.class); - return util.exportExcel(list, "rf测试历史结果数据"); - } - - /** - * 新增rf测试历史结果 - */ - @GetMapping("/add") - public String add() - { - return prefix + "/add"; - } - - /** - * 新增保存rf测试历史结果 - */ - @RequiresPermissions("rfMsg:vnaRawData:add") - @Log(title = "rf测试历史结果", businessType = BusinessType.INSERT) - @PostMapping("/add") - @ResponseBody - public AjaxResult addSave(VnaRawData vnaRawData) - { - return toAjax(vnaRawDataService.insertVnaRawData(vnaRawData)); - } - - /** - * 修改rf测试历史结果 - */ - @GetMapping("/edit/{id}") - public String edit(@PathVariable("id") Long id, ModelMap mmap) - { - VnaRawData vnaRawData = vnaRawDataService.selectVnaRawDataById(id); - mmap.put("vnaRawData", vnaRawData); - return prefix + "/edit"; - } - - /** - * 修改保存rf测试历史结果 - */ - @RequiresPermissions("rfMsg:vnaRawData:edit") - @Log(title = "rf测试历史结果", businessType = BusinessType.UPDATE) - @PostMapping("/edit") - @ResponseBody - public AjaxResult editSave(VnaRawData vnaRawData) - { - return toAjax(vnaRawDataService.updateVnaRawData(vnaRawData)); - } - - /** - * 删除rf测试历史结果 - */ - @RequiresPermissions("rfMsg:vnaRawData:remove") - @Log(title = "rf测试历史结果", businessType = BusinessType.DELETE) - @PostMapping( "/remove") - @ResponseBody - public AjaxResult remove(String ids) - { - return toAjax(vnaRawDataService.deleteVnaRawDataByIds(ids)); - } -} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/domain/VnaRawData.java b/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/domain/VnaRawData.java deleted file mode 100644 index f40e029e..00000000 --- a/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/domain/VnaRawData.java +++ /dev/null @@ -1,133 +0,0 @@ -package com.ruoyi.rfMsg.domain; - -import org.apache.commons.lang3.builder.ToStringBuilder; -import org.apache.commons.lang3.builder.ToStringStyle; -import com.ruoyi.common.annotation.Excel; -import com.ruoyi.common.core.domain.BaseEntity; - -/** - * rf测试历史结果对象 vna_raw_data - * - * @author ruoyi - * @date 2023-06-28 - */ -public class VnaRawData extends BaseEntity -{ - private static final long serialVersionUID = 1L; - - /** id */ - private Long id; - - /** 时间 */ - @Excel(name = "时间") - private String date; - - /** 序列号(设备) */ - @Excel(name = "序列号", readConverterExp = "设=备") - private String serialNumber; - - /** 操作人 */ - @Excel(name = "操作人") - private String operator; - - /** 是否通过,0为NG,1为PASS */ - @Excel(name = "是否通过,0为NG,1为PASS") - private Integer status; - - /** 端口号,例:PORT1 */ - @Excel(name = "端口号,例:PORT1") - private String port; - - /** 频率 */ - private String frequency; - - /** 数值,必须对应频率 */ - private String value; - - public void setId(Long id) - { - this.id = id; - } - - public Long getId() - { - return id; - } - public void setDate(String date) - { - this.date = date; - } - - public String getDate() - { - return date; - } - public void setSerialNumber(String serialNumber) - { - this.serialNumber = serialNumber; - } - - public String getSerialNumber() - { - return serialNumber; - } - public void setOperator(String operator) - { - this.operator = operator; - } - - public String getOperator() - { - return operator; - } - public void setStatus(Integer status) - { - this.status = status; - } - - public Integer getStatus() - { - return status; - } - public void setPort(String port) - { - this.port = port; - } - - public String getPort() - { - return port; - } - public void setFrequency(String frequency) - { - this.frequency = frequency; - } - - public String getFrequency() - { - return frequency; - } - public void setValue(String value) - { - this.value = value; - } - - public String getValue() - { - return value; - } - - @Override - public String toString() { - return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE) - .append("id", getId()) - .append("date", getDate()) - .append("serialNumber", getSerialNumber()) - .append("operator", getOperator()) - .append("status", getStatus()) - .append("port", getPort()) - .append("frequency", getFrequency()) - .append("value", getValue()) - .toString(); - } -} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/mapper/VnaRawDataMapper.java b/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/mapper/VnaRawDataMapper.java deleted file mode 100644 index c4bf7757..00000000 --- a/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/mapper/VnaRawDataMapper.java +++ /dev/null @@ -1,62 +0,0 @@ -package com.ruoyi.rfMsg.mapper; - -import com.ruoyi.rfMsg.domain.VnaRawData; - -import java.util.List; - -/** - * rf测试历史结果Mapper接口 - * - * @author ruoyi - * @date 2023-06-28 - */ -public interface VnaRawDataMapper -{ - /** - * 查询rf测试历史结果 - * - * @param id rf测试历史结果ID - * @return rf测试历史结果 - */ - public VnaRawData selectVnaRawDataById(Long id); - - /** - * 查询rf测试历史结果列表 - * - * @param vnaRawData rf测试历史结果 - * @return rf测试历史结果集合 - */ - public List selectVnaRawDataList(VnaRawData vnaRawData); - - /** - * 新增rf测试历史结果 - * - * @param vnaRawData rf测试历史结果 - * @return 结果 - */ - public int insertVnaRawData(VnaRawData vnaRawData); - - /** - * 修改rf测试历史结果 - * - * @param vnaRawData rf测试历史结果 - * @return 结果 - */ - public int updateVnaRawData(VnaRawData vnaRawData); - - /** - * 删除rf测试历史结果 - * - * @param id rf测试历史结果ID - * @return 结果 - */ - public int deleteVnaRawDataById(Long id); - - /** - * 批量删除rf测试历史结果 - * - * @param ids 需要删除的数据ID - * @return 结果 - */ - public int deleteVnaRawDataByIds(String[] ids); -} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/service/IVnaRawDataService.java b/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/service/IVnaRawDataService.java deleted file mode 100644 index 10570fa0..00000000 --- a/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/service/IVnaRawDataService.java +++ /dev/null @@ -1,61 +0,0 @@ -package com.ruoyi.rfMsg.service; - -import java.util.List; -import com.ruoyi.rfMsg.domain.VnaRawData; - -/** - * rf测试历史结果Service接口 - * - * @author ruoyi - * @date 2023-06-28 - */ -public interface IVnaRawDataService -{ - /** - * 查询rf测试历史结果 - * - * @param id rf测试历史结果ID - * @return rf测试历史结果 - */ - public VnaRawData selectVnaRawDataById(Long id); - - /** - * 查询rf测试历史结果列表 - * - * @param vnaRawData rf测试历史结果 - * @return rf测试历史结果集合 - */ - public List selectVnaRawDataList(VnaRawData vnaRawData); - - /** - * 新增rf测试历史结果 - * - * @param vnaRawData rf测试历史结果 - * @return 结果 - */ - public int insertVnaRawData(VnaRawData vnaRawData); - - /** - * 修改rf测试历史结果 - * - * @param vnaRawData rf测试历史结果 - * @return 结果 - */ - public int updateVnaRawData(VnaRawData vnaRawData); - - /** - * 批量删除rf测试历史结果 - * - * @param ids 需要删除的数据ID - * @return 结果 - */ - public int deleteVnaRawDataByIds(String ids); - - /** - * 删除rf测试历史结果信息 - * - * @param id rf测试历史结果ID - * @return 结果 - */ - public int deleteVnaRawDataById(Long id); -} diff --git a/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/service/impl/VnaRawDataServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/service/impl/VnaRawDataServiceImpl.java deleted file mode 100644 index fee03c38..00000000 --- a/ruoyi-admin/src/main/java/com/ruoyi/rfMsg/service/impl/VnaRawDataServiceImpl.java +++ /dev/null @@ -1,94 +0,0 @@ -package com.ruoyi.rfMsg.service.impl; - -import java.util.List; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.stereotype.Service; -import com.ruoyi.rfMsg.mapper.VnaRawDataMapper; -import com.ruoyi.rfMsg.domain.VnaRawData; -import com.ruoyi.rfMsg.service.IVnaRawDataService; -import com.ruoyi.common.core.text.Convert; - -/** - * rf测试历史结果Service业务层处理 - * - * @author ruoyi - * @date 2023-06-28 - */ -@Service -public class VnaRawDataServiceImpl implements IVnaRawDataService -{ - @Autowired - private VnaRawDataMapper vnaRawDataMapper; - - /** - * 查询rf测试历史结果 - * - * @param id rf测试历史结果ID - * @return rf测试历史结果 - */ - @Override - public VnaRawData selectVnaRawDataById(Long id) - { - return vnaRawDataMapper.selectVnaRawDataById(id); - } - - /** - * 查询rf测试历史结果列表 - * - * @param vnaRawData rf测试历史结果 - * @return rf测试历史结果 - */ - @Override - public List selectVnaRawDataList(VnaRawData vnaRawData) - { - return vnaRawDataMapper.selectVnaRawDataList(vnaRawData); - } - - /** - * 新增rf测试历史结果 - * - * @param vnaRawData rf测试历史结果 - * @return 结果 - */ - @Override - public int insertVnaRawData(VnaRawData vnaRawData) - { - return vnaRawDataMapper.insertVnaRawData(vnaRawData); - } - - /** - * 修改rf测试历史结果 - * - * @param vnaRawData rf测试历史结果 - * @return 结果 - */ - @Override - public int updateVnaRawData(VnaRawData vnaRawData) - { - return vnaRawDataMapper.updateVnaRawData(vnaRawData); - } - - /** - * 删除rf测试历史结果对象 - * - * @param ids 需要删除的数据ID - * @return 结果 - */ - @Override - public int deleteVnaRawDataByIds(String ids) - { - return vnaRawDataMapper.deleteVnaRawDataByIds(Convert.toStrArray(ids)); - } - - /** - * 删除rf测试历史结果信息 - * - * @param id rf测试历史结果ID - * @return 结果 - */ - @Override - public int deleteVnaRawDataById(Long id) - { - return vnaRawDataMapper.deleteVnaRawDataById(id); - } -} diff --git a/ruoyi-admin/src/main/resources/mapper/rfMsg/VnaRawDataMapper.xml b/ruoyi-admin/src/main/resources/mapper/rfMsg/VnaRawDataMapper.xml deleted file mode 100644 index 2f0abb45..00000000 --- a/ruoyi-admin/src/main/resources/mapper/rfMsg/VnaRawDataMapper.xml +++ /dev/null @@ -1,85 +0,0 @@ - - - - - - - - - - - - - - - - - select id, Date, Serial_Number, Operator, Status, Port, Frequency, Value from vna_raw_data - - - - - - - - insert into vna_raw_data - - Date, - Serial_Number, - Operator, - Status, - Port, - Frequency, - Value, - - - #{date}, - #{serialNumber}, - #{operator}, - #{status}, - #{port}, - #{frequency}, - #{value}, - - - - - update vna_raw_data - - Date = #{date}, - Serial_Number = #{serialNumber}, - Operator = #{operator}, - Status = #{status}, - Port = #{port}, - Frequency = #{frequency}, - Value = #{value}, - - where id = #{id} - - - - delete from vna_raw_data where id = #{id} - - - - delete from vna_raw_data where id in - - #{id} - - - - \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/rfMsg/vnaRawData/add.html b/ruoyi-admin/src/main/resources/templates/rfMsg/vnaRawData/add.html deleted file mode 100644 index 106a4826..00000000 --- a/ruoyi-admin/src/main/resources/templates/rfMsg/vnaRawData/add.html +++ /dev/null @@ -1,69 +0,0 @@ - - - - - - - -
-
-
- -
-
- - -
-
-
-
- -
- -
-
-
- -
- -
-
-
- -
-
- - -
-
-
-
- -
- -
-
-
-
- - - - - \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/rfMsg/vnaRawData/edit.html b/ruoyi-admin/src/main/resources/templates/rfMsg/vnaRawData/edit.html deleted file mode 100644 index 69239cf3..00000000 --- a/ruoyi-admin/src/main/resources/templates/rfMsg/vnaRawData/edit.html +++ /dev/null @@ -1,70 +0,0 @@ - - - - - - - -
-
- -
- -
-
- - -
-
-
-
- -
- -
-
-
- -
- -
-
-
- -
-
- - -
-
-
-
- -
- -
-
-
-
- - - - - \ No newline at end of file diff --git a/ruoyi-admin/src/main/resources/templates/rfMsg/vnaRawData/vnaRawData.html b/ruoyi-admin/src/main/resources/templates/rfMsg/vnaRawData/vnaRawData.html deleted file mode 100644 index da62ce54..00000000 --- a/ruoyi-admin/src/main/resources/templates/rfMsg/vnaRawData/vnaRawData.html +++ /dev/null @@ -1,219 +0,0 @@ - - - - - - - -
-
-
-
-
-
    -
  • - - - - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • - - -
  • -
  • -  搜索 -  重置 -
  • -
-
-
-
- -
- - - - - - - - - - - - -
-
-
-
-
-
- - - - \ No newline at end of file