2023-1-4设备

zhc4dev
lenovo 2 years ago
parent 3a8496b553
commit 2a712c198e
  1. 33
      ant-design-vue-jeecg/src/views/device/ZyDeviceList.vue
  2. 2
      ant-design-vue-jeecg/src/views/process/modules/ZyOperationtoolList.vue
  3. 2
      ant-design-vue-jeecg/src/views/process/modules/ZyProcessActionList.vue
  4. 2
      ant-design-vue-jeecg/src/views/process/modules/ZyProcessFabricList.vue
  5. 2
      ant-design-vue-jeecg/src/views/process/modules/ZyProcessMachineList.vue
  6. 2
      ant-design-vue-jeecg/src/views/process/modules/list/ZyMachine.vue
  7. 2
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/pro/entity/ZyProcessMachine.java
  8. 2
      jeecg-boot/jeecg-boot-module-process/src/main/java/org/jeecg/modules/demo/pro/mapper/ZyProcessMachineMapper.java
  9. 17
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/device/controller/ZyDeviceController.java
  10. 33
      jeecg-boot/jeecg-boot-module-system/src/main/java/org/jeecg/modules/device/entity/ZyDevice.java

@ -130,6 +130,26 @@
return parseInt(index)+1; return parseInt(index)+1;
} }
}, },
{
title:'设备类型',
align:"center",
dataIndex: 'typeCode_dictText'
},
{
title:'设备型号',
align:"center",
dataIndex: 'modelId_dictText'
},
{
title:'设备品牌',
align:"center",
dataIndex: 'brandId_dictText'
},
{
title:'设备名称',
align:"center",
dataIndex: 'name'
},
{ {
title:'设备图片', title:'设备图片',
align:"center", align:"center",
@ -139,14 +159,10 @@
{ {
title:'设备二维码', title:'设备二维码',
align:"center", align:"center",
dataIndex: 'erweima', dataIndex: 'qrcode',
scopedSlots: {customRender: 'imgeSlot'} scopedSlots: {customRender: 'imgeSlot'}
}, },
{
title:'设备类型',
align:"center",
dataIndex: 'typeid_dictText'
},
{ {
title:'设备编号', title:'设备编号',
align:"center", align:"center",
@ -165,11 +181,6 @@
align:"center", align:"center",
dataIndex: 'agent_dictText' dataIndex: 'agent_dictText'
}, },
{
title:'存放位置',
align:"center",
dataIndex: 'adress'
},
{ {
title:'设备状态', title:'设备状态',
align:"center", align:"center",

@ -12,7 +12,7 @@
<a-col :xl="6" :lg="7" :md="8" :sm="24"> <a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button> <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
<!-- <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>--> <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
</span> </span>
</a-col> </a-col>
</a-row> </a-row>

@ -12,7 +12,7 @@
<a-col :xl="6" :lg="7" :md="8" :sm="24"> <a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button> <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
<!-- <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>--> <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
</span> </span>
</a-col> </a-col>
</a-row> </a-row>

@ -17,7 +17,7 @@
<a-col :xl="6" :lg="7" :md="8" :sm="24"> <a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button> <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
<!-- <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>--> <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
</span> </span>
</a-col> </a-col>
</a-row> </a-row>

@ -17,7 +17,7 @@
<a-col :xl="6" :lg="7" :md="8" :sm="24"> <a-col :xl="6" :lg="7" :md="8" :sm="24">
<span style="float: left;overflow: hidden;" class="table-page-search-submitButtons"> <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
<a-button type="primary" @click="searchQuery" icon="search">查询</a-button> <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
<!-- <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>--> <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
</span> </span>
</a-col> </a-col>
</a-row> </a-row>

@ -142,7 +142,7 @@
// } // }
], ],
url: { url: {
list: "/devicetype/zyDevicetype/list1", list: "/device/zyDevice/list1",
importExcelUrl: "base/zyClothAction/importExcel", importExcelUrl: "base/zyClothAction/importExcel",
}, },

@ -41,7 +41,7 @@ public class ZyProcessMachine implements Serializable {
private String processId; private String processId;
/**机器*/ /**机器*/
@Excel(name = "机器", width = 15, dictTable = "zy_devicetype", dicText = "name", dicCode = "id") @Excel(name = "机器", width = 15, dictTable = "zy_devicetype", dicText = "name", dicCode = "id")
@Dict(dictTable = "zy_devicetype", dicText = "name", dicCode = "id") @Dict(dictTable = "zy_device", dicText = "name", dicCode = "id")
@ApiModelProperty(value = "机器") @ApiModelProperty(value = "机器")
private String machineId; private String machineId;
/**创建时间*/ /**创建时间*/

@ -21,6 +21,6 @@ public interface ZyProcessMachineMapper extends BaseMapper<ZyProcessMachine> {
@Select("<script>select * from zy_process_machine <where><if test=\" p != null\">process_id in (select id from zy_process where process_name like #{p})</if><if test=\" m != null\"> and machine_id in (select id from zy_devicetype where name like #{m})</if></where></script>") @Select("<script>select * from zy_process_machine <where><if test=\" p != null\">process_id in (select id from zy_process where process_name like #{p})</if><if test=\" m != null\"> and machine_id in (select id from zy_devicetype where name like #{m})</if></where></script>")
IPage<ZyProcessMachine> page(Page<ZyProcessMachine> page, @Param("p") String processId, @Param("m") String machineId); IPage<ZyProcessMachine> page(Page<ZyProcessMachine> page, @Param("p") String processId, @Param("m") String machineId);
@Select("<script>select a.*,b.process_code,c.code from zy_process_machine as a,zy_process as b,zy_devicetype as c <where> a.process_id=b.id and a.machine_id=c.id and a.process_id=#{p} <if test=\" m != null\"> and machine_id in (select id from zy_devicetype where name like #{m})</if></where></script>") @Select("<script>select a.*,b.process_code,c.code from zy_process_machine as a,zy_process as b,zy_device as c <where> a.process_id=b.id and a.machine_id=c.id and a.process_id=#{p} <if test=\" m != null\"> and machine_id in (select id from zy_device where name like #{m})</if></where></script>")
IPage<ZyProcessMachine> page1(Page<ZyProcessMachine> page, @Param("p") String s, @Param("m") String t); IPage<ZyProcessMachine> page1(Page<ZyProcessMachine> page, @Param("p") String s, @Param("m") String t);
} }

@ -102,12 +102,25 @@ public class ZyDeviceController extends JeecgController<ZyDevice, IZyDeviceServi
MatrixToImageWriter.writeToStream(bitMatrix, "PNG", outputStream); MatrixToImageWriter.writeToStream(bitMatrix, "PNG", outputStream);
Base64.Encoder encoder = Base64.getEncoder(); Base64.Encoder encoder = Base64.getEncoder();
String text = encoder.encodeToString(outputStream.toByteArray()); String text = encoder.encodeToString(outputStream.toByteArray());
pageList.getRecords().get(i).setErweima("data:image/png;base64,"+text); pageList.getRecords().get(i).setQrcode("data:image/png;base64,"+text);
} }
return Result.OK(pageList); return Result.OK(pageList);
} }
@AutoLog(value = "设备信息-分页列表查询")
@ApiOperation(value="设备信息-分页列表查询", notes="设备信息-分页列表查询")
@GetMapping(value = "/list1")
public Result<?> queryPageList1(ZyDevice zyDevice,
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
HttpServletRequest req) throws WriterException, IOException {
QueryWrapper<ZyDevice> queryWrapper = QueryGenerator.initQueryWrapper(zyDevice, req.getParameterMap());
Page<ZyDevice> page = new Page<ZyDevice>(pageNo, pageSize);
IPage<ZyDevice> pageList = zyDeviceService.page(page, queryWrapper);
return Result.OK(pageList);
}
/**
/**
* 添加 * 添加
* *
* @param zyDevice * @param zyDevice

@ -53,16 +53,16 @@ public class ZyDevice implements Serializable {
private Date updateTime; private Date updateTime;
/**所属部门*/ /**所属部门*/
@ApiModelProperty(value = "所属部门") @ApiModelProperty(value = "所属部门")
private String sysOrgCode; private String orgCode;
/**设备图片*/ /**设备图片*/
@Excel(name = "设备图片", width = 15) @Excel(name = "设备图片", width = 15)
@ApiModelProperty(value = "设备图片") @ApiModelProperty(value = "设备图片")
private String img; private String img;
/**设备类型*/ /**设备类型*/
@Excel(name = "设备类型", width = 15, dictTable = "zy_devicetype", dicText = "name", dicCode = "id") // @Excel(name = "设备类型", width = 15, dictTable = "zy_devicetype", dicText = "name", dicCode = "id")
@Dict(dictTable = "zy_devicetype", dicText = "name", dicCode = "id") // @Dict(dictTable = "zy_devicetype", dicText = "name", dicCode = "id")
@ApiModelProperty(value = "设备类型") // @ApiModelProperty(value = "设备类型")
private String typeid; // private String typeid;
/**设备编号*/ /**设备编号*/
@Excel(name = "设备编号", width = 15) @Excel(name = "设备编号", width = 15)
@ApiModelProperty(value = "设备编号") @ApiModelProperty(value = "设备编号")
@ -79,9 +79,9 @@ public class ZyDevice implements Serializable {
@ApiModelProperty(value = "经办人") @ApiModelProperty(value = "经办人")
private String agent; private String agent;
/**存放位置*/ /**存放位置*/
@Excel(name = "存放位置", width = 15) // @Excel(name = "存放位置", width = 15)
@ApiModelProperty(value = "存放位置") // @ApiModelProperty(value = "存放位置")
private String adress; // private String adress;
/**设备状态*/ /**设备状态*/
@Excel(name = "设备状态", width = 15) @Excel(name = "设备状态", width = 15)
@ApiModelProperty(value = "设备状态") @ApiModelProperty(value = "设备状态")
@ -89,11 +89,11 @@ public class ZyDevice implements Serializable {
/**二维码*/ /**二维码*/
@Excel(name = "二维码", width = 15) @Excel(name = "二维码", width = 15)
@ApiModelProperty(value = "二维码") @ApiModelProperty(value = "二维码")
private String erweima; private String qrcode;
/**维护周期*/ /**维护周期*/
@Excel(name = "维护周期", width = 15) @Excel(name = "维护周期", width = 15)
@ApiModelProperty(value = "维护周期") @ApiModelProperty(value = "维护周期")
private String maintenancecycle; private Integer maintenancecycle;
/**管理人*/ /**管理人*/
@Excel(name = "管理人", width = 15, dictTable = "sys_user", dicText = "realname", dicCode = "username") @Excel(name = "管理人", width = 15, dictTable = "sys_user", dicText = "realname", dicCode = "username")
@Dict(dictTable = "sys_user", dicText = "realname", dicCode = "username") @Dict(dictTable = "sys_user", dicText = "realname", dicCode = "username")
@ -109,4 +109,17 @@ public class ZyDevice implements Serializable {
@Excel(name = "3d模型", width = 15) @Excel(name = "3d模型", width = 15)
@ApiModelProperty(value = "3d模型") @ApiModelProperty(value = "3d模型")
private String img3d; private String img3d;
// @Excel(name = "设备品牌", width = 15, dictTable = "sys_user", dicText = "realname", dicCode = "username")
@Dict(dictTable = "zy_devicebrand", dicText = "brand", dicCode = "id")
@ApiModelProperty(value = "设备品牌")
private String brandId;
@Dict(dictTable = "zy_devicemodel", dicText = "model", dicCode = "id")
@ApiModelProperty(value = "设备型号")
private String modelId;
@Dict(dictTable = "zy_devicetype", dicText = "name", dicCode = "id")
@ApiModelProperty(value = "设备类型")
private String typeCode;
@ApiModelProperty(value = "设备名称")
private String name;
} }

Loading…
Cancel
Save