package com.engine.htsc.system.dao;

import com.engine.integration.util.StringUtils;
import weaver.general.Util;
import weaver.interfaces.htsc.GlobatTools.JAVATools;
import weaver.wechat.util.Utils;

import java.util.HashMap;
import java.util.Map;

/**
 * @ClassName WfAttentionTypeSetDao
 * @Author K1810015
 * @Date 2022/2/14 13:39
 * Version 1.0
 */
public class WfAttentionTypeSetDao {


    public static String getUsertolabelname(Map<String,Object> map){
        String value="";
        if(map==null || map.size()<=0) {
            return value;
        }
        String userid= Util.null2String(map.get("userid"));
        String showname= Util.null2String(map.get("showname"));
        if(StringUtils.isBlank(userid) || StringUtils.isBlank(showname)){
            return  value;
        }
        String sql="select id from workflow_attentionTypeSet where 1=1";
        Map<String,String> wheremap=new HashMap<>();
        wheremap.put("userid",userid);
        wheremap.put("showname",showname);
        Map<String,Object> retmap= JAVATools.GetTableToMap(sql,wheremap);
        if(retmap==null ||retmap.size()<=0){
            return value;
        }
        return Utils.null2String(retmap.get("id"));

    }
}
