REST Service API executor.executeAsync Call Ends in Failure Function in Sharepoint Hosted App

Any Answers Will Help me to Forward and Gain Knowledge in SharePoint Development

While i am Trying to get the list Items Using Rest API Calls in SharePoint Hosted App Using Below Function

function loadingSamples()  {     var JobListName = "RRR Jobs #";     var executor;     // Initialize the RequestExecutor with the app web URL.     executor = new SP.RequestExecutor("/");      //Fetching the choice values from the Job Status Field, to show in the Dropdown field     executor.executeAsync     ({         url: "/_api/web/lists/getbytitle('" + encodeURIComponent(JobListName) + "')/fields/getbytitle('Job Status')?$  select=Choices",         method: "GET",         headers: { "Accept": "application/json; odata=verbose" },         success: successHandlerStatus,         error: errorHandler     }); } function successHandlerStatus(data)  {     alert("sucesss") }  function errorHandler(data, errorCode, errorMessage)  {     alert("errorMessage") } 

It’s always going to error function named errorHandler With Error Code as -1002 and Error Message as Bad Request and Inside Data -> Body , the Error message is

{     "error":{            "code":"-1,Microsoft.SharePoint.Client.InvalidClientQueryException",         "message":{             "lang":"en-US",             "value":"The expression \"web/lists/getbytitle('DWR Jobs \" is not valid."         }     } } 

Note :

  • This is working code in Sharepoint Hosted App that previously hosted in another Windows server.

  • Now i hosted this App in New windows server,it’s successfully hosted but it gives above mentioned Error in Rest Service Call.

How do I call a system like a grammar, but where a rule has to be applied to all matches at once?

For example, given rules $ \{ a \to x, a \to y \}$ and input $ aa$ , I am usually allowed to derive strings $ \{ xx, xy, yx, yy \}$ . I would like to restrict this to only performing “consistent” rewrites, so that the language would be like $ \{ xx, yy \}$ . It is evidently possible to synchronize rewrites in distant parts of a sentence within the usual formal grammar setting, but I wonder if this possibility is better explored under a different name or in a different arrangement.

I notice that context-sensitive grammars pose trouble with this “consistency” condition. For example, given a ruleset $ \{ aa \to x\}$ and initial string $ aaa$ , I am not sure if I should allow anything to be derived. Then again, it is entirely possible that only some rules, and specifically some context-free rules, may be enhanced with consistency.

I am rather sure the system I have in mind defines a language, and even that I could with some thinking propose a formal way to rewrite a given grammar so that some select context free rules are made consistent. But I wonder if this is actually widely known under some other name.

How to solve Application is not registered in our store. error while using GRAPH API for making a call?

I am trying to make a call in one of the channels in MS Teams via Postman.

I followed all the steps mentioned in the below article. I have also given all the required permission.

Create Call to Teams using GRAPH API – BETA

I am able to successfully retrieve other beta APIs but with /beta/app/calls I am getting the Application is not registered in our store error.

Initially, I got Unsupported AAD Identity error but, that I solved as per the steps mentioned in the below reference.

Solve Unsupported AAD Identity Error

Note: I tried to make the call from SPFx web part but over there also I am getting the same error.

My main goal is to make a call to channel of the team and all the members should get the notification for the same. (Same as meet now button’s functionality in teams app)

Any help will be appreciated. Thanks in advance.

sharepoint 2013 Web part issue when call spweb

I am facing below issue on custom web part. I developed this web part in vs2010 and deployed into SharePoint 2013 and framework version is 3.5.

The Web application at could not be found. Verify that you have typed the URL correctly. If the URL should be serving existing content, the system administrator may need to add a new request URL mapping to the intended application.

But this is working when use url like http://servename:8899/xxx.

I tried with by changing the build platform any CPU , x64 etc. but still i am facing same issue. Please provide any help to resolve this issue.

Using OAuth2 with JWT, should a client pass along unused refresh tokens on a logout call?

I have a system with an OAuth2 authorization server. It hands out JWT access tokens and refresh tokens (the latter only to the mobile app client).

We don’t persist access tokens (as is normal with JWT) but we do persist the (hashed) refresh tokens together with some meta data to be able to revoke them so that users can log out other devices. We also only allow a single use for refresh tokens, the new request also gives back a new refresh token.

The OAuth2 login server itself uses regular basic auth with sessions. The user wants to be able to logout (single devices/clients) here. So of course I have to invalidate the session itself. But ideally I want to remove the refresh token that this client still has as well. The problem is that I don’t know that refresh token. A particular user could in theory have request multiple of them with their code request. The refresh token is also not normally passed in requests (only the access token)

Should I ask the clients (which are currently all under our own development) to send along their unused refresh tokens? Even if they ‘forget’ their refresh tokens locally, it still seems better if I also delete them on the server so they don’t linger around until their expiry time. Note I do know all the refresh tokens currently in use for a certain account but I don’t want to just delete them all because that would mean all devices are logged out. We also save some user agent-like info with the refresh tokens so users can use that to manually logout other devices, but it seems like a bad idea to try to perform string matching on those to automate that process.

False Hydra in Call of Cthulhu

I would like to run False Hydra but in Call of Cthulhu. The climate fits perfectly and the story can be adjusted to the system without a problem, but I have one concern – Is there a Lovecraftian creature which is anyhow similar or at least some spells in the rulebook that can cause False Hydra effects, or should I just homebrew this creature? From what I know the False Hydra is not canon in D&D as well, but I would like to know if there is anything similar in CoC.

[ Politics ] Open Question : Do you think Abby Huntsman and Meghan McCain should stand with their View hosts and call for Trump’s impeachment?

Trump has insulted Meghan’s father so many times and yet she’s still Republican.  She has even defended some of Trump’s actions: same with Huntsman.  Her father worked for Trump as an Ambassador.  

Call to undefined relationship [sub_category] on model [App\Sub_Category]

Estoy intentado hacer una llamada por get para obtener todas mis “subcategorias”, me surge el error: Call to undefined relationship [sub_category] on model [App\Sub_Category].

Estoy en duda ya que no se si el error es 100% de la base de datos o de la consulta.

Por favor si alguien pudiera ayudarme lo agradecería


public function store(Request $  request) {     // Recoger los datos     $  json = $  request->input('json', null);     $  params = json_decode($  json);     $  params_array = json_decode($  json, true);     if (!empty($  params_array)) {          $  jwtAuth = new JwtAuth();         $  token = $  request->header('Authorization', null);         $  user = $  jwtAuth->checkToken($  token, true);          // Validar los datos         $  validate = \Validator::make($  params_array, [                     'name' => 'required'         ]);         //Guardar los datos         if ($  validate->fails()) {             $  data = [                 'code' => 400,                 'status' => 'error',                 'message' => 'Envia el nombre'             ];         } else {             $  sub_category = new Sub_Category();             $  sub_category->name = $  params_array['name'];             $  sub_category->category_id = $  params->category_id;             $  sub_category->save();              $  data = [                 'code' => 200,                 'status' => 'success',                 'sub_category' => $  sub_category             ];         }     } else {         $  data = [             'code' => 400,             'status' => 'error',             'mensage' => 'No has enviado ninguna sub_categoria'         ];     }      // Devolcer Sub_Categoria     return response()->json($  data, $  data['code']); } 


class Sub_Category extends Model {     // Referencia a la base de datos     protected $  table = 'sub_categories';      // Unos a muchos     public function give_posts(){         return $  this->hasMany('App\Post');     }      // Relación Muchos a uno     public function category(){         return $  this->belongsTo('App\Category', 'category_id');     } 

Base de datos

El objetivo es poder obtener cualquier dato para poder modificar lo posteriormente, aquí dejo las 2 talabas que se tiene que relacionar.

CREATE TABLE categories( id                  int(255) auto_increment not null, name                varchar(255)  NOT NULL, created_at           datetime DEFAULT NULL, updated_at           datetime DEFAULT NULL, CONSTRAINT  pk_users PRIMARY KEY(id) )ENGINE=InnoDb;  CREATE TABLE sub_categories( id                  int(255) auto_increment not null, name                varchar(50)  NOT NULL, category_id         int(255) NOT NULL, created_at           datetime DEFAULT NULL, updated_at           datetime DEFAULT NULL, CONSTRAINT  pk_users PRIMARY KEY(id), CONSTRAINT  fk_post_category FOREIGN KEY(category_id) REFERENCES categories(id) )ENGINE=InnoDb;