Forum Discussion
SalesInfo
7 years agoQrew Assistant Captain
I have to type of tickets: service center ticket and customer ticket. The customer ticket does not have checkbox fields that i want the background to be changed. That's why the background color changed on different fields on the customer ticket. Can you please show me how I can fix this problem?
- EverettPatterso7 years agoQrew CaptainYou should be able to add to the dynamic form rule, if type=customer, then hide the field [-]
By hiding the IOL field [-], it will not call that code page and not highlight anything - EverettPatterso7 years agoQrew CaptainSo both types use the same form? Tickets Main Form?
- SalesInfo7 years agoQrew Assistant Captainyes.
- SalesInfo7 years agoQrew Assistant CaptainI used the dynamic form rule to hide and show the fields based one the input of another field to separate two types of tickets.
I think that I would need to use if-else statement to block a code but not sure how I can handle it. Do you have any idea on how to fix this problem? - SalesInfo7 years agoQrew Assistant CaptainI want the background color to be added only when we select the service center type which I have a html code below. Can you please write me to code with if/else statement to execute the background code only when we select the service center type. If you have another way beside using if/else, that's fine and perfect. Please help. THANKS SO MUCH!
<select onmousedown="CaptureSelectStateIfSafari(event);return true;" onchange=" OnCHF(this);" name="_fid_10" id="_fid_10" onblur="OnBF(this)" onfocus="OnFF(this)" size="1"> <option value=""></option> <option value="Altaquip">Altaquip</option> <option value="Parts to Consumer">Parts to Consumer</option> <option value="Service Center" selected="">Service Center</option> </select>
- SalesInfo7 years agoQrew Assistant CaptainYou're awesome!!! Thanks so much! I am really appreciated for your help and support. It works perfectly as what I want.
- EverettPatterso7 years agoQrew CaptainGlad to help = )
- SalesInfo7 years agoQrew Assistant CaptainEverett,
I have another question relate to the stuffs that we did above. Everything works perfectly fine as what I want. The problem is the background color does not work correctly when I edit the form. You can see below for what I mean. Please advice me on how to fix this.Thanks so much!!
The form is in view mode
The form is in Edit mode - EverettPatterso7 years agoQrew CaptainUse this on your code page, replace the alerts with what you want on each page type
(function(){
//$("img[qbu=module]").remove();
//$("img[qbu=module]").hide();
var querystring=document.location.search;
if (/dlta=mog/i.test(querystring)) {
//GRID EDIT PAGE ========================================
alert("You are on the Grid Edit Page");
} else if(/a=er/i.test(querystring)) {
//EDIT RECORD PAGE ========================================
alert("You are on the Edit Record Page");
} else if (/a=API_GenAddRecordForm/i.test(querystring)) {
//API_GenAddRecordForm PAGE ========================================
alert("You are on the GenAddRecordForm Page!");
} else if (/a=GenNewRecord/i.test(querystring)) {
//ADD RECORD PAGE ========================================
alert("You are on the Add Record Page");
} else if (/a=nwr/i.test(querystring)) {
//ADD RECORD PAGE ========================================
alert("You are on the Add Record Page");
} else if(/a=dr/i.test(querystring)) {
//DISPLAY RECORD PAGE
alert("You are on the Display Record Page");
$("img[qbu=module]").closest("td").css("background-color","#FFFFFF");
} else if(/a=q/i.test(querystring)) {
//REPORT PAGE ========================================
alert("You are on the Report Listing Page");
} else if(/a=td/i.test(querystring)) {
//TABLE DASHBOARD PAGE ========================================
alert("You are on the Table Dashboard Page");
} else if (/a=FinishEditRecord/i.test(querystring)) {
//FINISH EDIT RECORD PAGE ========================================
alert("You are on the Finish Edit Record Page");
} else if (/a=API_GenAddRecordForm/i.test(querystring) {
//API_GenAddRecordForm ========================================
alert("You are on the API_GenAddRecordForm Page");
} else {
//OTHER PAGE ========================================
alert("You are on the Some Other Page");
}
})(); - SalesInfo7 years agoQrew Assistant CaptainSo this means that I don't have to create the field that call iol variables?