diff options
| -rw-r--r-- | lisp/service/messages-service.lisp | 22 | ||||
| -rw-r--r-- | lisp/service/password-service.lisp | 14 | ||||
| -rw-r--r-- | lisp/service/profile-service.lisp | 12 |
3 files changed, 21 insertions, 27 deletions
diff --git a/lisp/service/messages-service.lisp b/lisp/service/messages-service.lisp index 5c0f241..55a31ce 100644 --- a/lisp/service/messages-service.lisp +++ b/lisp/service/messages-service.lisp @@ -12,6 +12,17 @@ :accessor form)) (:documentation "")) +(defclass messages/view-service (messages-service) + ((results :initarg :results + :initform nil + :accessor results) + (location-p :initform nil)) + (:documentation "")) + +(defclass messages/mark-service (messages-service) + ((location-p :initform nil)) + (:documentation "")) + (defun messages-json () (with-auth (instance messages-service "messages-view") (setf (title instance) "Messages Administration") @@ -21,13 +32,6 @@ `((:label "View Unread" :field-type "button" :onclick "on_messages_mode_clicked('unread')") (:label "View Read" :field-type "button" :onclick "on_messages_mode_clicked('read')")))))) -(defclass messages/view-service (messages-service) - ((results :initarg :results - :initform nil - :accessor results) - (location-p :initform nil)) - (:documentation "")) - (defun messages-view-json (read) (with-auth (instance messages/view-service "messages-view") (when read (setf (session-value :messages-read) read)) @@ -40,10 +44,6 @@ (loop for result in (results instance) do (sanitize-json result)))) -(defclass messages/mark-service (messages-service) - ((location-p :initform nil)) - (:documentation "")) - (defun messages-mark-json (read id) (with-auth (instance messages/mark-service "messages-view") (with-resume-database diff --git a/lisp/service/password-service.lisp b/lisp/service/password-service.lisp index d9ad4bc..d8a7213 100644 --- a/lisp/service/password-service.lisp +++ b/lisp/service/password-service.lisp @@ -12,6 +12,13 @@ :accessor title)) (:documentation "")) +(defclass password/modify-service (password-service) + ((form :initarg :form + :initform nil + :accessor form) + (location-p :initform nil)) + (:documentation "")) + (defun password-json () (with-auth (instance password-service "profile-modify") (let ((user (get-user))) @@ -24,13 +31,6 @@ (:name "pwd2" :label "Password (again)" :field-type "password" :required "required") (:label "Change Password" :field-type "button" :onclick "on_password_submit_clicked()"))))))) -(defclass password/modify-service (password-service) - ((form :initarg :form - :initform nil - :accessor form) - (location-p :initform nil)) - (:documentation "")) - (defun password-submit-json (id pwd pwd2) (declare (special pwd pwd2)) (with-auth (instance password/modify-service "profile-modify") diff --git a/lisp/service/profile-service.lisp b/lisp/service/profile-service.lisp index 990a9d0..de31d29 100644 --- a/lisp/service/profile-service.lisp +++ b/lisp/service/profile-service.lisp @@ -16,10 +16,11 @@ (location-p :initform nil)) (:documentation "")) -(defclass profile/modify-service (profile/view-service) +(defclass profile/modify-service (profile-service) ((form :initarg :form :initform nil - :accessor form)) + :accessor form) + (location-p :initform nil)) (:documentation "")) (defun profile-json () @@ -34,13 +35,6 @@ (loop for item in (items instance) do (sanitize-json item)))) -(defclass profile/modify-service (profile-service) - ((form :initarg :form - :initform nil - :accessor form) - (location-p :initform nil)) - (:documentation "")) - (defun profile-modify-json () (with-auth (instance profile/modify-service "profile-modify") (let ((user (get-user))) |
