Giter Site home page Giter Site logo

weblocks's Introduction

weblocks's People

Contributors

aggieben avatar brewski82 avatar chrisbronkhorst avatar coffeemug avatar db48x avatar dpavlenkov avatar eslick avatar evanmonroig avatar fare avatar html avatar jwr avatar makarovalexey avatar milancermak avatar radisb avatar s11001001 avatar simplyjt avatar skypher avatar slburson avatar svetlyak40wt avatar vibs29 avatar woudshoo avatar xrme avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

weblocks's Issues

clsql query does not work in some cases

When searching character column with integer value it returns nil

For example, column contains "31159" value

(find-persistent-objects *default-store* 
                           'citilink-excel-data-item 
                           :where [= [article] "31159"])

returns nil
and

(find-persistent-objects *default-store* 
                           'citilink-excel-data-item 
                           :where [= [article] 31159])

returns record

It seems that this is clsql issue

Continuations don't work in some cases

This code works well

(do-page 
 (make-widget 
  (lambda (&rest args)
   (with-html 
    (render-link 
     (lambda (&rest args)
      (answer (first (widget-children (root-widget)))))
     "back")))))

And this does not

(do-page 
  (lambda (&rest args)
   (with-html 
    (render-link 
     (lambda (&rest args)
      (answer (first (widget-children (root-widget)))))
     "back"))))

The difference is "make-widget"

Make find-persistent-objects behave identically across different stores

Currently find-persistent-objects has similar key params like :filter :filter-fn, :where

memory - filter
prevalence - filter
elephant - filter-fn
postmodern - where
clsql - where

I suppose it needs at least to use filter key for elephant.
To make single interface for all stores it needs to make some abstract sub language.
I have such language in git://github.com/html/weblocks-filtering-widget.git but it is not ready to use.

Some systems failed to build for Quicklisp dist

Building with SBCL 2.1.0.29-a1ce59262 / ASDF 3.3.1 for quicklisp dist creation.

Trying to build commit id fe96152

weblocks-demo-popover fails to build because of a failure in weblocks.

weblocks-s11 fails to build because of a failure in weblocks.

weblocks-test fails to build because of a failure in weblocks.

weblocks-yarek fails to build because of a failure in weblocks.

weblocks-yui fails to build because of a failure in weblocks.

weblocks fails to build with the following error:

; caught WARNING:
;   Derived type of #:G8 is (MEMBER CHILDREN), conflicting with its asserted type LIST.
;   See also:
;     The SBCL Manual, Node "Handling of Types"
...
Unhandled UIOP/LISP-BUILD:COMPILE-FILE-ERROR in thread #<SB-THREAD:THREAD "main thread" RUNNING {100E868433}>: COMPILE-FILE-ERROR while compiling #<CL-SOURCE-FILE "weblocks" "src" "widgets" "widget" "widget">

Full log here

Not found page

There is custom code in weblocks which shows not found page.
At some point hunchentoot started to show its own not found page.
It needs to be fixed.

Remove messy code in weblocks-prevalence

Also, it looks like you're going through a horrible bogus and roundabout way to have weblocks-prevalence
depend on weblocks-memory without doing it directly. Can you delete this prepare-prevalence-op nonsense,
and replace it with (1) adding weblocks-memory to :depends-on (2) calling any necessary initialization function
at the correct moment (whether it be compile-time, load-time, runtime or coffee-time).

Weblocks actions append to session on every request

At this moment when refreshing page with some widgets like gridedit, session becomes bigger. This is because of make-action which generates unique symbol for the same action every time code executes (on each request).
This can by fixed by some actions identification. Each action should have unique id which works across requests.

(make-action (lambda(&rest args)) "some-action-name") works ok but for internal actions action name should be hard to guess.

Next code should work fine even if we shared application source code. Internal actions will save under same name and name should be hard to guess.

(make-action (lambda(&rest args)) (md5 (format nil "gridedit-render-widget-body-action-1 ~A ~A" (get-universal-time) (random 1000))))

There is a lack in this solution - we should always name actions.
If we could name actions automatically depending on code position it would be great but as I know only sbcl will allow to do this.

Some systems failed to build for Quicklisp dist

Building with SBCL 2.1.7.62-417920f09 / ASDF 3.3.5 for quicklisp dist creation.

Trying to build commit id fe96152

weblocks-demo-popover fails to build because of a failure in weblocks.

weblocks-s11 fails to build because of a failure in weblocks.

weblocks-test fails to build because of a failure in weblocks.

weblocks-yarek fails to build because of a failure in weblocks.

weblocks-yui fails to build because of a failure in weblocks.

weblocks fails to build with the following error:

; caught WARNING:
;   Derived type of #:G8 is (MEMBER CHILDREN), conflicting with its asserted type LIST.
;   See also:
;     The SBCL Manual, Node "Handling of Types"
...
Unhandled UIOP/LISP-BUILD:COMPILE-FILE-ERROR in thread #<SB-THREAD:THREAD "main thread" RUNNING {1001BF0103}>: COMPILE-FILE-ERROR while compiling #<CL-SOURCE-FILE "weblocks" "src" "widgets" "widget" "widget">

Full log here

weblocks-postmodern/elephant: symbol conflicts

I get a symbol conflict when building weblocks-postmodern:

unhandled NAME-CONFLICT in thread #<SB-THREAD:THREAD "main thread"
RUNNING {10030C1403}>: USE-PACKAGE #<PACKAGE "POSTMODERN"> causes
name-conflicts in #<PACKAGE "WEBLOCKS-POSTMODERN"> between the
following symbols:POSTMODERN:WITH-TRANSACTION,
WEBLOCKS:WITH-TRANSACTION

See also:
  The ANSI Standard, Section 11.1.1.2.5

I get this for weblocks-elephant:

unhandled NAME-CONFLICT in thread #<SB-THREAD:THREAD "main thread"
RUNNING {10030C13E3}>: USE-PACKAGE #<PACKAGE "WEBLOCKS"> causes
name-conflicts in #<PACKAGE "WEBLOCKS-ELEPHANT"> between the
following symbols:WEBLOCKS:WITH-TRANSACTION,
ELEPHANT:WITH-TRANSACTION

See also:
  The ANSI Standard, Section 11.1.1.2.5

Make global navigation.

Currently every navigation widget rendered works locally. Its navigation is available while widget is rendered and when we change page navigation becomes unavailable.
For exampe when we have navigation, navigation pane with url "/test" and link to action "a" on this pane which displays page with do-page, when we click on the link and page will be shown, "/test" url will become unavailable.
I suggest to make macro defnavigation which will add navigation to global navigation map.

Make integer form fields

Integer form fields should have integer validation and write value to record as integer not string.

trac can't synchronize

I'm not sure, if it's a correct place to put it, but trac at:
https://trac.common-lisp.net/cl-weblocks

Can't synchronize with repository:

"Warning: Can't synchronize with repository "(default)" (/project/cl-weblocks/svn does not appear to be a Subversion repository.). Look in the Trac log for more information."

It's shown in a box below navigation links.

Doesn't build in SBCL - stray close paren

; caught ERROR:
;   READ error during COMPILE-FILE: unmatched close parenthesisLine: 95, Column: 36, File-Position: 4327Stream: #<SB-INT:FORM-TRACKING-STREAM for "file /home/quicklisp/quicklisp-controller/dist/build-cache/weblocks/dfb3a41d5284e1579966badacab4968a26be99b7/weblocks-20160519-git/src/views/types/presentations/choices.lisp" {10033A7733}>
Unhandled UIOP/LISP-BUILD:COMPILE-FILE-ERROR in thread #<SB-THREAD:THREAD "main thread" RUNNING {100334F673}>: COMPILE-FILE-ERROR while compiling #<CL-SOURCE-FILE "weblocks" "src" "views" "types" "presentations" "choices">

Does not build - LOOP error

I get this:

; caught WARNING:
;   Use of QUOTE around stepping function in LOOP will be left verbatim.
;   current LOOP context: FOR (KEY VALUE) ON CONTEXT :BY (QUOTE CDDR) SUM.

;     (LET ((WEBLOCKS-UTIL::NAME (CAR WEBLOCKS-UTIL::TEMPLATE))
;           (WEBLOCKS-UTIL::CONTEXT (COPY-TREE (CDR WEBLOCKS-UTIL::TEMPLATE))))
;       (OR
;        (LOOP WEBLOCKS-UTIL::FOR (WEBLOCKS-UTIL::KEY
;                                  WEBLOCKS-UTIL::VALUE) WEBLOCKS-UTIL::ON WEBLOCKS-UTIL::CONTEXT :BY 'CDDR
;              WEBLOCKS-UTIL::SUM (COND (# #) (# #) (# #) (T 0)))
;        0))
; 

As a result, weblocks does not build. This is in templates.lisp.

Need to load javascript backend: the simple blog example doesn't work

I tried the demo:

CL-USER> (ql:quickload "weblocks-demo")
To load "weblocks-demo":
Load 1 ASDF system:
weblocks-demo
; Loading "weblocks-demo"
CL-USER>(weblocks-demo:start-weblocks-demo)

but I get this error message:

>  Please load javascript backend for framework (default is :prototype from https://github.com
> /html/weblocks-prototype-js) and pass :js-backend value (:js-backend :prototype for example) 
> into your defwebapp

try:

(weblocks-demo:start-weblocks-demo :js-backend :prototype)

and get the same error.
What I have to do to resolve this problem.

employer-employee system doesn't build: reference to SWANK package

I get this:

;   READ error during COMPILE-FILE: Package SWANK does not exist. Line: 40, Column: 50, File-Position: 1512 Stream: #<SB-INT:FORM-TRACKING-STREAM for "file /home/quicklisp/quicklisp-controller/dist/build-cache/weblocks/e416f64744e54eb0e7cb6e199c09d3b797ea21b3/weblocks-20180123-git/contrib/yarek/examples/employer-employee/src/init-session.lisp" {10026E6763}>

Add filter parameters for view fields

We have :reader and :writer parameters which have database item as parameters.
There are much cases where we want not to touch reader and we use :reader only for filtering value. In this case it is better to use :read-filter and :write-filter for view field.
For example to save string only in upcase variant we passing :write-filter #'string-upcase

Templates for weblocks

Weblocks should be a component framework but MVC should be used in every weblocks widget since it is comfortably (widget is controller itself).

I suggest to use templates in weblocks.
Template should be piece of code, it should return string or write strings to some stream and shoud not contain complex logic like loops. I've been inspired by mustache approach (http://mustache.github.com/mustache.5.html) which does not use loops in template logic and it looks good, but it would be not a problem to have logic for templates.

We can use functions for templates, in this way we can use many templates backends like cl-who, yaclml, cl-mustache or cl-emb or any other templating library. To use some backend we will need only some glue functions/macros.
And functions are also great for parameters passing (no need in reinventing a bike).
Another question to discuss is should we create some naming convention for views ?

I would like to rewrite weblocks code piece by piece without changing library for html generation (cl-who) but with separating logic from views. As a result templates (views) should add flexibility which weblocks does not have yet and anyone could rewrite widgets look on their needs.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.