跳至内容
菜单
此问题已终结
该问题已被关闭 原因: Question / Code not indented
Benjamin Damour2024年03月28日 12时08分48秒

the action:

def action_view_company(self):        

                                 for record in self:           

                                                                i = record.id         

                                                                  i = i           

                                                                     return  {  'type': 'ir.actions.act_window',                                                                                           'name': 'view company',                                                                                                          'res_model': 'res.partner',                                                                                             'view_id': 'company_view',                                                                                                     'view_type': 'form',                                                                                                             "view_mode": 'form',                                                                                                          'res_id': i                                                                                                                      }       

the error:

ValueError: Expected singleton: ir.ui.view('c', 'o', 'm', 'p', 'a', 'n', 'y', '_', 'v', 'i', 'e', 'w')

how can I solve this?

                                                                            

形象
丢弃
相关帖文 回复 查看 活动
3
5月 20
5330
0
8月 25
174
1
8月 25
665
0
8月 25
397
0
7月 25
1527