how to use a custom calendar int he django backend? - django

I have a Date of birth field in my admin form of my django app.
When a user has to select a date he must click back month by month. An old person has to click a lot (If born in 1970 and the calendar starts on 2011 for example).
Is there a way to select year by clicking on it? Or to load a difference calendar widget completely i.e. jquery-calendar? How can I do either of these?
Thanks.

If you're not happy with the default Django form widgets, any of the widgets, your recourse is to create your own or subclass and modify one of the existing. There's tons of posts online about this topic. As always, Google is your friend.
Specifically concerning jQuery Datepicker, I found this gist (updated), which might be helpful to you.

Related

Adding custom data to Django's admin dashboard

I'm having a bit of trouble with Django again.
I have a simple e-commerce website project that I'm working on for my graduation. It sells books. I've got basic functionalities down, such as adding categories and products, client sign-ups and logins, a session-based shopping cart, a checkout page fully connected to a payment API, and an orders model to keep track of data.
My professor has asked me now to to add relevant reports in the Admin panel, talked to me a while about what would be relevant to see and all. So, I've got in mind what I'm hoping to make.
I want to have two containers in the main dashboard page, which would display some quick analytics (like, how many books the store has sold in the past seven days, how much money from sales the site has made in the past month), as well as links in the sidebar: I want each relevant app within my project to have their own reports section in the Admin panel, maybe led to from a link underneath their models. I've separated the storefront, accounts, orders, shopping cart, and checkout, for instance, in different apps
The problem is I can't really figure out how to actually... do that...
I've fiddled with the layout and templates on the admin; I've figured out how to add custom links to the admin page, and change its design elements, for instance. But I'm not sure how to link the data I want to the dashboard. It feels like the answer is right in front of me and I can't reach it...
I guess my question is, how can I add my reports to the Django admin page per app, and how can I add these containers that I want in the dashboard?
I've guessed that I have to start out by building a view for each report. So I am currently reading the Django docs on the Admin page again, as well as looking at questions similar to mine.
But any information y'all can share that could ease up this process and save me some time would be very much appreciated. Thanks so much!
PS: If it helps, I am overriding the admin templates by having all the .html pages copied on my project's templates folder - it's how I got it to display the store's header in the admin dashboard.

Passing a value from one Sharepoint page to a table in a second Sharepoint page

I made a table on a SharePoint page using a webpart/snippet and some coding. My goal is to add code to pull a value for a couple of the cells in the table from another SharePoint page using a QueryString. My issue, I'm newer to SharePoint, and not sure how to set up the page that I'm pulling the information from. Ultimately, the page with the table will only be editable by a few owners. The page with the info to populate the cells will have multiple people that have the permission to edit the page to update their information daily. Now, here is where I'm not sure how to proceed. I don't want the users, most of which have no coding experience, to have to deal with entering their daily values into a coded snippet. But I'm not sure how to call the value from randomly entered data on a SharePoint page line. I believe it is SharePoint 2013. I can insert a table using the SharePoint feature rather than a snippet code, and that would be easily editable for the users. But Then I'm right back with not being sure how to call the information. I believe I can come up with the code once I figure out how I need to set up page with the information, but can edit the question as deemed necessary.
Follow the below thread
There are many way to send data from one page to another page
Query string is better if you are using table, redirect the link using custom code else follow the below link it might be help you to clarify or achieve something
https://social.technet.microsoft.com/Forums/sharepoint/en-US/b9d62eb1-57ed-4251-975d-13f9ae35f29f/how-to-pass-query-string-parameter-from-sharepoint-list-view-web-part-?forum=sharepointdevelopmentprevious
have a nice day
Regards
Vinod

How to modify the CIM API hosted form

I wanted to modify the expiration date settings in the form hosted by Authorize.net's CIM API.
I wanted it to be displayed in 2 drop downs, one for month and the other for year, instead of a single text field (mm/yy).
Is it possible to modify the form fields in the form?
Can anyone help me in getting this done.
Thanks in advance.
It is not possible to modify the hosted payment form as you describe.

Mirror Calendar between two SharePoint sites

I have two SharePoint sites and want to mirror their calendars.
Lets say site 1 Calendar is editable, then any change made to its Calendar should reflect on site 2's Calendar.
I will really appreciate if some one knows how to do it or even have an idea coz I am totally lost. Also, I am using SharePoint 2010.
Thanks in advance.
Clarification: these are two different SharePoint sites (not pages).
I've found a solution. But, it is not exactly as you want. Here, you can add an overlay of a calendar in which the main calendar will be treated as master calendar and the other calendars will be treated as children.
If you add an item/task in the children calendar, the item/task will be automatically added to the master calendar. Here is the procedure....
Go to your Calendar that you want to make as a master calendar.
Click on “Calendars Overlay” in the calendar tab.
Click new calendar and yo will have a form to fill up.
Enter the Web url for the Site that contain your child calendar
This overlay is specific to a given view, so you may want to specify the view in your calendar that you want to roll -up.
Note : Please note that the limit of calendars in an overlay is 10

Creating new user welcome tips

I'd like to create a tooltip bubbles for my site for new users - many other sites do this (most google apps). I'd like to show them for all accounts created within the last week, unless the user specifically 'dismisses' the tip.
I thought about doing this with cookies - ie. set a "-dismissed=True" value that I could check as well as the account creation date and determine whether to show the tips.
However - this doesn't work across browsers, since cookies aren't shared between browsers. So if a user logs into chrome, dismisses the tip then logs in in FF the tip will reappear.
Does anyone know if there is common way to do this sort of thing? Or at least a better way than what i've described?
I'm using browser length sessions so I can't store it in the session.
You could have a user preferences model, with a one-to-one relationship to the main user model, which stores preferences like this. Create an instance when the user entry itself is created, and default the 'show tips' field to True.
You could also use the new custom user model functionality in 1.5 to store this in the user model itself, but that seems like overkill here.