def BasicData( *args ): # For entering of lps, head, PS type and produce rest or an update of just one of these fetchGUI_data() # This is the only widget call permissable untill there is enough data to work with. See site.initial_data permits unlocking rest of widgets siteGUI.GUI_process_option = 'basicdata' process_here() if (siteGUI.GUI_initial_data == 0): # Now unblock rest of gui dialouge for user to update with own site data dialouge.pipe_head_entry.config(state='NORMAL') dialouge.pipe_len_entry.config(state='NORMAL') dialouge.pipe_dia_entry.config(state='NORMAL') dialouge.pipe_height_entry.config(state='NORMAL') dialouge.Num_LH_entry.config(state='NORMAL') dialouge.load_Vmin_entry.config(state='NORMAL') dialouge.design_cable_eff_entry.config(state='NORMAL') dialouge.cable_len_entry.config(state='NORMAL') dialouge.cable_material_entry.config(state='NORMAL') dialouge.cable_size_entry.config(state='NORMAL') dialouge.cable_AWG_entry.config(state='NORMAL') #dialouge.Lock_pipe_entry.config( state=NORMAL) #dialouge.LockNumLH_entry.config( state=NORMAL) #dialouge.LockCable_entry.config( state=NORMAL) putGUI_data()
siteGUI.GUI_cable_mm_title) + "\", " response += "\"cable_AWG_title\" : \"" + str( siteGUI.GUI_cable_AWG_title) + "\", " response += "\"cable_dia_mm_sld\" : \"" + str( siteGUI.GUI_cable_dia_mm_sld) + "\", " response += "\"cable_dia_mm_str\" : \"" + str( siteGUI.GUI_cable_dia_mm_str) + "\", " response += "\"cable_dia_in_sld\" : \"" + str( siteGUI.GUI_cable_dia_in_sld) + "\", " response += "\"cable_dia_in_str\" : \"" + str( siteGUI.GUI_cable_dia_in_str) + "\", " response += "\"cable_A\" : \"" + str(siteGUI.GUI_cable_A) + "\", " response += "\"actual_cable_eff\" : \"" + str( siteGUI.GUI_actual_cable_eff) + "\", " response += "\"Load_pwr\" : \"" + str(siteGUI.GUI_Load_pwr) + "\", " response += "\"design_notes_hydro\" : \"" + re.sub( '\s{2,}|\r|\n', ' ', siteGUI.GUI_design_notes_hydro) + "\", " response += "\"design_notes_elec\" : \"" + re.sub( '\s{2,}|\r|\n', ' ', siteGUI.GUI_design_notes_elec) + "\", " response += "\"design_notes_safety\" : \"" + re.sub( '\s{2,}|\r|\n', ' ', siteGUI.GUI_design_notes_safety) + "\"" response += "}" return response print("Content-Type: text/plain\n") fetchHTTP_data() process_here() print(putHTTP_data())
def newAWG(*args): fetchGUI_data() siteGUI.GUI_process_option = 'NewCableAWG' process_here() putGUI_data()
def newcablesize(*args): fetchGUI_data() siteGUI.GUI_process_option = 'NewCablesize' process_here() putGUI_data()
def newcablematerial(*args): fetchGUI_data() siteGUI.GUI_process_option = 'NewCableMaterial' process_here() putGUI_data()
def LockCable(*args): fetchGUI_data() siteGUI.GUI_process_option = 'CableLock' process_here() putGUI_data()
def newcableeff(*args): fetchGUI_data() siteGUI.GUI_process_option = 'SetCableEff' process_here() putGUI_data()
def LockNumLH(*args): fetchGUI_data() siteGUI.GUI_process_option = 'SetLockNumLH' process_here() putGUI_data()
def newNoPS(*args): fetchGUI_data() siteGUI.GUI_process_option = 'SetNumLH' process_here() putGUI_data()
def PipeFlume_sel(*args): fetchGUI_data() siteGUI.GUI_process_option = 'pipe_dia' process_here() putGUI_data()
def newpendia(*args): fetchGUI_data() siteGUI.GUI_process_option = 'pipe_dia' process_here() putGUI_data()
def newpipelen(*args): fetchGUI_data() siteGUI.GUI_process_option = 'pipelen' process_here() putGUI_data()
def units(*args): fetchGUI_data() siteGUI.GUI_process_option = 'basicdata' process_here() putGUI_data()