Need To Alter Candidate's Field & Input type.

Please describe the issue you're having
If you accept the answer, please mark the topic as [SOLVED] by clicking the tick.

Moderators: RussH, cptr13

Forum rules
Just please remember to play nicely once you walk through the door. You can disagree with us, or any other commenters in this forum, but respect our space and keep your comments directed to the topic at hand.
User avatar
cptr13
Posts: 412
Joined: 23 Apr 2008, 01:53
what is two(2) plus three(3) ?: 5
Location: Mobile, AL
Contact:

Re: Need To Alter Candidate's Field & Input type.

Post by cptr13 » 20 Sep 2017, 16:59

Ok got it.

Go into modules/candidates/Add.tpl

For middle name: Remove the following:
<tr>
<td class="tdVertical">
<label id="middleNameLabel" for="middleName">Middle Name:</label>
</td>
<td class="tdData">
<input type="text" tabindex="2" name="middleName" id="middleName" class="inputbox" style="width: 150px" value="<?php if(isset($this->preassignedFields['middleName'])) $this->_($this->preassignedFields['middleName']); ?>" />
</td>
</tr>

For 2nd email, remove the following:
<tr>
<td class="tdVertical">
<label id="email2Label" for="email2">2nd E-Mail:</label>
</td>
<td class="tdData">
<input type="text" tabindex="4" name="email2" id="email2" class="inputbox" style="width: 150px" value="<?php if (isset($this->preassignedFields['email2'])) $this->_($this->preassignedFields['email2']); ?>" onchange="checkEmailAlreadyInSystem(this.value);" />
</td>
</tr>


You can remove any of the fields from that screen like this.

karthikjoe
Posts: 40
Joined: 19 Jul 2017, 05:31
what is two(2) plus three(3) ?: 5
Location: Madurai,Tamilnadu,India

Re: Need To Alter Candidate's Field & Input type.

Post by karthikjoe » 21 Sep 2017, 15:21

Thanks Cptr13

Its Working superb. But Another one thing how can i change field names and input types..?.i think there are several files & Databases are linked field name. Is This possible..?

User avatar
cptr13
Posts: 412
Joined: 23 Apr 2008, 01:53
what is two(2) plus three(3) ?: 5
Location: Mobile, AL
Contact:

Re: Need To Alter Candidate's Field & Input type.

Post by cptr13 » 21 Sep 2017, 15:23

I'm not clear on your question.

You want to change existing? Or add new?

Adding a new one is pretty simple.

Changing existing, I'd have to look and get back to you

karthikjoe
Posts: 40
Joined: 19 Jul 2017, 05:31
what is two(2) plus three(3) ?: 5
Location: Madurai,Tamilnadu,India

Re: Need To Alter Candidate's Field & Input type.

Post by karthikjoe » 22 Sep 2017, 06:33

Hi Cptr13

I am looking for change a existing fields...

User avatar
cptr13
Posts: 412
Joined: 23 Apr 2008, 01:53
what is two(2) plus three(3) ?: 5
Location: Mobile, AL
Contact:

Re: Need To Alter Candidate's Field & Input type.

Post by cptr13 » 22 Sep 2017, 10:12

Ok.

I think I would recommend not changing existing fields.

Unless.

If the purpose of the field stays the same, and you are only changing the word that's is labeled...it would be ok.

I am using the Add candidate screen for examples. The principle is the same across OpenCATs though.

For example, if you wanted to change the "Cell Phone" to "Mobile phone". That would be ok.
If you wanted to change the "cell phone" field to "favorite food", it may get weird.

The reason why, is that if you change the front end stuff (what you see on the web interface) but you don't change the back end stuff (what goes in to the database), OpenCATS will call it "favorite food" on the front, but think it's "cell phone" in the database.

I'm not a programmer, so I don't know how that would affect things, if at all.

See next post for more information.

User avatar
cptr13
Posts: 412
Joined: 23 Apr 2008, 01:53
what is two(2) plus three(3) ?: 5
Location: Mobile, AL
Contact:

Re: Need To Alter Candidate's Field & Input type.

Post by cptr13 » 22 Sep 2017, 10:45

This is a minor edit example. I am using the prior "Cell Phone" to "Mobile Phone" to show.

Again, this is fine, because the intent isn't changing, therefore, no database changes are necessary.

If we want to change all the labels from "Cell Phone" to "Mobile Phone" we have to make changes for a few screens.

We need to find the "Cell Phone" on the following files and change them to "Mobile phone"

BE CAREFUL TO NOT CHANGE ANYTHING ELSE!!!!!

Example from Modules/contacts/Edit.tpl:
<tr>
<td class="tdVertical">
<label id="phoneCellLabel" for="phoneCell">Mobile Phone:</label>
</td>
<td class="tdData">
<input type="text" name="phoneCell" id="phoneCell" value="<?php $this->_($this->data['phoneCell']); ?>" class="inputbox" style="width: 150px" />
</td>
</tr>

That is the only change to make here. That's what appears on your screen. The other cell references or programming stuff which may affect the functionality.


For candidates, change:
Modules/candidates/Add.tpl

modules/candidates/Show.tpl

modules/import/ImportUI.php

modules/candidates/Edit.tpl

For company contacts, also change:
modules/contacts/Add.tpl

modules/companies/Show.tpl

modules/contacts/Show.tpl

modules/contacts/Edit.tpl

User avatar
cptr13
Posts: 412
Joined: 23 Apr 2008, 01:53
what is two(2) plus three(3) ?: 5
Location: Mobile, AL
Contact:

Re: Need To Alter Candidate's Field & Input type.

Post by cptr13 » 22 Sep 2017, 10:49

Also, please start a separate post for the pdf upload question

karthikjoe
Posts: 40
Joined: 19 Jul 2017, 05:31
what is two(2) plus three(3) ?: 5
Location: Madurai,Tamilnadu,India

Re: Need To Alter Candidate's Field & Input type.

Post by karthikjoe » 23 Sep 2017, 08:07

Thanks Cptr13 for your valuable reply.. It's Working awesome now.

Post Reply