         totalTyku += Math.floor(Math.sqrt(t) * item.api_tyku)
   totalTyku
 
-updateJson = (jsonId, jsonContent) ->
-  console.log jsonId
-  console.log jsonContent
+updateJson = async (jsonId, jsonContent) ->
   if jsonContent?
     enemyInformation[jsonId] = Object.clone jsonContent
     fs.writeFileSync enemyPath, JSON.stringify(enemyInformation), 'utf8'
+    try
+      yield request.postAsync "http://#{SERVER_HOSTNAME}/api/prophet/#{jsonId}/update",
+        form:
+          data: JSON.stringify(jsonContent)
+    catch e
+      console.error e
   null
 
 getMapEnemy = (shipName, shipLv, maxHp, nowHp, enemyFormation, enemyTyku, enemyInfo) ->

          getShip = null
          shipLv[i] = -1 for i in [6..11]
          if body.api_enemy?
            console.log body.api_enemy.api_enemy_id
            if enemyInformation[body.api_enemy.api_enemy_id]?
              [shipName, shipLv, maxHp, nowHp, enemyFormation, enemyTyku] = getMapEnemy shipName, shipLv, maxHp, nowHp, enemyFormation, enemyTyku, enemyInformation[body.api_enemy.api_enemy_id]
              afterHp = Object.clone nowHp

Promise = require 'bluebird'
async = Promise.coroutine
request = Promise.promisifyAll require('request')
{relative, join} = require 'path-extra'
fs = require 'fs-extra'
{_, $, $$, React, ReactBootstrap, ROOT, resolveTime, layout, toggleModal} = window
{Table, ProgressBar, Grid, Input, Col, Alert} = ReactBootstrap
{APPDATA_PATH, SERVER_HOSTNAME} = window

window.addEventListener 'layout.change', (e) ->
  {layout} = e.detail
