Do telephony-service setup and it will build the basic config. for pri, you need to know how many digits DID you have and how your extensions are.
network-clock-participate wic X
network-clock-select E1 0/X/0
card-type E1 X
controller E1 0/X/0
For the rest need to know how your extensions looks like.
If you only want to connect all and any call to 777, just configure "connection plar 777" under voice port x/y/z.
As an appreciation to those providing answers, please rate useful posts with the scrollbox below!
Under telephony service
dialplan-pattern 1 04xxxxx.. extension-length 3 extension-pattern 7..
xxx has to be replaced with your number. If that doesn't work you need to take "debug isdn q931" with "term mon" for an incoming call.