
package com.jeelowcode.module.biz.service.impl;

import com.jeelowcode.core.framework.mapper.JeeLowCodeSqlMapper;
import com.jeelowcode.core.framework.service.IFrameSqlService;
import com.jeelowcode.framework.global.JeeLowCodeBaseConstant;
import com.jeelowcode.framework.plus.SqlHelper;
import com.jeelowcode.framework.plus.build.buildmodel.wrapper.SqlInfoQueryWrapper;
import com.jeelowcode.framework.plus.core.model.SqlFormatModel;
import com.jeelowcode.module.biz.mapper.DemoMapper;
import com.jeelowcode.module.biz.service.IDemoService;
import com.jeelowcode.module.biz.service.IPlanIssusService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;


/**
 * demo
 */
@Slf4j
@Service
public class PlanIssusServiceImpl implements IPlanIssusService {

    @Autowired
    private JeeLowCodeSqlMapper sqlMapper;

    @Override
    public void savePlanIssus(String tableName, Map<String, Object> addDataMap) {
        SqlFormatModel sqlFormatModel = SqlHelper.getInsertWrapper()
                .setTableName(tableName)
                .setMap(addDataMap)
                .buildSql();
        String sql = sqlFormatModel.getEwSql();
        sqlMapper.insertData(JeeLowCodeBaseConstant.DS_MASTER,sql, sqlFormatModel.getDataMap());

    }
}
