Skip to Content
Menu
This question has been flagged
1324 Views

 @api.constrains('line_ids')    def_check_exist_product_in_line(self):        err_products = []        # res = super(MybodyLine, self.line_ids).browse()        # if  self.line_ids:
        #         # return warning message
        #         raise ValidationError(_(f"No Journal Items {self.line_ids.name_sas.name}"))
        # return res                list_vali=[]        list_repe=[]            forlineinself.line_ids.name_sas :            # if line.id not in err_products:                forcopyinself.line_ids.name_sas:                    list_vali.append(copy.name)
                # # for copye in self.repito.name:                #     list_repe.append(self.repito ==self.line_ids.name_sas)
                ifline.name == list_vali:                     raiseexceptions.Warning(f" This field is already placed {line.name}, {list_vali}")                else :                    # pass                    err_products.append(line.id)                    raiseexceptions.Warning(_(f' {line.name} , {list_vali} ,{list_repe}'))                # else:            #     raise exceptions.Warning(_(' Exist'))

 I want to place a part of the body I bone a neck and an arm but the system does not validate if I add another neck in a line_ids

Avatar
Discard
Related Posts Replies Views Activity
0
Oct 24
155
0
Aug 24
163
0
Jan 24
727
1
Nov 23
414
2
Oct 23
3950