Comments (19)
This is already there. Isn't it?
from mapknitter.
It asks for a combined one:
Map title/URL (you won't be able to change this)
additionally if we separate them, users will be able to change the title
although not the URL.
On Tue, Dec 23, 2014 at 4:57 PM, Viduranga Wijesooriya <
[email protected]> wrote:
This is already there. Isn't it?
—
Reply to this email directly or view it on GitHub
#43 (comment).
from mapknitter.
Ahh okay got it. When should I take the approval of the user for the url? What's the workflow?
from mapknitter.
So, perhaps:
- user enters text title with fewer formatting rules
- as theyre typing, javascript cleans and reformats the title text into a
URL-compatible string that'll pass the validation:
https://github.com/publiclab/mapknitter/blob/master/app/models/map.rb#L7 - user tabs to or select next field -- the URL field -- and can adapt/edit
it to their liking - user enters a location (this interaction itself needs some work)
- save
On Tue, Dec 23, 2014 at 5:05 PM, Viduranga Wijesooriya <
[email protected]> wrote:
Ahh okay got it. When should I take the approval of the user for the url?
What's the workflow?—
Reply to this email directly or view it on GitHub
#43 (comment).
from mapknitter.
Okay got it. I will do it. Can you assign me to this.
from mapknitter.
Hi Jeff,
I added this function by introducing new field called "url" to the map model. But there are lot of places in the app where it uses map.name to identify the maps, create images, in rxml files etc. We need to fix all of them. I may need your help regarding some of them.
from mapknitter.
Hi Vidurqnga, @manleyjster and I were talking about using the friendly_url
gem to do this... There's more discussion of it in the comments here:
justinmanley#1
And I also want to be sure you're working off the latest branch:
This is a big integration project and I apologize if it wasn't clear what
our plans for the codebase were.
On Jan 11, 2015 2:06 AM, "Viduranga Wijesooriya" [email protected]
wrote:
Hi Jeff,
I added this function by introducing new field called "url" to the map
model. But there are lot of places in the app where it uses map.name to
identify the maps, create images, in rxml files etc. We need to fix all of
them. I may need your help regarding some of them.—
Reply to this email directly or view it on GitHub
#43 (comment).
from mapknitter.
I followed your instructions in above comment in order to implement it.
So is it already implemented?
If you want, you can look at my implementation too. I can make a pull request.
I think I also have to merge the latest code
from mapknitter.
Its not already implemented, but I will take a look in a little bit and see
what we can do. Thanks!
On Jan 11, 2015 10:26 AM, "Viduranga Wijesooriya" [email protected]
wrote:
I followed your instructions in above comment in order to implement it.
So is it already implemented?
If you want, you can look at my implementation too. I can make a pull
request.
I think I also have to merge the latest code—
Reply to this email directly or view it on GitHub
#43 (comment).
from mapknitter.
Hi, Viduranga - I can't find your code -- it doesn't seem to be here: https://github.com/vpowerrc/mapknitter/tree/viduranga could you make a branch with it called "map-url-fields" or something?
I'm sorry, when you didn't respond last time I didn't realize you were going to continue work on this branch. I think it's plausible (although I would have to look at the code) that you could:
a) pull the https://github.com/jywarren/mapknitter/tree/annotation-interface branch into a fresh local branch,
b) cherry-pick your map URL commits and merge them in on top of annotation-interface
c) submit a pull request
Or perhaps @manleyjster can suggest a better way.
The other issue is whether:
- we should adopt your code and ditch the friendly_id based plan
- we can integrate all or parts of friendly_id into your code, perhaps by letting friendly_id handle slug generation but using map.url to store it? Hard to say without seeing your code.
- we could substantially rewrite your code around friendly_id
- either approach can easily preserve old URLs with a database migration, where we save the currently auto-generated routes
/maps/foo
into either map.url or friendly_id-based saved URLs.
Apologies again, but if we adopt @manleyjster's recommendation to treat publiclab/mapkniter master as our edge branch (and the stable
branch as the deployed code) , it'll be more clear to new contributors what to base their pull requests on. His suggestion makes a lot of sense in light of this situation. However, in the future, can I ask you to check in on the plots-dev discussion list as you work, which should also help to keep synced? Thanks so much for your work.
from mapknitter.
Hi Jeff,
I pushed my current changes without merging with https://github.com/jywarren/mapknitter/tree/annotation-interface to "map-url-fields" branch for now.
I will do the merge tomorrow.
As I said before there are lot places still need to be changed since now map is identified by the url column, not by the name column. I changed it in most of the places which I could understand. But I need help in some areas of the app.
No problem. First you can take a look at my code, then we can decide what to do.
from mapknitter.
Hi, Viduranga - i hope you saw my email to plots-dev -- I think the best
thing to do may be to rebase your changes on top of the upcoming
mapknitter2 code:
https://groups.google.com/forum/#!topic/plots-dev/9dWJqchfGPM
I also think it's worth it to use friendly_id, and after browsing the
documentation, it
seems like that's possible. That means you could just use
Map.find('my-map') directly, which is cool. If you can rebase your changes,
would you consider attempting to integrate friendly_id also? Keep an eye
also on the "parameterize" function in ActiveRecord -- we def. want the
client-side slug generation you've written to work the same as
ActiveRecord's conversion if that's possible.
Jeff
On Sun, Jan 11, 2015 at 2:20 PM, Viduranga Wijesooriya <
[email protected]> wrote:
Hi Jeff,
I pushed my current changes without merging with
https://github.com/jywarren/mapknitter/tree/annotation-interface to
"map-url-fields" branch for now.
I will do the merge tomorrow.As I said before there are lot places still need to be changed since now
map is identified by the url column, not by the name column. I changed it
in most of the places which I could understand. But I need help in some
areas of the app.No problem. First you can take a look at my code, then we can decide what
to do.—
Reply to this email directly or view it on GitHub
#43 (comment).
from mapknitter.
Great I will integrate friendly_id
from mapknitter.
Hi Jeff,
Map.find('my-map') kind of queries only work with friendly_id 5.0 or greater. Otherwise we need to use Map.friendly.find('my-map')
But friendly_id 5.0 depends on active-record 4.0
How should I proceed?
from mapknitter.
Map.friendly.find is fine! Thanks.
On Jan 15, 2015 1:13 AM, "Viduranga Wijesooriya" [email protected]
wrote:
Hi Jeff,
Map.find('my-map') kind of queries only work with friendly_id 5.0 or
greater. Otherwise we need to use Map.friendly.find('my-map')
But friendly_id 5.0 depends on active-record 4.0
How should I proceed?
Also shall I keep a separate column like "url" for the slug(like I already
did) or use the same "name" column and use friendly_id to parameterize it
whenever we want?—
Reply to this email directly or view it on GitHub
#43 (comment).
from mapknitter.
Hi again
I was able to integrate friendly_id successfully. Then I cherry picked my commits like you suggested. But there were about 25 conflicts. So I decided to redo my changes on the new branch since some views were also changed. I will send a pull request as soon as possible.
Cheers
from mapknitter.
super!
On Thu, Jan 15, 2015 at 2:04 PM, Viduranga Wijesooriya <
[email protected]> wrote:
Hi again
I was able to integrate friendly_id successfully. Then I cherry picked my
commits like you suggested. But there were about 25 conflicts. So I decided
to redo my changes on the new branch since some views were also changed. I
will send a pull request as soon as possible.
Cheers—
Reply to this email directly or view it on GitHub
#43 (comment).
from mapknitter.
I made a pull request jywarren#182
from mapknitter.
merged into the master development branch, thanks!
from mapknitter.
Related Issues (20)
- Update Staging urls HOT 3
- why didn't a yarn error trigger a failure in GitHub Actions? node version mismatch HOT 6
- FTO: Fix typos and update config.yml HOT 4
- AWS credentials issue on stable HOT 7
- CodeCov not registering recent test reports HOT 3
- Outreachy: "MapKnitter.org Spam Management System" Project Planning HOT 16
- Outreachy: "MapKnitter.org Spam Management System" Project Q&A HOT 19
- Create status columns on maps and users tables
- Create batch-spam and single spam endpoints
- Create batch-publish and single publish endpoints
- Improve "card" section of the maps show page HOT 13
- Add first-timers-only issue template HOT 11
- Create batch-delete endpoint
- Adjust existing fetch map(s) and user(s) endpoints to fetch based on status
- building in stable - notes HOT 5
- Create batch-ban and single ban endpoints
- Create batch-unban and single unban endpoints
- Create endpoints for fetching maps on the spam dashboard page
- Create endpoints for fetching users on the spam dashboard page
- Edit login process to allow only active users HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mapknitter.