package com.zksy.basicData.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.zksy.basicData.domain.XcrTrademark;
import com.zksy.basicData.mapper.XcrTrademarkMapper;
import com.zksy.basicData.service.IXcrTrademarkService;
import com.zksy.common.core.domain.AjaxResult;
import com.zksy.common.utils.DeleteTableUtils;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import javax.annotation.Resource;

/**
 * 商标Service业务层处理
 *
 * @author nahida
 * @date 2024-12-12
 */
@Service
public class XcrTrademarkServiceImpl extends ServiceImpl<XcrTrademarkMapper, XcrTrademark> implements IXcrTrademarkService {

    @Resource
    private XcrTrademarkMapper mapper;

    @Override
    @Transactional
    public AjaxResult deleteAll() {
        DeleteTableUtils<XcrTrademark> utils = new DeleteTableUtils<>();
        utils.del(XcrTrademark::getXhCodeId,mapper);
        return AjaxResult.success("全部删除成功");
    }
}
