using BBM.ChatGLM.Dtos;
using BBM.ChatGLM.PromptWord;
using Volo.Abp.Application.Dtos;

namespace BBM.ChatGLM.Controllers
{
    [Route("PromptWords")]
    public class PromptWordsController : ChatGLMController, IPromptWordsAppService
    {
        private readonly IPromptWordsAppService _promptWordsAppService;
        public PromptWordsController(IPromptWordsAppService promptWordsAppService)
        {
            _promptWordsAppService = promptWordsAppService;
        }

        [HttpPost("create")]
        public async Task<PromptWordDto> CreateAsync([FromBody] PromptWordCreateInput input)
        {
            return await _promptWordsAppService.CreateAsync(input);
        }

        [HttpPost("update")]
        public async Task<PromptWordDto> UpdateAsync([FromBody] PromptWordUpdateInput input)
        {
            return await _promptWordsAppService.UpdateAsync(input);
        }

        [HttpPost("delete")]
        public async Task<int> DeleteAsync([FromBody] GuidIdInput input)
        {
            return await _promptWordsAppService.DeleteAsync(input);
        }

        [HttpPost("page")]
        public async Task<PagedResultDto<PromptWordDto>> PageAsync([FromBody] PromptWordPageInput input)
        {
            return await _promptWordsAppService.PageAsync(input);
        }

        [HttpPost("type")]
        public List<string> GetTypeAsync()
        {
            return new List<string> { "产品导购词", "客户问答话术", "门窗销售流程", "门窗生产流程", "门窗运输流程", "门窗安装流程", "门窗售后流程", "营销活动策划", "新媒体创作", "竞品动态", "竞品优劣分析", "灵感提示" };
        }
    }
}
