mirror of
https://github.com/guohuadeng/app-odoo.git
synced 2025-02-23 04:11:36 +02:00
update data 文件
This commit is contained in:
@@ -6,7 +6,10 @@ from odoo import api, fields, models, _
|
||||
class GptRobot(models.Model):
|
||||
_name = 'gpt.robot'
|
||||
_description = 'Gpt Robot'
|
||||
_order = 'sequence, name'
|
||||
|
||||
|
||||
name = fields.Char(string='Name')
|
||||
openapi_api_key = fields.Char(string="API Key", help="Provide the API key here")
|
||||
temperature = fields.Float(string='Temperature')
|
||||
temperature = fields.Float(string='Temperature', default=0.9)
|
||||
sequence = fields.Integer('Sequence', help="Determine the display order", default=10)
|
||||
|
||||
@@ -89,6 +89,7 @@ class Channel(models.Model):
|
||||
# print('author_id:',author_id)
|
||||
|
||||
gpt_id = self.env['gpt.robot']
|
||||
# todo: 应该先确定 gpt_id,才处理对话黑名单。 黑名单是指是否允许与 gpt对话,不是是否允许绑定 gpt
|
||||
partner_ids = list(msg_vals.get('partner_ids'))
|
||||
if partner_ids:
|
||||
partners = self.env['res.partner'].search([('id', 'in', partner_ids)])
|
||||
|
||||
Reference in New Issue
Block a user