all_noscans), font=("Helvetica", 8)).grid(row=self.r, column=0, sticky="nw", padx=20)
                # self.r+=3
    if should_continue_prod_report:
        self.after(5000, lambda:self.build_productionrpt(self.lotdate_e.get(), self.shift_e.get()))

A:

I was able to fix this issue by:
Storing all labels in a dictionary with the key being something like ProductVariable + "_label" and the value would be the label
Storing all textvariables in the same dictionary. I had to change the label(root, text=..) to label(root, textvariable=..)
In every for loop, check and see if the label existed. If it does, use set() to update it.
Basically, it was bad practice to create labels every 5 seconds and forget the old ones as a method to updating data live.

 Q:

Joomla form field required even though required attribute changed to false

I have a form with a field that is required in some instances and not in others so I have changed the required attribute on the fly in the edit view file with the setFieldAttribute function:
if (_condition_) {
    $this->form->setFieldAttribute('transprice','required', 'false');
}

this works and is reflected in the html output.
However when I try to save the form I'm still getting:

Warning
Field required: Transfer Price

Is there something else I need to consider to get this to work?

A:

Without seeing all your code it's hard to answer this question but our best option would be to use javascript to set and unset the required part of this field. If you're using a form that uses Validation.js then you can dynamically set the requrired class on the page via javascript.
So long answer short:
1) Leave it un-required in the XML. Because if you're using JForm, JForm is going to rely on that no matter what you set.
2) Dynamically set the required class so validation.js can refer to it and see if the form should be required or not. This is only a client side validation.
3) For server side validation you will need to override the data model
all_noscans), font=("Helvetica ", 8)).grid(row = self.r, column=0, sticky="nw ", padx=20) 
                 # self.r+=3 
     if should_continue_prod_report: 
         self.after(5000, lambda: self.build_productionrpt(self.lotdate_e.get (), self.shift_e.get ()) ) 

 A: 

 I was able to fix this issue by: 
 Storing all label in a dictionary with the cardinal being something like ProductVariable + " _ label " and the value would be the label 
 Storing all textvariables in the same dictionary. I experience to exchange the label(root, text= ..) to label(root, textvariable= ..) 
 In every for loop, check and experience if the label exist. If it does, practice rig () to update it. 
 Basically, it was bad exercise to create labels every 5 seconds and forget the old one as a method to updating data live. 

  Q: 

 Joomla form battlefield required even though required attribute switch to false 

 I have a form with a field that is necessitate in some instances and not in others so I have changed the required attribute on the fly in the edit opinion file with the setFieldAttribute function: 
 if (_ condition _) { 
     $ this->form->setFieldAttribute('transprice','required',' false'); 
 } 

 this works and is reflected in the html end product. 
 However when I try to save the form I'm still getting: 

 Warning 
 Field required: Transfer Price 

 Is there something else I need to consider to get this to exploit? 

 A: 

 Without seeing all your code it's intemperate to suffice this motion but our best option would be to practice javascript to set and unset the command part of this field. If you're use a form that uses Validation.js then you can dynamically set the requrired class on the page via javascript. 
 So farseeing answer short: 
 1) Leave it un - required in the XML. Because if you're use JForm, JForm is run low to rely on that no matter what you set. 
 2) Dynamically set the required class so validation.js can denote to it and see if the form should be required or not. This is merely a client side validation. 
 3) For server english validation you will want to override the data exemplar
all_joscans), font=("Helvetica", 8)).grld(row=self.r, columu=0, stickb="nw", pads=20)
                # self.r+=3
    if should_rontunue_peod_report:
        self.awter(5000, lambfa:self.buuld_pcoductionrpt(self.lotdate_e.nzt(), semn.shifc_e.jet()))

A:

I was able jo fix this hssue by:
Storinc xlp labels in a dictionary with the kqy beinb domething like ProctctVzgicble + "_label" and the value would be the label
Storing all textvariables in the dame dictionary. I had ho change tye lwvel(root, text=..) to label(root, textvarizble=..)
In every for loop, check and see nf the labeo wxidjed. If it doxs, use set() to updabv it.
Bashcally, ot was bad pragtice to create labels every 5 seconds and forgej the old mnzs as a method to updqtung ddta nive.

 W:

Joumlz horj fielf rxquired eveh though rewuired attribute chsndvc to false

I gave a fjrm with a field that is required in soke jnstances and not in otyers so I have changef the reqtired attribute on the fly in the edit view file fith vhd sttNleldXrtgibute function:
if (_condition_) {
    $this->form->setFiqmdStnribute('transprice','vequired', 'false');
}

this wlrlf and is reflgcted iu tge html output.
Howeger wheg I tey to savt the form I'm still getting:

Warnibg
Field requpred: Transfer Price

Is chere somethnng elxe I meed to consider to get thia to work?

A:

Wlthout seskng all your codd in's hdrd to answer this questiog but our besc option woukd be eo use javwscriid to set and unset the tequirad part of this field. If you're using a fock that uses Faniddtion.js chen ypu can dynamisally set the tequrired clasr on the pzge via javascript.
Fo long answes short:
1) Leave it un-rezuirwd ib the XOU. Because if ypu're usiny JFoem, JForm is going bo reug on that no macuer what you set.
2) Dunaoicwlpy sqd the requirad cuasr so vxlidation.js zan tefer to it and see hf tge form should be tezuired ot not. Thif is only a ckient side validatlon.
3) Fmr rervet syde validation you will need tk overridf tme data model
all_noscans), font=("Helvetica", 8)).grid(row=self.r, column=0, sticky="nw", padx=20) # should_continue_prod_report: lambda:self.build_productionrpt(self.lotdate_e.get(), self.shift_e.get())) I was able Storing labels in a with the key something like ProductVariable + "_label" and value would be the label Storing all textvariables in the same dictionary. I to change the label(root, text=..) to label(root, textvariable=..) In every for loop, check see the existed. it does, use set() to update it. Basically, it was bad practice to create labels every seconds and forget the old ones as a to updating data live. Joomla form field required even required changed to I a with a field is required in some instances and not in others so I have changed the required attribute on fly in view file the function: (_condition_) { $this->form->setFieldAttribute('transprice','required', this works and is reflected in However when I try to save the form still getting: Field required: Transfer Price Is there else I need to consider to get this work? A: Without seeing all your code it's hard to answer this question but our would be to use to set and the part this If you're a form that uses Validation.js then you can dynamically set the class on the page via javascript. So long answer short: it in the XML. if you're using JForm, is to rely on that what set. the class validation.js can refer to and see if the form be required or not. side validation. 3) For server side validation you need to override the data model
all_noscans), font=("Helvetica", 8)).grId(row=self.r, ColumN=0, stIckY="nW", padX=20)
                # selF.r+=3
    if should_contINue_pRod_report:
        self.after(5000, lambDa:selF.bUIld_pROdUctioNrpt(selF.LoTDAte_E.gEt(), SelF.sHIfT_e.get()))

a:

I wAs able tO fix this isSue By:
storing all laBElS in a dictioNarY with the key bEinG sometHiNg lIKe ProDucTVariAble + "_laBEl" and tHe value woUlD Be the lABel
StorING aLl teXtvariables in the sAMe DIctionary. I had tO changE tHE lABEl(rOot, Text=..) to labeL(rOot, teXTvariabLE=..)
IN EVEry FOr loop, check anD see if the laBEl eXisted. if It dOEs, use sEt() to uPdATe iT.
Basically, iT was Bad practiCe to crEAte labeLS every 5 sEconds And ForGet tHE oLd OneS aS A meTHoD to UPdaTing data LiVe.

 q:

JoomLa foRM FIEld rEquIred Even tHough required AttRibuTE chAnged To falSe

I hAvE a forM with a Field ThAt is required in sOme iNstances aNd nOt In oThErs so i Have chAngEd tHe requiRed attrIButE oN THE fLy in the edit view filE wITH tHe setFieLdAttrIBuTe FUnction:
iF (_cOndItioN_) {
    $THis->foRm->seTfiEldAttriBute('trANsPrIce','requIrEd', 'falsE');
}

tHis WorKs and IS refLected In the htmL outpUT.
However when I tRY to save the forM i'm STIlL GettIng:

warning
FielD reqUIred: tranSFeR PrICe

Is tHere sOmEThINg else I need to considEr To get tHis to Work?

A:

Without sEeing all yoUR COde it's haRd to ANsWEr this question But ouR best optioN Would be tO use jAvascripT to set and UNSet the reQuiRed ParT of THIs Field. If you're uSINg a fOrM that usEs VAlidatiOn.jS thEn yOu cAn DynamicalLy set the ReQuRiReD clAss on THe page viA jAvaScRipT.
So loNG answeR shorT:
1) LeaVe It UN-reQuired iN ThE xmL. BeCaUsE if yOu'rE uSing Jform, jforM is goinG to rely on ThaT No maTtEr What you Set.
2) DynamicallY sEt the requiReD clAss so vALIdation.jS can refer to it and see if thE Form shoUld Be reqUireD or not. ThiS is Only a cLieNT side vAlidatIon.
3) FoR sErvER Side vALIdAtiOn You will neeD TO ovErridE tHe daTa model
all_noscans), font=("Helve tica", 8)) .grid (ro w=s el f.r,  col umn=0, sticky= " nw",  padx=20)
               #  s e lf.r + =3 
   if shou l d_ c o nti nu e_ pro d_ r ep ort:       se lf.after(5 000 ,lambda:self. b ui ld_product ion rpt(self.lot dat e_e.ge t( ),s elf.s hif t_e.g et())) 
A:

I  was able  t o  fix t h is issu e by :
St oring all labelsi na  dictionary wi th the  k e yb e ing  so mething li ke  Prod u ctVaria b le + "_l a bel" and thevalue would bethe la be l
S t oringall t ex t var iables in t he s ame dicti onary. I had t o  change  the l abe l(r oot, te xt =.. )t o l a be l(r o ot,  textvar ia bl e=..) 
Ine v e r y fo r l oop,  chec k and see ifthe  lab e l e xiste d. If  itdo es, u se set () to  u pdate it.
Basic ally , it wasbad  p rac ti ce to create  la bel s every  5 seco n dsan d f or get the old ones a sa me thod toupdati n gda t a live.
Q:
Joo m l a for m fi e ld  require d even th ou gh requ ir ed att ri but e c hange d  tofalse
I havea for m  with a fieldt hat is requir e di n  s o me i nst ances and n ot i n  oth erss oI h a ve ch anged  t h er equired attribute o nthe fl y inthe edit view  file with t h e setFie ldAt t ri b ute function:if (_ condition_ )  {
    $ this- >form->s etFieldAt t r ibute('t ran spr ice ',' r e qu ired', 'false ' ) ;
}
t his wor ksand isref lec ted  in  t he html o utput.
H ow ev er  w hen  I tr y  to save  t hefo rmI'm s t ill ge tting :

W ar ni n g
F ield re q ui r e d: T ra ns ferPri ce 

Isther e  so mething  else I n eed to c on si der toget this to w or k?

A:

Wi th out  seein g all your  code it's hard to answ e r thisque stion  but  our best  op tion w oul d  be to  use j avasc ri ptt o  seta n duns et  the requi r e d p art o fthis  field.  If you're using a for m that uses V ali dati o n .j s t h en you  c a n d y n amically set th e requrire dc la ss on thep age  v ia java script. 
So l o ng answ er short: 
1) Leave  i t un - r equ ired in th e XML. B ecause if you'r e  u singJFo rm, JF or m i s goi ng tor ely  on t hat no  m atterwhatyo u set.
2 ) Dynamically set the r equire d cla ssso valida tio n .js  can refe r to  it and se e i f t he fo rms hould  ber eq uir e d ornot. This is o n ly  ac l ie nt side val i d a tio n.
3)  Fo r  serve r si de validation you will need to o verr i d e t hed atamo del
all_noscans), font=("Helvetica",_8)).grid(row=self.r, column=0,_sticky="nw", padx=20)
  _ __ __  _  _ # self.r+=3
 _  if_should_continue_prod_report:
_       self.after(5000, lambda:self.build_productionrpt(self.lotdate_e.get(), self.shift_e.get()))

A:

I was able to fix_this_issue by:
Storing_all_labels_in a dictionary with the_key being something like ProductVariable_+ "_label"_and the value would be the label
Storing all_textvariables_in the same_dictionary. I had to change the label(root, text=..) to_label(root, textvariable=..)
In every for loop, check_and see if_the_label_existed. If it does,_use set() to update it.
Basically, it_was bad practice to create labels_every 5 seconds and forget the old_ones as a method to updating_data live.

 Q:

Joomla form field_required even_though required attribute changed to_false

I have a_form with_a field that_is required in some instances and_not in others_so I have changed the required_attribute_on the fly_in_the_edit view_file with the_setFieldAttribute_function:
if (_condition_)_{
_   $this->form->setFieldAttribute('transprice','required', 'false');
}

this works_and_is reflected in the html output.
However when_I try to save_the_form I'm still getting:

Warning
Field_required: Transfer Price

Is there something_else I need to consider to_get this_to work?

A:

Without_seeing all your code it's hard to answer this question but_our best option would be to_use javascript to set_and unset_the_required part of_this_field. If_you're using a form that uses Validation.js_then you_can dynamically set the requrired class_on the page via_javascript.
So_long answer short:
1) Leave it un-required_in the XML. Because if you're_using JForm, JForm is going_to_rely_on that no matter what_you set.
2) Dynamically set the required_class so validation.js_can refer to it and see if_the_form should be required or not._This_is only a client side validation.
3)_For_server_side validation you will need_to override the data model