Skip ke Konten
Odoo Menu
  • Login
  • Uji coba gratis
  • Aplikasi
    Keuangan
    • Akuntansi
    • Faktur
    • Pengeluaran
    • Spreadsheet (BI)
    • Dokumen
    • Tanda Tangan
    Sales
    • CRM
    • Sales
    • POS Toko
    • POS Restoran
    • Langganan
    • Rental
    Website
    • Website Builder
    • eCommerce
    • Blog
    • Forum
    • Live Chat
    • eLearning
    Rantai Pasokan
    • Inventaris
    • Manufaktur
    • PLM
    • Purchase
    • Maintenance
    • Kualitas
    Sumber Daya Manusia
    • Karyawan
    • Rekrutmen
    • Cuti
    • Appraisal
    • Referensi
    • Armada
    Marketing
    • Social Marketing
    • Email Marketing
    • SMS Marketing
    • Acara
    • Otomatisasi Marketing
    • Survei
    Layanan
    • Project
    • Timesheet
    • Layanan Lapangan
    • Meja Bantuan
    • Planning
    • Appointment
    Produktivitas
    • Diskusi
    • Approval
    • IoT
    • VoIP
    • Pengetahuan
    • WhatsApp
    Aplikasi pihak ketiga Odoo Studio Platform Odoo Cloud
  • Industri-Industri
    Retail
    • Toko Buku
    • Toko Baju
    • Toko Furnitur
    • Toko Kelontong
    • Toko Hardware
    • Toko Mainan
    Makanan & Hospitality
    • Bar dan Pub
    • Restoran
    • Fast Food
    • Rumah Tamu
    • Distributor Minuman
    • Hotel
    Real Estate
    • Agensi Real Estate
    • Firma Arsitektur
    • Konstruksi
    • Estate Management
    • Perkebunan
    • Asosiasi Pemilik Properti
    Konsultansi
    • Firma Akuntansi
    • Mitra Odoo
    • Agensi Marketing
    • Firma huku
    • Talent Acquisition
    • Audit & Sertifikasi
    Manufaktur
    • Tekstil
    • Logam
    • Perabotan
    • Makanan
    • Brewery
    • Corporate Gift
    Kesehatan & Fitness
    • Sports Club
    • Toko Kacamata
    • Fitness Center
    • Wellness Practitioners
    • Farmasi
    • Salon Rambut
    Perdagangan
    • Handyman
    • IT Hardware & Support
    • Sistem-Sistem Energi Surya
    • Pembuat Sepatu
    • Cleaning Service
    • Layanan HVAC
    Lainnya
    • Organisasi Nirlaba
    • Agen Lingkungan
    • Rental Billboard
    • Fotografi
    • Penyewaan Sepeda
    • Reseller Software
    Browse semua Industri
  • Komunitas
    Belajar
    • Tutorial-tutorial
    • Dokumentasi
    • Sertifikasi
    • Pelatihan
    • Blog
    • Podcast
    Empower Education
    • Program Edukasi
    • Game Bisnis 'Scale Up!'
    • Kunjungi Odoo
    Dapatkan Softwarenya
    • Download
    • Bandingkan Edisi
    • Daftar Rilis
    Kolaborasi
    • Github
    • Forum
    • Acara
    • Terjemahan
    • Menjadi Partner
    • Layanan untuk Partner
    • Daftarkan perusahaan Akuntansi Anda.
    Dapatkan Layanan
    • Temukan Mitra
    • Temukan Akuntan
    • Temui penasihat
    • Layanan Implementasi
    • Referensi Pelanggan
    • Bantuan
    • Upgrades
    Github Youtube Twitter Linkedin Instagram Facebook Spotify
    +1 (650) 691-3277
    Dapatkan demo
  • Harga
  • Bantuan

Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:

  • CRM
  • e-Commerce
  • Akuntansi
  • Inventaris
  • PoS
  • Project
  • MRP
All apps
Anda harus terdaftar untuk dapat berinteraksi di komunitas.
Semua Post Orang Lencana-Lencana
Label (Lihat semua)
odoo accounting v14 pos v15
Mengenai forum ini
Anda harus terdaftar untuk dapat berinteraksi di komunitas.
Semua Post Orang Lencana-Lencana
Label (Lihat semua)
odoo accounting v14 pos v15
Mengenai forum ini
Help

odoo 17, can't import Wysiwyg

Langganan

Dapatkan notifikasi saat terdapat aktivitas pada post ini

Pertanyaan ini telah diberikan tanda
importingwysiwygJSv17
2 Replies
4051 Tampilan
Avatar
Lev Semenov

Hi all

Can anyone tell me why, after migrating from version 16 to version 17, it is no longer possible to import Wysiwyg in the usual way?


In my module i use

import { Wysiwyg } from "@web_editor/js/wysiwyg/wysiwyg";

I need this to add new commands to powerbox

But this results in an error:


The following modules are needed by other modules but have not been defined, they may not be present in the correct asset bundle:

@web_editor/js/wysiwyg/wysiwyg


At the same time, 

import fonts from '@web_editor/js/wysiwyg/fonts';

in the same file, does not lead to errors.


__manifest__ contains dependencies:

'depends': ['base', 'mail', 'web_editor']


I tried to do this on a completely empty module to avoid possible conflicts, but the error was the same. What could be wrong?

0
Avatar
Buang
Avatar
Lev Semenov
Penulis Jawaban Terbai

The problem was in the order in which the assets were loaded.

In version 17, it is important that wysiwyg is loaded in a separate assets group:

web.assets_backend:
        'web.assets_backend': [
            'my_module/static/src/scss/**',
            'my_module/static/src/xml/**'
        ],
        'web_editor.backend_assets_wysiwyg': [
            'my_module/static/src/js/wysiwyg.js',
        ],
0
Avatar
Buang
Vertec LLC

Hi I'm trying to do something very similar in Odoo 18.0 upgrading from Odoo 17.0. Have you had any issues with this?

I have this in my manifest:
web.assets_backend:
'web.assets_backend': [
'my_module/static/src/scss/**',
'my_module/static/src/xml/**'
],
'web_editor.backend_assets_wysiwyg': [
'my_module/static/src/js/wysiwyg.js',
],

And this is my wysiwyg.js file:

/** @odoo-module **/
import { Wysiwyg } from '@web_editor/js/wysiwyg/wysiwyg';
import { patch } from '@web/core/utils/patch';
import { _t } from '@web/core/l10n/translation';
import {parseHTML} from '@web_editor/js/editor/odoo-editor/src/utils/utils'

patch(Wysiwyg.prototype, {
_getPowerboxOptions() {
const options = super._getPowerboxOptions();
const wysiwyg = this

options.commands.push({
category: _t('Widgets'),
name: _t('10 Stars'),
priority: 5,
description: _t('Insert a rating over 10 stars'),
fontawesome: 'fa-star',
callback: function () {
let html = '\u200B<span contenteditable="false" class="o_stars o_ten_stars">';
html += Array(10).fill().map(() => '<i class="fa fa-star-o"></i>').join('');
html += '</span>\u200B';
wysiwyg.odooEditor.execCommand('insert', parseHTML(window.document, html));
},
});
return options;
},
});

It works perfectly in Odoo 17.0, but in Odoo 18.0 the modules aren't even loading at all. I can't even see console logs. I've tried it on other browsers, other computers, clearing cache, regenerating assets, restarting odoo http. Can't seem to get anything to load using the web_editor.backend_assets_wysiwyg bundle

Avatar
Craig Horrocks
Jawaban Terbai

Hi Vertec LLC - did you resolve this - have the same issue.


0
Avatar
Buang
Menikmati diskusi? Jangan hanya membaca, ikuti!

Buat akun sekarang untuk menikmati fitur eksklufi dan agar terlibat dengan komunitas kami!

Daftar
Post Terkait Replies Tampilan Aktivitas
Create new values on csv upload when there is no matching value no longer works after upgrade to v17
importing bug v17
Avatar
Avatar
1
Okt 25
3807
Issue with Importing POS Orders in Odoo: Payment Method and Multi-Company Access Errors
pos importing Point Of Sale v17 V15
Avatar
0
Nov 24
1880
Lack of mouse cursor after new html element in Odoo wysiwyg
cursor html wysiwyg command v17
Avatar
0
Mar 24
2158
Ya es posible hacer Upgrade de v17 a v17.1 ?
v17
Avatar
Avatar
1
Okt 25
1322
How to add a new Many2one field in res.config.settings? Diselesaikan
v17
Avatar
Avatar
Avatar
Avatar
4
Okt 25
3711
Komunitas
  • Tutorial-tutorial
  • Dokumentasi
  • Forum
Open Source
  • Download
  • Github
  • Runbot
  • Terjemahan
Layanan
  • Odoo.sh Hosting
  • Bantuan
  • Peningkatan
  • Custom Development
  • Pendidikan
  • Temukan Akuntan
  • Temukan Mitra
  • Menjadi Partner
Tentang Kami
  • Perusahaan kami
  • Aset Merek
  • Hubungi kami
  • Tugas
  • Acara
  • Podcast
  • Blog
  • Pelanggan
  • Hukum • Privasi
  • Keamanan
الْعَرَبيّة Català 简体中文 繁體中文 (台灣) Čeština Dansk Nederlands English Suomi Français Deutsch हिंदी Bahasa Indonesia Italiano 日本語 한국어 (KR) Lietuvių kalba Język polski Português (BR) română русский язык Slovenský jazyk slovenščina Español (América Latina) Español ภาษาไทย Türkçe українська Tiếng Việt

Odoo adalah rangkaian aplikasi bisnis open source yang mencakup semua kebutuhan perusahaan Anda: CRM, eCommerce, akuntansi, inventaris, point of sale, manajemen project, dan seterusnya.

Mudah digunakan dan terintegrasi penuh pada saat yang sama adalah value proposition unik Odoo.

Website made with

Odoo Experience on YouTube

1. Use the live chat to ask your questions.
2. The operator answers within a few minutes.

Live support on Youtube
Watch now