package com.chushang.inspection.project.service;

import cn.hutool.core.bean.BeanUtil;
import com.baomidou.mybatisplus.extension.service.IService;
import com.chushang.inspection.project.dto.TaskGraphDTO;
import com.chushang.inspection.project.po.PollingTaskAutograph;

/**
  * @auther: zhao
  * @date: 2024/6/18 15:39
  */
public interface PollingTaskAutographService extends IService<PollingTaskAutograph>{


    default void save(TaskGraphDTO task){
        PollingTaskAutograph pollingTaskAutograph = BeanUtil.copyProperties(task, PollingTaskAutograph.class);
        save(pollingTaskAutograph);
    }

    default void update(TaskGraphDTO task){
        PollingTaskAutograph pollingTaskAutograph = BeanUtil.copyProperties(task, PollingTaskAutograph.class);
        updateById(pollingTaskAutograph);
    }
}
