* admin users with is_master = 0, cannot see other admin users
(this includes system users) and brings the is_master flag
to the common behaviour
* ccareadmin, ccare users can now access te UI Admins page
as well as /api/admins but they are limited to see/manage
only themselves
* admin users cannot see system users (UI/API)
* reseller users cannot see system/admin users (UI/API)
* admin users cannot modify their own role and flags except for:
email, password, can_reset_password (UI/API)
* UI edit form now does not render fields that are not meant to be
modified by a user (exception: "login")
Change-Id: I82e1946437fd2ec4651abd24074470c695a40582
Otherwise administrative subscribers cannot change Customer
preferences on JS CSC, while they were able to do it in Perl CSC.
It is a side effect of commin 27da72e41b in ngcp-panel.git.
Change-Id: I7da3bd3fbd9f56353cd9332d3f85489eaf8bd8b1
If accordion is fully opened and we are closing one element,
ngcp-panel was removing orange background from all orange
accordion items (keeping all of them open). It was abnormal.
Let's use the common logic:
- if accordion item "open" -> it should have orange background.
- if accordion item "closed" -> it should have gray background.
Change-Id: Ice689dd470711ad6c37bdb80da83297b60274a92
Otherwise the attribute 'open' has been removed from class '.accordion-group'
when user removes mouse from element 'search/from/to' (the 'hide' event is triggered).
Ngcp-panel should remove orange background on manual click to close accordion,
this is why we are validating 'e.target' to ignore tooltip events.
Change-Id: I04bee203f3e5a51eee66158c775ef6158b578a18
* subscriber/preferences.tt and helper/pref_table.tt
contained directly rendered data, without using
helper/datatable.tt, leading to unescaped html in
rendered data values. such cases are now fixed
by using tt2 html filter
Change-Id: If266903cc5df754c6e6fe6b8363398b9e4f3236c
Previously ngcp-panel didn't restore the lastTab collapse state properly,
as a result the restored tab kept opened during the further navigation on WEB.
Change-Id: I476ea9939f2cae13baeb60a81f31ab6813aa097f
Otherwise it is hard to navigate through ngcp-panel due to
different orientation of datatables.
Also add a link to switch to Reseller from Customer object
(like we have to switch from Customer to Contracts/Domain/...).
Change-Id: I1e30a2c3518310ee08e0608bcead99ed39e1c481
* Login CSC v2 button is shown on the subscriber's master
data page if www_admin.http_csc.csc_js_enable == 1 or 2
* When the login is triggered an auth token
is generated internally followed by a redirect to
CSC as /?a=auth_token
* move generate_auth_token() into Utils/Auth
* improve generate_auth_token() arguments support
* add /api/authtokens error handling
Change-Id: Idd65400bf8ce6ce48979c736f6a199fb567ffaa4
It was close to impossible to read ngcp-panel debug log due to:
* missing clear marker of the start reuqest processing, use '***' once only
* some personal markers (like '+++++++') have been removed as they have no
meaning for other developers. Let's remove the personal markers and work to
make the panel debug log well readable for all developers.
Change-Id: I69faff3ab2258fc156e88c7b8da0edfef14c3e6e
Presto Opera is no longer supported by Opera.
They have been migrated to Opera Next long time ago (Chromium codebase).
Change-Id: I433e77e2d5295f2d97901e4e2ce58b857fa9281d
Otherwise those elements are not translated.
Note all the rest elemets are translated in
share/static/js/i18n/dataTables.*.js files.
Also date format hint 'YYYY-MM-DD' has been localised too.
Change-Id: I1b8655be15aa9f3693905bc508d0b7dde6af246e
On CSC v1 the page has name/title 'Customer Details'
and the menu item was 'Customer Settings'.
On CSC v2 it is 'Customer Details'.
Let's sync all the places. As it is read-only customer
details, let's call it 'Customer Details' everywhere.
Change-Id: I759f1da0662660b1f389765a6f9daf250c940ddc
Historically ngcp-panel hides both 'Upload CVS' and 'Download CVS' buttons for
pages call list suppression and phone book but hides no buttons at all for emergency mapping and lnp.
Let's synchronize the behaviour to prevent any kind of confusing.
Change-Id: I44efbb1606ee4db3be03e0edb2488ef27bf20485
The ngcp-panel had never supported any kind of plugins
and the functionality 'Sign Up' was never available.
Removing it to prevent any kind of confusion.
Change-Id: Ia022c36fd1d51ffa6582ef0c354efdfe8d9c2e96
JS CSC needs JWT token and backend is not compatible here (yet).
Let's hide the button 'Login to CSC' if JS CSC is a default UI.
Change-Id: I8c7bcf194c3cfee1ccb47eddaf25c9971f4cf19e
The in field testing showed the following pager numbers for the best usability:
FullHD:
* v1/iframe: 15 elements per page is the best
* v2: 18 elements per page (will be 20 after removal "GO TO OLD ADMIN PANEL" banner)
2K:
* v1/iframe: 20 elements per page
* v2: 25 elements per page
4K:
* v1/iframe: 35 is the best
* v2: 50 elements per page (45 actually, but 35/50 can be used for now).
Change-Id: Ibcc0c9bd663d477151ea3449cb2e82e8276ec079
* upon pressing the button, a new session object
with selected subscriber's details will be inserted
in Redis, and also a new ngcp-panel_subscriber
cookie will be created containing the session id
of the previously created session object; then
the user will be redirected to CSC v1 address
where the selected subscriber will be authenticated
based on the cookie and Redis info
* the new button will be available for admin,
reseller, ccare and ccareadmin roles
Change-Id: I03952efe4abe18e61884859c466d700a7885ead4
* /api/platforminfo does not have its own endpoint file
and therefore, does not appear in the rendered documentation.
it only supports GET method and renders the template file.
the endpoint is designed to provide with the prerendered JSON
data containing the current platform configuration.
* /api/platforminfo supports both authenticated and anonymous
requests, where based on that, the template provides with
the corresponding info withing the current scope.
Change-Id: Idc8138595eda2c14e7f8dc7ed97cc50039fd1adc
Dialogic doesn't exist anymore, it is Sangoma for more than a year.
IMS/SS7/Dialogic was never finished. Let's hide the button for now.
Change-Id: I01c69d984a6dc99dbfd420b64e659f2c463c74e8
It worked unreliable in the past (~50% of time maximised and
50% of time is minimised). The changes makes it reliable.
Huge thank you to Sergii Leonenko for the fix!
Change-Id: I35ffb6632565851592406acb4bd9d3c7bc8d8c03
No security issues noticed here, those buttons lead to "403 Access Denied",
still it is nice to hide them otherwise it looks unprofessional.
Change-Id: I65a1d0f25c9eeace3fc9b32636f11373ed390d8a
Otherwise we might get elements from the previous table,
the one example has been described in a ticket:
The "Phonebook" datatable had "Download" button from "Invoices".
Change-Id: I6961d7bda209b8ff95600f56036185566b520f52
The 'Back' button on level 3 "Subscriber Profile - Preferences"
should move users to level 2 and not to level 1.
level 1: Subscriber Profile Sets
level 2: - Subscriber Profiles for Profile Set
level 3: --- Subscriber Profile - Preferences
Change-Id: Iac5bc38644ea24b4a854da160f7aa56e96be01e9
After the recent migration to new Grafana the old link produces: 'Dashboard not found'.
It is a fixup for the commit e4cfc9842a
> TT#51065 Update grafana dashboard URLs for grafana 5.x
Let's also sync param 'ngcp_grafana_admin=no' for all links.
Change-Id: I7be1a021cff154093ee41bc57bbbb7482eda9954
Also perform fine tunning for 'Reseller details' page
to have identical layout with 'Customer details'.
Change-Id: I87f3bd9f45431e7093f108e91ac97d85167495f1
The Reseller object received Breadcrumbs on ngcp-admin-ui and
the v1 navigation elements are no longer necessary for iframed/framed=1 output.
In the feature we will also move 'Expand/Collapse Groups' button to v2,
while at the moment we still have to keep it inside framed output.
Change-Id: Ia65a5f9b92242900c978ff7435fc46e3ed205043
* in mRender (custom_renderers), "data" variable is
a string, therefore data.escapeHtml could not be used
* add new function argument "opt", where it is a dedicated hash
containing custom passable options, so it now looks as
function(data, type, full, opt)
* adapted the existing code to include/use the new argument where
applicable
Change-Id: I4957eece3b2d0f6359cbc8f36caf5a350d7bad95
* add color pickers and store the hex code of the colors
inside the branding table in panel UI
* implement /api/resellerbrandings endpoint, where all things
related to reseller branding can be managed; the branding
logo will still be retrieved using /api/resellerrandinglogos
Change-Id: Ib7ed364811acf67ffd62252d9799a0af8b91e9bc
The localization was missing for the following lines:
> <p>ANY of the rules must match to choose the peering group for outbound calls.</p>
> <p>ALL of the rules must match to choose the peering group for inbound calls.</p>
Committing them to test translation of new messages on crowdin.com.
Change-Id: I5fef746f38d09ddb1ce27131758f104bf0f7bdeb
* Keep all buttons in the same "line".
* Add localization for all strings on the page.
* Align the code accordingly to the Sipwise code style.
Change-Id: I60df82b0a9f75b353ccf30d9ad5a7a94d05f46f4
* Create upload and content type form fields for 'blob'
type preferences
* Implement blob preference upload/download to database
* Show blob content in read only text area if content
is text
Change-Id: Ic4b800f84324eab0aadbf8eeb55c03c770ecc94f
* Devices already had these buttons in Customer -> PBX Devices;
creating same buttons for Device Management -> Deployed Devices
simplifies testing a lot
Change-Id: I5db3a8584821058db12225cae4e3ff201a9643f2
The min/max buttons did not work for dynamic block.
It is a regression of the initial commit d0f339eef7 and 6f2cc8b717.
Fixing it by removing min\max buttons from dynamic popups. It looks like the information on those popups will not look better after maximization (subscriber prefferences \ CallForwarding section \ question mark icons to activate popups).
Change-Id: Idca62bf55a411d12e7f75b240c0a139bb22c8874
We have two pop-up declarations in modal.tt: default & dynamic.
The min/max buttons order was wrong for dynamic block.
It is a regression of the initial commit d0f339eef7
Fixing it by aligning dynamic block with the default one.
Change-Id: I134ec88ad8c40ae5a560a406608543f556694e2c
Add missing title and use the same style buttons with better padding:
x - close
+ - maximize
- - minimize
Change-Id: I8d15d90f00f0d8ba452bfbd75c40e0780599ae95
It will improve end-users usability significantly.
The code created by Sergii Leonenko <sleonenko@sipwise.com>, THANK YOU!
Change-Id: Ifc083fd53df5392791728ea102591fb6aa764dab
* on administrator login, store said variables so
we can automatically log in to v2 without having
to redirect
Change-Id: I50d79996198561c54e555d264388d26610905ca6
The dashboard is the default page which user see on login.
Unfortunately, the current v1 padding 30px looks miss-aligned on v2.
Let's remove the padding here to improve v2 first impression.
As side effect here: dashboard will use full page on v2,
which actually looks pretty nice on v2. Let's give it a try.
Change-Id: I6345986955a5a1783ec98be55f2273778101b83b
* In view mode, webpaswords are shown as '******'
* In edit mode, the generated or written password
is hidden
* A button with an eye icon can change wether the
password is shown or not
* When pushing 'Generate' button show '(modified)'
after the input
Change-Id: I494d61b0ea5808a1be0f518d0667bf75b9ab20d5
* The endpoint generates a jwt token and stores it in
Redis, then redirects to /v2/#/?v1_auth={token}
* Also added an id in DOM to indentify the Panel V1 login page
Change-Id: I307a3f457f88bbba04bb7735d60fa51bdc5d0438
* if there are no more *enabled* CFT left after editing
callforwards (simple/advanced) or if CFT is deleted,
the ringtimeout has to be removed.
Change-Id: Icfa2fb1db281a5a5b4b2edce28ad7b0d69ddf47c
* new c.users.role 'lintercept', that set to when an admin user has
enabled 'lawful_intercept' flag
* only Administrator page /api/admins and /api/interceptions are available for
the role
* 'lintercept' role can only see own user and only change password
and email
Change-Id: Iadcb022a124afbd77b224e734026f380af0170e8
- also show page description/location for proxied pages,
like: "Subscriber Preferences for carol@10.0.0.1".
It significantly improves user experience/understanding
about the current location.
- restore missing button "Expand Groups" for proxied 'accordion' pages
- restore missing confirmation "Are you sure?" for proxied pages
- fix main navigation buttons layout to have proper padding on proxied pages
- fix missing "Edit" button on all pages for proxied mode
Change-Id: I0df8cd37abdd0eebfd90b8c3e9f38daa1c97cc2d
We have several pages with Create/Download/Upload buttons,
for example the page 'Phonebook' has the proper buttons order
in one line layout:
> [Create] [Download] [Upload]
while on the page 'Call List Suppressions' it was two lines:
> [Download] [Upload]
> [Create]
Let's use common buttons order on page 'Call List Suppressions'.
Change-Id: Ic6828a8c825590df43879e20dfb7ea7622db568f
All the top buttons "Create", "Download", "Upload" were displayed with
the wrong positioning due to "margin-left: -30px;" in bootstrap-responsive.css.
Most probably it was some workaround from the middle ages and
it is not a time to refactor it and provide the "proper fix" here
as we are trying to deprecate the old admin panel interface completely.
Those margin-left has been introduced in the very first commit f33ed459 back to 2013.
Let's mute the annoying margin-left padding for the admin-ui case framed=1.
Change-Id: I7a9cae804587515bf380da1ccb2672784c2431c0
The initial commit d31797c tried to hide back button using helper 'datatables'
while some ngcp-panel pages have separate 'back' button definition.
Let's mute all of them for ngcp-admin-ui case (framed=1).
Change-Id: Ib2ed3e9362a26a1c4a353e2f615138f8b6ab6461
* Introduce endopint '/resetpassword' for asking for
password reset using admin username
* Create form for introducing username
* Create url with unique token pointing to '/recoverpassword'
where admin user can introduce new password and email
said url to admin's email address
* Create form for setting new password
* Store username and unique token in Redis expiring
in 5 minutes to store password reset attempt
and identify it when user accesses url in email
* Limit admin access to be able to only change own password
due to new password reset possibility as requested in
TT#76110
Change-Id: Ie3acb961444398afa5b2fdc85e3ca8ceccf9244a
* Remove headers, menu, site title and footer if
parameter 'framed' is sent
* Persist 'framed' in the session once it's sent
and only restore header/footer once 'framed' is
sent again with the value 0
Change-Id: Ie1dcc698b901ea3c659a05391ffcdc882113ef13
- persist prov tmeplates in the database: create, update
and permanently remove them again.
- prov templates from config.yml are still supported,
but cannot be edited though. the templates from
config.yml are merged with those from the db.
- each reseller can have their own prov templates,
while the prov templates from config.yml are visible
to all.
- YAML syntax highlighting and parse check when saving.
Scripting language (perl/javascript) is currently parsed
when executing a provisioning templates only. It is
possible to further extend the parsing checks.
- the prov template "name" + reseller is the unique
identifier. relevant also for the command line tool.
Change-Id: I58d7c54fa82fe512b263b3219bfc84d7e49c56a8
* Change the way webpassword is handled accross
NGCP Panel UI/API to comply with new password
encryption
* At login, if password is not encrypted with
high cost due to the ngcp-bcrypt-webpassword
script, encrypt it with proper cost
* Accept old password format as well until all
webpasswords are encrypted
Change-Id: Iefa9584a62ab4b7d2a224d10bdd415e9cbb8dfb5
* The search field was disabled because of long
time filtering duration when caching it for calls
but it is desirable to cache it in other places
* Added condition to not cache the field only in
calls table
Change-Id: I7a359c60f5fcc016fe37a587905ac06e2e81a366
Even if kamailo supports negative q-value it will handle them
as positive one creating confusion in customers.
Change-Id: Ia74f798c48191af1aacca5660448b664883b9860
* Enabled stateSave but only for row
number because it was previously
disabled for caching the search box
Change-Id: Ie1bd42dc890bd574167db3a073f8350c3d90f043
* Change datepicker to datetimepicker
to be able to select time as well
* datetimepicker is now available only
for call lists since this is where
a more thorough filtering is needed
in case the limit of 1000 entries is
passed
Change-Id: I48107fa8f7c4d4ee9b40044c8ae5f7842e35c2a5
* Remove '(details)' and make the status
text clickable
* If no errors, don't make status clickable
and not show the modal
Change-Id: I1ae1d05231aea450f99649996acdb63fcd2e6f75