Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
2759 Lượt xem

I have the situation that I have a component if I use a template it's

export class GeoengineRecord extends Component {

static template = "base_geoengine.GeoengineRecord";

...


I get the error message:

Uncaught Promise > Missing template: "base_geoengine.GeoengineRecord" (for component "GeoengineRecord")


If I Introduce the same xml via:

static template = xml`<p>Test</p>`

There is no issue.

I suspect it has something to do with the way I import it:

"web.assets_backend": [ "base_geoengine/static/src/js/**/*", "base_geoengine/static/src/js/views/**/*",

I had a similar issue where i needed to make my own bundle which is not good for this use case. -> a custom name instead of "web.assets_backend".

Any help would be appriciated.

Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

Hi,


1. Change the folder to static/src/xml/file name.xml

2. Check the Template Definition in XML

3. make sure the assets are loaded in the right bundle


Hope it helps

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 7 22
4168
1
thg 11 20
3705
1
thg 12 23
2665
1
thg 8 25
925
0
thg 1 25
1426