| | |
| | | Precondition: |
| | | [* |
| | | feedback := Translations::FilllingCapacity_ValidateInput(); |
| | | checkValue := not Coefficient.Text() = '' |
| | | checkValue := not Coefficient.Text() = '' and not PriorityFactorName.Text() = ''; |
| | | |
| | | if(not checkValue ) |
| | | { |
| | | if(not checkValue ){ |
| | | feedback := Translations::PriorityFactor_CheckNameValid(); |
| | | editData := DataHolderEditPriorityFactor.Data(); |
| | | checkValue := not PriorityFactor::CheckNameValid( MacroPlan,editData.BusinessType(),[Real]Coefficient.Text(),PriorityFactorName.Text(),Desc.Text()); |
| | | |
| | | } |
| | | |
| | | if( PriorityFactorName.Text() = ''){ |
| | | feedback := Translations::PriorityFactor_CheckNameNull(); |
| | | } |
| | | return checkValue |
| | | *] |
| | | QuillAction |
| | | { |
| | | Body: |
| | | [* |
| | | Form.ClickBtnOK(); |
| | | if( NewFlag.Checked() ){ |
| | | // New |
| | | repeatOne := select( MacroPlan,PriorityFactor,pf,pf.Name() = PriorityFactorName.Text()); |
| | | if( not isnull( repeatOne )){ |
| | | WebMessageBox::Error( Translations::PriorityFactor_CheckNameValid() ); |
| | | }else{ |
| | | Form.ClickBtnOK(); |
| | | } |
| | | }else { |
| | | if (EditFlag.Checked() and PriorityFactorNameCache.Text() <>PriorityFactorName.Text()){ |
| | | // Edit |
| | | repeatOne:=select(MacroPlan, PriorityFactor, pf, pf.Name() = PriorityFactorName.Text()); |
| | | if (not isnull(repeatOne)){ |
| | | WebMessageBox::Error (Translations::PriorityFactor_CheckNameValid () ); |
| | | }else{ |
| | | Form.ClickBtnOK(); |
| | | } |
| | | }else{ |
| | | Form.ClickBtnOK(); |
| | | } |
| | | } |
| | | *] |
| | | GroupServerCalls: false |
| | | } |