viewer/vueapp/src/components/users/UserService.js
/**
   * Creates a specified view for a user
   * @param {Object} data       The new view data to the server
   *                            { name: 'specialview', expression: 'something == somethingelse'}
   * @param {string} userId     The unique identifier for a user
   *                            (only required if not the current user)
   * @returns {Promise} Promise A promise object that signals the completion
   *                            or rejection of the request.
   */
Creates a specified view for a user
@param {Object} data       The new view data to the server
{ name: 'specialview', expression: 'something == somethingelse'}
@param {string} userId     The unique identifier for a user
(only required if not the current user)
@returns {Promise} Promise A promise object that signals the completion
or rejection of the request.
Creates a specified view for a user @param { Object } data The new view data to the server { name : ' specialview ' expression : ' something == somethingelse ' } @param { string } userId The unique identifier for a user ( only required if not the current user ) @returns { Promise } Promise A promise object that signals the completion or rejection of the request .
createView (data, userId) {
    return new Promise((resolve, reject) => {
      const options = {
        url: 'api/user/view',
        method: 'POST',
        data: data,
        params: { userId: userId }
      };
      Vue.axios(options)
        .then((response) => {
          resolve(response.data);
        }, (error) => {
          reject(error);
        });
    });
  }
createView ( data , userId ) { return new Promise ( ( resolve , reject ) => { const options = { url : 'api/user/view' , method : 'POST' , data : data , params : { userId : userId } } ; Vue . axios ( options ) . then ( ( response ) => { resolve ( response . data ) ; } , ( error ) => { reject ( error ) ; } ) ; } ) ; }
Creates a specified view for a user
 @param {Object} data       The new view data to the server
                            { name: 'specialview', expression: 'something == somethingelse'}
 @param {string} userId     The unique identifier for a user
                            (only required if not the current user)
 @returns {Promise} Promise A promise object that signals the completion
                            or rejection of the request.
Creates a specified view for a user @param { Object } data The new view data to the server { name : ' specialview ' expression : ' something == somethingelse ' } @param { string } userId The unique identifier for a user ( only required if not the current user ) @returns { Promise } Promise A promise object that signals the completion or rejection of the request .