(self, master)
return
Show all record fields in entry fields or labels
Show all record fields in entry fields or labels
Show all record fields in entry fields or labels
def body(self, master):
        """Show all record fields in entry fields or labels"""

        model = self.model
        cols = self.recdata.keys()
        self.editable = []
        self.fieldnames = {}
        self.fieldvars = {}
        self.fieldvars['Name'] = StringVar()
        self.fieldvars['Name'].set(self.recname)
        Label(master, text='Rec Name:').grid(row=0,column=0,padx=2,pady=2,sticky='news')
        Entry(master, textvariable=self.fieldvars['Name']).grid(row=0,column=1,padx=2,pady=2,sticky='news')
        i=1
        for col in cols:
            self.fieldvars[col] = StringVar()
            if col in self.recdata:
                val = self.recdata[col]
                self.fieldvars[col].set(val)
            self.fieldnames[col] = Label(master, text=col).grid(row=i,column=0,padx=2,pady=2,sticky='news')
            ent = Entry(master, textvariable=self.fieldvars[col])
            ent.grid(row=i,column=1,padx=2,pady=2,sticky='news')
            if not type(self.recdata[col]) is str:
                ent.config(state=DISABLED)
            else:
                self.editable.append(col)
            i+=1
        top=self.winfo_toplevel()
        top.columnconfigure(1,weight=1)
        return
def body ( self , master ) : model = self . model cols = self . recdata . keys ( ) self . editable = [ ] self . fieldnames = { } self . fieldvars = { } self . fieldvars [ 'Name' ] = StringVar ( ) self . fieldvars [ 'Name' ] . set ( self . recname ) Label ( master , text = 'Rec Name:' ) . grid ( row = 0 , column = 0 , padx = 2 , pady = 2 , sticky = 'news' ) Entry ( master , textvariable = self . fieldvars [ 'Name' ] ) . grid ( row = 0 , column = 1 , padx = 2 , pady = 2 , sticky = 'news' ) i = 1 for col in cols : self . fieldvars [ col ] = StringVar ( ) if col in self . recdata : val = self . recdata [ col ] self . fieldvars [ col ] . set ( val ) self . fieldnames [ col ] = Label ( master , text = col ) . grid ( row = i , column = 0 , padx = 2 , pady = 2 , sticky = 'news' ) ent = Entry ( master , textvariable = self . fieldvars [ col ] ) ent . grid ( row = i , column = 1 , padx = 2 , pady = 2 , sticky = 'news' ) if not type ( self . recdata [ col ] ) is str : ent . config ( state = DISABLED ) else : self . editable . append ( col ) i += 1 top = self . winfo_toplevel ( ) top . columnconfigure ( 1 , weight = 1 ) return