table_term_editor.php 891 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. <?php
  2. require_once "../config.php";
  3. require_once "../sync/function.php";
  4. $input = (object) [
  5. "database" => _FILE_DB_TERM_,
  6. "table" => "term",
  7. "uuid" => "guid",
  8. "sync_id" => ["pali","tag","owner"],
  9. "modify_time" => "modify_time",
  10. "receive_time" => "receive_time",
  11. "where"=>" and ( (channal IS NULL) or channal = '' )",
  12. "insert" => [
  13. 'guid',
  14. 'word',
  15. 'word_en',
  16. 'meaning',
  17. 'other_meaning',
  18. 'note',
  19. 'tag',
  20. 'create_time',
  21. 'owner',
  22. 'hit',
  23. 'language',
  24. 'receive_time',
  25. 'modify_time'
  26. ],
  27. "update" => [
  28. "word",
  29. "word_en",
  30. "meaning",
  31. "other_meaning",
  32. "note",
  33. "tag",
  34. "owner",
  35. "hit",
  36. "language",
  37. "create_time",
  38. "modify_time",
  39. "receive_time"
  40. ]
  41. ];
  42. $result = do_sync($input);
  43. echo json_encode($result, JSON_UNESCAPED_UNICODE);
  44. ?>