Join the conversation

Sign in to join this conversation, and others like it, in the communities you care about.

Wekan

Wekan is an open-source kanban board (Trello like) which allows a card-based task and to-do management.

Wekan / General

Cards.find() returns no cards

Cards.find() returns no cards

Wekan / General · December 26, 2020 at 11:28am (Edited 4 years ago)

Fooling around with putting together a simple My Cards implementation. However, I cannot get Cards.find() to return any cards. Boards.find() works perfectly.

cards() {
// return [{ title: 'Card 1' }, { title: 'Card 2' }];
const query = {
archived: false,
assignees: Meteor.userId(),
};
return Cards.find(query);
},

Is there something special that needs to be done to get Cards.find() to work?

P.S. Running the query in meteor mongo works perfectly.

Load previous messages

December 27, 2020 at 4:53pm

Meteor.js also automatically resolves write conficts of each user

    • reply
    • like

    Although, for some use cases, having manual control would in some cases improve things

      • reply
      • like

      Hmm, I don't know am I able to explain well enough.

        • reply
        • like

        Anyway, at https://github.com/wekan/wekan/pull/3008/files that code is very similar to what My Cards feature would be like. So, instead of adding Public, you would add My Cards. Then, you would copu that Public related code, so that instead of showing Public boards, you would show My Cards, creating new publication that sends to browserside all cards that are part of your My Cards, and no other data. Then, each of those cards would have link that points to that card full address in URL, the same you see in webbrowser URL bar currently when card is opened.

          • reply
          • like

          So I think, with so much already existing similar code and instructions, you should be able to add My Cards feature.

            • reply
            • like

            Oops typo above, copu that => copy that

              • reply
              • like

              publications/subscriptions do send cards to browserside

                • reply
                • like

                etc data

                  • reply
                  • like

                  to browserside mongo, so they can be listed at webbrowser

                    • reply
                    • like

                    Usually adding some new feature is like looking at some existing feature, and adding something similar.

                      • reply
                      • like

                      It's not like it would require reading all of Wekan code. Instead, read and add only what is required, and try does it work.

                        • reply
                        • like

                        For translation strings, you can add new ones with pull request to wekan/i18n/en.i18n.json, other languages are translated by other translation contributors at https://transifex.com/wekan/wekan/

                          • reply
                          • like

                          And in general, client side UI is at wekan/client/components/ , there is cards, sidebar etc. .jade files have HTML templates, .js Javasript code is related code, and .styl is CSS like styling code in stylus language

                            • reply
                            • like