110 lines
5.5 KiB
XML
110 lines
5.5 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<odoo>
|
|
|
|
<!-- ================================================================
|
|
SCHEDULE SLOT VIEWS
|
|
================================================================ -->
|
|
|
|
<record id="view_blog_schedule_tree" model="ir.ui.view">
|
|
<field name="name">itsulu.blog.schedule.tree</field>
|
|
<field name="model">itsulu.blog.schedule</field>
|
|
<field name="arch" type="xml">
|
|
<list string="Schedule Slots">
|
|
<field name="name"/>
|
|
<field name="slot"/>
|
|
<field name="trigger_time"/>
|
|
<field name="blog_id"/>
|
|
<field name="llm_provider"/>
|
|
<field name="llm_model"/>
|
|
<field name="image_provider"/>
|
|
<field name="auto_publish" widget="toggle_button"/>
|
|
<field name="active" widget="toggle_button"/>
|
|
<field name="last_run" optional="show"/>
|
|
<button name="%(action_blog_generate_wizard)d" type="action"
|
|
string="▶ Run Now" class="btn-sm btn-primary"
|
|
context="{'default_blog_id': blog_id, 'default_llm_provider': llm_provider, 'default_llm_model': llm_model}"/>
|
|
</list>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="view_blog_schedule_form" model="ir.ui.view">
|
|
<field name="name">itsulu.blog.schedule.form</field>
|
|
<field name="model">itsulu.blog.schedule</field>
|
|
<field name="arch" type="xml">
|
|
<form string="Schedule Slot">
|
|
<header>
|
|
<button name="%(action_blog_generate_wizard)d" type="action"
|
|
string="▶ Run Now" class="btn-primary"/>
|
|
</header>
|
|
<sheet>
|
|
<widget name="web_ribbon" title="Inactive" bg_color="bg-danger"
|
|
invisible="active"/>
|
|
<div class="oe_title">
|
|
<h1><field name="name" placeholder="e.g. Morning Post"/></h1>
|
|
</div>
|
|
<group>
|
|
<group string="Timing">
|
|
<field name="slot"/>
|
|
<field name="trigger_time"/>
|
|
<field name="active"/>
|
|
</group>
|
|
<group string="Content">
|
|
<field name="blog_id"/>
|
|
<field name="tone"/>
|
|
<field name="auto_publish"/>
|
|
</group>
|
|
</group>
|
|
<notebook>
|
|
<page string="LLM Configuration">
|
|
<group>
|
|
<group string="Text Generation">
|
|
<field name="llm_provider"/>
|
|
<field name="llm_model"/>
|
|
</group>
|
|
<group string="Image Generation">
|
|
<field name="image_provider"/>
|
|
</group>
|
|
</group>
|
|
</page>
|
|
<page string="Social Media Platforms">
|
|
<p class="text-muted">Enable or disable social media copy generation for this slot.</p>
|
|
<group>
|
|
<field name="platform_twitter" widget="toggle_button"/>
|
|
<field name="platform_bluesky" widget="toggle_button"/>
|
|
<field name="platform_mastodon" widget="toggle_button"/>
|
|
<field name="platform_linkedin" widget="toggle_button"/>
|
|
</group>
|
|
</page>
|
|
<page string="Prompt Override">
|
|
<p class="text-muted">Leave blank to use the global prompt template from Settings. Enter a custom prompt to override for this slot only.</p>
|
|
<field name="prompt_override" placeholder="Optional: custom user prompt for this slot..."/>
|
|
</page>
|
|
<page string="Notification">
|
|
<field name="notification_emails"
|
|
placeholder="Leave blank to use global Settings (nicholasr@itsulu.com,sales@itsulu.com)"/>
|
|
</page>
|
|
<page string="Generation Log">
|
|
<field name="log_ids" readonly="1">
|
|
<list decoration-danger="state=='error'" decoration-success="state=='success'">
|
|
<field name="create_date"/>
|
|
<field name="state" widget="badge"/>
|
|
<field name="topic_used"/>
|
|
<field name="tokens_used"/>
|
|
<field name="duration_seconds" string="Duration (s)"/>
|
|
<field name="blog_post_id"/>
|
|
</list>
|
|
</field>
|
|
</page>
|
|
</notebook>
|
|
</sheet>
|
|
</form>
|
|
</field>
|
|
</record>
|
|
|
|
<record id="action_blog_schedule_list" model="ir.actions.act_window">
|
|
<field name="name">Schedule Slots</field>
|
|
<field name="res_model">itsulu.blog.schedule</field>
|
|
<field name="view_mode">list,form</field>
|
|
</record>
|
|
|
|
</odoo>
|