質問編集履歴
1
name changed
title
CHANGED
|
File without changes
|
body
CHANGED
|
@@ -37,12 +37,12 @@
|
|
|
37
37
|
$items = DB::table('machines')->where('id',1)->first();
|
|
38
38
|
|
|
39
39
|
|
|
40
|
-
$token = 'MkWsCdxIqUcTU5CUboL6G3qe6S4l6KB5MIjv5fGB'; //
|
|
40
|
+
$token = 'MkWsCdxIqUcTU5CUboL6G3qe6S4l6KB5MIjv5fGB'; // API トークン
|
|
41
41
|
$out_type = 'pdf'; // 出力形式
|
|
42
42
|
$template_name = 'yuuki_okubo_test_1'; // 保存済みテンプレート名
|
|
43
43
|
$entity_json = $items->name; // 帳票テンプレートに適用する任意のデータ(JSON)
|
|
44
44
|
|
|
45
|
-
$url = "https://api.
|
|
45
|
+
$url = "https://api.jp/api/{$out_type}/{$template_name}";
|
|
46
46
|
$headers['Authorization'] = "token {$token}";
|
|
47
47
|
$headers['Content-Type'] = 'application/json';
|
|
48
48
|
$options = [
|