package org.springblade.plugin.workflow.chat.wrapper;

import org.springblade.core.mp.support.BaseEntityWrapper;
import org.springblade.core.tool.utils.BeanUtil;
import org.springblade.plugin.workflow.chat.pojo.entity.WfChatAppEntity;
import org.springblade.plugin.workflow.chat.pojo.vo.WfChatAppVO;
import java.util.Objects;

/**
 * dify - 应用 包装类,返回视图层所需的字段
 *
 * @author ssc
 */
public class WfChatAppWrapper extends BaseEntityWrapper<WfChatAppEntity, WfChatAppVO>  {

	public static WfChatAppWrapper build() {
		return new WfChatAppWrapper();
 	}

	@Override
	public WfChatAppVO entityVO(WfChatAppEntity appEntity) {
		WfChatAppVO chatModelVO = Objects.requireNonNull(BeanUtil.copyProperties(appEntity, WfChatAppVO.class));

		//User createUser = UserCache.getUser(appEntity.getCreateUser());
		//User updateUser = UserCache.getUser(appEntity.getUpdateUser());
		//modelVO.setCreateUserName(createUser.getName());
		//modelVO.setUpdateUserName(updateUser.getName());

		return chatModelVO;
	}


}
