New file |
| | |
| | | package com.zy.asrs.controller; |
| | | |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.baomidou.mybatisplus.mapper.EntityWrapper; |
| | | import com.baomidou.mybatisplus.mapper.Wrapper; |
| | | import com.baomidou.mybatisplus.plugins.Page; |
| | | import com.zy.asrs.entity.BasArm; |
| | | import com.zy.asrs.service.BasArmService; |
| | | import com.core.annotations.ManagerAuth; |
| | | import com.core.common.BaseRes; |
| | | import com.core.common.Cools; |
| | | import com.core.common.R; |
| | | import com.zy.common.web.BaseController; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import java.util.*; |
| | | |
| | | @RestController |
| | | public class BasArmController extends BaseController { |
| | | |
| | | @Autowired |
| | | private BasArmService basArmService; |
| | | |
| | | @RequestMapping(value = "/basArm/{id}/auth") |
| | | @ManagerAuth |
| | | public R get(@PathVariable("id") String id) { |
| | | return R.ok(basArmService.selectById(String.valueOf(id))); |
| | | } |
| | | |
| | | @RequestMapping(value = "/basArm/add/auth") |
| | | @ManagerAuth |
| | | public R add(BasArm basArm) { |
| | | basArmService.insert(basArm); |
| | | return R.ok(); |
| | | } |
| | | |
| | | @RequestMapping(value = "/basArm/update/auth") |
| | | @ManagerAuth |
| | | public R update(BasArm basArm){ |
| | | if (Cools.isEmpty(basArm) || null==basArm.getId()){ |
| | | return R.error(); |
| | | } |
| | | basArmService.updateById(basArm); |
| | | return R.ok(); |
| | | } |
| | | |
| | | @RequestMapping(value = "/basArm/delete/auth") |
| | | @ManagerAuth |
| | | public R delete(@RequestParam(value="ids[]") Long[] ids){ |
| | | for (Long id : ids){ |
| | | basArmService.deleteById(id); |
| | | } |
| | | return R.ok(); |
| | | } |
| | | |
| | | @RequestMapping(value = "/basArmQuery/auth") |
| | | @ManagerAuth |
| | | public R query(String condition) { |
| | | EntityWrapper<BasArm> wrapper = new EntityWrapper<>(); |
| | | wrapper.like("id", condition); |
| | | Page<BasArm> page = basArmService.selectPage(new Page<>(0, 10), wrapper); |
| | | List<Map<String, Object>> result = new ArrayList<>(); |
| | | for (BasArm basArm : page.getRecords()){ |
| | | Map<String, Object> map = new HashMap<>(); |
| | | map.put("id", basArm.getId()); |
| | | map.put("value", basArm.getId()); |
| | | result.add(map); |
| | | } |
| | | return R.ok(result); |
| | | } |
| | | |
| | | @RequestMapping(value = "/basArm/check/column/auth") |
| | | @ManagerAuth |
| | | public R query(@RequestBody JSONObject param) { |
| | | Wrapper<BasArm> wrapper = new EntityWrapper<BasArm>().eq(humpToLine(String.valueOf(param.get("key"))), param.get("val")); |
| | | if (null != basArmService.selectOne(wrapper)){ |
| | | return R.parse(BaseRes.REPEAT).add(getComment(BasArm.class, String.valueOf(param.get("key")))); |
| | | } |
| | | return R.ok(); |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.zy.asrs.entity; |
| | | |
| | | import com.baomidou.mybatisplus.annotations.TableField; |
| | | import com.baomidou.mybatisplus.annotations.TableId; |
| | | import com.baomidou.mybatisplus.annotations.TableName; |
| | | import com.baomidou.mybatisplus.enums.IdType; |
| | | import com.core.common.Cools; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import org.springframework.format.annotation.DateTimeFormat; |
| | | |
| | | import java.io.Serializable; |
| | | import java.text.SimpleDateFormat; |
| | | import java.util.Date; |
| | | |
| | | @Data |
| | | @TableName("man_api_log") |
| | | public class ApiLog implements Serializable { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * ID |
| | | */ |
| | | @ApiModelProperty(value= "ID") |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 日志编号 |
| | | */ |
| | | @ApiModelProperty(value= "日志编号") |
| | | private String uuid; |
| | | |
| | | /** |
| | | * 名称空间 |
| | | */ |
| | | @ApiModelProperty(value= "名称空间") |
| | | private String namespace; |
| | | |
| | | /** |
| | | * 接口地址 |
| | | */ |
| | | @ApiModelProperty(value= "接口地址") |
| | | private String url; |
| | | |
| | | /** |
| | | * 平台密钥 |
| | | */ |
| | | @ApiModelProperty(value= "平台密钥") |
| | | private String appkey; |
| | | |
| | | /** |
| | | * 时间戳 |
| | | */ |
| | | @ApiModelProperty(value= "时间戳") |
| | | private String timestamp; |
| | | |
| | | /** |
| | | * 客户端IP |
| | | */ |
| | | @ApiModelProperty(value= "客户端IP") |
| | | @TableField("client_ip") |
| | | private String clientIp; |
| | | |
| | | /** |
| | | * 请求内容 |
| | | */ |
| | | @ApiModelProperty(value= "请求内容") |
| | | private String request; |
| | | |
| | | /** |
| | | * 响应内容 |
| | | */ |
| | | @ApiModelProperty(value= "响应内容") |
| | | private String response; |
| | | |
| | | /** |
| | | * 异常内容 |
| | | */ |
| | | @ApiModelProperty(value= "异常内容") |
| | | private String err; |
| | | |
| | | /** |
| | | * 结果 1: 成功 0: 失败 |
| | | */ |
| | | @ApiModelProperty(value= "结果 1: 成功 0: 失败 ") |
| | | private Integer result; |
| | | |
| | | /** |
| | | * 状态 1: 正常 0: 禁用 |
| | | */ |
| | | @ApiModelProperty(value= "状态 1: 正常 0: 禁用 ") |
| | | private Integer status; |
| | | |
| | | /** |
| | | * 添加时间 |
| | | */ |
| | | @ApiModelProperty(value= "添加时间") |
| | | @TableField("create_time") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") |
| | | private Date createTime; |
| | | |
| | | /** |
| | | * 修改时间 |
| | | */ |
| | | @ApiModelProperty(value= "修改时间") |
| | | @TableField("update_time") |
| | | @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") |
| | | private Date updateTime; |
| | | |
| | | /** |
| | | * 备注 |
| | | */ |
| | | @ApiModelProperty(value= "备注") |
| | | private String memo; |
| | | |
| | | public ApiLog() {} |
| | | |
| | | public ApiLog(String uuid, String namespace, String url, String appkey, String timestamp, String clientIp, String request, String response, String err, Integer result, Integer status, Date createTime, Date updateTime, String memo) { |
| | | this.uuid = uuid; |
| | | this.namespace = namespace; |
| | | this.url = url; |
| | | this.appkey = appkey; |
| | | this.timestamp = timestamp; |
| | | this.clientIp = clientIp; |
| | | this.request = request; |
| | | this.response = response; |
| | | this.err = err; |
| | | this.result = result; |
| | | this.status = status; |
| | | this.createTime = createTime; |
| | | this.updateTime = updateTime; |
| | | this.memo = memo; |
| | | } |
| | | |
| | | // ApiLog apiLog = new ApiLog( |
| | | // null, // 日志编号 |
| | | // null, // 名称空间 |
| | | // null, // 接口地址 |
| | | // null, // 平台密钥 |
| | | // null, // 时间戳 |
| | | // null, // 客户端IP |
| | | // null, // 请求内容 |
| | | // null, // 响应内容 |
| | | // null, // 异常内容 |
| | | // null, // 结果 |
| | | // null, // 状态 |
| | | // null, // 添加时间 |
| | | // null, // 修改时间 |
| | | // null // 备注 |
| | | // ); |
| | | |
| | | public String getResult$(){ |
| | | if (null == this.result){ return null; } |
| | | switch (this.result){ |
| | | case 1: |
| | | return "成功"; |
| | | case 0: |
| | | return "失败"; |
| | | default: |
| | | return String.valueOf(this.result); |
| | | } |
| | | } |
| | | |
| | | public String getStatus$(){ |
| | | if (null == this.status){ return null; } |
| | | switch (this.status){ |
| | | case 1: |
| | | return "正常"; |
| | | case 0: |
| | | return "禁用"; |
| | | default: |
| | | return String.valueOf(this.status); |
| | | } |
| | | } |
| | | |
| | | public String getCreateTime$(){ |
| | | if (Cools.isEmpty(this.createTime)){ |
| | | return ""; |
| | | } |
| | | return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.createTime); |
| | | } |
| | | |
| | | public String getUpdateTime$(){ |
| | | if (Cools.isEmpty(this.updateTime)){ |
| | | return ""; |
| | | } |
| | | return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.updateTime); |
| | | } |
| | | |
| | | |
| | | } |
New file |
| | |
| | | package com.zy.asrs.entity; |
| | | |
| | | import com.core.common.Cools;import com.baomidou.mybatisplus.annotations.TableId; |
| | | import com.baomidou.mybatisplus.enums.IdType; |
| | | import com.baomidou.mybatisplus.annotations.TableField; |
| | | |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | import com.baomidou.mybatisplus.annotations.TableName; |
| | | import java.io.Serializable; |
| | | |
| | | @Data |
| | | @TableName("asr_bas_arm") |
| | | public class BasArm implements Serializable { |
| | | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * ID |
| | | */ |
| | | @ApiModelProperty(value= "ID") |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 机械臂编号 |
| | | */ |
| | | @ApiModelProperty(value= "机械臂编号") |
| | | @TableField("arm_no") |
| | | private Integer armNo; |
| | | |
| | | /** |
| | | * 码垛位 |
| | | */ |
| | | @ApiModelProperty(value= "码垛位") |
| | | @TableId(value = "sta_no", type = IdType.INPUT) |
| | | @TableField("sta_no") |
| | | private Integer staNo; |
| | | |
| | | /** |
| | | * 拆垛位 |
| | | */ |
| | | @ApiModelProperty(value= "拆垛位") |
| | | @TableId(value = "sorting_line", type = IdType.INPUT) |
| | | @TableField("sorting_line") |
| | | private Integer sortingLine; |
| | | |
| | | @ApiModelProperty(value= "") |
| | | private Integer status; |
| | | |
| | | public BasArm() {} |
| | | |
| | | public BasArm(Integer armNo,Integer staNo,Integer sortingLine,Integer status) { |
| | | this.armNo = armNo; |
| | | this.staNo = staNo; |
| | | this.sortingLine = sortingLine; |
| | | this.status = status; |
| | | } |
| | | |
| | | // BasArm basArm = new BasArm( |
| | | // null, // 机械臂编号[非空] |
| | | // null, // 码垛位[非空] |
| | | // null, // 拆垛位[非空] |
| | | // null // [非空] |
| | | // ); |
| | | |
| | | |
| | | } |
| | |
| | | * ID |
| | | */ |
| | | @ApiModelProperty(value= "ID") |
| | | @TableId(value = "id", type = IdType.AUTO) |
| | | private Long id; |
| | | |
| | | /** |
| | | * 机械臂编号 |
| | | */ |
| | | @ApiModelProperty(value= "机械臂编号") |
| | | @TableId(value = "arm_no", type = IdType.INPUT) |
| | | @TableField("arm_no") |
| | | private Integer armNo; |
| | | |
New file |
| | |
| | | package com.zy.asrs.entity.param; |
| | | |
| | | import lombok.Data; |
| | | |
| | | /* |
| | | * Created by Monkey D. Luffy on 2025.09.09 |
| | | * */ |
| | | @Data |
| | | public class ArmTaskAssignmentParam { |
| | | |
| | | private String id; |
| | | |
| | | public ArmTaskAssignmentParam() {} |
| | | |
| | | public ArmTaskAssignmentParam(String id) { |
| | | this.id = id; |
| | | } |
| | | |
| | | public ArmTaskAssignmentParam(int id) { |
| | | this.id = String.valueOf(id); |
| | | } |
| | | } |
New file |
| | |
| | | package com.zy.asrs.mapper; |
| | | |
| | | import com.baomidou.mybatisplus.mapper.BaseMapper; |
| | | import com.zy.asrs.entity.ApiLog; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | @Mapper |
| | | @Repository |
| | | public interface ApiLogMapper extends BaseMapper<ApiLog> { |
| | | int clearWeekBefore(); |
| | | } |
New file |
| | |
| | | package com.zy.asrs.mapper; |
| | | |
| | | import com.zy.asrs.entity.BasArm; |
| | | import com.baomidou.mybatisplus.mapper.BaseMapper; |
| | | import org.apache.ibatis.annotations.Mapper; |
| | | import org.springframework.stereotype.Repository; |
| | | |
| | | @Mapper |
| | | @Repository |
| | | public interface BasArmMapper extends BaseMapper<BasArm> { |
| | | |
| | | } |
New file |
| | |
| | | package com.zy.asrs.service; |
| | | |
| | | import com.baomidou.mybatisplus.service.IService; |
| | | import com.zy.asrs.entity.ApiLog; |
| | | |
| | | public interface ApiLogService extends IService<ApiLog> { |
| | | void save(String namespace, String url, String appkey, String ip, String request, String response, boolean success); |
| | | |
| | | boolean clearWeekBefore(); |
| | | } |
New file |
| | |
| | | package com.zy.asrs.service; |
| | | |
| | | import com.zy.asrs.entity.BasArm; |
| | | import com.baomidou.mybatisplus.service.IService; |
| | | |
| | | public interface BasArmService extends IService<BasArm> { |
| | | |
| | | } |
New file |
| | |
| | | package com.zy.asrs.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.service.impl.ServiceImpl; |
| | | import com.core.common.SnowflakeIdWorker; |
| | | import com.zy.asrs.entity.ApiLog; |
| | | import com.zy.asrs.mapper.ApiLogMapper; |
| | | import com.zy.asrs.service.ApiLogService; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.scheduling.annotation.Async; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.Date; |
| | | |
| | | @Slf4j |
| | | @Service("apiLogService") |
| | | public class ApiLogServiceImpl extends ServiceImpl<ApiLogMapper, ApiLog> implements ApiLogService { |
| | | |
| | | @Autowired |
| | | private SnowflakeIdWorker snowflakeIdWorker; |
| | | |
| | | @Async |
| | | @Override |
| | | public void save(String namespace, String url, String appkey, String ip, String request, String response, boolean success) { |
| | | Date now = new Date(); |
| | | ApiLog apiLog = new ApiLog( |
| | | String.valueOf(snowflakeIdWorker.nextId()), // 日志编号 |
| | | namespace, // 名称空间 |
| | | url, // 接口地址 |
| | | appkey, // 平台密钥 |
| | | String.valueOf(now.getTime()), // 时间戳 |
| | | ip, // 客户端IP |
| | | request, // 请求内容 |
| | | response, |
| | | null, // 异常内容 |
| | | success?1:0 , // 结果 |
| | | 1, // 状态 |
| | | now, // 添加时间 |
| | | null, // 修改时间 |
| | | null // 备注 |
| | | ); |
| | | if (!this.insert(apiLog)) { |
| | | log.error("接口调用日志保存失败!"); |
| | | } |
| | | } |
| | | |
| | | @Override |
| | | public boolean clearWeekBefore() { |
| | | return this.baseMapper.clearWeekBefore() > 0; |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.zy.asrs.service.impl; |
| | | |
| | | import com.zy.asrs.mapper.BasArmMapper; |
| | | import com.zy.asrs.entity.BasArm; |
| | | import com.zy.asrs.service.BasArmService; |
| | | import com.baomidou.mybatisplus.service.impl.ServiceImpl; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | @Service("basArmService") |
| | | public class BasArmServiceImpl extends ServiceImpl<BasArmMapper, BasArm> implements BasArmService { |
| | | |
| | | } |
| | |
| | | import com.core.common.DateUtils; |
| | | import com.core.exception.CoolException; |
| | | import com.zy.asrs.entity.*; |
| | | import com.zy.asrs.entity.param.ArmTaskAssignmentParam; |
| | | import com.zy.asrs.mapper.*; |
| | | import com.zy.asrs.service.*; |
| | | import com.zy.asrs.utils.PostMesDataUtils; |
| | | import com.zy.asrs.utils.RouteUtils; |
| | | import com.zy.asrs.utils.Utils; |
| | | import com.zy.asrs.utils.VersionUtils; |
| | | import com.zy.asrs.utils.core.ReturnT; |
| | | import com.zy.common.constant.ArmConstant; |
| | | import com.zy.common.model.LocTypeDto; |
| | | import com.zy.common.model.MatDto; |
| | | import com.zy.common.model.SearchLocParam; |
| | |
| | | private WrkMastService wrkMastService; |
| | | @Autowired |
| | | private BasRgvMapService basRgvMapService; |
| | | @Autowired |
| | | private BasArmService basArmService; |
| | | @Autowired |
| | | private BasArmMastService basArmMastService; |
| | | |
| | | @Value("${wms.url}") |
| | | private String wmsUrl; |
| | |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | /* |
| | | * arm任务下发 |
| | | * */ |
| | | public synchronized void armTaskAssignment() { |
| | | try{ |
| | | List<BasArm> basArmList = basArmService.selectList(new EntityWrapper<>()); |
| | | for (BasArm basArm : basArmList) { |
| | | if (basArm.getStatus()!=1){ |
| | | continue; |
| | | } |
| | | try{ |
| | | List<BasArmMast> basArmMastListRuning = basArmMastService.selectList( |
| | | new EntityWrapper<BasArmMast>() |
| | | .eq("arm_no", basArm.getArmNo()) |
| | | .eq("sorting_line", basArm.getSortingLine()) |
| | | .eq("status", 1) |
| | | ); |
| | | if (basArmMastListRuning.isEmpty()){ |
| | | List<BasArmMast> basArmMastList = basArmMastService.selectList( |
| | | new EntityWrapper<BasArmMast>() |
| | | .eq("arm_no", basArm.getArmNo()) |
| | | .eq("sorting_line", basArm.getSortingLine()) |
| | | .eq("status", 0) |
| | | ); |
| | | if (basArmMastList.isEmpty()){ |
| | | continue; |
| | | } |
| | | if (basArmMastList.size()>1){ |
| | | log.error("arm编号:"+basArm.getArmNo()+"====》拆码垛任务异常禁止下发!!!任务待执行数量大于1!!!"); |
| | | continue; |
| | | } |
| | | for (BasArmMast basArmMast:basArmMastList) { |
| | | ArmTaskAssignmentParam armTaskAssignmentParam = new ArmTaskAssignmentParam(basArmMast.getSortingLine()); |
| | | //设置工作空间就绪 |
| | | ReturnT<String> result = new PostMesDataUtils().postMesData("机械臂抓取任务",ArmConstant.ARM_URL, ArmConstant.ARM_WORKSPACE, armTaskAssignmentParam); |
| | | if (result.getCode()==200){ |
| | | basArmMast.setStatus(1); |
| | | basArmMastService.updateById(basArmMast); |
| | | } else { |
| | | log.error("机械臂抓取任务:"+JSON.toJSON(basArmMast)+"===》任务信息下发失败"); |
| | | } |
| | | } |
| | | } |
| | | } catch (Exception e){ |
| | | log.error("arm编号:"+basArm.getArmNo()+"====》拆码垛任务下发失败"+e.getMessage()); |
| | | } |
| | | } |
| | | }catch (Exception e){ |
| | | log.error("arm任务下发失败"+e.getMessage()); |
| | | } |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.zy.asrs.utils; |
| | | |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.core.common.SpringUtils; |
| | | import com.core.exception.CoolException; |
| | | import com.zy.asrs.service.ApiLogService; |
| | | import com.zy.asrs.utils.core.AbstractHandler; |
| | | import com.zy.asrs.utils.core.ReturnT; |
| | | import com.zy.common.utils.HttpHandler; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | |
| | | import java.util.Map; |
| | | |
| | | @Slf4j |
| | | public class PostMesDataUtils extends AbstractHandler<String> { |
| | | |
| | | public ReturnT<String> postMesDataWcs(String URL, String erpPath, Object combParam){ |
| | | if(combParam != null){ |
| | | String response = ""; |
| | | boolean success = false; |
| | | try { |
| | | response = new HttpHandler.Builder() |
| | | .setUri(URL) |
| | | .setPath(erpPath) |
| | | .setJson(JSON.toJSONString(combParam)) |
| | | .build() |
| | | .doPost(); |
| | | JSONObject jsonObject = JSON.parseObject(response); |
| | | if (jsonObject.getInteger("code")==200) { |
| | | success = true; |
| | | } else { |
| | | log.error("任务完成信息上传请求接口失败!!!url:{};request:{};response:{}"+URL+erpPath, JSON.toJSONString(combParam), response); |
| | | throw new CoolException("上报wcs系统失败"); |
| | | } |
| | | } catch (Exception e) { |
| | | log.error("fail:上报wcs系统失败==>", e); |
| | | // TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); |
| | | return FAIL.setMsg(e.getMessage()); |
| | | } finally { |
| | | try { |
| | | // 保存接口日志 |
| | | ApiLogService apiLogService = SpringUtils.getBean(ApiLogService.class); |
| | | |
| | | apiLogService.save( |
| | | "上报wcs系统", |
| | | URL + erpPath, |
| | | null, |
| | | URL, |
| | | JSON.toJSONString(combParam), |
| | | response, |
| | | success |
| | | ); |
| | | } catch (Exception e) { |
| | | log.error("任务完成信息上传保存接口日志异常,异常信息:", e); |
| | | } |
| | | } |
| | | } |
| | | return SUCCESS; |
| | | } |
| | | |
| | | public ReturnT<String> postMesData(String name, String URL, String mesPath, Object combParam){ |
| | | // if (true){ |
| | | // System.out.println("name:"+name+",URL:"+URL+",mesPath:"+mesPath+",combParam:"+combParam); |
| | | // return SUCCESS; |
| | | // } |
| | | if(combParam != null){ |
| | | String response = ""; |
| | | boolean success = false; |
| | | try { |
| | | // Map<String, Object> map = new HashMap<>() |
| | | // map.put("appkey","ea1f0459efc02a79f046f982767939ae"); |
| | | response = new HttpHandler.Builder() |
| | | // .setHeaders(map) |
| | | .setUri(URL) |
| | | .setPath(mesPath) |
| | | .setJson(JSON.toJSONString(combParam)) |
| | | .build() |
| | | .doPost(); |
| | | System.out.println("response:"+response); |
| | | JSONObject jsonObject = JSON.parseObject(response); |
| | | |
| | | if (jsonObject.getInteger("code").equals(200)) { |
| | | success = true; |
| | | } else { |
| | | log.error("请求接口失败!!!url:{};request:{};response:{}", URL+"/"+mesPath, JSON.toJSONString(combParam), response); |
| | | throw new CoolException("上报"+name); |
| | | } |
| | | } catch (Exception e) { |
| | | log.error("请求接口失败!!!url:{};request:{};response:{}", URL+"/"+mesPath, JSON.toJSONString(combParam), response); |
| | | // TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); |
| | | return FAIL.setMsg(e.getMessage()); |
| | | } finally { |
| | | try { |
| | | // 保存接口日志 |
| | | ApiLogService apiLogService = SpringUtils.getBean(ApiLogService.class); |
| | | apiLogService.save( |
| | | "上报"+name, |
| | | URL +"/"+ mesPath, |
| | | null, |
| | | "127.0.0.1", |
| | | JSON.toJSONString(combParam), |
| | | response, |
| | | success |
| | | ); |
| | | } catch (Exception e) { |
| | | log.error("", e); } |
| | | } |
| | | } |
| | | return SUCCESS; |
| | | } |
| | | |
| | | public ReturnT<String> postMesData(String name, String URL, String mesPath, Object combParam,Map<String, Object> map){ |
| | | // if (true){ |
| | | // System.out.println("name:"+name+",URL:"+URL+",mesPath:"+mesPath+",combParam:"+combParam); |
| | | // return SUCCESS; |
| | | // } |
| | | if(combParam != null){ |
| | | String response = ""; |
| | | boolean success = false; |
| | | try { |
| | | // Map<String, Object> map = new HashMap<>(); |
| | | // map.put("appkey","ea1f0459efc02a79f046f982767939ae"); |
| | | response = new HttpHandler.Builder() |
| | | .setHeaders(map) |
| | | .setUri(URL) |
| | | .setPath(mesPath) |
| | | .setJson(JSON.toJSONString(combParam)) |
| | | .build() |
| | | .doPost(); |
| | | System.out.println("response:"+response); |
| | | JSONObject jsonObject = JSON.parseObject(response); |
| | | |
| | | if (jsonObject.getInteger("code").equals(200)) { |
| | | success = true; |
| | | } else { |
| | | log.error("请求接口失败!!!url:{};request:{};response:{}", URL+"/"+mesPath, JSON.toJSONString(combParam), response); |
| | | throw new CoolException("上报"+name); |
| | | } |
| | | } catch (Exception e) { |
| | | log.error("请求接口失败!!!url:{};request:{};response:{}", URL+"/"+mesPath, JSON.toJSONString(combParam), response); |
| | | // TransactionAspectSupport.currentTransactionStatus().setRollbackOnly(); |
| | | return FAIL.setMsg(e.getMessage()); |
| | | } finally { |
| | | try { |
| | | // 保存接口日志 |
| | | ApiLogService apiLogService = SpringUtils.getBean(ApiLogService.class); |
| | | apiLogService.save( |
| | | "上报"+name, |
| | | URL +"/"+ mesPath, |
| | | null, |
| | | "127.0.0.1", |
| | | JSON.toJSONString(combParam), |
| | | response, |
| | | success |
| | | ); |
| | | } catch (Exception e) { |
| | | log.error("", e); } |
| | | } |
| | | } |
| | | return SUCCESS; |
| | | } |
| | | } |
New file |
| | |
| | | package com.zy.asrs.utils.core; |
| | | |
| | | import com.core.exception.CoolException; |
| | | import com.zy.asrs.utils.core.ReturnT; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | |
| | | import java.text.MessageFormat; |
| | | |
| | | /** |
| | | * Created by vincent on 2020/7/4 |
| | | */ |
| | | @Slf4j |
| | | public abstract class AbstractHandler<T> { |
| | | |
| | | public final ReturnT<T> SUCCESS = new ReturnT<>(200, null); |
| | | public final ReturnT<T> FAIL = new ReturnT<>(500, null); |
| | | |
| | | // protected abstract ReturnT<T> start(); |
| | | |
| | | protected void exceptionHandle(String errorMsg){ |
| | | log.error(errorMsg); |
| | | exceptionHandle(errorMsg, (Object) null); |
| | | } |
| | | |
| | | protected void exceptionHandle(String errorMsg, Object... args){ |
| | | log.error(errorMsg); |
| | | throw new CoolException(MessageFormat.format(errorMsg, args)); |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.zy.asrs.utils.core; |
| | | |
| | | /** |
| | | * Created by vincent on 2020/7/7 |
| | | */ |
| | | public class AsrsException extends RuntimeException { |
| | | |
| | | public AsrsException(Throwable e) { |
| | | super(e); |
| | | } |
| | | |
| | | public AsrsException(String message) { |
| | | super(message); |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | package com.zy.asrs.utils.core; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | /** |
| | | * Created by vincent on 2020/7/7 |
| | | */ |
| | | public class ReturnT<T> implements Serializable { |
| | | |
| | | public static final long serialVersionUID = 42L; |
| | | public static final int SUCCESS_CODE = 200; |
| | | public static final int FAIL_CODE = 500; |
| | | private int code; |
| | | private String msg; |
| | | private T content; |
| | | |
| | | public ReturnT() { |
| | | } |
| | | |
| | | public ReturnT(int code, String msg) { |
| | | this.code = code; |
| | | this.msg = msg; |
| | | } |
| | | |
| | | public ReturnT(T content) { |
| | | this.code = 200; |
| | | this.content = content; |
| | | } |
| | | |
| | | public boolean isSuccess(){ |
| | | return this.code == 200; |
| | | } |
| | | |
| | | public int getCode() { |
| | | return this.code; |
| | | } |
| | | |
| | | public ReturnT<T> setCode(int code) { |
| | | this.code = code; |
| | | return this; |
| | | } |
| | | |
| | | public String getMsg() { |
| | | return this.msg; |
| | | } |
| | | |
| | | public ReturnT<T> setMsg(String msg) { |
| | | this.msg = msg; |
| | | return this; |
| | | } |
| | | |
| | | public T getContent() { |
| | | return this.content; |
| | | } |
| | | |
| | | public ReturnT<T> setContent(T content) { |
| | | this.content = content; |
| | | return this; |
| | | } |
| | | |
| | | public String toString() { |
| | | return "ReturnT [code=" + this.code + ", msg=" + this.msg + ", content=" + this.content + "]"; |
| | | } |
| | | |
| | | } |
| | |
| | | generator.url="192.168.4.191:50948;databasename=jshdasrs"; |
| | | generator.username="sa"; |
| | | generator.password="sa@123"; |
| | | generator.table="asr_bas_arm_mast_log"; |
| | | generator.table="asr_bas_arm"; |
| | | generator.packagePath="com.zy.asrs"; |
| | | generator.build(); |
| | | } |
New file |
| | |
| | | package com.zy.common.constant; |
| | | |
| | | /* |
| | | * Created by Monkey D. Luffy on 2025.09.09 |
| | | * */ |
| | | public class ArmConstant { |
| | | |
| | | public static final String ARM_URL = "http://192.168.99.130:80"; |
| | | |
| | | public static final String ARM_ADAPTOR = "adaptor/api/wcs/order";//创建订单 |
| | | |
| | | public static final String ARM_WORKSPACE = "adaptor/api/wcs/workspace/ready";//通知工作空间已就绪 |
| | | |
| | | } |
| | |
| | | private MainServiceImpl mainService; |
| | | // 所属线程 |
| | | private Thread thread; |
| | | private Thread thread2; |
| | | private Thread armThread; |
| | | // 频率 |
| | | private int i = 0; |
| | | private int k = 0; |
| | |
| | | thread = new Thread(this::crnAndDevRun); |
| | | thread.start(); |
| | | |
| | | thread2 = new Thread(this::roboticArmDispatch); |
| | | // thread2.start(); |
| | | armThread = new Thread(this::roboticArmDispatch); |
| | | armThread.start(); |
| | | } |
| | | private void crnAndDevRun() { |
| | | while (!Thread.currentThread().isInterrupted()) { |
| | |
| | | continue; |
| | | } |
| | | |
| | | //arm任务下发 |
| | | mainService.armTaskAssignment(); |
| | | |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | |
| | | @PreDestroy |
| | | public void shutDown(){ |
| | | if (thread != null) thread.interrupt(); |
| | | if (thread2 != null) thread2.interrupt(); |
| | | if (armThread != null) armThread.interrupt(); |
| | | } |
| | | |
| | | } |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.zy.asrs.mapper.ApiLogMapper"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="BaseResultMap" type="com.zy.asrs.entity.ApiLog"> |
| | | <id column="id" property="id" /> |
| | | <result column="uuid" property="uuid" /> |
| | | <result column="namespace" property="namespace" /> |
| | | <result column="url" property="url" /> |
| | | <result column="appkey" property="appkey" /> |
| | | <result column="timestamp" property="timestamp" /> |
| | | <result column="client_ip" property="clientIp" /> |
| | | <result column="request" property="request" /> |
| | | <result column="response" property="response" /> |
| | | <result column="err" property="err" /> |
| | | <result column="result" property="result" /> |
| | | <result column="status" property="status" /> |
| | | <result column="create_time" property="createTime" /> |
| | | <result column="update_time" property="updateTime" /> |
| | | <result column="memo" property="memo" /> |
| | | |
| | | </resultMap> |
| | | |
| | | <delete id="clearWeekBefore"> |
| | | delete from man_api_log |
| | | where 1=1 |
| | | and datediff(week,create_time,getdate()) >= 1 |
| | | and result != 1 |
| | | </delete> |
| | | |
| | | </mapper> |
New file |
| | |
| | | <?xml version="1.0" encoding="UTF-8"?> |
| | | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.zy.asrs.mapper.BasArmMapper"> |
| | | |
| | | <!-- 通用查询映射结果 --> |
| | | <resultMap id="BaseResultMap" type="com.zy.asrs.entity.BasArm"> |
| | | <id column="id" property="id" /> |
| | | <result column="arm_no" property="armNo" /> |
| | | <result column="sta_no" property="staNo" /> |
| | | <result column="sorting_line" property="sortingLine" /> |
| | | <result column="status" property="status" /> |
| | | |
| | | </resultMap> |
| | | |
| | | </mapper> |
New file |
| | |
| | | var pageCurr; |
| | | layui.config({ |
| | | base: baseUrl + "/static/layui/lay/modules/" |
| | | }).use(['table','laydate', 'form', 'admin'], function(){ |
| | | var table = layui.table; |
| | | var $ = layui.jquery; |
| | | var layer = layui.layer; |
| | | var layDate = layui.laydate; |
| | | var form = layui.form; |
| | | var admin = layui.admin; |
| | | |
| | | // 数据渲染 |
| | | tableIns = table.render({ |
| | | elem: '#basArm', |
| | | headers: {token: localStorage.getItem('token')}, |
| | | url: baseUrl+'/basArm/list/auth', |
| | | page: true, |
| | | limit: 15, |
| | | limits: [15, 30, 50, 100, 200, 500], |
| | | toolbar: '#toolbar', |
| | | cellMinWidth: 50, |
| | | height: 'full-120', |
| | | cols: [[ |
| | | {type: 'checkbox'} |
| | | ,{field: 'id', align: 'center',title: 'ID'} |
| | | ,{field: 'armNo', align: 'center',title: '机械臂编号'} |
| | | ,{field: 'staNo', align: 'center',title: '码垛位'} |
| | | ,{field: 'sortingLine', align: 'center',title: '拆垛位'} |
| | | ,{field: 'status', align: 'center',title: ''} |
| | | |
| | | ,{fixed: 'right', title:'操作', align: 'center', toolbar: '#operate', width:120} |
| | | ]], |
| | | request: { |
| | | pageName: 'curr', |
| | | pageSize: 'limit' |
| | | }, |
| | | parseData: function (res) { |
| | | return { |
| | | 'code': res.code, |
| | | 'msg': res.msg, |
| | | 'count': res.data.total, |
| | | 'data': res.data.records |
| | | } |
| | | }, |
| | | response: { |
| | | statusCode: 200 |
| | | }, |
| | | done: function(res, curr, count) { |
| | | if (res.code === 403) { |
| | | top.location.href = baseUrl+"/"; |
| | | } |
| | | pageCurr=curr; |
| | | limit(); |
| | | } |
| | | }); |
| | | |
| | | // 监听排序事件 |
| | | table.on('sort(basArm)', function (obj) { |
| | | var searchData = {}; |
| | | $.each($('#search-box [name]').serializeArray(), function() { |
| | | searchData[this.name] = this.value; |
| | | }); |
| | | searchData['orderByField'] = obj.field; |
| | | searchData['orderByType'] = obj.type; |
| | | tableIns.reload({ |
| | | where: searchData, |
| | | page: {curr: 1} |
| | | }); |
| | | }); |
| | | |
| | | // 监听头工具栏事件 |
| | | table.on('toolbar(basArm)', function (obj) { |
| | | var checkStatus = table.checkStatus(obj.config.id).data; |
| | | switch(obj.event) { |
| | | case 'addData': |
| | | showEditModel(); |
| | | break; |
| | | case 'deleteData': |
| | | if (checkStatus.length === 0) { |
| | | layer.msg('请选择要删除的数据', {icon: 2}); |
| | | return; |
| | | } |
| | | del(checkStatus.map(function (d) { |
| | | return d.id; |
| | | })); |
| | | break; |
| | | case 'exportData': |
| | | admin.confirm('确定导出Excel吗', {shadeClose: true}, function(){ |
| | | var titles=[]; |
| | | var fields=[]; |
| | | obj.config.cols[0].map(function (col) { |
| | | if (col.type === 'normal' && col.hide === false && col.toolbar == null) { |
| | | titles.push(col.title); |
| | | fields.push(col.field); |
| | | } |
| | | }); |
| | | var exportData = {}; |
| | | $.each($('#search-box [name]').serializeArray(), function() { |
| | | exportData[this.name] = this.value; |
| | | }); |
| | | var param = { |
| | | 'basArm': exportData, |
| | | 'fields': fields |
| | | }; |
| | | $.ajax({ |
| | | url: baseUrl+"/basArm/export/auth", |
| | | headers: {'token': localStorage.getItem('token')}, |
| | | data: JSON.stringify(param), |
| | | dataType:'json', |
| | | contentType:'application/json;charset=UTF-8', |
| | | method: 'POST', |
| | | success: function (res) { |
| | | layer.closeAll(); |
| | | if (res.code === 200) { |
| | | table.exportFile(titles,res.data,'xls'); |
| | | } else if (res.code === 403) { |
| | | top.location.href = baseUrl+"/"; |
| | | } else { |
| | | layer.msg(res.msg, {icon: 2}) |
| | | } |
| | | } |
| | | }); |
| | | }); |
| | | break; |
| | | } |
| | | }); |
| | | |
| | | // 监听行工具事件 |
| | | table.on('tool(basArm)', function(obj){ |
| | | var data = obj.data; |
| | | switch (obj.event) { |
| | | case 'edit': |
| | | showEditModel(data); |
| | | break; |
| | | case "del": |
| | | del([data.id]); |
| | | break; |
| | | } |
| | | }); |
| | | |
| | | /* 弹窗 - 新增、修改 */ |
| | | function showEditModel(mData) { |
| | | admin.open({ |
| | | type: 1, |
| | | area: '600px', |
| | | title: (mData ? '修改' : '添加') + '订单状态', |
| | | content: $('#editDialog').html(), |
| | | success: function (layero, dIndex) { |
| | | layDateRender(mData); |
| | | form.val('detail', mData); |
| | | form.on('submit(editSubmit)', function (data) { |
| | | var loadIndex = layer.load(2); |
| | | $.ajax({ |
| | | url: baseUrl+"/basArm/"+(mData?'update':'add')+"/auth", |
| | | headers: {'token': localStorage.getItem('token')}, |
| | | data: data.field, |
| | | method: 'POST', |
| | | success: function (res) { |
| | | layer.close(loadIndex); |
| | | if (res.code === 200){ |
| | | layer.close(dIndex); |
| | | layer.msg(res.msg, {icon: 1}); |
| | | tableReload(); |
| | | } else if (res.code === 403){ |
| | | top.location.href = baseUrl+"/"; |
| | | }else { |
| | | layer.msg(res.msg, {icon: 2}); |
| | | } |
| | | } |
| | | }) |
| | | return false; |
| | | }); |
| | | $(layero).children('.layui-layer-content').css('overflow', 'visible'); |
| | | layui.form.render('select'); |
| | | } |
| | | }); |
| | | } |
| | | |
| | | /* 删除 */ |
| | | function del(ids) { |
| | | layer.confirm('确定要删除选中数据吗?', { |
| | | skin: 'layui-layer-admin', |
| | | shade: .1 |
| | | }, function (i) { |
| | | layer.close(i); |
| | | var loadIndex = layer.load(2); |
| | | $.ajax({ |
| | | url: baseUrl+"/basArm/delete/auth", |
| | | headers: {'token': localStorage.getItem('token')}, |
| | | data: {ids: ids}, |
| | | method: 'POST', |
| | | success: function (res) { |
| | | layer.close(loadIndex); |
| | | if (res.code === 200){ |
| | | layer.msg(res.msg, {icon: 1}); |
| | | tableReload(); |
| | | } else if (res.code === 403){ |
| | | top.location.href = baseUrl+"/"; |
| | | } else { |
| | | layer.msg(res.msg, {icon: 2}); |
| | | } |
| | | } |
| | | }) |
| | | }); |
| | | } |
| | | |
| | | // 搜索 |
| | | form.on('submit(search)', function (data) { |
| | | pageCurr = 1; |
| | | tableReload(false); |
| | | }); |
| | | |
| | | // 重置 |
| | | form.on('submit(reset)', function (data) { |
| | | pageCurr = 1; |
| | | clearFormVal($('#search-box')); |
| | | tableReload(false); |
| | | }); |
| | | |
| | | // 时间选择器 |
| | | function layDateRender(data) { |
| | | setTimeout(function () { |
| | | layDate.render({ |
| | | elem: '.layui-laydate-range' |
| | | ,type: 'datetime' |
| | | ,range: true |
| | | }); |
| | | |
| | | }, 300); |
| | | } |
| | | layDateRender(); |
| | | |
| | | }); |
| | | |
| | | // 关闭动作 |
| | | $(document).on('click','#data-detail-close', function () { |
| | | parent.layer.closeAll(); |
| | | }); |
| | | |
| | | function tableReload(child) { |
| | | var searchData = {}; |
| | | $.each($('#search-box [name]').serializeArray(), function() { |
| | | searchData[this.name] = this.value; |
| | | }); |
| | | tableIns.reload({ |
| | | where: searchData, |
| | | page: {curr: pageCurr} |
| | | }); |
| | | } |
New file |
| | |
| | | <!DOCTYPE html> |
| | | <html lang="en"> |
| | | <head> |
| | | <meta charset="utf-8"> |
| | | <title></title> |
| | | <meta name="renderer" content="webkit"> |
| | | <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> |
| | | <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"> |
| | | <link rel="stylesheet" href="../../static/layui/css/layui.css" media="all"> |
| | | <link rel="stylesheet" href="../../static/css/admin.css?v=318" media="all"> |
| | | <link rel="stylesheet" href="../../static/css/cool.css" media="all"> |
| | | </head> |
| | | <body> |
| | | |
| | | <div class="layui-fluid"> |
| | | <div class="layui-card"> |
| | | <div class="layui-card-body"> |
| | | <div class="layui-form toolbar" id="search-box"> |
| | | <div class="layui-form-item"> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="id" placeholder="编号" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width: 300px"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input layui-laydate-range" name="create_time" type="text" placeholder="起始时间 - 终止时间" autocomplete="off" style="width: 300px"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="condition" placeholder="请输入" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline">  |
| | | <button class="layui-btn icon-btn" lay-filter="search" lay-submit> |
| | | <i class="layui-icon"></i>搜索 |
| | | </button> |
| | | <button class="layui-btn icon-btn" lay-filter="reset" lay-submit> |
| | | <i class="layui-icon"></i>重置 |
| | | </button> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | <table class="layui-hide" id="basArm" lay-filter="basArm"></table> |
| | | </div> |
| | | </div> |
| | | </div> |
| | | |
| | | <script type="text/html" id="toolbar"> |
| | | <div class="layui-btn-container"> |
| | | <button class="layui-btn layui-btn-sm" id="btn-add" lay-event="addData">新增</button> |
| | | <button class="layui-btn layui-btn-sm layui-btn-danger" id="btn-delete" lay-event="deleteData">删除</button> |
| | | <button class="layui-btn layui-btn-primary layui-btn-sm" id="btn-export" lay-event="exportData" style="float: right">导出</button> |
| | | </div> |
| | | </script> |
| | | |
| | | <script type="text/html" id="operate"> |
| | | <a class="layui-btn layui-btn-primary layui-btn-xs btn-edit" lay-event="edit">修改</a> |
| | | <a class="layui-btn layui-btn-danger layui-btn-xs btn-edit" lay-event="del">删除</a> |
| | | </script> |
| | | |
| | | <script type="text/javascript" src="../../static/js/jquery/jquery-3.3.1.min.js"></script> |
| | | <script type="text/javascript" src="../../static/layui/layui.js" charset="utf-8"></script> |
| | | <script type="text/javascript" src="../../static/js/common.js" charset="utf-8"></script> |
| | | <script type="text/javascript" src="../../static/js/cool.js" charset="utf-8"></script> |
| | | <script type="text/javascript" src="../../static/js/basArm/basArm.js" charset="utf-8"></script> |
| | | </body> |
| | | <!-- 表单弹窗 --> |
| | | <script type="text/html" id="editDialog"> |
| | | <form id="detail" lay-filter="detail" class="layui-form admin-form model-form"> |
| | | <input name="id" type="hidden"> |
| | | <div class="layui-row"> |
| | | <div class="layui-col-md12"> |
| | | <div class="layui-form-item"> |
| | | <label class="layui-form-label layui-form-required">机械臂编号: </label> |
| | | <div class="layui-input-block"> |
| | | <input class="layui-input" name="armNo" placeholder="请输入机械臂编号" lay-vertype="tips" lay-verify="required"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-form-item"> |
| | | <label class="layui-form-label layui-form-required">码垛位: </label> |
| | | <div class="layui-input-block"> |
| | | <input class="layui-input" name="staNo" placeholder="请输入码垛位" lay-vertype="tips" lay-verify="required"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-form-item"> |
| | | <label class="layui-form-label layui-form-required">拆垛位: </label> |
| | | <div class="layui-input-block"> |
| | | <input class="layui-input" name="sortingLine" placeholder="请输入拆垛位" lay-vertype="tips" lay-verify="required"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-form-item"> |
| | | <label class="layui-form-label layui-form-required">: </label> |
| | | <div class="layui-input-block"> |
| | | <input class="layui-input" name="status" placeholder="请输入" lay-vertype="tips" lay-verify="required"> |
| | | </div> |
| | | </div> |
| | | |
| | | </div> |
| | | </div> |
| | | <hr class="layui-bg-gray"> |
| | | <div class="layui-form-item text-right"> |
| | | <button class="layui-btn" lay-filter="editSubmit" lay-submit="">保存</button> |
| | | <button class="layui-btn layui-btn-primary" type="button" ew-event="closeDialog">取消</button> |
| | | </div> |
| | | </form> |
| | | </script> |
| | | </html> |
| | | |