cancel
Showing results for 
Search instead for 
Did you mean: 

NW 7.40: Cannot edit CAF simple type

Former Member
0 Kudos

Hi,

I've a CAF simple type "ApproverType".

In the past I was always able to change enumeration values etc. for the created simple types.

For the complex types this is still possible.

But since we moved to NWDI it appears as non-editable in NWDS (before the lock symbol was not there):

I've found a file called "ApproverType.java" in the CAF EJB package.

But if I add the new enumeration there, the file always gets overwritten when I regenerate the CAF DC.

How can I edit the enumeration values for that simple type?

Thanks in advance.

Best regards,

Thorsten.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Got it:

  1. In NWDS Development Infrastructure perspective: Open file "ca_model.cafmm" in metadata DC and set attribute "Read-only" of Simple Type to false:


  2. Press "Save" and click on "No" in the popup:
  3. Et voilà! Simple types are editable again:

I know that's it's not recommended to edit "ca_model.cafmm".

But it seems that the change didn't harm my CAF model.

Best regards,
Thorsten.

Answers (3)

Answers (3)

ErvinSzolke
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi,

alright, this is what I got:

CAF artifacts in this case reside in the CAF model (ca_model.cafmm). The classes corresponding to them are generated out of the model. You have to check out the model file. It resides in the xxx/metadata DC, but better check out the whole DC. Double check if you checked out this DC exactly.

The other thing might happen is that these types reside in another CAF application. You can have dependencies between CAF applications and the types from one application can be reused in a second application. If the application in which the types originally reside is not checked out or is synched as archive, types cannot be edited.

I hope this helps.

Regards,

Ervin

Former Member
0 Kudos

Thanks, Ervin!

I've tried check out the whole metadata DC:

Afterwards all files are included in the activity:

In DTR I've only the same 3 open activies than in NWDS (actually there're some more, but they seem to be empty):

But in NWDS the Simple Types still appear as non-editable:

As you can see, there's no other CAF DC in this BPM product.

I'm really lost with that...

Maybe I should open a message to SAP.

Best regards,

Thorsten.

Former Member
0 Kudos

Hi Thorsten,

I think a message to SAP is probably the best way forward.  I still can't get my NWDS to even create a new CAF DC so can't help further, however in the past I've found the support guys at SAP are pretty good on issues around NWDI like this (and I've experienced a fair few!)

As an aside, it is stuff like this that perpetuates the negativity towards the SAP Java stack when compared to ABAP.  Such a shame, as CE, BPM, CAF, PO, etc. and all the other SAP Java tools and platforms have so much potential...

Cheers,

G.

Former Member
0 Kudos

This one is still unresolved!

I've tried to put all CAF files into an activity.

There's no other open activity...

But still my old simple data types can't be edited, just for the newly created ApproverType2 it works...

christian_santej
Active Participant
0 Kudos

hi thorsten,

maybe can help you with this issue.

regards,

christian

ErvinSzolke
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Christian,

unfortunately I am not really into CAF, though I am almost sure that if this project is nwdi controlled then one has to go the "checkout-checkin-activate-release-import" way.

I asked around in the meantime, I hope my colleagues can help so I can come back to you with some answers.

Cheers,

Ervin

christian_santej
Active Participant
0 Kudos

hi ervin,

yeah i thought you can help since you're a nwdi-specialist

ty & regards,

christian

Former Member
0 Kudos

Hi Thorsten,

Does your NWDI implementation work correctly with all of your other DC's and objects within them?

I've just launched my local NWDS install to try and look into this for you and can't even create a new CAF DC for some random reason...  Robust definitely isn't the word!

Cheers,

G.

Former Member
0 Kudos

Hi Gareth,

before I switched from local development to NWDI I never faced this issue...

The strange thing is that it's only limited to Simple Types (and only to old ones), Complex Types are still editable...

Best regards,

Thorsten.

christian_santej
Active Participant
0 Kudos

hi thorsten,

i think you have to checkout /create an edit acitivity on the caf Project (metadata and/or ejb) itself. then you should be able to edit the enumartions.

regards,

christian

Former Member
0 Kudos

Hi Christian,

I assigned whole metadata/ejb folder to an activity, but I'm still not able to edit the simple type...

Best regards,

Thorsten.

christian_santej
Active Participant
0 Kudos

hi thorsten,

hmm that's quite strange...

have you tried to create a new workspace? if not - revert/checkin all related activities related to this caf dc, create a new workspace and try it again.

regards,

christian

Former Member
0 Kudos

Hi Christian,

where and how should I create a new workspace?

Meanwhile I've found a workaround:

I've created a copy of "ApproverType":

There I've added the missing enumeration.

But personally I don't like this solution...

The strange thing is that the new type remains editable, whereas the old simple types are all non-editable.

Additionally all complex structures can still be edited.

I don't get this.

Best regards,

Thorsten.

christian_santej
Active Participant
0 Kudos

hi thorsten,


where and how should I create a new workspace?

in your NWDS: File - Switch Workspace - Other... -> select a new folder an create the project again from your sld. then try again to update the simple type

the workaround you've mentioned really can't be the solution since in our environment it is indeed possible to only edit a simple type.

regards,

christian

Former Member
0 Kudos

Hi Christian,

I've just created a new workspace and imported the DCs again from NWDI.

But unfortunately the situation is exactly the same as before!

Can't I somehow edit the source code?

I tried to modify the file ca_model.cafmm, but that didn't work...

Best regards,

Thorsten.

christian_santej
Active Participant
0 Kudos

hi thorsten,

puh - i must say i'm running out of ideas on this...

make sure that your code is synced and builded. also check that there are no other open activities around. then try to exclusively edit all the files in your caf project (metadata,ejb,ear.


I tried to modify the file ca_model.cafmm, but that didn't work...

you shouldn't do that. you could mess up/destroy your caf project.

regards,

christian