fix: correct subtable URLs to use relative aliases for same-module, absolute paths for cross-module

This commit is contained in:
yumoqing 2026-05-06 08:56:03 +08:00
parent ecada505c9
commit 4154d22ed2

View File

@ -2,7 +2,9 @@
"tblname": "opportunities",
"title": "商机管理",
"params": {
"sortby": ["created_at desc"],
"sortby": [
"created_at desc"
],
"logined_userid": "owner_id",
"confidential_fields": [],
"editor": {
@ -16,7 +18,7 @@
},
{
"wid": "probability",
"event": "changed",
"event": "changed",
"actiontype": "script",
"target": "predicted_revenue",
"script": "const amount = parseFloat(document.getElementById('estimated_amount')?.value) || 0;\nconst probability = parseFloat(widget.getValue()) || 0;\nconst predicted = (amount * probability / 100).toFixed(2);\ndocument.getElementById('predicted_revenue').value = predicted;"
@ -24,42 +26,88 @@
]
},
"browserfields": {
"exclouded": ["id", "customer_id", "owner_id", "created_at", "updated_at"],
"exclouded": [
"id",
"customer_id",
"owner_id",
"created_at",
"updated_at"
],
"alters": {
"current_stage": {
"uitype": "code",
"data": [
{"value": "初步接洽", "text": "初步接洽"},
{"value": "需求确认", "text": "需求确认"},
{"value": "方案报价", "text": "方案报价"},
{"value": "合同谈判", "text": "合同谈判"},
{"value": "成交", "text": "成交"}
{
"value": "初步接洽",
"text": "初步接洽"
},
{
"value": "需求确认",
"text": "需求确认"
},
{
"value": "方案报价",
"text": "方案报价"
},
{
"value": "合同谈判",
"text": "合同谈判"
},
{
"value": "成交",
"text": "成交"
}
]
},
"source_type": {
"uitype": "code",
"data": [
{"value": "manual", "text": "手动录入"},
{"value": "lead", "text": "线索转化"}
{
"value": "manual",
"text": "手动录入"
},
{
"value": "lead",
"text": "线索转化"
}
]
},
"status": {
"uitype": "code",
"data": [
{"value": "active", "text": "活跃"},
{"value": "won", "text": "已成交"},
{"value": "lost", "text": "已丢失"},
{"value": "closed", "text": "已关闭"}
{
"value": "active",
"text": "活跃"
},
{
"value": "won",
"text": "已成交"
},
{
"value": "lost",
"text": "已丢失"
},
{
"value": "closed",
"text": "已关闭"
}
]
}
}
},
"editexclouded": ["id", "customer_id", "owner_id", "created_at", "updated_at", "predicted_revenue"],
"editexclouded": [
"id",
"customer_id",
"owner_id",
"created_at",
"updated_at",
"predicted_revenue"
],
"subtables": [
{
"field": "opportunity_id",
"title": "阶段变更历史",
"url": "{{entire_url('opportunity_stage_history')}}",
"url": "{{entire_url('stage_history_list')}}",
"subtable": "opportunity_stage_history"
}
]