cancel
Showing results for 
Search instead for 
Did you mean: 

Adding fields in appresousrces.xml

Former Member
0 Kudos

Hi,

I am having a problem trying to add a new field to the appresources.xml. I have amended the downloadscheme.xml and the sql database is showing the new field. But when I go to the data element "employee details" and add the field. It errors when I try and encrypt it back. It is in the database as PersonnelSubarea but it doesn't like the name is appresources. Should I be using the sap field in the admin console of BTRTL?

Also where would I go to chnage the welcome page - i.e text and addition of a logo?

Many Thanks

Accepted Solutions (0)

Answers (13)

Answers (13)

Former Member
0 Kudos

Hi Luke,

You'll be please to know I got it working Thanks for bearing with me. I am looking at ammending the welcome page as mentioned earlier. The welcomepage.apsx is this were you make the text changes and logo additions?

Thanks lots

lukemarson
Active Contributor
0 Kudos

Most of the WelcomePage.aspx file is HTML, particularly the bits where you will want to add content, so it should be straight forward to edit.

Former Member
0 Kudos

Hi Luke,

I have found the detaildata section for Employeedetails and it says the data element is EmployeeDetails which is where I added my new field PersonnelSubarea but looking at the snippet below it didn't seem to have this field there. Should I add it?

<detaildata name="EmployeeDetailsData">

<dataelement>EmployeeDetailsDataElement</dataelement>

<fieldsets>

<fieldset name="EmployeeName" max="0">

<field name="PositionStext" />

<field name="EmpNameF" />

</fieldset>

<fieldset name="EmployeeInformation" max="0">

<field name="Pernr" />

<field name="LastName" />

<field name="FirstName" />

<field name="Position" />

<field name="PositionStext" />

<field name="OrgUnit" />

<field name="OrgUnitStext" />

<field name="Job" />

<field name="JobStext" />

<field name="PersonnelArea" />

Thanks

Former Member
0 Kudos

Hi Luke,

I have found the detaildata section for Employeedetails and it says the data element is EmployeeDetails which is where I added my new field PersonnelSubarea but looking at the snippet below it didn't seem to have this field there. Should I add it?

<detaildata name="EmployeeDetailsData">

<dataelement>EmployeeDetailsDataElement</dataelement>

<fieldsets>

<fieldset name="EmployeeName" max="0">

<field name="PositionStext" />

<field name="EmpNameF" />

</fieldset>

<fieldset name="EmployeeInformation" max="0">

<field name="Pernr" />

<field name="LastName" />

<field name="FirstName" />

<field name="Position" />

<field name="PositionStext" />

<field name="OrgUnit" />

<field name="OrgUnitStext" />

<field name="Job" />

<field name="JobStext" />

<field name="PersonnelArea" />

Thanks

Former Member
0 Kudos

Hi Luke,

I have found the detaildata section for Employeedetails and it says the data element is EmployeeDetails which is where I added my new field PersonnelSubarea but looking at the snippet below it didn't seem to have this field there. Should I add it?

<detaildata name="EmployeeDetailsData">

<dataelement>EmployeeDetailsDataElement</dataelement>

<fieldsets>

<fieldset name="EmployeeName" max="0">

<field name="PositionStext" />

<field name="EmpNameF" />

</fieldset>

<fieldset name="EmployeeInformation" max="0">

<field name="Pernr" />

<field name="LastName" />

<field name="FirstName" />

<field name="Position" />

<field name="PositionStext" />

<field name="OrgUnit" />

<field name="OrgUnitStext" />

<field name="Job" />

<field name="JobStext" />

<field name="PersonnelArea" />

Thanks

Former Member
0 Kudos

Hi Luke,

I have found the detaildata section for Employeedetails and it says the data element is EmployeeDetails which is where I added my new field PersonnelSubarea but looking at the snippet below it didn't seem to have this field there. Should I add it?

<detaildata name="EmployeeDetailsData">

<dataelement>EmployeeDetailsDataElement</dataelement>

<fieldsets>

<fieldset name="EmployeeName" max="0">

<field name="PositionStext" />

<field name="EmpNameF" />

</fieldset>

<fieldset name="EmployeeInformation" max="0">

<field name="Pernr" />

<field name="LastName" />

<field name="FirstName" />

<field name="Position" />

<field name="PositionStext" />

<field name="OrgUnit" />

<field name="OrgUnitStext" />

<field name="Job" />

<field name="JobStext" />

<field name="PersonnelArea" />

Thanks

Former Member
0 Kudos

Hi Luke,

Near the top of my appresources.xml I have found the details panel object (employeedetails):

<dataelement name="EmployeeDetailsDataElement" webservice="False">

<cacherequests><![CDATA[True]]></cacherequests>

<connection><![CDATA[DestinationConnection]]></connection>

<table><![CDATA[EmpDetailsCombined]]></table>

<casesensitive>False</casesensitive>

<filter><![CDATA[]]></filter>

<dynamicfilter><![CDATA[]]></dynamicfilter>

<objectclass><![CDATA[]]></objectclass>

<relativednfield><![CDATA[]]></relativednfield>

<fields>

So I added the field to the other fields below this. Obviously this is incorrect but when you say follow the chain to get to the data element I don't know what I would be looking for. Could you point me in the right direction?

Thanks

lukemarson
Active Contributor
0 Kudos

Refer to my post at 12:13 for how to find this.

Former Member
0 Kudos

Hi Luke,

I have checked appresources.xml and found employeedetails data element it used the table EmpDetailsCombined and (which is where my new filed is in the data base so I have added the field to that data element. How would I check the deatiled data which you advised to do? Can't see where I'm going wrong?

lukemarson
Active Contributor
0 Kudos

It doesn't matter what the data element is called - that might not be the name of the detail that uses it. You have to follow the chain as I mentioned in my previous post.

Find the object you are adding the detail to (ie the details panel) and then follow the chain though the AppResources.xml until you get to your data element. Without seeing your entire AppResources.xml I cannot help.

Former Member
0 Kudos

How do you mean? I added the field to employee detaails data element like you previosuly advised. When I hoover over the box in deatils designer it says emloyee details.

lukemarson
Active Contributor
0 Kudos

This is the basic structure of how the application configuration works for OrgChart. You have a data element which is used by detaildata which in turn is used by detail sections to display the data.

You should check the EmployeeDetails detail section in AppResources.xml to see which detaildata it uses (I am assuming that this is the detail section "employee details", although it could EmployeeDetails2). Then check the detaildata to see what data element it is using and then add the field to that data element.

If you are adding something to the Position details panel then you can look at the orgchart configuration and find out what the details panel is called. You can then navigate to that detail and see if there is a linked detail called EmployeeDetails or EmployeeDetails2. If not then one of the linked details may have this detail linked to it.

You'll get there eventually!

Former Member
0 Kudos

Hi Luke,

I have done so now and no errors so it encrypted fine. I have run the extractor and published the build but when I go into detailed designer for organisational hieracrchy the field is not showing in employeedetails options.

lukemarson
Active Contributor
0 Kudos

Is it EmployeeDetails2? You need to find what detaildata is used in the EmployeeDetails/EmployeeDetails2 detail and then what data element is used. It may not be the one you've added the field to.

Former Member
0 Kudos

Yes I have ammended in Notepad2 but I don't see any errors at the bottom of the document. It's only when I go to encrypt.

lukemarson
Active Contributor
0 Kudos

Notepad2 is not an XML editor, I mean something like XMLSpy or XML Marker. Internet Explorer will show any malformed XML.

Former Member
0 Kudos

Hi Luke,

Thanks I missed that. I tried again and it errored on encrypting (instance error). I have only added it to the employeedeatils data element should i add it to the other data elements that feed from employteedetails combined (where I have added it in the sql databse.)

Thanks

lukemarson
Active Contributor
0 Kudos

You only need to add it to the data element that you need to use it from. If there is an instance error it is likely to be down to XML syntax issues. Open your AppResources.xml file in Internet Explorer (or an XML editor) and navigate to the bottom of the document. You will find an error where the code is malformed.

Former Member
0 Kudos

Hi Luke,

This is the section I have added to the employeedetails data element:

</field>

</field name="PersonnelSubarea">

<caption key="EmployeeDetailsDataElement_FieldCaption_PersonnelSubarea"><![CDATA[PersonnelSubarea]></caption>

</field>

Thanks

lukemarson
Active Contributor
0 Kudos

Your XML is not formed correctly:

</field name="PersonnelSubarea">

should be

<field name="PersonnelSubarea">

ie no / at the start of field.

lukemarson
Active Contributor
0 Kudos

Hi there,

What is the code you've used in AppResources.xml? It sounds like a syntax error as I've not had this problem before.

WelcomePage.aspx is your welcome page file.

Luke