Эх сурвалжийг харах

张丁 预约开票台账页面

zhangding 3 жил өмнө
parent
commit
6449156a4f
16 өөрчлөгдсөн 2864 нэмэгдсэн , 0 устгасан
  1. 104 0
      master/src/main/java/com/ruoyi/project/invoice/controller/TInvoiceBookingworkticketController.java
  2. 105 0
      master/src/main/java/com/ruoyi/project/invoice/controller/TInvoiceWorkcontentController.java
  3. 281 0
      master/src/main/java/com/ruoyi/project/invoice/domain/TInvoiceBookingworkticket.java
  4. 222 0
      master/src/main/java/com/ruoyi/project/invoice/domain/TInvoiceWorkcontent.java
  5. 63 0
      master/src/main/java/com/ruoyi/project/invoice/mapper/TInvoiceBookingworkticketMapper.java
  6. 63 0
      master/src/main/java/com/ruoyi/project/invoice/mapper/TInvoiceWorkcontentMapper.java
  7. 61 0
      master/src/main/java/com/ruoyi/project/invoice/service/ITInvoiceBookingworkticketService.java
  8. 61 0
      master/src/main/java/com/ruoyi/project/invoice/service/ITInvoiceWorkcontentService.java
  9. 93 0
      master/src/main/java/com/ruoyi/project/invoice/service/impl/TInvoiceBookingworkticketServiceImpl.java
  10. 93 0
      master/src/main/java/com/ruoyi/project/invoice/service/impl/TInvoiceWorkcontentServiceImpl.java
  11. 147 0
      master/src/main/resources/mybatis/invoice/TInvoiceBookingworkticketMapper.xml
  12. 127 0
      master/src/main/resources/mybatis/invoice/TInvoiceWorkcontentMapper.xml
  13. 53 0
      ui/src/api/invoice/bookingworkticket.js
  14. 53 0
      ui/src/api/invoice/workcontent.js
  15. 788 0
      ui/src/views/invoice/bookingworkticket/index.vue
  16. 550 0
      ui/src/views/invoice/workcontent/index.vue

+ 104 - 0
master/src/main/java/com/ruoyi/project/invoice/controller/TInvoiceBookingworkticketController.java

@@ -0,0 +1,104 @@
+package com.ruoyi.project.invoice.controller;
+
+import java.util.List;
+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.framework.aspectj.lang.annotation.Log;
+import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
+import com.ruoyi.project.invoice.domain.TInvoiceBookingworkticket;
+import com.ruoyi.project.invoice.service.ITInvoiceBookingworkticketService;
+import com.ruoyi.framework.web.controller.BaseController;
+import com.ruoyi.framework.web.domain.AjaxResult;
+import com.ruoyi.common.utils.poi.ExcelUtil;
+import com.ruoyi.framework.web.page.TableDataInfo;
+
+/**
+ * 预约作业票台账Controller
+ *
+ * @author ruoyi
+ * @date 2022-08-25
+ */
+@RestController
+@RequestMapping("/invoice/bookingworkticket")
+public class TInvoiceBookingworkticketController extends BaseController
+{
+    @Autowired
+    private ITInvoiceBookingworkticketService tInvoiceBookingworkticketService;
+
+    /**
+     * 查询预约作业票台账列表
+     */
+    @PreAuthorize("@ss.hasPermi('invoice:bookingworkticket:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(TInvoiceBookingworkticket tInvoiceBookingworkticket)
+    {
+        startPage();
+        List<TInvoiceBookingworkticket> list = tInvoiceBookingworkticketService.selectTInvoiceBookingworkticketList(tInvoiceBookingworkticket);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出预约作业票台账列表
+     */
+    @PreAuthorize("@ss.hasPermi('invoice:bookingworkticket:export')")
+    @Log(title = "预约作业票台账", businessType = BusinessType.EXPORT)
+    @GetMapping("/export")
+    public AjaxResult export(TInvoiceBookingworkticket tInvoiceBookingworkticket)
+    {
+        List<TInvoiceBookingworkticket> list = tInvoiceBookingworkticketService.selectTInvoiceBookingworkticketList(tInvoiceBookingworkticket);
+        ExcelUtil<TInvoiceBookingworkticket> util = new ExcelUtil<TInvoiceBookingworkticket>(TInvoiceBookingworkticket.class);
+        return util.exportExcel(list, "bookingworkticket");
+    }
+
+    /**
+     * 获取预约作业票台账详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('invoice:bookingworkticket:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return AjaxResult.success(tInvoiceBookingworkticketService.selectTInvoiceBookingworkticketById(id));
+    }
+
+    /**
+     * 新增预约作业票台账
+     */
+    @PreAuthorize("@ss.hasPermi('invoice:bookingworkticket:add')")
+    @Log(title = "预约作业票台账", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody TInvoiceBookingworkticket tInvoiceBookingworkticket)
+    {
+        tInvoiceBookingworkticketService.insertTInvoiceBookingworkticket(tInvoiceBookingworkticket);
+        return AjaxResult.success(tInvoiceBookingworkticket.getId());
+    }
+
+    /**
+     * 修改预约作业票台账
+     */
+    @PreAuthorize("@ss.hasPermi('invoice:bookingworkticket:edit')")
+    @Log(title = "预约作业票台账", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody TInvoiceBookingworkticket tInvoiceBookingworkticket)
+    {
+        return toAjax(tInvoiceBookingworkticketService.updateTInvoiceBookingworkticket(tInvoiceBookingworkticket));
+    }
+
+    /**
+     * 删除预约作业票台账
+     */
+    @PreAuthorize("@ss.hasPermi('invoice:bookingworkticket:remove')")
+    @Log(title = "预约作业票台账", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(tInvoiceBookingworkticketService.deleteTInvoiceBookingworkticketByIds(ids));
+    }
+}

+ 105 - 0
master/src/main/java/com/ruoyi/project/invoice/controller/TInvoiceWorkcontentController.java

@@ -0,0 +1,105 @@
+package com.ruoyi.project.invoice.controller;
+
+import java.util.List;
+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.framework.aspectj.lang.annotation.Log;
+import com.ruoyi.framework.aspectj.lang.enums.BusinessType;
+import com.ruoyi.project.invoice.domain.TInvoiceWorkcontent;
+import com.ruoyi.project.invoice.service.ITInvoiceWorkcontentService;
+import com.ruoyi.framework.web.controller.BaseController;
+import com.ruoyi.framework.web.domain.AjaxResult;
+import com.ruoyi.common.utils.poi.ExcelUtil;
+import com.ruoyi.framework.web.page.TableDataInfo;
+
+/**
+ * 预约作业内容Controller
+ *
+ * @author ruoyi
+ * @date 2022-08-26
+ */
+@RestController
+@RequestMapping("/invoice/workcontent")
+public class TInvoiceWorkcontentController extends BaseController
+{
+    @Autowired
+    private ITInvoiceWorkcontentService tInvoiceWorkcontentService;
+
+    /**
+     * 查询预约作业内容列表
+     */
+    @PreAuthorize("@ss.hasPermi('invoice:workcontent:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(TInvoiceWorkcontent tInvoiceWorkcontent)
+    {
+        startPage();
+        List<TInvoiceWorkcontent> list = tInvoiceWorkcontentService.selectTInvoiceWorkcontentList(tInvoiceWorkcontent);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出预约作业内容列表
+     */
+    @PreAuthorize("@ss.hasPermi('invoice:workcontent:export')")
+    @Log(title = "预约作业内容", businessType = BusinessType.EXPORT)
+    @GetMapping("/export")
+    public AjaxResult export(TInvoiceWorkcontent tInvoiceWorkcontent)
+    {
+        List<TInvoiceWorkcontent> list = tInvoiceWorkcontentService.selectTInvoiceWorkcontentList(tInvoiceWorkcontent);
+        ExcelUtil<TInvoiceWorkcontent> util = new ExcelUtil<TInvoiceWorkcontent>(TInvoiceWorkcontent.class);
+        return util.exportExcel(list, "workcontent");
+    }
+
+    /**
+     * 获取预约作业内容详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('invoice:workcontent:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return AjaxResult.success(tInvoiceWorkcontentService.selectTInvoiceWorkcontentById(id));
+    }
+
+    /**
+     * 新增预约作业内容
+     */
+    @PreAuthorize("@ss.hasPermi('invoice:workcontent:add')")
+    @Log(title = "预约作业内容", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody TInvoiceWorkcontent tInvoiceWorkcontent)
+    {
+        return toAjax(tInvoiceWorkcontentService.insertTInvoiceWorkcontent(tInvoiceWorkcontent));
+    }
+
+
+    /**
+     * 修改预约作业内容
+     */
+    @PreAuthorize("@ss.hasPermi('invoice:workcontent:edit')")
+    @Log(title = "预约作业内容", businessType = BusinessType.UPDATE)
+    @PutMapping
+
+    public AjaxResult edit(@RequestBody TInvoiceWorkcontent tInvoiceWorkcontent)
+    {
+        return toAjax(tInvoiceWorkcontentService.updateTInvoiceWorkcontent(tInvoiceWorkcontent));
+    }
+
+    /**
+     * 删除预约作业内容
+     */
+    @PreAuthorize("@ss.hasPermi('invoice:workcontent:remove')")
+    @Log(title = "预约作业内容", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(tInvoiceWorkcontentService.deleteTInvoiceWorkcontentByIds(ids));
+    }
+}

+ 281 - 0
master/src/main/java/com/ruoyi/project/invoice/domain/TInvoiceBookingworkticket.java

@@ -0,0 +1,281 @@
+package com.ruoyi.project.invoice.domain;
+
+import java.util.Date;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ruoyi.framework.aspectj.lang.annotation.Excel;
+import com.ruoyi.framework.web.domain.BaseEntity;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+/**
+ * 预约作业票台账对象 t_invoice_bookingworkticket
+ *
+ * @author ruoyi
+ * @date 2022-08-25
+ */
+public class TInvoiceBookingworkticket extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 唯一标识ID */
+    private Long id;
+
+    /** 作业单位 */
+    @Excel(name = "作业单位")
+    private Long workUnit;
+
+    /** 作业区域 */
+    @Excel(name = "作业区域")
+    private Long workArea;
+
+    /** 单元号 */
+    @Excel(name = "单元号")
+    private Long unitNumber;
+
+    /** 楼层位置 */
+    @Excel(name = "楼层位置")
+    private Long floorLocation;
+
+    /**  作业开始时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
+    @Excel(name = " 作业开始时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date workStartTime;
+
+    /** 作业结束时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
+    @Excel(name = "作业结束时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date workEndTime;
+
+    /** 状态 1 :正常 ;0:删除 */
+    private Long delFlag;
+
+    /** 创建人 */
+    @Excel(name = "创建人")
+    private Long createrCode;
+
+    /** 创建时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
+    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date createdate;
+
+    /** 修改人 */
+    @Excel(name = "修改人")
+    private Long updaterCode;
+
+    /** 修改时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
+    @Excel(name = "修改时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date updatedate;
+
+    /** 联系人 */
+    @Excel(name = "联系人")
+    private String contact;
+
+    /** 联系方式 */
+    @Excel(name = "联系方式")
+    private String phonenumber;
+
+    /** 状态 */
+    @Excel(name = "状态")
+    private Long status;
+
+    /** 部门编号 */
+    @Excel(name = "部门编号")
+    private Long deptId;
+
+    /** 用户主管 */
+    @Excel(name = "用户主管")
+    private Long userMg;
+
+    /** 用户单位 */
+    @Excel(name = "用户单位")
+    private Long userUnit;
+
+    public void setId(Long id)
+    {
+        this.id = id;
+    }
+
+    public Long getId()
+    {
+        return id;
+    }
+    public void setWorkUnit(Long workUnit)
+    {
+        this.workUnit = workUnit;
+    }
+
+    public Long getWorkUnit()
+    {
+        return workUnit;
+    }
+    public void setWorkArea(Long workArea)
+    {
+        this.workArea = workArea;
+    }
+
+    public Long getWorkArea()
+    {
+        return workArea;
+    }
+    public void setUnitNumber(Long unitNumber)
+    {
+        this.unitNumber = unitNumber;
+    }
+
+    public Long getUnitNumber()
+    {
+        return unitNumber;
+    }
+    public void setFloorLocation(Long floorLocation)
+    {
+        this.floorLocation = floorLocation;
+    }
+
+    public Long getFloorLocation()
+    {
+        return floorLocation;
+    }
+    public void setWorkStartTime(Date workStartTime)
+    {
+        this.workStartTime = workStartTime;
+    }
+
+    public Date getWorkStartTime()
+    {
+        return workStartTime;
+    }
+    public void setWorkEndTime(Date workEndTime)
+    {
+        this.workEndTime = workEndTime;
+    }
+
+    public Date getWorkEndTime()
+    {
+        return workEndTime;
+    }
+    public void setDelFlag(Long delFlag)
+    {
+        this.delFlag = delFlag;
+    }
+
+    public Long getDelFlag()
+    {
+        return delFlag;
+    }
+    public void setCreaterCode(Long createrCode)
+    {
+        this.createrCode = createrCode;
+    }
+
+    public Long getCreaterCode()
+    {
+        return createrCode;
+    }
+    public void setCreatedate(Date createdate)
+    {
+        this.createdate = createdate;
+    }
+
+    public Date getCreatedate()
+    {
+        return createdate;
+    }
+    public void setUpdaterCode(Long updaterCode)
+    {
+        this.updaterCode = updaterCode;
+    }
+
+    public Long getUpdaterCode()
+    {
+        return updaterCode;
+    }
+    public void setUpdatedate(Date updatedate)
+    {
+        this.updatedate = updatedate;
+    }
+
+    public Date getUpdatedate()
+    {
+        return updatedate;
+    }
+    public void setContact(String contact)
+    {
+        this.contact = contact;
+    }
+
+    public String getContact()
+    {
+        return contact;
+    }
+    public void setPhonenumber(String phonenumber)
+    {
+        this.phonenumber = phonenumber;
+    }
+
+    public String getPhonenumber()
+    {
+        return phonenumber;
+    }
+    public void setStatus(Long status)
+    {
+        this.status = status;
+    }
+
+    public Long getStatus()
+    {
+        return status;
+    }
+    public void setDeptId(Long deptId)
+    {
+        this.deptId = deptId;
+    }
+
+    public Long getDeptId()
+    {
+        return deptId;
+    }
+    public void setUserMg(Long userMg)
+    {
+        this.userMg = userMg;
+    }
+
+    public Long getUserMg()
+    {
+        return userMg;
+    }
+
+    public void setUserUnit(Long userUnit)
+    {
+        this.userUnit = userUnit;
+    }
+
+    public Long getUserUnit()
+    {
+        return userUnit;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
+            .append("id", getId())
+            .append("workUnit", getWorkUnit())
+            .append("workArea", getWorkArea())
+            .append("unitNumber", getUnitNumber())
+            .append("floorLocation", getFloorLocation())
+            .append("workStartTime", getWorkStartTime())
+            .append("workEndTime", getWorkEndTime())
+            .append("delFlag", getDelFlag())
+            .append("createrCode", getCreaterCode())
+            .append("createdate", getCreatedate())
+            .append("updaterCode", getUpdaterCode())
+            .append("updatedate", getUpdatedate())
+            .append("contact", getContact())
+            .append("phonenumber", getPhonenumber())
+            .append("status", getStatus())
+            .append("deptId", getDeptId())
+            .append("userMg", getUserMg())
+                .append("userUnit", getUserUnit())
+            .toString();
+    }
+}

+ 222 - 0
master/src/main/java/com/ruoyi/project/invoice/domain/TInvoiceWorkcontent.java

@@ -0,0 +1,222 @@
+package com.ruoyi.project.invoice.domain;
+
+import java.util.Date;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import com.ruoyi.framework.aspectj.lang.annotation.Excel;
+import com.ruoyi.framework.web.domain.BaseEntity;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+
+/**
+ * 预约作业内容对象 t_invoice_workcontent
+ *
+ * @author ruoyi
+ * @date 2022-08-26
+ */
+public class TInvoiceWorkcontent extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 唯一标识ID */
+    private Long id;
+
+    /** 状态 1 :正常 ;0:删除 */
+    private Long delFlag;
+
+    /** 创建人 */
+    @Excel(name = "创建人")
+    private Long createrCode;
+
+    /** 创建时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
+    @Excel(name = "创建时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date createdate;
+
+    /** 修改人 */
+    @Excel(name = "修改人")
+    private Long updaterCode;
+
+    /** 修改时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd" , timezone = "GMT+8")
+    @Excel(name = "修改时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date updatedate;
+
+    /** 作业类型 */
+    @Excel(name = "作业类型")
+    private Long workType;
+
+    /** 风险等级 */
+    @Excel(name = "风险等级")
+    private Long riskLevel;
+
+    /** 作业内容描述 */
+    @Excel(name = "作业内容描述")
+    private String workDescription;
+
+    /** 作业人员数 */
+    @Excel(name = "作业人员数")
+    private Long workPeopleNumber;
+
+    /** 监护人单位 */
+    @Excel(name = "监护人单位")
+    private String guardianUnit;
+
+    /** 预计作业时间 */
+    @Excel(name = "预计作业时间")
+    private String estimateWorktime;
+
+    /** 关联的预约开票ID */
+    @Excel(name = "关联的预约开票ID")
+    private Long bookingticketId;
+
+    /** 部门编号 */
+    @Excel(name = "部门编号")
+    private Long deptId;
+
+    public void setId(Long id)
+    {
+        this.id = id;
+    }
+
+    public Long getId()
+    {
+        return id;
+    }
+    public void setDelFlag(Long delFlag)
+    {
+        this.delFlag = delFlag;
+    }
+
+    public Long getDelFlag()
+    {
+        return delFlag;
+    }
+    public void setCreaterCode(Long createrCode)
+    {
+        this.createrCode = createrCode;
+    }
+
+    public Long getCreaterCode()
+    {
+        return createrCode;
+    }
+    public void setCreatedate(Date createdate)
+    {
+        this.createdate = createdate;
+    }
+
+    public Date getCreatedate()
+    {
+        return createdate;
+    }
+    public void setUpdaterCode(Long updaterCode)
+    {
+        this.updaterCode = updaterCode;
+    }
+
+    public Long getUpdaterCode()
+    {
+        return updaterCode;
+    }
+    public void setUpdatedate(Date updatedate)
+    {
+        this.updatedate = updatedate;
+    }
+
+    public Date getUpdatedate()
+    {
+        return updatedate;
+    }
+    public void setWorkType(Long workType)
+    {
+        this.workType = workType;
+    }
+
+    public Long getWorkType()
+    {
+        return workType;
+    }
+    public void setRiskLevel(Long riskLevel)
+    {
+        this.riskLevel = riskLevel;
+    }
+
+    public Long getRiskLevel()
+    {
+        return riskLevel;
+    }
+    public void setWorkDescription(String workDescription)
+    {
+        this.workDescription = workDescription;
+    }
+
+    public String getWorkDescription()
+    {
+        return workDescription;
+    }
+    public void setWorkPeopleNumber(Long workPeopleNumber)
+    {
+        this.workPeopleNumber = workPeopleNumber;
+    }
+
+    public Long getWorkPeopleNumber()
+    {
+        return workPeopleNumber;
+    }
+    public void setGuardianUnit(String guardianUnit)
+    {
+        this.guardianUnit = guardianUnit;
+    }
+
+    public String getGuardianUnit()
+    {
+        return guardianUnit;
+    }
+    public void setEstimateWorktime(String estimateWorktime)
+    {
+        this.estimateWorktime = estimateWorktime;
+    }
+
+    public String getEstimateWorktime()
+    {
+        return estimateWorktime;
+    }
+    public void setBookingticketId(Long bookingticketId)
+    {
+        this.bookingticketId = bookingticketId;
+    }
+
+    public Long getBookingticketId()
+    {
+        return bookingticketId;
+    }
+    public void setDeptId(Long deptId)
+    {
+        this.deptId = deptId;
+    }
+
+    public Long getDeptId()
+    {
+        return deptId;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
+            .append("id", getId())
+            .append("delFlag", getDelFlag())
+            .append("createrCode", getCreaterCode())
+            .append("createdate", getCreatedate())
+            .append("updaterCode", getUpdaterCode())
+            .append("updatedate", getUpdatedate())
+            .append("workType", getWorkType())
+            .append("riskLevel", getRiskLevel())
+            .append("workDescription", getWorkDescription())
+            .append("workPeopleNumber", getWorkPeopleNumber())
+            .append("guardianUnit", getGuardianUnit())
+            .append("estimateWorktime", getEstimateWorktime())
+            .append("bookingticketId", getBookingticketId())
+            .append("deptId", getDeptId())
+            .toString();
+    }
+}

+ 63 - 0
master/src/main/java/com/ruoyi/project/invoice/mapper/TInvoiceBookingworkticketMapper.java

@@ -0,0 +1,63 @@
+package com.ruoyi.project.invoice.mapper;
+
+import java.util.List;
+import com.ruoyi.framework.aspectj.lang.annotation.DataScope;
+import com.ruoyi.project.invoice.domain.TInvoiceBookingworkticket;
+
+/**
+ * 预约作业票台账Mapper接口
+ * 
+ * @author ruoyi
+ * @date 2022-08-25
+ */
+public interface TInvoiceBookingworkticketMapper 
+{
+    /**
+     * 查询预约作业票台账
+     * 
+     * @param id 预约作业票台账ID
+     * @return 预约作业票台账
+     */
+    public TInvoiceBookingworkticket selectTInvoiceBookingworkticketById(Long id);
+
+    /**
+     * 查询预约作业票台账列表
+     * 
+     * @param tInvoiceBookingworkticket 预约作业票台账
+     * @return 预约作业票台账集合
+     */
+    @DataScope(deptAlias = "d")
+    public List<TInvoiceBookingworkticket> selectTInvoiceBookingworkticketList(TInvoiceBookingworkticket tInvoiceBookingworkticket);
+
+    /**
+     * 新增预约作业票台账
+     * 
+     * @param tInvoiceBookingworkticket 预约作业票台账
+     * @return 结果
+     */
+    public int insertTInvoiceBookingworkticket(TInvoiceBookingworkticket tInvoiceBookingworkticket);
+
+    /**
+     * 修改预约作业票台账
+     * 
+     * @param tInvoiceBookingworkticket 预约作业票台账
+     * @return 结果
+     */
+    public int updateTInvoiceBookingworkticket(TInvoiceBookingworkticket tInvoiceBookingworkticket);
+
+    /**
+     * 删除预约作业票台账
+     * 
+     * @param id 预约作业票台账ID
+     * @return 结果
+     */
+    public int deleteTInvoiceBookingworkticketById(Long id);
+
+    /**
+     * 批量删除预约作业票台账
+     * 
+     * @param ids 需要删除的数据ID
+     * @return 结果
+     */
+    public int deleteTInvoiceBookingworkticketByIds(Long[] ids);
+}

+ 63 - 0
master/src/main/java/com/ruoyi/project/invoice/mapper/TInvoiceWorkcontentMapper.java

@@ -0,0 +1,63 @@
+package com.ruoyi.project.invoice.mapper;
+
+import java.util.List;
+import com.ruoyi.framework.aspectj.lang.annotation.DataScope;
+import com.ruoyi.project.invoice.domain.TInvoiceWorkcontent;
+
+/**
+ * 预约作业内容Mapper接口
+ * 
+ * @author ruoyi
+ * @date 2022-08-26
+ */
+public interface TInvoiceWorkcontentMapper 
+{
+    /**
+     * 查询预约作业内容
+     * 
+     * @param id 预约作业内容ID
+     * @return 预约作业内容
+     */
+    public TInvoiceWorkcontent selectTInvoiceWorkcontentById(Long id);
+
+    /**
+     * 查询预约作业内容列表
+     * 
+     * @param tInvoiceWorkcontent 预约作业内容
+     * @return 预约作业内容集合
+     */
+    @DataScope(deptAlias = "d")
+    public List<TInvoiceWorkcontent> selectTInvoiceWorkcontentList(TInvoiceWorkcontent tInvoiceWorkcontent);
+
+    /**
+     * 新增预约作业内容
+     * 
+     * @param tInvoiceWorkcontent 预约作业内容
+     * @return 结果
+     */
+    public int insertTInvoiceWorkcontent(TInvoiceWorkcontent tInvoiceWorkcontent);
+
+    /**
+     * 修改预约作业内容
+     * 
+     * @param tInvoiceWorkcontent 预约作业内容
+     * @return 结果
+     */
+    public int updateTInvoiceWorkcontent(TInvoiceWorkcontent tInvoiceWorkcontent);
+
+    /**
+     * 删除预约作业内容
+     * 
+     * @param id 预约作业内容ID
+     * @return 结果
+     */
+    public int deleteTInvoiceWorkcontentById(Long id);
+
+    /**
+     * 批量删除预约作业内容
+     * 
+     * @param ids 需要删除的数据ID
+     * @return 结果
+     */
+    public int deleteTInvoiceWorkcontentByIds(Long[] ids);
+}

+ 61 - 0
master/src/main/java/com/ruoyi/project/invoice/service/ITInvoiceBookingworkticketService.java

@@ -0,0 +1,61 @@
+package com.ruoyi.project.invoice.service;
+
+import java.util.List;
+import com.ruoyi.project.invoice.domain.TInvoiceBookingworkticket;
+
+/**
+ * 预约作业票台账Service接口
+ * 
+ * @author ruoyi
+ * @date 2022-08-25
+ */
+public interface ITInvoiceBookingworkticketService 
+{
+    /**
+     * 查询预约作业票台账
+     * 
+     * @param id 预约作业票台账ID
+     * @return 预约作业票台账
+     */
+    public TInvoiceBookingworkticket selectTInvoiceBookingworkticketById(Long id);
+
+    /**
+     * 查询预约作业票台账列表
+     * 
+     * @param tInvoiceBookingworkticket 预约作业票台账
+     * @return 预约作业票台账集合
+     */
+    public List<TInvoiceBookingworkticket> selectTInvoiceBookingworkticketList(TInvoiceBookingworkticket tInvoiceBookingworkticket);
+
+    /**
+     * 新增预约作业票台账
+     * 
+     * @param tInvoiceBookingworkticket 预约作业票台账
+     * @return 结果
+     */
+    public int insertTInvoiceBookingworkticket(TInvoiceBookingworkticket tInvoiceBookingworkticket);
+
+    /**
+     * 修改预约作业票台账
+     * 
+     * @param tInvoiceBookingworkticket 预约作业票台账
+     * @return 结果
+     */
+    public int updateTInvoiceBookingworkticket(TInvoiceBookingworkticket tInvoiceBookingworkticket);
+
+    /**
+     * 批量删除预约作业票台账
+     * 
+     * @param ids 需要删除的预约作业票台账ID
+     * @return 结果
+     */
+    public int deleteTInvoiceBookingworkticketByIds(Long[] ids);
+
+    /**
+     * 删除预约作业票台账信息
+     * 
+     * @param id 预约作业票台账ID
+     * @return 结果
+     */
+    public int deleteTInvoiceBookingworkticketById(Long id);
+}

+ 61 - 0
master/src/main/java/com/ruoyi/project/invoice/service/ITInvoiceWorkcontentService.java

@@ -0,0 +1,61 @@
+package com.ruoyi.project.invoice.service;
+
+import java.util.List;
+import com.ruoyi.project.invoice.domain.TInvoiceWorkcontent;
+
+/**
+ * 预约作业内容Service接口
+ * 
+ * @author ruoyi
+ * @date 2022-08-26
+ */
+public interface ITInvoiceWorkcontentService 
+{
+    /**
+     * 查询预约作业内容
+     * 
+     * @param id 预约作业内容ID
+     * @return 预约作业内容
+     */
+    public TInvoiceWorkcontent selectTInvoiceWorkcontentById(Long id);
+
+    /**
+     * 查询预约作业内容列表
+     * 
+     * @param tInvoiceWorkcontent 预约作业内容
+     * @return 预约作业内容集合
+     */
+    public List<TInvoiceWorkcontent> selectTInvoiceWorkcontentList(TInvoiceWorkcontent tInvoiceWorkcontent);
+
+    /**
+     * 新增预约作业内容
+     * 
+     * @param tInvoiceWorkcontent 预约作业内容
+     * @return 结果
+     */
+    public int insertTInvoiceWorkcontent(TInvoiceWorkcontent tInvoiceWorkcontent);
+
+    /**
+     * 修改预约作业内容
+     * 
+     * @param tInvoiceWorkcontent 预约作业内容
+     * @return 结果
+     */
+    public int updateTInvoiceWorkcontent(TInvoiceWorkcontent tInvoiceWorkcontent);
+
+    /**
+     * 批量删除预约作业内容
+     * 
+     * @param ids 需要删除的预约作业内容ID
+     * @return 结果
+     */
+    public int deleteTInvoiceWorkcontentByIds(Long[] ids);
+
+    /**
+     * 删除预约作业内容信息
+     * 
+     * @param id 预约作业内容ID
+     * @return 结果
+     */
+    public int deleteTInvoiceWorkcontentById(Long id);
+}

+ 93 - 0
master/src/main/java/com/ruoyi/project/invoice/service/impl/TInvoiceBookingworkticketServiceImpl.java

@@ -0,0 +1,93 @@
+package com.ruoyi.project.invoice.service.impl;
+
+import java.util.List;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.ruoyi.project.invoice.mapper.TInvoiceBookingworkticketMapper;
+import com.ruoyi.project.invoice.domain.TInvoiceBookingworkticket;
+import com.ruoyi.project.invoice.service.ITInvoiceBookingworkticketService;
+
+/**
+ * 预约作业票台账Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2022-08-25
+ */
+@Service
+public class TInvoiceBookingworkticketServiceImpl implements ITInvoiceBookingworkticketService
+{
+    @Autowired
+    private TInvoiceBookingworkticketMapper tInvoiceBookingworkticketMapper;
+
+    /**
+     * 查询预约作业票台账
+     *
+     * @param id 预约作业票台账ID
+     * @return 预约作业票台账
+     */
+    @Override
+    public TInvoiceBookingworkticket selectTInvoiceBookingworkticketById(Long id)
+    {
+        return tInvoiceBookingworkticketMapper.selectTInvoiceBookingworkticketById(id);
+    }
+
+    /**
+     * 查询预约作业票台账列表
+     *
+     * @param tInvoiceBookingworkticket 预约作业票台账
+     * @return 预约作业票台账
+     */
+    @Override
+    public List<TInvoiceBookingworkticket> selectTInvoiceBookingworkticketList(TInvoiceBookingworkticket tInvoiceBookingworkticket)
+    {
+        return tInvoiceBookingworkticketMapper.selectTInvoiceBookingworkticketList(tInvoiceBookingworkticket);
+    }
+
+    /**
+     * 新增预约作业票台账
+     *
+     * @param tInvoiceBookingworkticket 预约作业票台账
+     * @return 结果
+     */
+    @Override
+    public int insertTInvoiceBookingworkticket(TInvoiceBookingworkticket tInvoiceBookingworkticket)
+    {
+        return tInvoiceBookingworkticketMapper.insertTInvoiceBookingworkticket(tInvoiceBookingworkticket);
+    }
+
+    /**
+     * 修改预约作业票台账
+     *
+     * @param tInvoiceBookingworkticket 预约作业票台账
+     * @return 结果
+     */
+    @Override
+    public int updateTInvoiceBookingworkticket(TInvoiceBookingworkticket tInvoiceBookingworkticket)
+    {
+        return tInvoiceBookingworkticketMapper.updateTInvoiceBookingworkticket(tInvoiceBookingworkticket);
+    }
+
+    /**
+     * 批量删除预约作业票台账
+     *
+     * @param ids 需要删除的预约作业票台账ID
+     * @return 结果
+     */
+    @Override
+    public int deleteTInvoiceBookingworkticketByIds(Long[] ids)
+    {
+        return tInvoiceBookingworkticketMapper.deleteTInvoiceBookingworkticketByIds(ids);
+    }
+
+    /**
+     * 删除预约作业票台账信息
+     *
+     * @param id 预约作业票台账ID
+     * @return 结果
+     */
+    @Override
+    public int deleteTInvoiceBookingworkticketById(Long id)
+    {
+        return tInvoiceBookingworkticketMapper.deleteTInvoiceBookingworkticketById(id);
+    }
+}

+ 93 - 0
master/src/main/java/com/ruoyi/project/invoice/service/impl/TInvoiceWorkcontentServiceImpl.java

@@ -0,0 +1,93 @@
+package com.ruoyi.project.invoice.service.impl;
+
+import java.util.List;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.ruoyi.project.invoice.mapper.TInvoiceWorkcontentMapper;
+import com.ruoyi.project.invoice.domain.TInvoiceWorkcontent;
+import com.ruoyi.project.invoice.service.ITInvoiceWorkcontentService;
+
+/**
+ * 预约作业内容Service业务层处理
+ *
+ * @author ruoyi
+ * @date 2022-08-26
+ */
+@Service
+public class TInvoiceWorkcontentServiceImpl implements ITInvoiceWorkcontentService
+{
+    @Autowired
+    private TInvoiceWorkcontentMapper tInvoiceWorkcontentMapper;
+
+    /**
+     * 查询预约作业内容
+     *
+     * @param id 预约作业内容ID
+     * @return 预约作业内容
+     */
+    @Override
+    public TInvoiceWorkcontent selectTInvoiceWorkcontentById(Long id)
+    {
+        return tInvoiceWorkcontentMapper.selectTInvoiceWorkcontentById(id);
+    }
+
+    /**
+     * 查询预约作业内容列表
+     *
+     * @param tInvoiceWorkcontent 预约作业内容
+     * @return 预约作业内容
+     */
+    @Override
+    public List<TInvoiceWorkcontent> selectTInvoiceWorkcontentList(TInvoiceWorkcontent tInvoiceWorkcontent)
+    {
+        return tInvoiceWorkcontentMapper.selectTInvoiceWorkcontentList(tInvoiceWorkcontent);
+    }
+
+    /**
+     * 新增预约作业内容
+     *
+     * @param tInvoiceWorkcontent 预约作业内容
+     * @return 结果
+     */
+    @Override
+    public int insertTInvoiceWorkcontent(TInvoiceWorkcontent tInvoiceWorkcontent)
+    {
+        return tInvoiceWorkcontentMapper.insertTInvoiceWorkcontent(tInvoiceWorkcontent);
+    }
+
+    /**
+     * 修改预约作业内容
+     *
+     * @param tInvoiceWorkcontent 预约作业内容
+     * @return 结果
+     */
+    @Override
+    public int updateTInvoiceWorkcontent(TInvoiceWorkcontent tInvoiceWorkcontent)
+    {
+        return tInvoiceWorkcontentMapper.updateTInvoiceWorkcontent(tInvoiceWorkcontent);
+    }
+
+    /**
+     * 批量删除预约作业内容
+     *
+     * @param ids 需要删除的预约作业内容ID
+     * @return 结果
+     */
+    @Override
+    public int deleteTInvoiceWorkcontentByIds(Long[] ids)
+    {
+        return tInvoiceWorkcontentMapper.deleteTInvoiceWorkcontentByIds(ids);
+    }
+
+    /**
+     * 删除预约作业内容信息
+     *
+     * @param id 预约作业内容ID
+     * @return 结果
+     */
+    @Override
+    public int deleteTInvoiceWorkcontentById(Long id)
+    {
+        return tInvoiceWorkcontentMapper.deleteTInvoiceWorkcontentById(id);
+    }
+}

+ 147 - 0
master/src/main/resources/mybatis/invoice/TInvoiceBookingworkticketMapper.xml

@@ -0,0 +1,147 @@
+<?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.project.invoice.mapper.TInvoiceBookingworkticketMapper">
+    
+    <resultMap type="TInvoiceBookingworkticket" id="TInvoiceBookingworkticketResult">
+        <result property="id"    column="id"    />
+        <result property="workUnit"    column="work_unit"    />
+        <result property="workArea"    column="work_area"    />
+        <result property="unitNumber"    column="unit_number"    />
+        <result property="floorLocation"    column="floor_location"    />
+        <result property="workStartTime"    column="work_start_time"    />
+        <result property="workEndTime"    column="work_end_time"    />
+        <result property="delFlag"    column="del_flag"    />
+        <result property="createrCode"    column="creater_code"    />
+        <result property="createdate"    column="createdate"    />
+        <result property="updaterCode"    column="updater_code"    />
+        <result property="updatedate"    column="updatedate"    />
+        <result property="contact"    column="contact"    />
+        <result property="phonenumber"    column="phonenumber"    />
+        <result property="status"    column="status"    />
+        <result property="deptId"    column="dept_id"    />
+        <result property="userMg"    column="user_mg"    />
+        <result property="deptName" column="dept_name" />
+        <result property="userUnit"    column="user_unit"    />
+    </resultMap>
+
+    <sql id="selectTInvoiceBookingworkticketVo">
+        select d.id, d.work_unit, d.work_area, d.unit_number, d.floor_location, d.work_start_time, d.work_end_time, d.del_flag, d.creater_code, d.createdate, d.updater_code, d.updatedate, d.contact, d.phonenumber, d.status, d.dept_id, d.user_mg ,s.dept_name from t_invoice_bookingworkticket d
+      left join sys_dept s on s.dept_id = d.dept_id
+    </sql>
+
+    <select id="selectTInvoiceBookingworkticketList" parameterType="TInvoiceBookingworkticket" resultMap="TInvoiceBookingworkticketResult">
+        <include refid="selectTInvoiceBookingworkticketVo"/>
+        <where>  
+            <if test="workUnit != null "> and work_unit = #{workUnit}</if>
+            <if test="workArea != null "> and work_area = #{workArea}</if>
+            <if test="unitNumber != null "> and unit_number = #{unitNumber}</if>
+            <if test="floorLocation != null "> and floor_location = #{floorLocation}</if>
+            <if test="workStartTime != null "> and work_start_time = #{workStartTime}</if>
+            <if test="workEndTime != null "> and work_end_time = #{workEndTime}</if>
+            <if test="createrCode != null "> and creater_code = #{createrCode}</if>
+            <if test="createdate != null "> and createdate = #{createdate}</if>
+            <if test="updaterCode != null "> and updater_code = #{updaterCode}</if>
+            <if test="updatedate != null "> and updatedate = #{updatedate}</if>
+            <if test="contact != null  and contact != ''"> and contact = #{contact}</if>
+            <if test="phonenumber != null  and phonenumber != ''"> and phonenumber = #{phonenumber}</if>
+            <if test="status != null "> and status = #{status}</if>
+            <if test="deptId != null "> and dept_id = #{deptId}</if>
+            <if test="userMg != null "> and user_mg = #{userMg}</if>
+            <if test="userUnit != null "> and user_unit = #{userUnit}</if>
+            and d.del_flag = 0
+        </where>
+        <!-- 数据范围过滤 -->
+        ${params.dataScope}
+    </select>
+    
+    <select id="selectTInvoiceBookingworkticketById" parameterType="Long" resultMap="TInvoiceBookingworkticketResult">
+        <include refid="selectTInvoiceBookingworkticketVo"/>
+        where id = #{id}
+    </select>
+        
+    <insert id="insertTInvoiceBookingworkticket" parameterType="TInvoiceBookingworkticket" useGeneratedKeys = "true" keyProperty = "id">
+        <selectKey keyProperty="id" resultType="long" order="BEFORE">
+            SELECT t_bookingworkticket_seq.NEXTVAL as id FROM DUAL
+        </selectKey>
+        insert into t_invoice_bookingworkticket
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="workUnit != null">work_unit,</if>
+            <if test="workArea != null">work_area,</if>
+            <if test="unitNumber != null">unit_number,</if>
+            <if test="floorLocation != null">floor_location,</if>
+            <if test="workStartTime != null">work_start_time,</if>
+            <if test="workEndTime != null">work_end_time,</if>
+            <if test="delFlag != null">del_flag,</if>
+            <if test="createrCode != null">creater_code,</if>
+            <if test="createdate != null">createdate,</if>
+            <if test="updaterCode != null">updater_code,</if>
+            <if test="updatedate != null">updatedate,</if>
+            <if test="contact != null">contact,</if>
+            <if test="phonenumber != null">phonenumber,</if>
+            <if test="status != null">status,</if>
+            <if test="deptId != null">dept_id,</if>
+            <if test="userMg != null">user_mg,</if>
+            <if test="userUnit != null">user_unit,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="workUnit != null">#{workUnit},</if>
+            <if test="workArea != null">#{workArea},</if>
+            <if test="unitNumber != null">#{unitNumber},</if>
+            <if test="floorLocation != null">#{floorLocation},</if>
+            <if test="workStartTime != null">#{workStartTime},</if>
+            <if test="workEndTime != null">#{workEndTime},</if>
+            <if test="delFlag != null">#{delFlag},</if>
+            <if test="createrCode != null">#{createrCode},</if>
+            <if test="createdate != null">#{createdate},</if>
+            <if test="updaterCode != null">#{updaterCode},</if>
+            <if test="updatedate != null">#{updatedate},</if>
+            <if test="contact != null">#{contact},</if>
+            <if test="phonenumber != null">#{phonenumber},</if>
+            <if test="status != null">#{status},</if>
+            <if test="deptId != null">#{deptId},</if>
+            <if test="userMg != null">#{userMg},</if>
+            <if test="userUnit != null">#{userUnit},</if>
+         </trim>
+    </insert>
+
+    <update id="updateTInvoiceBookingworkticket" parameterType="TInvoiceBookingworkticket">
+        update t_invoice_bookingworkticket
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="workUnit != null">work_unit = #{workUnit},</if>
+            <if test="workArea != null">work_area = #{workArea},</if>
+            <if test="unitNumber != null">unit_number = #{unitNumber},</if>
+            <if test="floorLocation != null">floor_location = #{floorLocation},</if>
+            <if test="workStartTime != null">work_start_time = #{workStartTime},</if>
+            <if test="workEndTime != null">work_end_time = #{workEndTime},</if>
+            <if test="delFlag != null">del_flag = #{delFlag},</if>
+            <if test="createrCode != null">creater_code = #{createrCode},</if>
+            <if test="createdate != null">createdate = #{createdate},</if>
+            <if test="updaterCode != null">updater_code = #{updaterCode},</if>
+            <if test="updatedate != null">updatedate = #{updatedate},</if>
+            <if test="contact != null">contact = #{contact},</if>
+            <if test="phonenumber != null">phonenumber = #{phonenumber},</if>
+            <if test="status != null">status = #{status},</if>
+            <if test="deptId != null">dept_id = #{deptId},</if>
+            <if test="userMg != null">user_mg = #{userMg},</if>
+            <if test="userUnit != null">user_unit = #{userUnit},</if>
+
+        </trim>
+        where id = #{id}
+    </update>
+
+    <update id="deleteTInvoiceBookingworkticketById" parameterType="Long">
+        update t_invoice_bookingworkticket set del_flag = 2 where id = #{id}
+    </update>
+
+    <update id="deleteTInvoiceBookingworkticketByIds" parameterType="String">
+        update t_invoice_bookingworkticket set del_flag = 2 where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </update>
+    
+</mapper>

+ 127 - 0
master/src/main/resources/mybatis/invoice/TInvoiceWorkcontentMapper.xml

@@ -0,0 +1,127 @@
+<?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.project.invoice.mapper.TInvoiceWorkcontentMapper">
+    
+    <resultMap type="TInvoiceWorkcontent" id="TInvoiceWorkcontentResult">
+        <result property="id"    column="id"    />
+        <result property="delFlag"    column="del_flag"    />
+        <result property="createrCode"    column="creater_code"    />
+        <result property="createdate"    column="createdate"    />
+        <result property="updaterCode"    column="updater_code"    />
+        <result property="updatedate"    column="updatedate"    />
+        <result property="workType"    column="work_type"    />
+        <result property="riskLevel"    column="risk_level"    />
+        <result property="workDescription"    column="work_description"    />
+        <result property="workPeopleNumber"    column="work_people_number"    />
+        <result property="guardianUnit"    column="guardian_unit"    />
+        <result property="estimateWorktime"    column="estimate_worktime"    />
+        <result property="bookingticketId"    column="bookingticket_id"    />
+        <result property="deptId"    column="dept_id"    />
+        <result property="deptName" column="dept_name" />
+    </resultMap>
+
+    <sql id="selectTInvoiceWorkcontentVo">
+        select d.id, d.del_flag, d.creater_code, d.createdate, d.updater_code, d.updatedate, d.work_type, d.risk_level, d.work_description, d.work_people_number, d.guardian_unit, d.estimate_worktime, d.bookingticket_id, d.dept_id ,s.dept_name from t_invoice_workcontent d
+      left join sys_dept s on s.dept_id = d.dept_id
+    </sql>
+
+    <select id="selectTInvoiceWorkcontentList" parameterType="TInvoiceWorkcontent" resultMap="TInvoiceWorkcontentResult">
+        <include refid="selectTInvoiceWorkcontentVo"/>
+        <where>  
+            <if test="createrCode != null "> and creater_code = #{createrCode}</if>
+            <if test="createdate != null "> and createdate = #{createdate}</if>
+            <if test="updaterCode != null "> and updater_code = #{updaterCode}</if>
+            <if test="updatedate != null "> and updatedate = #{updatedate}</if>
+            <if test="workType != null "> and work_type = #{workType}</if>
+            <if test="riskLevel != null "> and risk_level = #{riskLevel}</if>
+            <if test="workDescription != null  and workDescription != ''"> and work_description = #{workDescription}</if>
+            <if test="workPeopleNumber != null "> and work_people_number = #{workPeopleNumber}</if>
+            <if test="guardianUnit != null  and guardianUnit != ''"> and guardian_unit = #{guardianUnit}</if>
+            <if test="estimateWorktime != null  and estimateWorktime != ''"> and estimate_worktime = #{estimateWorktime}</if>
+            <if test="bookingticketId != null "> and bookingticket_id = #{bookingticketId}</if>
+            <if test="deptId != null "> and dept_id = #{deptId}</if>
+            and d.del_flag = 0
+        </where>
+        <!-- 数据范围过滤 -->
+        ${params.dataScope}
+    </select>
+    
+    <select id="selectTInvoiceWorkcontentById" parameterType="Long" resultMap="TInvoiceWorkcontentResult">
+        <include refid="selectTInvoiceWorkcontentVo"/>
+        where id = #{id}
+    </select>
+        
+    <insert id="insertTInvoiceWorkcontent" parameterType="TInvoiceWorkcontent">
+        <selectKey keyProperty="id" resultType="long" order="BEFORE">
+            SELECT T_INVOICE_WORKCONTENT_SEQ.NEXTVAL as id FROM DUAL
+        </selectKey>
+        insert into t_invoice_workcontent
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="id != null">id,</if>
+            <if test="delFlag != null">del_flag,</if>
+            <if test="createrCode != null">creater_code,</if>
+            <if test="createdate != null">createdate,</if>
+            <if test="updaterCode != null">updater_code,</if>
+            <if test="updatedate != null">updatedate,</if>
+            <if test="workType != null">work_type,</if>
+            <if test="riskLevel != null">risk_level,</if>
+            <if test="workDescription != null">work_description,</if>
+            <if test="workPeopleNumber != null">work_people_number,</if>
+            <if test="guardianUnit != null">guardian_unit,</if>
+            <if test="estimateWorktime != null">estimate_worktime,</if>
+            <if test="bookingticketId != null">bookingticket_id,</if>
+            <if test="deptId != null">dept_id,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="id != null">#{id},</if>
+            <if test="delFlag != null">#{delFlag},</if>
+            <if test="createrCode != null">#{createrCode},</if>
+            <if test="createdate != null">#{createdate},</if>
+            <if test="updaterCode != null">#{updaterCode},</if>
+            <if test="updatedate != null">#{updatedate},</if>
+            <if test="workType != null">#{workType},</if>
+            <if test="riskLevel != null">#{riskLevel},</if>
+            <if test="workDescription != null">#{workDescription},</if>
+            <if test="workPeopleNumber != null">#{workPeopleNumber},</if>
+            <if test="guardianUnit != null">#{guardianUnit},</if>
+            <if test="estimateWorktime != null">#{estimateWorktime},</if>
+            <if test="bookingticketId != null">#{bookingticketId},</if>
+            <if test="deptId != null">#{deptId},</if>
+         </trim>
+    </insert>
+
+
+    <update id="updateTInvoiceWorkcontent" parameterType="TInvoiceWorkcontent">
+        update t_invoice_workcontent
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="delFlag != null">del_flag = #{delFlag},</if>
+            <if test="createrCode != null">creater_code = #{createrCode},</if>
+            <if test="createdate != null">createdate = #{createdate},</if>
+            <if test="updaterCode != null">updater_code = #{updaterCode},</if>
+            <if test="updatedate != null">updatedate = #{updatedate},</if>
+            <if test="workType != null">work_type = #{workType},</if>
+            <if test="riskLevel != null">risk_level = #{riskLevel},</if>
+            <if test="workDescription != null">work_description = #{workDescription},</if>
+            <if test="workPeopleNumber != null">work_people_number = #{workPeopleNumber},</if>
+            <if test="guardianUnit != null">guardian_unit = #{guardianUnit},</if>
+            <if test="estimateWorktime != null">estimate_worktime = #{estimateWorktime},</if>
+            <if test="bookingticketId != null">bookingticket_id = #{bookingticketId},</if>
+            <if test="deptId != null">dept_id = #{deptId},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <update id="deleteTInvoiceWorkcontentById" parameterType="Long">
+        update t_invoice_workcontent set del_flag = 2 where id = #{id}
+    </update>
+
+    <update id="deleteTInvoiceWorkcontentByIds" parameterType="String">
+        update t_invoice_workcontent set del_flag = 2 where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </update>
+    
+</mapper>

+ 53 - 0
ui/src/api/invoice/bookingworkticket.js

@@ -0,0 +1,53 @@
+import request from '@/utils/request'
+
+// 查询预约作业票台账列表
+export function listBookingworkticket(query) {
+  return request({
+    url: '/invoice/bookingworkticket/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询预约作业票台账详细
+export function getBookingworkticket(id) {
+  return request({
+    url: '/invoice/bookingworkticket/' + id,
+    method: 'get'
+  })
+}
+
+// 新增预约作业票台账
+export function addBookingworkticket(data) {
+  return request({
+    url: '/invoice/bookingworkticket',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改预约作业票台账
+export function updateBookingworkticket(data) {
+  return request({
+    url: '/invoice/bookingworkticket',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除预约作业票台账
+export function delBookingworkticket(id) {
+  return request({
+    url: '/invoice/bookingworkticket/' + id,
+    method: 'delete'
+  })
+}
+
+// 导出预约作业票台账
+export function exportBookingworkticket(query) {
+  return request({
+    url: '/invoice/bookingworkticket/export',
+    method: 'get',
+    params: query
+  })
+}

+ 53 - 0
ui/src/api/invoice/workcontent.js

@@ -0,0 +1,53 @@
+import request from '@/utils/request'
+
+// 查询预约作业内容列表
+export function listWorkcontent(query) {
+  return request({
+    url: '/invoice/workcontent/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询预约作业内容详细
+export function getWorkcontent(id) {
+  return request({
+    url: '/invoice/workcontent/' + id,
+    method: 'get'
+  })
+}
+
+// 新增预约作业内容
+export function addWorkcontent(data) {
+  return request({
+    url: '/invoice/workcontent',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改预约作业内容
+export function updateWorkcontent(data) {
+  return request({
+    url: '/invoice/workcontent',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除预约作业内容
+export function delWorkcontent(id) {
+  return request({
+    url: '/invoice/workcontent/' + id,
+    method: 'delete'
+  })
+}
+
+// 导出预约作业内容
+export function exportWorkcontent(query) {
+  return request({
+    url: '/invoice/workcontent/export',
+    method: 'get',
+    params: query
+  })
+}

+ 788 - 0
ui/src/views/invoice/bookingworkticket/index.vue

@@ -0,0 +1,788 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="作业单位" prop="workUnit">
+        <el-select v-model="queryParams.workUnit" placeholder="请选择作业单位" clearable size="small">
+             <el-option
+              v-for="dict in workUnitOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+             ></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label="作业区域" prop="workArea">
+        <el-select v-model="queryParams.workArea" placeholder="请选择作业区域" clearable size="small">
+             <el-option
+            v-for="dict in workAreaOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+                 ></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label="单元号" prop="unitNumber">
+        <el-select v-model="queryParams.unitNumber" placeholder="请选择单元号" clearable size="small">
+          <el-option
+             v-for="dict in unitNumberOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+                   ></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label="楼层位置" prop="floorLocation">
+        <el-select v-model="queryParams.floorLocation" placeholder="请选择楼层位置" clearable size="small">
+            <el-option
+            v-for="dict in floorLocationOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+                ></el-option>
+        </el-select>
+      </el-form-item>
+      <el-form-item label=" 作业开始时间" prop="workStartTime">
+        <el-date-picker clearable size="small" style="width: 200px"
+          v-model="queryParams.workStartTime"
+          type="date"
+          value-format="yyyy-MM-dd"
+          placeholder="选择 作业开始时间">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="作业结束时间" prop="workEndTime">
+        <el-date-picker clearable size="small" style="width: 200px"
+          v-model="queryParams.workEndTime"
+          type="date"
+          value-format="yyyy-MM-dd"
+          placeholder="选择作业结束时间">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="联系人" prop="contact">
+        <el-input
+          v-model="queryParams.contact"
+          placeholder="请输入联系人"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="联系方式" prop="phonenumber">
+        <el-input
+          v-model="queryParams.phonenumber"
+          placeholder="请输入联系方式"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item>
+        <el-button type="cyan" 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"
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['invoice:bookingworkticket:add']"
+        >新增</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['invoice:bookingworkticket:edit']"
+        >修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+        v-if=""
+          type="danger"
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['invoice:bookingworkticket:remove']"
+        >删除</el-button>
+      </el-col>
+        <el-col :span="1.5">
+            <el-button
+                    type="info"
+                    icon="el-icon-upload2"
+                    size="mini"
+                    @click="handleImport"
+                    v-hasPermi="['invoice:bookingworkticket:edit']"
+            >导入</el-button>
+        </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['invoice:bookingworkticket:export']"
+        >导出</el-button>
+      </el-col>
+	  <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="bookingworkticketList" @selection-change="handleSelectionChange" :height="clientHeight" border>
+      <el-table-column type="selection" width="55" align="center" />
+      <el-table-column label="作业单位" align="center" prop="workUnit" :formatter="workUnitFormat"/>
+      <el-table-column label="作业区域" align="center" prop="workArea" :formatter="workAreaFormat"/>
+      <el-table-column label="单元号" align="center" prop="unitNumber" :formatter="unitNumberFormat"/>
+      <el-table-column label="楼层位置" align="center" prop="floorLocation" :formatter="floorLocationFormat"/>
+      <el-table-column label=" 作业开始时间" align="center" prop="workStartTime" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.workStartTime, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="作业结束时间" align="center" prop="workEndTime" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.workEndTime, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="联系人" align="center" prop="contact" :show-overflow-tooltip="true"/>
+      <el-table-column label="联系方式" align="center" prop="phonenumber" :show-overflow-tooltip="true"/>
+      <el-table-column label="状态" align="center" prop="status" width="100" :formatter="statusFormat" />
+      <el-table-column label="操作" align="center" fixed="right" width="200" 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="['invoice:bookingworkticket:edit']"
+          >修改</el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="signature(scope.row)"
+            v-hasPermi="['invoice:bookingworkticket:remove']"
+          >签字</el-button>
+           <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="association(scope.row)"
+            v-hasPermi="['invoice:bookingworkticket:remove']"
+          >关联票号</el-button>
+           <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="billSee(scope.row)"
+            v-hasPermi="['invoice:bookingworkticket: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="600px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+       <el-row>
+        <el-col :span="12">
+            <el-form-item label="承包商" prop="workUnit">
+          <el-select v-model="form.workUnit" placeholder="请选择作业单位">
+            <el-option
+              v-for="dict in workUnitOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+             ></el-option>
+          </el-select>
+        </el-form-item>
+          </el-col>
+        <el-col :span="12">
+        <el-form-item label="作业区域" prop="workArea">
+          <el-select v-model="form.workArea" placeholder="请选择作业区域">
+             <el-option
+            v-for="dict in workAreaOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+                 ></el-option>
+          </el-select>
+        </el-form-item>
+        </el-col>
+      </el-row>
+       <el-row>
+        <el-col :span="12">
+        <el-form-item label="单元号" prop="unitNumber">
+          <el-select v-model="form.unitNumber" placeholder="请选择单元号">
+            <el-option
+             v-for="dict in unitNumberOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+                   ></el-option>
+          </el-select>
+        </el-form-item>
+          </el-col>
+        <el-col :span="12">
+        <el-form-item label="楼层位置" prop="floorLocation">
+          <el-select v-model="form.floorLocation" placeholder="请选择楼层位置">
+             <el-option
+            v-for="dict in floorLocationOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+                ></el-option>
+          </el-select>
+        </el-form-item>
+           </el-col>
+      </el-row>
+         <el-row>
+        <el-col :span="12">
+        <el-form-item label=" 作业开始" prop="workStartTime">
+          <el-date-picker clearable size="small" style="width: 190px"
+            v-model="form.workStartTime"
+            type="date"
+            value-format="yyyy-MM-dd"
+            placeholder="选择 作业开始时间">
+          </el-date-picker>
+        </el-form-item>
+        </el-col>
+        <el-col :span="12">
+        <el-form-item label="作业结束" prop="workEndTime">
+          <el-date-picker clearable size="small" style="width: 190px"
+            v-model="form.workEndTime"
+            type="date"
+            value-format="yyyy-MM-dd"
+            placeholder="选择作业结束时间">
+          </el-date-picker>
+        </el-form-item>
+         </el-col>
+      </el-row>
+        <el-row>
+        <el-col :span="12">
+  <el-form-item label="用户单位" prop="userUnit">
+          <el-select v-model="form.userUnit" placeholder="请选择用户单位">
+             <el-option
+            v-for="dict in userUnitOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+             ></el-option>
+          </el-select>
+        </el-form-item>
+          </el-col>
+        <el-col :span="12">
+        <el-form-item label="用户主管" prop="userMg">
+          <el-select v-model="form.userMg" placeholder="请选择用户单位">
+             <el-option
+              v-for="dict in userMgOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+            ></el-option>
+          </el-select>
+        </el-form-item>
+            </el-col>
+      </el-row>
+      </el-form>
+        
+            <el-form v-for="(ruleForm, index) in ruleForm" :key="index" :model="ruleForm" :rules="rules" ref="ruleForm" label-width="100px" class="demo-ruleForm">
+   <el-divider content-position="left" >新增一条作业内容</el-divider>
+          <el-form-item label="作业内容描述" prop="workDescription">
+            <el-input v-model="ruleForm.workDescription"></el-input>
+          </el-form-item> 
+               <el-row>
+        <el-col :span="12">
+              <el-form-item label="作业类型" prop="workType">
+        <el-select v-model="ruleForm.workType" placeholder="请选择作业类型" clearable size="small">
+          <el-option
+            v-for="dict in workTypeOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+          />
+        </el-select>
+      </el-form-item>
+        </el-col>
+        <el-col :span="12">
+          <el-form-item label="风险等级" prop="riskLevel">
+        <el-select v-model="ruleForm.riskLevel" placeholder="请选择风险等级" clearable size="small">
+          <el-option
+            v-for="dict in riskLevelOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+          />
+        </el-select>
+      </el-form-item>
+       </el-col>
+      </el-row>
+            <el-row>
+        <el-col :span="12">
+          <el-form-item label="作业人数" prop="workPeopleNumber">
+            <el-input v-model="ruleForm.workPeopleNumber"></el-input>
+          </el-form-item>
+            </el-col>
+        <el-col :span="12">
+              <el-form-item label="监护人单位" prop="guardianUnit">
+        <el-select v-model="ruleForm.guardianUnit" placeholder="请选择监护人单位" clearable size="small">
+          <el-option
+            v-for="dict in guardianUnitOptions"
+            :key="dict.dictValue"
+            :label="dict.dictLabel"
+            :value="parseInt(dict.dictValue)"
+          />
+        </el-select>
+      </el-form-item>
+       </el-col>
+      </el-row>
+      <el-form-item label="预计作业时间" prop="estimateWorktime">
+        <el-input v-model="ruleForm.estimateWorktime"  style="width: 190px"></el-input>
+      </el-form-item>
+        </el-form>
+        
+        <el-button @click="resetForm1()">重置</el-button>
+        <el-button @click="add">+</el-button>
+        <el-button @click="reduce" :disabled="flag">-</el-button>
+
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+      <!-- 用户导入对话框 -->
+      <el-dialog :title="upload.title" :visible.sync="upload.open" width="400px" append-to-body>
+          <el-upload
+                  ref="upload"
+                  :limit="1"
+                  accept=".xlsx, .xls"
+                  :headers="upload.headers"
+                  :action="upload.url + '?updateSupport=' + upload.updateSupport"
+                  :disabled="upload.isUploading"
+                  :on-progress="handleFileUploadProgress"
+                  :on-success="handleFileSuccess"
+                  :auto-upload="false"
+                  drag
+          >
+              <i class="el-icon-upload"></i>
+              <div class="el-upload__text">
+                  将文件拖到此处,或
+                  <em>点击上传</em>
+              </div>
+              <div class="el-upload__tip" slot="tip">
+                  <el-checkbox v-model="upload.updateSupport" />是否更新已经存在的用户数据
+                  <el-link type="info" style="font-size:12px" @click="importTemplate">下载模板</el-link>
+              </div>
+              <div class="el-upload__tip" style="color:red" slot="tip">提示:仅允许导入“xls”或“xlsx”格式文件!</div>
+          </el-upload>
+          <div slot="footer" class="dialog-footer">
+              <el-button type="primary" @click="submitFileForm">确 定</el-button>
+              <el-button @click="upload.open = false">取 消</el-button>
+          </div>
+      </el-dialog>
+  </div>
+</template>
+
+<script>
+import { listBookingworkticket, getBookingworkticket, delBookingworkticket, addBookingworkticket, updateBookingworkticket, exportBookingworkticket, importTemplate} from "@/api/invoice/bookingworkticket";
+import { listWorkcontent, getWorkcontent, delWorkcontent, addWorkcontent, updateWorkcontent, exportWorkcontent} from "@/api/invoice/workcontent";
+import { treeselect } from "@/api/system/dept";
+import { getToken } from "@/utils/auth";
+import Treeselect from "@riophae/vue-treeselect";
+import "@riophae/vue-treeselect/dist/vue-treeselect.css";
+
+export default {
+  name: "Bookingworkticket",
+  components: { Treeselect },
+  data() {
+    return {
+      //bookticked关联ID
+      btid:"",
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: false,
+      // 总条数
+      total: 0,
+      // 预约作业票台账表格数据
+      bookingworkticketList: [],
+      // 弹出层标题
+      title: "",
+      // 部门树选项
+      deptOptions: undefined,
+      clientHeight:300,
+        // 状态字典
+      statusOptions: [],
+      // 作业单位字典
+      workUnitOptions: [],
+      // 作业区域字典
+      workAreaOptions: [],
+      // 单元号字典
+      unitNumberOptions: [],
+      // 楼层字典
+      floorLocationOptions: [],
+       // 用户单位字典
+      userUnitOptions: [],
+       // 用户主管字典
+      userMgOptions: [],
+        // 作业类型字典
+      workTypeOptions: [],
+        // 风险等级字典
+      riskLevelOptions: [],
+        // 监护人单位字典
+      guardianUnitOptions: [],
+     
+      // 是否显示弹出层
+      open: false,
+        // 用户导入参数
+        upload: {
+            // 是否显示弹出层(用户导入)
+            open: false,
+            // 弹出层标题(用户导入)
+            title: "",
+            // 是否禁用上传
+            isUploading: false,
+            // 是否更新已经存在的用户数据
+            updateSupport: 0,
+            // 设置上传的请求头部
+            headers: { Authorization: "Bearer " + getToken() },
+            // 上传的地址
+            url: process.env.VUE_APP_BASE_API + "/invoice/bookingworkticket/importData"
+        },
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 20,
+        workUnit: null,
+        workArea: null,
+        unitNumber: null,
+        floorLocation: null,
+        workStartTime: null,
+        workEndTime: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        contact: null,
+        phonenumber: null,
+        status: null,
+        deptId: null,
+        userMg: null,
+         userUnit: null
+      },
+      // 表单参数
+      form: {  },
+       ruleForm: [{} ],
+         flag: true,
+      // 表单校验
+      rules: {
+        workUnit: [
+          { required: true, message: "作业单位不能为空", trigger: "blur" }
+        ],
+         riskLevel: [
+          { required: true, message: "风险等级不能为空", trigger: "blur" }
+        ],
+      }
+    };
+  },
+  watch: {
+        // 根据名称筛选部门树
+        deptName(val) {
+            this.$refs.tree.filter(val);
+        }
+   },
+  created() {
+      //设置表格高度对应屏幕高度
+      this.$nextTick(() => {
+          this.clientHeight = document.body.clientHeight -250
+      })
+    this.getList();
+    this.getTreeselect();
+      this.getDicts("booking_work_status").then(response => {
+      this.statusOptions = response.data;
+    });
+    this.getDicts("book_work_area").then(response => {
+      this.workAreaOptions = response.data;
+    });
+    this.getDicts("book_unit_number").then(response => {
+      this.unitNumberOptions = response.data;
+    });
+    this.getDicts("book_floor_location").then(response => {
+      this.floorLocationOptions = response.data;
+    });
+    this.getDicts("book_user_mg").then(response => {
+      this.userMgOptions = response.data;
+    });
+      this.getDicts("book_user_unit").then(response => {
+      this.userUnitOptions = response.data;
+    });
+    this.getDicts("book_work_unit").then(response => {
+      this.workUnitOptions = response.data;
+    });
+    this.getDicts("book_work_type").then(response => {
+      this.workTypeOptions = response.data;
+    });
+    this.getDicts("book_risk_level").then(response => {
+      this.riskLevelOptions = response.data;
+    });
+    this.getDicts("book_guardian_unit").then(response => {
+      this.guardianUnitOptions = response.data;
+    });
+  },
+  methods: {
+// 表单添加一行
+    add() {
+      var arr = { }
+      this.ruleForm.push(arr)
+      this.flags()
+    },
+    // 表单减少一行
+    reduce() {
+      this.ruleForm.length = this.ruleForm.length - 1
+      this.flags()
+    },
+    // 判断数组长度
+    flags() {
+      if (this.ruleForm.length < 2) {
+        this.flag = true
+      } else {
+      	//先赋值为true再赋为false, 不然会没反应
+        this.flag = true
+        this.flag = false
+      }
+    },
+    // 重置方法
+    resetForm1() {
+      this.ruleForm = [{}]
+    },
+
+    /** 查询预约作业票台账列表 */
+    getList() {
+      this.loading = true;
+      listBookingworkticket(this.queryParams).then(response => {
+        this.bookingworkticketList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+     /** 查询部门下拉树结构 */
+     getTreeselect() {
+          treeselect().then(response => {
+              this.deptOptions = response.data;
+          });
+     },
+ // 状态字典翻译
+    statusFormat(row, column) {
+      return this.selectDictLabel(this.statusOptions, row.status);
+    },
+    // 字典翻译
+    workUnitFormat(row, column) {
+      return this.selectDictLabel(this.workUnitOptions, row.workUnit);
+    },
+    // 字典翻译
+    workAreaFormat(row, column) {
+      return this.selectDictLabel(this.workAreaOptions, row.workArea);
+    },
+    // 字典翻译
+    unitNumberFormat(row, column) {
+      return this.selectDictLabel(this.unitNumberOptions, row.unitNumber);
+    },
+    // 字典翻译
+    floorLocationFormat(row, column) {
+      return this.selectDictLabel(this.floorLocationOptions, row.floorLocation);
+    },
+     // 字典翻译
+    userMgFormat(row, column) {
+      return this.selectDictLabel(this.userMgOptions, row.userMg);
+    },
+    // 字典翻译
+    userUnitFormat(row, column) {
+      return this.selectDictLabel(this.userUnitOptions, row.userUnit);
+    },
+    // 字典翻译
+    workTypeFormat(row, column) {
+      return this.selectDictLabel(this.workTypeOptions, row.workType);
+    },
+    // 字典翻译
+    riskLevelFormat(row, column) {
+      return this.selectDictLabel(this.riskLevelOptions, row.riskLevel);
+    },
+    // 字典翻译
+    guardianUnitFormat(row, column) {
+      return this.selectDictLabel(this.guardianUnitOptions, row.guardianUnit);
+    },
+
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        workUnit: null,
+        workArea: null,
+        unitNumber: null,
+        floorLocation: null,
+        workStartTime: null,
+        workEndTime: null,
+        delFlag: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        contact: null,
+        phonenumber: null,
+        status: 0,
+        deptId: null,
+        userMg: null,
+        userUnit: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
+      getBookingworkticket(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改预约作业票台账";
+        getWorkcontent(id).then(response => {
+          
+          });
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateBookingworkticket(this.form).then(response => {
+              
+              this.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addBookingworkticket(this.form).then(response => {
+              //取得返回的关联id,然后多个作业内容数据表单 插入到后台
+                 this.btid=   response.data;
+                for(var i=0;i<this.ruleForm.length;i++){
+                   this.ruleForm[i].bookingticketId=this.btid;
+                 addWorkcontent(this.ruleForm[i]).then(response => {
+            });
+              }
+           this.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+              this.resetForm1();
+            });
+        
+              
+          }
+        }
+      });
+      
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$confirm('是否确认删除?', "警告", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        }).then(function() {
+          return delBookingworkticket(ids);
+        }).then(() => {
+          this.getList();
+          this.msgSuccess("删除成功");
+        })
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      const queryParams = this.queryParams;
+      this.$confirm('是否确认导出所有预约作业票台账数据项?', "警告", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        }).then(function() {
+          return exportBookingworkticket(queryParams);
+        }).then(response => {
+          this.download(response.msg);
+        })
+    },
+      /** 导入按钮操作 */
+      handleImport() {
+          this.upload.title = "用户导入";
+          this.upload.open = true;
+      },
+      /** 下载模板操作 */
+      importTemplate() {
+          importTemplate().then(response => {
+              this.download(response.msg);
+          });
+      },
+      // 文件上传中处理
+      handleFileUploadProgress(event, file, fileList) {
+          this.upload.isUploading = true;
+      },
+      // 文件上传成功处理
+      handleFileSuccess(response, file, fileList) {
+          this.upload.open = false;
+          this.upload.isUploading = false;
+          this.$refs.upload.clearFiles();
+          this.$alert(response.msg, "导入结果", { dangerouslyUseHTMLString: true });
+          this.getList();
+      },
+      // 提交上传文件
+      submitFileForm() {
+          this.$refs.upload.submit();
+      }
+  }
+};
+</script>
+

+ 550 - 0
ui/src/views/invoice/workcontent/index.vue

@@ -0,0 +1,550 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="创建人" prop="createrCode">
+        <el-input
+          v-model="queryParams.createrCode"
+          placeholder="请输入创建人"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="创建时间" prop="createdate">
+        <el-date-picker clearable size="small" style="width: 200px"
+          v-model="queryParams.createdate"
+          type="date"
+          value-format="yyyy-MM-dd"
+          placeholder="选择创建时间">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="修改人" prop="updaterCode">
+        <el-input
+          v-model="queryParams.updaterCode"
+          placeholder="请输入修改人"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="修改时间" prop="updatedate">
+        <el-date-picker clearable size="small" style="width: 200px"
+          v-model="queryParams.updatedate"
+          type="date"
+          value-format="yyyy-MM-dd"
+          placeholder="选择修改时间">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="作业类型" prop="workType">
+        <el-select v-model="queryParams.workType" placeholder="请选择作业类型" clearable size="small">
+          <el-option label="请选择字典生成" value="" />
+        </el-select>
+      </el-form-item>
+      <el-form-item label="风险等级" prop="riskLevel">
+        <el-input
+          v-model="queryParams.riskLevel"
+          placeholder="请输入风险等级"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="作业内容描述" prop="workDescription">
+        <el-input
+          v-model="queryParams.workDescription"
+          placeholder="请输入作业内容描述"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="作业人员数" prop="workPeopleNumber">
+        <el-input
+          v-model="queryParams.workPeopleNumber"
+          placeholder="请输入作业人员数"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="监护人单位" prop="guardianUnit">
+        <el-input
+          v-model="queryParams.guardianUnit"
+          placeholder="请输入监护人单位"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="预计作业时间" prop="estimateWorktime">
+        <el-input
+          v-model="queryParams.estimateWorktime"
+          placeholder="请输入预计作业时间"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="关联的预约开票ID" prop="bookingticketId">
+        <el-input
+          v-model="queryParams.bookingticketId"
+          placeholder="请输入关联的预约开票ID"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="部门编号" prop="deptId">
+        <el-input
+          v-model="queryParams.deptId"
+          placeholder="请输入部门编号"
+          clearable
+          size="small"
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item>
+        <el-button type="cyan" 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"
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['invoice:workcontent:add']"
+        >新增</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['invoice:workcontent:edit']"
+        >修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['invoice:workcontent:remove']"
+        >删除</el-button>
+      </el-col>
+        <el-col :span="1.5">
+            <el-button
+                    type="info"
+                    icon="el-icon-upload2"
+                    size="mini"
+                    @click="handleImport"
+                    v-hasPermi="['invoice:workcontent:edit']"
+            >导入</el-button>
+        </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['invoice:workcontent:export']"
+        >导出</el-button>
+      </el-col>
+	  <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="workcontentList" @selection-change="handleSelectionChange" :height="clientHeight" border>
+      <el-table-column type="selection" width="55" align="center" />
+      <el-table-column label="创建人" align="center" prop="createrCode" :show-overflow-tooltip="true"/>
+      <el-table-column label="创建时间" align="center" prop="createdate" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.createdate, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="修改人" align="center" prop="updaterCode" :show-overflow-tooltip="true"/>
+      <el-table-column label="修改时间" align="center" prop="updatedate" width="100">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.updatedate, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="作业类型" align="center" prop="workType" :show-overflow-tooltip="true"/>
+      <el-table-column label="风险等级" align="center" prop="riskLevel" :show-overflow-tooltip="true"/>
+      <el-table-column label="作业内容描述" align="center" prop="workDescription" :show-overflow-tooltip="true"/>
+      <el-table-column label="作业人员数" align="center" prop="workPeopleNumber" :show-overflow-tooltip="true"/>
+      <el-table-column label="监护人单位" align="center" prop="guardianUnit" :show-overflow-tooltip="true"/>
+      <el-table-column label="预计作业时间" align="center" prop="estimateWorktime" :show-overflow-tooltip="true"/>
+      <el-table-column label="关联的预约开票ID" align="center" prop="bookingticketId" :show-overflow-tooltip="true"/>
+      <el-table-column label="部门编号" align="center" prop="deptId" :show-overflow-tooltip="true"/>
+      <el-table-column label="操作" align="center" fixed="right" width="120" 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="['invoice:workcontent:edit']"
+          >修改</el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['invoice:workcontent: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="唯一标识ID" prop="id">
+          <el-input v-model="form.id" placeholder="请输入唯一标识ID" />
+        </el-form-item>
+        <el-form-item label="状态 1 :正常 ;0:删除" prop="delFlag">
+          <el-input v-model="form.delFlag" placeholder="请输入状态 1 :正常 ;0:删除" />
+        </el-form-item>
+        <el-form-item label="创建人" prop="createrCode">
+          <el-input v-model="form.createrCode" placeholder="请输入创建人" />
+        </el-form-item>
+        <el-form-item label="创建时间" prop="createdate">
+          <el-date-picker clearable size="small" style="width: 200px"
+            v-model="form.createdate"
+            type="date"
+            value-format="yyyy-MM-dd"
+            placeholder="选择创建时间">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="修改人" prop="updaterCode">
+          <el-input v-model="form.updaterCode" placeholder="请输入修改人" />
+        </el-form-item>
+        <el-form-item label="修改时间" prop="updatedate">
+          <el-date-picker clearable size="small" style="width: 200px"
+            v-model="form.updatedate"
+            type="date"
+            value-format="yyyy-MM-dd"
+            placeholder="选择修改时间">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="作业类型" prop="workType">
+          <el-select v-model="form.workType" placeholder="请选择作业类型">
+            <el-option label="请选择字典生成" value="" />
+          </el-select>
+        </el-form-item>
+        <el-form-item label="风险等级" prop="riskLevel">
+          <el-input v-model="form.riskLevel" placeholder="请输入风险等级" />
+        </el-form-item>
+        <el-form-item label="作业内容描述" prop="workDescription">
+          <el-input v-model="form.workDescription" placeholder="请输入作业内容描述" />
+        </el-form-item>
+        <el-form-item label="作业人员数" prop="workPeopleNumber">
+          <el-input v-model="form.workPeopleNumber" placeholder="请输入作业人员数" />
+        </el-form-item>
+        <el-form-item label="监护人单位" prop="guardianUnit">
+          <el-input v-model="form.guardianUnit" placeholder="请输入监护人单位" />
+        </el-form-item>
+        <el-form-item label="预计作业时间" prop="estimateWorktime">
+          <el-input v-model="form.estimateWorktime" placeholder="请输入预计作业时间" />
+        </el-form-item>
+        <el-form-item label="关联的预约开票ID" prop="bookingticketId">
+          <el-input v-model="form.bookingticketId" placeholder="请输入关联的预约开票ID" />
+        </el-form-item>
+        <el-form-item label="部门编号" prop="deptId">
+          <el-input v-model="form.deptId" placeholder="请输入部门编号" />
+        </el-form-item>
+          <el-form-item label="归属部门" prop="deptId">
+              <treeselect v-model="form.deptId" :options="deptOptions" :show-count="true" placeholder="请选择归属部门" />
+          </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>
+      <!-- 用户导入对话框 -->
+      <el-dialog :title="upload.title" :visible.sync="upload.open" width="400px" append-to-body>
+          <el-upload
+                  ref="upload"
+                  :limit="1"
+                  accept=".xlsx, .xls"
+                  :headers="upload.headers"
+                  :action="upload.url + '?updateSupport=' + upload.updateSupport"
+                  :disabled="upload.isUploading"
+                  :on-progress="handleFileUploadProgress"
+                  :on-success="handleFileSuccess"
+                  :auto-upload="false"
+                  drag
+          >
+              <i class="el-icon-upload"></i>
+              <div class="el-upload__text">
+                  将文件拖到此处,或
+                  <em>点击上传</em>
+              </div>
+              <div class="el-upload__tip" slot="tip">
+                  <el-checkbox v-model="upload.updateSupport" />是否更新已经存在的用户数据
+                  <el-link type="info" style="font-size:12px" @click="importTemplate">下载模板</el-link>
+              </div>
+              <div class="el-upload__tip" style="color:red" slot="tip">提示:仅允许导入“xls”或“xlsx”格式文件!</div>
+          </el-upload>
+          <div slot="footer" class="dialog-footer">
+              <el-button type="primary" @click="submitFileForm">确 定</el-button>
+              <el-button @click="upload.open = false">取 消</el-button>
+          </div>
+      </el-dialog>
+  </div>
+</template>
+
+<script>
+import { listWorkcontent, getWorkcontent, delWorkcontent, addWorkcontent, updateWorkcontent, exportWorkcontent, importTemplate} from "@/api/invoice/workcontent";
+import { treeselect } from "@/api/system/dept";
+import { getToken } from "@/utils/auth";
+import Treeselect from "@riophae/vue-treeselect";
+import "@riophae/vue-treeselect/dist/vue-treeselect.css";
+
+export default {
+  name: "Workcontent",
+  components: { Treeselect },
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: false,
+      // 总条数
+      total: 0,
+      // 预约作业内容表格数据
+      workcontentList: [],
+      // 弹出层标题
+      title: "",
+      // 部门树选项
+      deptOptions: undefined,
+      clientHeight:300,
+      // 是否显示弹出层
+      open: false,
+        // 用户导入参数
+        upload: {
+            // 是否显示弹出层(用户导入)
+            open: false,
+            // 弹出层标题(用户导入)
+            title: "",
+            // 是否禁用上传
+            isUploading: false,
+            // 是否更新已经存在的用户数据
+            updateSupport: 0,
+            // 设置上传的请求头部
+            headers: { Authorization: "Bearer " + getToken() },
+            // 上传的地址
+            url: process.env.VUE_APP_BASE_API + "/invoice/workcontent/importData"
+        },
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 20,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        workType: null,
+        riskLevel: null,
+        workDescription: null,
+        workPeopleNumber: null,
+        guardianUnit: null,
+        estimateWorktime: null,
+        bookingticketId: null,
+        deptId: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+        id: [
+          { required: true, message: "唯一标识ID不能为空", trigger: "blur" }
+        ],
+      }
+    };
+  },
+  watch: {
+        // 根据名称筛选部门树
+        deptName(val) {
+            this.$refs.tree.filter(val);
+        }
+   },
+  created() {
+      //设置表格高度对应屏幕高度
+      this.$nextTick(() => {
+          this.clientHeight = document.body.clientHeight -250
+      })
+    this.getList();
+    this.getTreeselect();
+  },
+  methods: {
+    /** 查询预约作业内容列表 */
+    getList() {
+      this.loading = true;
+      listWorkcontent(this.queryParams).then(response => {
+        this.workcontentList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+     /** 查询部门下拉树结构 */
+     getTreeselect() {
+          treeselect().then(response => {
+              this.deptOptions = response.data;
+          });
+     },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        delFlag: null,
+        createrCode: null,
+        createdate: null,
+        updaterCode: null,
+        updatedate: null,
+        workType: null,
+        riskLevel: null,
+        workDescription: null,
+        workPeopleNumber: null,
+        guardianUnit: null,
+        estimateWorktime: null,
+        bookingticketId: null,
+        deptId: 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
+      getWorkcontent(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) {
+            updateWorkcontent(this.form).then(response => {
+              this.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addWorkcontent(this.form).then(response => {
+              this.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$confirm('是否确认删除?', "警告", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        }).then(function() {
+          return delWorkcontent(ids);
+        }).then(() => {
+          this.getList();
+          this.msgSuccess("删除成功");
+        })
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      const queryParams = this.queryParams;
+      this.$confirm('是否确认导出所有预约作业内容数据项?', "警告", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        }).then(function() {
+          return exportWorkcontent(queryParams);
+        }).then(response => {
+          this.download(response.msg);
+        })
+    },
+      /** 导入按钮操作 */
+      handleImport() {
+          this.upload.title = "用户导入";
+          this.upload.open = true;
+      },
+      /** 下载模板操作 */
+      importTemplate() {
+          importTemplate().then(response => {
+              this.download(response.msg);
+          });
+      },
+      // 文件上传中处理
+      handleFileUploadProgress(event, file, fileList) {
+          this.upload.isUploading = true;
+      },
+      // 文件上传成功处理
+      handleFileSuccess(response, file, fileList) {
+          this.upload.open = false;
+          this.upload.isUploading = false;
+          this.$refs.upload.clearFiles();
+          this.$alert(response.msg, "导入结果", { dangerouslyUseHTMLString: true });
+          this.getList();
+      },
+      // 提交上传文件
+      submitFileForm() {
+          this.$refs.upload.submit();
+      }
+  }
+};
+</script>