Prechádzať zdrojové kódy

초기 편집 문구 추가

잉여개발기 (SPDV) 6 rokov pred
rodič
commit
5ce1bbd94d
5 zmenil súbory, kde vykonal 20 pridanie a 4 odobranie
  1. 2 0
      language/en-US.json
  2. 3 1
      language/ko-KR.json
  3. 8 1
      route/edit.py
  4. 6 1
      route/setting.py
  5. 1 1
      version.json

+ 2 - 0
language/en-US.json

@@ -242,6 +242,7 @@
                 "reset_user_text" : "Password reset complete text",
                 "error_401" : "ACL view limited document notice",
                 "error_404" : "Missing document notice",
+                "edit_help" : "Editing textarea phrase",
             "_comment_2.2.4_" : "Google",
                 "recaptcha" : "reCAPTCHA",
                 "google_imap" : "Google IMAP",
@@ -295,6 +296,7 @@
         "no_login_warring" : "Non-login status. IP is logged when working with non-login.",
         "user_reset_sign" : "Your account information has changed like this.",
         "update_warring" : "Manual updates are recommended if your version is 0.2 or lower than the latest version. For Windows, the contents of the route folder disappear.",
+        "defalut_edit_help" : "Describe it here",
         "markup_enabled" : "Markup enabled",
         "_comment_3.1_" : "Error",
             "update_error" : "Auto update is not support.",

+ 3 - 1
language/ko-KR.json

@@ -299,5 +299,7 @@
     "icon": "아이콘",
     "topic_setting" : "토론 설정",
     "old_page" : "오래된 문서",
-    "skin_set" : "스킨 설정"
+    "skin_set" : "스킨 설정",
+    "edit_help" : "편집창 문구",
+    "defalut_edit_help" : "이곳에 내용을 써주세요"
 }

+ 8 - 1
route/edit.py

@@ -111,13 +111,20 @@ def edit_2(conn, name):
         else:
             b_text = ''
 
+        curs.execute(db_change('select data from other where name = "edit_help"'))
+        sql_d = curs.fetchall()
+        if sql_d and sql_d[0][0] != '':
+            p_text = sql_d[0][0]
+        else:
+            p_text = load_lang('defalut_edit_help')
+
         return easy_minify(flask.render_template(skin_check(), 
             imp = [name, wiki_set(), custom(), other2([' (' + load_lang('edit') + ')', 0])],
             data =  get_name + '''
                 <form method="post">
                     <script>do_stop_exit();</script>
                     ''' + edit_button() + '''
-                    <textarea rows="25" id="content" name="content">''' + html.escape(re.sub('\n$', '', data)) + '''</textarea>
+                    <textarea rows="25" id="content" placeholder="''' + p_text + '''" name="content">''' + html.escape(re.sub('\n$', '', data)) + '''</textarea>
                     <textarea id="origin" name="otent">''' + html.escape(re.sub('\n$', '', data_old)) + '''</textarea>
                     <hr class=\"main_hr\">
                     <input placeholder="''' + load_lang('why') + '''" name="send" type="text">

+ 6 - 1
route/setting.py

@@ -225,7 +225,8 @@ def setting_2(conn, num):
             'password_search_text',
             'reset_user_text',
             'error_401',
-            'error_404'
+            'error_404',
+            'edit_help'
         ]
         if flask.request.method == 'POST':
             for i in i_list:
@@ -302,6 +303,10 @@ def setting_2(conn, num):
                         <hr class=\"main_hr\">
                         <input name="''' + i_list[10] + '''" value="''' + html.escape(d_list[10]) + '''">
                         <hr class=\"main_hr\">
+                        <span>''' + load_lang('edit_help') + '''</span>
+                        <hr class=\"main_hr\">
+                        <input name="''' + i_list[11] + '''" value="''' + html.escape(d_list[11]) + '''">
+                        <hr class=\"main_hr\">
                         <button id="save" type="submit">''' + load_lang('save') + '''</button>
                     </form>
                 ''',

+ 1 - 1
version.json

@@ -1,6 +1,6 @@
 {
     "master" : {
-        "r_ver" : "v3.1.4-master-19",
+        "r_ver" : "v3.1.4-master-20",
         "c_ver" : "400004",
         "s_ver" : "5"
     }, "stable" : {