parent
756df3a31e
commit
0a206e861c
@ -0,0 +1,104 @@
|
||||
package com.ruoyi.szxc.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
import com.ruoyi.common.enums.BusinessType;
|
||||
import com.ruoyi.szxc.domain.SzxcWishManage;
|
||||
import com.ruoyi.szxc.service.ISzxcWishManageService;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 心愿管理Controller
|
||||
*
|
||||
* @author hs
|
||||
* @date 2024-04-03
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/szxc/wish")
|
||||
public class SzxcWishManageController extends BaseController
|
||||
{
|
||||
@Autowired
|
||||
private ISzxcWishManageService szxcWishManageService;
|
||||
|
||||
/**
|
||||
* 查询心愿管理列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('szxc:wish:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(SzxcWishManage szxcWishManage)
|
||||
{
|
||||
startPage();
|
||||
List<SzxcWishManage> list = szxcWishManageService.selectSzxcWishManageList(szxcWishManage);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出心愿管理列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('szxc:wish:export')")
|
||||
@Log(title = "心愿管理", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, SzxcWishManage szxcWishManage)
|
||||
{
|
||||
List<SzxcWishManage> list = szxcWishManageService.selectSzxcWishManageList(szxcWishManage);
|
||||
ExcelUtil<SzxcWishManage> util = new ExcelUtil<SzxcWishManage>(SzxcWishManage.class);
|
||||
util.exportExcel(response, list, "心愿管理数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取心愿管理详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('szxc:wish:query')")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult getInfo(@PathVariable("id") Long id)
|
||||
{
|
||||
return success(szxcWishManageService.selectSzxcWishManageById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增心愿管理
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('szxc:wish:add')")
|
||||
@Log(title = "心愿管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody SzxcWishManage szxcWishManage)
|
||||
{
|
||||
return toAjax(szxcWishManageService.insertSzxcWishManage(szxcWishManage));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改心愿管理
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('szxc:wish:edit')")
|
||||
@Log(title = "心愿管理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody SzxcWishManage szxcWishManage)
|
||||
{
|
||||
return toAjax(szxcWishManageService.updateSzxcWishManage(szxcWishManage));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除心愿管理
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('szxc:wish:remove')")
|
||||
@Log(title = "心愿管理", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public AjaxResult remove(@PathVariable Long[] ids)
|
||||
{
|
||||
return toAjax(szxcWishManageService.deleteSzxcWishManageByIds(ids));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,298 @@
|
||||
package com.ruoyi.szxc.domain;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.ruoyi.common.annotation.Excel;
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 心愿管理对象 szxc_wish_manage
|
||||
*
|
||||
* @author hs
|
||||
* @date 2024-04-03
|
||||
*/
|
||||
public class SzxcWishManage extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** id */
|
||||
private Long id;
|
||||
|
||||
/** 申请人 */
|
||||
@Excel(name = "申请人")
|
||||
private String applyName;
|
||||
|
||||
/** 申请人电话 */
|
||||
@Excel(name = "申请人电话")
|
||||
private String applyPhone;
|
||||
|
||||
/** 申请时间 */
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "申请时间", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date applyDate;
|
||||
|
||||
/** 心愿标题 */
|
||||
@Excel(name = "心愿标题")
|
||||
private String title;
|
||||
|
||||
/** 心愿类型 */
|
||||
@Excel(name = "心愿类型")
|
||||
private String wishType;
|
||||
|
||||
/** 心愿描述 */
|
||||
@Excel(name = "心愿描述")
|
||||
private String wishDescrib;
|
||||
|
||||
/** 心愿状态 */
|
||||
@Excel(name = "心愿状态")
|
||||
private String wishStatus;
|
||||
|
||||
/** 认领人 */
|
||||
@Excel(name = "认领人")
|
||||
private String rlName;
|
||||
|
||||
/** 认领人电话 */
|
||||
@Excel(name = "认领人电话")
|
||||
private String rlPhone;
|
||||
|
||||
/** 认领人居民id */
|
||||
@Excel(name = "认领人居民id")
|
||||
private Long rlId;
|
||||
|
||||
/** 审核部门 */
|
||||
@Excel(name = "审核部门")
|
||||
private String auditDept;
|
||||
|
||||
/** 审核部门id */
|
||||
@Excel(name = "审核部门id")
|
||||
private Long auditDeptid;
|
||||
|
||||
/** 审核人 */
|
||||
@Excel(name = "审核人")
|
||||
private String auditName;
|
||||
|
||||
/** 审核结果 */
|
||||
@Excel(name = "审核结果")
|
||||
private String auditResult;
|
||||
|
||||
/** 审核原因 */
|
||||
@Excel(name = "审核原因")
|
||||
private String auditReason;
|
||||
|
||||
/** 申请人网格 */
|
||||
@Excel(name = "申请人网格")
|
||||
private String deptName;
|
||||
|
||||
/** 申请人部门id */
|
||||
@Excel(name = "申请人部门id")
|
||||
private Long deptId;
|
||||
|
||||
/** 创建者ID */
|
||||
@Excel(name = "创建者ID")
|
||||
private Long userId;
|
||||
|
||||
public void setId(Long id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public Long getId()
|
||||
{
|
||||
return id;
|
||||
}
|
||||
public void setApplyName(String applyName)
|
||||
{
|
||||
this.applyName = applyName;
|
||||
}
|
||||
|
||||
public String getApplyName()
|
||||
{
|
||||
return applyName;
|
||||
}
|
||||
public void setApplyPhone(String applyPhone)
|
||||
{
|
||||
this.applyPhone = applyPhone;
|
||||
}
|
||||
|
||||
public String getApplyPhone()
|
||||
{
|
||||
return applyPhone;
|
||||
}
|
||||
public void setApplyDate(Date applyDate)
|
||||
{
|
||||
this.applyDate = applyDate;
|
||||
}
|
||||
|
||||
public Date getApplyDate()
|
||||
{
|
||||
return applyDate;
|
||||
}
|
||||
public void setTitle(String title)
|
||||
{
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
public String getTitle()
|
||||
{
|
||||
return title;
|
||||
}
|
||||
public void setWishType(String wishType)
|
||||
{
|
||||
this.wishType = wishType;
|
||||
}
|
||||
|
||||
public String getWishType()
|
||||
{
|
||||
return wishType;
|
||||
}
|
||||
public void setWishDescrib(String wishDescrib)
|
||||
{
|
||||
this.wishDescrib = wishDescrib;
|
||||
}
|
||||
|
||||
public String getWishDescrib()
|
||||
{
|
||||
return wishDescrib;
|
||||
}
|
||||
public void setWishStatus(String wishStatus)
|
||||
{
|
||||
this.wishStatus = wishStatus;
|
||||
}
|
||||
|
||||
public String getWishStatus()
|
||||
{
|
||||
return wishStatus;
|
||||
}
|
||||
public void setRlName(String rlName)
|
||||
{
|
||||
this.rlName = rlName;
|
||||
}
|
||||
|
||||
public String getRlName()
|
||||
{
|
||||
return rlName;
|
||||
}
|
||||
public void setRlPhone(String rlPhone)
|
||||
{
|
||||
this.rlPhone = rlPhone;
|
||||
}
|
||||
|
||||
public String getRlPhone()
|
||||
{
|
||||
return rlPhone;
|
||||
}
|
||||
public void setRlId(Long rlId)
|
||||
{
|
||||
this.rlId = rlId;
|
||||
}
|
||||
|
||||
public Long getRlId()
|
||||
{
|
||||
return rlId;
|
||||
}
|
||||
public void setAuditDept(String auditDept)
|
||||
{
|
||||
this.auditDept = auditDept;
|
||||
}
|
||||
|
||||
public String getAuditDept()
|
||||
{
|
||||
return auditDept;
|
||||
}
|
||||
public void setAuditDeptid(Long auditDeptid)
|
||||
{
|
||||
this.auditDeptid = auditDeptid;
|
||||
}
|
||||
|
||||
public Long getAuditDeptid()
|
||||
{
|
||||
return auditDeptid;
|
||||
}
|
||||
public void setAuditName(String auditName)
|
||||
{
|
||||
this.auditName = auditName;
|
||||
}
|
||||
|
||||
public String getAuditName()
|
||||
{
|
||||
return auditName;
|
||||
}
|
||||
public void setAuditResult(String auditResult)
|
||||
{
|
||||
this.auditResult = auditResult;
|
||||
}
|
||||
|
||||
public String getAuditResult()
|
||||
{
|
||||
return auditResult;
|
||||
}
|
||||
public void setAuditReason(String auditReason)
|
||||
{
|
||||
this.auditReason = auditReason;
|
||||
}
|
||||
|
||||
public String getAuditReason()
|
||||
{
|
||||
return auditReason;
|
||||
}
|
||||
public void setDeptName(String deptName)
|
||||
{
|
||||
this.deptName = deptName;
|
||||
}
|
||||
|
||||
public String getDeptName()
|
||||
{
|
||||
return deptName;
|
||||
}
|
||||
public void setDeptId(Long deptId)
|
||||
{
|
||||
this.deptId = deptId;
|
||||
}
|
||||
|
||||
public Long getDeptId()
|
||||
{
|
||||
return deptId;
|
||||
}
|
||||
public void setUserId(Long userId)
|
||||
{
|
||||
this.userId = userId;
|
||||
}
|
||||
|
||||
public Long getUserId()
|
||||
{
|
||||
return userId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id", getId())
|
||||
.append("applyName", getApplyName())
|
||||
.append("applyPhone", getApplyPhone())
|
||||
.append("applyDate", getApplyDate())
|
||||
.append("title", getTitle())
|
||||
.append("wishType", getWishType())
|
||||
.append("wishDescrib", getWishDescrib())
|
||||
.append("wishStatus", getWishStatus())
|
||||
.append("rlName", getRlName())
|
||||
.append("rlPhone", getRlPhone())
|
||||
.append("rlId", getRlId())
|
||||
.append("auditDept", getAuditDept())
|
||||
.append("auditDeptid", getAuditDeptid())
|
||||
.append("auditName", getAuditName())
|
||||
.append("auditResult", getAuditResult())
|
||||
.append("auditReason", getAuditReason())
|
||||
.append("remark", getRemark())
|
||||
.append("deptName", getDeptName())
|
||||
.append("deptId", getDeptId())
|
||||
.append("createBy", getCreateBy())
|
||||
.append("createTime", getCreateTime())
|
||||
.append("updateBy", getUpdateBy())
|
||||
.append("updateTime", getUpdateTime())
|
||||
.append("userId", getUserId())
|
||||
.toString();
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,62 @@
|
||||
package com.ruoyi.szxc.mapper;
|
||||
|
||||
import com.ruoyi.szxc.domain.SzxcWishManage;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 心愿管理Mapper接口
|
||||
*
|
||||
* @author hs
|
||||
* @date 2024-04-03
|
||||
*/
|
||||
public interface SzxcWishManageMapper
|
||||
{
|
||||
/**
|
||||
* 查询心愿管理
|
||||
*
|
||||
* @param id 心愿管理主键
|
||||
* @return 心愿管理
|
||||
*/
|
||||
public SzxcWishManage selectSzxcWishManageById(Long id);
|
||||
|
||||
/**
|
||||
* 查询心愿管理列表
|
||||
*
|
||||
* @param szxcWishManage 心愿管理
|
||||
* @return 心愿管理集合
|
||||
*/
|
||||
public List<SzxcWishManage> selectSzxcWishManageList(SzxcWishManage szxcWishManage);
|
||||
|
||||
/**
|
||||
* 新增心愿管理
|
||||
*
|
||||
* @param szxcWishManage 心愿管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertSzxcWishManage(SzxcWishManage szxcWishManage);
|
||||
|
||||
/**
|
||||
* 修改心愿管理
|
||||
*
|
||||
* @param szxcWishManage 心愿管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateSzxcWishManage(SzxcWishManage szxcWishManage);
|
||||
|
||||
/**
|
||||
* 删除心愿管理
|
||||
*
|
||||
* @param id 心愿管理主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteSzxcWishManageById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除心愿管理
|
||||
*
|
||||
* @param ids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteSzxcWishManageByIds(Long[] ids);
|
||||
}
|
||||
@ -0,0 +1,62 @@
|
||||
package com.ruoyi.szxc.service;
|
||||
|
||||
import com.ruoyi.szxc.domain.SzxcWishManage;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 心愿管理Service接口
|
||||
*
|
||||
* @author hs
|
||||
* @date 2024-04-03
|
||||
*/
|
||||
public interface ISzxcWishManageService
|
||||
{
|
||||
/**
|
||||
* 查询心愿管理
|
||||
*
|
||||
* @param id 心愿管理主键
|
||||
* @return 心愿管理
|
||||
*/
|
||||
public SzxcWishManage selectSzxcWishManageById(Long id);
|
||||
|
||||
/**
|
||||
* 查询心愿管理列表
|
||||
*
|
||||
* @param szxcWishManage 心愿管理
|
||||
* @return 心愿管理集合
|
||||
*/
|
||||
public List<SzxcWishManage> selectSzxcWishManageList(SzxcWishManage szxcWishManage);
|
||||
|
||||
/**
|
||||
* 新增心愿管理
|
||||
*
|
||||
* @param szxcWishManage 心愿管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertSzxcWishManage(SzxcWishManage szxcWishManage);
|
||||
|
||||
/**
|
||||
* 修改心愿管理
|
||||
*
|
||||
* @param szxcWishManage 心愿管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateSzxcWishManage(SzxcWishManage szxcWishManage);
|
||||
|
||||
/**
|
||||
* 批量删除心愿管理
|
||||
*
|
||||
* @param ids 需要删除的心愿管理主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteSzxcWishManageByIds(Long[] ids);
|
||||
|
||||
/**
|
||||
* 删除心愿管理信息
|
||||
*
|
||||
* @param id 心愿管理主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteSzxcWishManageById(Long id);
|
||||
}
|
||||
@ -1,62 +0,0 @@
|
||||
package com.ruoyi.szxc.service.impl;
|
||||
|
||||
import com.ruoyi.szxc.domain.SzxcZcss;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 资产设施Service接口
|
||||
*
|
||||
* @author hs
|
||||
* @date 2024-04-02
|
||||
*/
|
||||
public interface ISzxcZcssService
|
||||
{
|
||||
/**
|
||||
* 查询资产设施
|
||||
*
|
||||
* @param id 资产设施主键
|
||||
* @return 资产设施
|
||||
*/
|
||||
public SzxcZcss selectSzxcZcssById(Long id);
|
||||
|
||||
/**
|
||||
* 查询资产设施列表
|
||||
*
|
||||
* @param szxcZcss 资产设施
|
||||
* @return 资产设施集合
|
||||
*/
|
||||
public List<SzxcZcss> selectSzxcZcssList(SzxcZcss szxcZcss);
|
||||
|
||||
/**
|
||||
* 新增资产设施
|
||||
*
|
||||
* @param szxcZcss 资产设施
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertSzxcZcss(SzxcZcss szxcZcss);
|
||||
|
||||
/**
|
||||
* 修改资产设施
|
||||
*
|
||||
* @param szxcZcss 资产设施
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateSzxcZcss(SzxcZcss szxcZcss);
|
||||
|
||||
/**
|
||||
* 批量删除资产设施
|
||||
*
|
||||
* @param ids 需要删除的资产设施主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteSzxcZcssByIds(Long[] ids);
|
||||
|
||||
/**
|
||||
* 删除资产设施信息
|
||||
*
|
||||
* @param id 资产设施主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteSzxcZcssById(Long id);
|
||||
}
|
||||
@ -0,0 +1,97 @@
|
||||
package com.ruoyi.szxc.service.impl;
|
||||
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.szxc.domain.SzxcWishManage;
|
||||
import com.ruoyi.szxc.mapper.SzxcWishManageMapper;
|
||||
import com.ruoyi.szxc.service.ISzxcWishManageService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 心愿管理Service业务层处理
|
||||
*
|
||||
* @author hs
|
||||
* @date 2024-04-03
|
||||
*/
|
||||
@Service
|
||||
public class SzxcWishManageServiceImpl implements ISzxcWishManageService
|
||||
{
|
||||
@Autowired
|
||||
private SzxcWishManageMapper szxcWishManageMapper;
|
||||
|
||||
/**
|
||||
* 查询心愿管理
|
||||
*
|
||||
* @param id 心愿管理主键
|
||||
* @return 心愿管理
|
||||
*/
|
||||
@Override
|
||||
public SzxcWishManage selectSzxcWishManageById(Long id)
|
||||
{
|
||||
return szxcWishManageMapper.selectSzxcWishManageById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询心愿管理列表
|
||||
*
|
||||
* @param szxcWishManage 心愿管理
|
||||
* @return 心愿管理
|
||||
*/
|
||||
@Override
|
||||
public List<SzxcWishManage> selectSzxcWishManageList(SzxcWishManage szxcWishManage)
|
||||
{
|
||||
return szxcWishManageMapper.selectSzxcWishManageList(szxcWishManage);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增心愿管理
|
||||
*
|
||||
* @param szxcWishManage 心愿管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertSzxcWishManage(SzxcWishManage szxcWishManage)
|
||||
{
|
||||
szxcWishManage.setCreateTime(DateUtils.getNowDate());
|
||||
return szxcWishManageMapper.insertSzxcWishManage(szxcWishManage);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改心愿管理
|
||||
*
|
||||
* @param szxcWishManage 心愿管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateSzxcWishManage(SzxcWishManage szxcWishManage)
|
||||
{
|
||||
szxcWishManage.setUpdateTime(DateUtils.getNowDate());
|
||||
return szxcWishManageMapper.updateSzxcWishManage(szxcWishManage);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除心愿管理
|
||||
*
|
||||
* @param ids 需要删除的心愿管理主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteSzxcWishManageByIds(Long[] ids)
|
||||
{
|
||||
return szxcWishManageMapper.deleteSzxcWishManageByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除心愿管理信息
|
||||
*
|
||||
* @param id 心愿管理主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteSzxcWishManageById(Long id)
|
||||
{
|
||||
return szxcWishManageMapper.deleteSzxcWishManageById(id);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,161 @@
|
||||
<?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.ruoyi.szxc.mapper.SzxcWishManageMapper">
|
||||
|
||||
<resultMap type="SzxcWishManage" id="SzxcWishManageResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="applyName" column="apply_name" />
|
||||
<result property="applyPhone" column="apply_phone" />
|
||||
<result property="applyDate" column="apply_date" />
|
||||
<result property="title" column="title" />
|
||||
<result property="wishType" column="wish_type" />
|
||||
<result property="wishDescrib" column="wish_describ" />
|
||||
<result property="wishStatus" column="wish_status" />
|
||||
<result property="rlName" column="rl_name" />
|
||||
<result property="rlPhone" column="rl_phone" />
|
||||
<result property="rlId" column="rl_id" />
|
||||
<result property="auditDept" column="audit_dept" />
|
||||
<result property="auditDeptid" column="audit_deptid" />
|
||||
<result property="auditName" column="audit_name" />
|
||||
<result property="auditResult" column="audit_result" />
|
||||
<result property="auditReason" column="audit_reason" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="deptName" column="dept_name" />
|
||||
<result property="deptId" column="dept_id" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
<result property="userId" column="user_id" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectSzxcWishManageVo">
|
||||
select id, apply_name, apply_phone, apply_date, title, wish_type, wish_describ, wish_status, rl_name, rl_phone, rl_id, audit_dept, audit_deptid, audit_name, audit_result, audit_reason, remark, dept_name, dept_id, create_by, create_time, update_by, update_time, user_id from szxc_wish_manage
|
||||
</sql>
|
||||
|
||||
<select id="selectSzxcWishManageList" parameterType="SzxcWishManage" resultMap="SzxcWishManageResult">
|
||||
<include refid="selectSzxcWishManageVo"/>
|
||||
<where>
|
||||
<if test="applyName != null and applyName != ''"> and apply_name like concat('%', #{applyName}, '%')</if>
|
||||
<if test="applyPhone != null and applyPhone != ''"> and apply_phone = #{applyPhone}</if>
|
||||
<if test="applyDate != null "> and apply_date = #{applyDate}</if>
|
||||
<if test="title != null and title != ''"> and title = #{title}</if>
|
||||
<if test="wishType != null and wishType != ''"> and wish_type = #{wishType}</if>
|
||||
<if test="wishDescrib != null and wishDescrib != ''"> and wish_describ = #{wishDescrib}</if>
|
||||
<if test="wishStatus != null and wishStatus != ''"> and wish_status = #{wishStatus}</if>
|
||||
<if test="rlName != null and rlName != ''"> and rl_name like concat('%', #{rlName}, '%')</if>
|
||||
<if test="rlPhone != null and rlPhone != ''"> and rl_phone = #{rlPhone}</if>
|
||||
<if test="rlId != null "> and rl_id = #{rlId}</if>
|
||||
<if test="auditDept != null and auditDept != ''"> and audit_dept = #{auditDept}</if>
|
||||
<if test="auditDeptid != null "> and audit_deptid = #{auditDeptid}</if>
|
||||
<if test="auditName != null and auditName != ''"> and audit_name like concat('%', #{auditName}, '%')</if>
|
||||
<if test="auditResult != null and auditResult != ''"> and audit_result = #{auditResult}</if>
|
||||
<if test="auditReason != null and auditReason != ''"> and audit_reason = #{auditReason}</if>
|
||||
<if test="deptName != null and deptName != ''"> and dept_name like concat('%', #{deptName}, '%')</if>
|
||||
<if test="deptId != null "> and dept_id = #{deptId}</if>
|
||||
<if test="userId != null "> and user_id = #{userId}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectSzxcWishManageById" parameterType="Long" resultMap="SzxcWishManageResult">
|
||||
<include refid="selectSzxcWishManageVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertSzxcWishManage" parameterType="SzxcWishManage" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into szxc_wish_manage
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="applyName != null">apply_name,</if>
|
||||
<if test="applyPhone != null">apply_phone,</if>
|
||||
<if test="applyDate != null">apply_date,</if>
|
||||
<if test="title != null">title,</if>
|
||||
<if test="wishType != null">wish_type,</if>
|
||||
<if test="wishDescrib != null">wish_describ,</if>
|
||||
<if test="wishStatus != null">wish_status,</if>
|
||||
<if test="rlName != null">rl_name,</if>
|
||||
<if test="rlPhone != null">rl_phone,</if>
|
||||
<if test="rlId != null">rl_id,</if>
|
||||
<if test="auditDept != null">audit_dept,</if>
|
||||
<if test="auditDeptid != null">audit_deptid,</if>
|
||||
<if test="auditName != null">audit_name,</if>
|
||||
<if test="auditResult != null">audit_result,</if>
|
||||
<if test="auditReason != null">audit_reason,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="deptName != null">dept_name,</if>
|
||||
<if test="deptId != null">dept_id,</if>
|
||||
<if test="createBy != null">create_by,</if>
|
||||
<if test="createTime != null">create_time,</if>
|
||||
<if test="updateBy != null">update_by,</if>
|
||||
<if test="updateTime != null">update_time,</if>
|
||||
<if test="userId != null">user_id,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="applyName != null">#{applyName},</if>
|
||||
<if test="applyPhone != null">#{applyPhone},</if>
|
||||
<if test="applyDate != null">#{applyDate},</if>
|
||||
<if test="title != null">#{title},</if>
|
||||
<if test="wishType != null">#{wishType},</if>
|
||||
<if test="wishDescrib != null">#{wishDescrib},</if>
|
||||
<if test="wishStatus != null">#{wishStatus},</if>
|
||||
<if test="rlName != null">#{rlName},</if>
|
||||
<if test="rlPhone != null">#{rlPhone},</if>
|
||||
<if test="rlId != null">#{rlId},</if>
|
||||
<if test="auditDept != null">#{auditDept},</if>
|
||||
<if test="auditDeptid != null">#{auditDeptid},</if>
|
||||
<if test="auditName != null">#{auditName},</if>
|
||||
<if test="auditResult != null">#{auditResult},</if>
|
||||
<if test="auditReason != null">#{auditReason},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="deptName != null">#{deptName},</if>
|
||||
<if test="deptId != null">#{deptId},</if>
|
||||
<if test="createBy != null">#{createBy},</if>
|
||||
<if test="createTime != null">#{createTime},</if>
|
||||
<if test="updateBy != null">#{updateBy},</if>
|
||||
<if test="updateTime != null">#{updateTime},</if>
|
||||
<if test="userId != null">#{userId},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateSzxcWishManage" parameterType="SzxcWishManage">
|
||||
update szxc_wish_manage
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="applyName != null">apply_name = #{applyName},</if>
|
||||
<if test="applyPhone != null">apply_phone = #{applyPhone},</if>
|
||||
<if test="applyDate != null">apply_date = #{applyDate},</if>
|
||||
<if test="title != null">title = #{title},</if>
|
||||
<if test="wishType != null">wish_type = #{wishType},</if>
|
||||
<if test="wishDescrib != null">wish_describ = #{wishDescrib},</if>
|
||||
<if test="wishStatus != null">wish_status = #{wishStatus},</if>
|
||||
<if test="rlName != null">rl_name = #{rlName},</if>
|
||||
<if test="rlPhone != null">rl_phone = #{rlPhone},</if>
|
||||
<if test="rlId != null">rl_id = #{rlId},</if>
|
||||
<if test="auditDept != null">audit_dept = #{auditDept},</if>
|
||||
<if test="auditDeptid != null">audit_deptid = #{auditDeptid},</if>
|
||||
<if test="auditName != null">audit_name = #{auditName},</if>
|
||||
<if test="auditResult != null">audit_result = #{auditResult},</if>
|
||||
<if test="auditReason != null">audit_reason = #{auditReason},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="deptName != null">dept_name = #{deptName},</if>
|
||||
<if test="deptId != null">dept_id = #{deptId},</if>
|
||||
<if test="createBy != null">create_by = #{createBy},</if>
|
||||
<if test="createTime != null">create_time = #{createTime},</if>
|
||||
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||
<if test="userId != null">user_id = #{userId},</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteSzxcWishManageById" parameterType="Long">
|
||||
delete from szxc_wish_manage where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteSzxcWishManageByIds" parameterType="String">
|
||||
delete from szxc_wish_manage where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -0,0 +1,44 @@
|
||||
import request from '@/utils/request'
|
||||
|
||||
// 查询心愿管理列表
|
||||
export function listWish(query) {
|
||||
return request({
|
||||
url: '/szxc/wish/list',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
|
||||
// 查询心愿管理详细
|
||||
export function getWish(id) {
|
||||
return request({
|
||||
url: '/szxc/wish/' + id,
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
// 新增心愿管理
|
||||
export function addWish(data) {
|
||||
return request({
|
||||
url: '/szxc/wish',
|
||||
method: 'post',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 修改心愿管理
|
||||
export function updateWish(data) {
|
||||
return request({
|
||||
url: '/szxc/wish',
|
||||
method: 'put',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
// 删除心愿管理
|
||||
export function delWish(id) {
|
||||
return request({
|
||||
url: '/szxc/wish/' + id,
|
||||
method: 'delete'
|
||||
})
|
||||
}
|
||||
@ -0,0 +1,471 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
|
||||
<el-form-item label="申请人" prop="applyName">
|
||||
<el-input
|
||||
v-model="queryParams.applyName"
|
||||
placeholder="请输入申请人"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="申请人电话" prop="applyPhone">
|
||||
<el-input
|
||||
v-model="queryParams.applyPhone"
|
||||
placeholder="请输入申请人电话"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="申请时间" prop="applyDate">
|
||||
<el-date-picker clearable
|
||||
v-model="queryParams.applyDate"
|
||||
type="date"
|
||||
value-format="yyyy-MM-dd"
|
||||
placeholder="请选择申请时间">
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item label="心愿标题" prop="title">
|
||||
<el-input
|
||||
v-model="queryParams.title"
|
||||
placeholder="请输入心愿标题"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="认领人" prop="rlName">
|
||||
<el-input
|
||||
v-model="queryParams.rlName"
|
||||
placeholder="请输入认领人"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="认领人电话" prop="rlPhone">
|
||||
<el-input
|
||||
v-model="queryParams.rlPhone"
|
||||
placeholder="请输入认领人电话"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="认领人居民id" prop="rlId">
|
||||
<el-input
|
||||
v-model="queryParams.rlId"
|
||||
placeholder="请输入认领人居民id"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="审核部门" prop="auditDept">
|
||||
<el-input
|
||||
v-model="queryParams.auditDept"
|
||||
placeholder="请输入审核部门"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="审核部门id" prop="auditDeptid">
|
||||
<el-input
|
||||
v-model="queryParams.auditDeptid"
|
||||
placeholder="请输入审核部门id"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="审核人" prop="auditName">
|
||||
<el-input
|
||||
v-model="queryParams.auditName"
|
||||
placeholder="请输入审核人"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="审核结果" prop="auditResult">
|
||||
<el-input
|
||||
v-model="queryParams.auditResult"
|
||||
placeholder="请输入审核结果"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="审核原因" prop="auditReason">
|
||||
<el-input
|
||||
v-model="queryParams.auditReason"
|
||||
placeholder="请输入审核原因"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="申请人网格" prop="deptName">
|
||||
<el-input
|
||||
v-model="queryParams.deptName"
|
||||
placeholder="请输入申请人网格"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="申请人部门id" prop="deptId">
|
||||
<el-input
|
||||
v-model="queryParams.deptId"
|
||||
placeholder="请输入申请人部门id"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="创建者ID" prop="userId">
|
||||
<el-input
|
||||
v-model="queryParams.userId"
|
||||
placeholder="请输入创建者ID"
|
||||
clearable
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
||||
<el-row :gutter="10" class="mb8">
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="primary"
|
||||
plain
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="handleAdd"
|
||||
v-hasPermi="['szxc:wish:add']"
|
||||
>新增</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="success"
|
||||
plain
|
||||
icon="el-icon-edit"
|
||||
size="mini"
|
||||
:disabled="single"
|
||||
@click="handleUpdate"
|
||||
v-hasPermi="['szxc:wish:edit']"
|
||||
>修改</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="danger"
|
||||
plain
|
||||
icon="el-icon-delete"
|
||||
size="mini"
|
||||
:disabled="multiple"
|
||||
@click="handleDelete"
|
||||
v-hasPermi="['szxc:wish:remove']"
|
||||
>删除</el-button>
|
||||
</el-col>
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="warning"
|
||||
plain
|
||||
icon="el-icon-download"
|
||||
size="mini"
|
||||
@click="handleExport"
|
||||
v-hasPermi="['szxc:wish:export']"
|
||||
>导出</el-button>
|
||||
</el-col>
|
||||
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
||||
</el-row>
|
||||
|
||||
<el-table v-loading="loading" :data="wishList" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table-column label="id" align="center" prop="id" />
|
||||
<el-table-column label="申请人" align="center" prop="applyName" />
|
||||
<el-table-column label="申请人电话" align="center" prop="applyPhone" />
|
||||
<el-table-column label="申请时间" align="center" prop="applyDate" width="180">
|
||||
<template slot-scope="scope">
|
||||
<span>{{ parseTime(scope.row.applyDate, '{y}-{m}-{d}') }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="心愿标题" align="center" prop="title" />
|
||||
<el-table-column label="心愿类型" align="center" prop="wishType" />
|
||||
<el-table-column label="心愿描述" align="center" prop="wishDescrib" />
|
||||
<el-table-column label="心愿状态" align="center" prop="wishStatus" />
|
||||
<el-table-column label="认领人" align="center" prop="rlName" />
|
||||
<el-table-column label="认领人电话" align="center" prop="rlPhone" />
|
||||
<el-table-column label="认领人居民id" align="center" prop="rlId" />
|
||||
<el-table-column label="审核部门" align="center" prop="auditDept" />
|
||||
<el-table-column label="审核部门id" align="center" prop="auditDeptid" />
|
||||
<el-table-column label="审核人" align="center" prop="auditName" />
|
||||
<el-table-column label="审核结果" align="center" prop="auditResult" />
|
||||
<el-table-column label="审核原因" align="center" prop="auditReason" />
|
||||
<el-table-column label="备注" align="center" prop="remark" />
|
||||
<el-table-column label="申请人网格" align="center" prop="deptName" />
|
||||
<el-table-column label="申请人部门id" align="center" prop="deptId" />
|
||||
<el-table-column label="创建者ID" align="center" prop="userId" />
|
||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-edit"
|
||||
@click="handleUpdate(scope.row)"
|
||||
v-hasPermi="['szxc:wish:edit']"
|
||||
>修改</el-button>
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-delete"
|
||||
@click="handleDelete(scope.row)"
|
||||
v-hasPermi="['szxc:wish:remove']"
|
||||
>删除</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
||||
<pagination
|
||||
v-show="total>0"
|
||||
:total="total"
|
||||
:page.sync="queryParams.pageNum"
|
||||
:limit.sync="queryParams.pageSize"
|
||||
@pagination="getList"
|
||||
/>
|
||||
|
||||
<!-- 添加或修改心愿管理对话框 -->
|
||||
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
|
||||
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
|
||||
<el-form-item label="申请人" prop="applyName">
|
||||
<el-input v-model="form.applyName" placeholder="请输入申请人" />
|
||||
</el-form-item>
|
||||
<el-form-item label="申请人电话" prop="applyPhone">
|
||||
<el-input v-model="form.applyPhone" placeholder="请输入申请人电话" />
|
||||
</el-form-item>
|
||||
<el-form-item label="申请时间" prop="applyDate">
|
||||
<el-date-picker clearable
|
||||
v-model="form.applyDate"
|
||||
type="date"
|
||||
value-format="yyyy-MM-dd"
|
||||
placeholder="请选择申请时间">
|
||||
</el-date-picker>
|
||||
</el-form-item>
|
||||
<el-form-item label="心愿标题" prop="title">
|
||||
<el-input v-model="form.title" placeholder="请输入心愿标题" />
|
||||
</el-form-item>
|
||||
<el-form-item label="心愿描述" prop="wishDescrib">
|
||||
<el-input v-model="form.wishDescrib" type="textarea" placeholder="请输入内容" />
|
||||
</el-form-item>
|
||||
<el-form-item label="认领人" prop="rlName">
|
||||
<el-input v-model="form.rlName" placeholder="请输入认领人" />
|
||||
</el-form-item>
|
||||
<el-form-item label="认领人电话" prop="rlPhone">
|
||||
<el-input v-model="form.rlPhone" placeholder="请输入认领人电话" />
|
||||
</el-form-item>
|
||||
<el-form-item label="认领人居民id" prop="rlId">
|
||||
<el-input v-model="form.rlId" placeholder="请输入认领人居民id" />
|
||||
</el-form-item>
|
||||
<el-form-item label="审核部门" prop="auditDept">
|
||||
<el-input v-model="form.auditDept" placeholder="请输入审核部门" />
|
||||
</el-form-item>
|
||||
<el-form-item label="审核部门id" prop="auditDeptid">
|
||||
<el-input v-model="form.auditDeptid" placeholder="请输入审核部门id" />
|
||||
</el-form-item>
|
||||
<el-form-item label="审核人" prop="auditName">
|
||||
<el-input v-model="form.auditName" placeholder="请输入审核人" />
|
||||
</el-form-item>
|
||||
<el-form-item label="审核结果" prop="auditResult">
|
||||
<el-input v-model="form.auditResult" placeholder="请输入审核结果" />
|
||||
</el-form-item>
|
||||
<el-form-item label="审核原因" prop="auditReason">
|
||||
<el-input v-model="form.auditReason" placeholder="请输入审核原因" />
|
||||
</el-form-item>
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-input v-model="form.remark" placeholder="请输入备注" />
|
||||
</el-form-item>
|
||||
<el-form-item label="申请人网格" prop="deptName">
|
||||
<el-input v-model="form.deptName" placeholder="请输入申请人网格" />
|
||||
</el-form-item>
|
||||
<el-form-item label="申请人部门id" prop="deptId">
|
||||
<el-input v-model="form.deptId" placeholder="请输入申请人部门id" />
|
||||
</el-form-item>
|
||||
<el-form-item label="创建者ID" prop="userId">
|
||||
<el-input v-model="form.userId" placeholder="请输入创建者ID" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||
<el-button @click="cancel">取 消</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { listWish, getWish, delWish, addWish, updateWish } from "@/api/szxc/wish";
|
||||
|
||||
export default {
|
||||
name: "Wish",
|
||||
data() {
|
||||
return {
|
||||
// 遮罩层
|
||||
loading: true,
|
||||
// 选中数组
|
||||
ids: [],
|
||||
// 非单个禁用
|
||||
single: true,
|
||||
// 非多个禁用
|
||||
multiple: true,
|
||||
// 显示搜索条件
|
||||
showSearch: true,
|
||||
// 总条数
|
||||
total: 0,
|
||||
// 心愿管理表格数据
|
||||
wishList: [],
|
||||
// 弹出层标题
|
||||
title: "",
|
||||
// 是否显示弹出层
|
||||
open: false,
|
||||
// 查询参数
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
applyName: null,
|
||||
applyPhone: null,
|
||||
applyDate: null,
|
||||
title: null,
|
||||
wishType: null,
|
||||
wishDescrib: null,
|
||||
wishStatus: null,
|
||||
rlName: null,
|
||||
rlPhone: null,
|
||||
rlId: null,
|
||||
auditDept: null,
|
||||
auditDeptid: null,
|
||||
auditName: null,
|
||||
auditResult: null,
|
||||
auditReason: null,
|
||||
deptName: null,
|
||||
deptId: null,
|
||||
userId: null
|
||||
},
|
||||
// 表单参数
|
||||
form: {},
|
||||
// 表单校验
|
||||
rules: {
|
||||
}
|
||||
};
|
||||
},
|
||||
created() {
|
||||
this.getList();
|
||||
},
|
||||
methods: {
|
||||
/** 查询心愿管理列表 */
|
||||
getList() {
|
||||
this.loading = true;
|
||||
listWish(this.queryParams).then(response => {
|
||||
this.wishList = response.rows;
|
||||
this.total = response.total;
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
// 取消按钮
|
||||
cancel() {
|
||||
this.open = false;
|
||||
this.reset();
|
||||
},
|
||||
// 表单重置
|
||||
reset() {
|
||||
this.form = {
|
||||
id: null,
|
||||
applyName: null,
|
||||
applyPhone: null,
|
||||
applyDate: null,
|
||||
title: null,
|
||||
wishType: null,
|
||||
wishDescrib: null,
|
||||
wishStatus: null,
|
||||
rlName: null,
|
||||
rlPhone: null,
|
||||
rlId: null,
|
||||
auditDept: null,
|
||||
auditDeptid: null,
|
||||
auditName: null,
|
||||
auditResult: null,
|
||||
auditReason: null,
|
||||
remark: null,
|
||||
deptName: null,
|
||||
deptId: null,
|
||||
createBy: null,
|
||||
createTime: null,
|
||||
updateBy: null,
|
||||
updateTime: null,
|
||||
userId: null
|
||||
};
|
||||
this.resetForm("form");
|
||||
},
|
||||
/** 搜索按钮操作 */
|
||||
handleQuery() {
|
||||
this.queryParams.pageNum = 1;
|
||||
this.getList();
|
||||
},
|
||||
/** 重置按钮操作 */
|
||||
resetQuery() {
|
||||
this.resetForm("queryForm");
|
||||
this.handleQuery();
|
||||
},
|
||||
// 多选框选中数据
|
||||
handleSelectionChange(selection) {
|
||||
this.ids = selection.map(item => item.id)
|
||||
this.single = selection.length!==1
|
||||
this.multiple = !selection.length
|
||||
},
|
||||
/** 新增按钮操作 */
|
||||
handleAdd() {
|
||||
this.reset();
|
||||
this.open = true;
|
||||
this.title = "添加心愿管理";
|
||||
},
|
||||
/** 修改按钮操作 */
|
||||
handleUpdate(row) {
|
||||
this.reset();
|
||||
const id = row.id || this.ids
|
||||
getWish(id).then(response => {
|
||||
this.form = response.data;
|
||||
this.open = true;
|
||||
this.title = "修改心愿管理";
|
||||
});
|
||||
},
|
||||
/** 提交按钮 */
|
||||
submitForm() {
|
||||
this.$refs["form"].validate(valid => {
|
||||
if (valid) {
|
||||
if (this.form.id != null) {
|
||||
updateWish(this.form).then(response => {
|
||||
this.$modal.msgSuccess("修改成功");
|
||||
this.open = false;
|
||||
this.getList();
|
||||
});
|
||||
} else {
|
||||
addWish(this.form).then(response => {
|
||||
this.$modal.msgSuccess("新增成功");
|
||||
this.open = false;
|
||||
this.getList();
|
||||
});
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
/** 删除按钮操作 */
|
||||
handleDelete(row) {
|
||||
const ids = row.id || this.ids;
|
||||
this.$modal.confirm('是否确认删除心愿管理编号为"' + ids + '"的数据项?').then(function() {
|
||||
return delWish(ids);
|
||||
}).then(() => {
|
||||
this.getList();
|
||||
this.$modal.msgSuccess("删除成功");
|
||||
}).catch(() => {});
|
||||
},
|
||||
/** 导出按钮操作 */
|
||||
handleExport() {
|
||||
this.download('szxc/wish/export', {
|
||||
...this.queryParams
|
||||
}, `wish_${new Date().getTime()}.xlsx`)
|
||||
}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
Loading…
Reference in new issue