(www-get-feature-value): Add error-handler for `concord-object-get'.
authorMORIOKA Tomohiko <tomo@kanji.zinbun.kyoto-u.ac.jp>
Sat, 20 Nov 2010 05:07:03 +0000 (14:07 +0900)
committerMORIOKA Tomohiko <tomo@kanji.zinbun.kyoto-u.ac.jp>
Sat, 20 Nov 2010 05:07:03 +0000 (14:07 +0900)
(www-format-value-as-char-list): Refer feature
`object-representation-format' instead of `name'.
(www-format-apply-value): Modify to edit non-character object.

cwiki-common.el

index a94e7a3..939571b 100644 (file)
          (char-feature object feature))
       )
      (t
-      (or (concord-object-get object latest-feature)
-         (concord-object-get object feature))
+      (or (condition-case nil
+             (concord-object-get object latest-feature)
+           (error nil))
+         (condition-case nil
+             (concord-object-get object feature)
+           (error nil)))
       ))))
 
 (defun get-previous-code-point (ccs code)
                                                 '=id
                                                 (concord-object-genre unit)
                                                 'genre))
-                                         (www-get-feature-value genre-o 'name)
+                                         (www-get-feature-value
+                                          genre-o
+                                          'object-representation-format)
                                        'name))))
                         (www-format-eval-feature-value
                          unit name-f nil nil nil ret
            without-edit
            (eq (plist-get props :mode) 'peek))
        ret
-      (format "%s <a href=\"%s?char=%s&feature=%s&format=%s\"
+      (format "%s <a href=\"%s?%s=%s&feature=%s&format=%s\"
 ><input type=\"submit\" value=\"edit\" /></a>"
              ret
              chise-wiki-edit-url
+             (concord-object-genre object)
              uri-object uri-feature format))))
 
 (defun www-format-eval-feature-value (object