ソースを参照

add systemLang getter for swig template

utsushiiro 7 年 前
コミット
3be553a2fb
1 ファイル変更8 行追加0 行削除
  1. 8 0
      src/server/util/swigFunctions.js

+ 8 - 0
src/server/util/swigFunctions.js

@@ -49,6 +49,14 @@ module.exports = function(crowi, app, req, locals) {
     return crowi.xss.process(Config.appTitle(config));
     return crowi.xss.process(Config.appTitle(config));
   };
   };
 
 
+  /**
+   * return system language
+   */
+  locals.systemLang = function() {
+    const config = crowi.getConfig();
+    return Config.systemLang(config);
+  };
+
   /**
   /**
    * return true if enabled
    * return true if enabled
    */
    */