GithubHelp home page GithubHelp logo

rwilson504 / pcfcontrols Goto Github PK

View Code? Open in Web Editor NEW
113.0 11.0 124.0 18.31 MB

Reusable PowerApps Control Framework (PCF) controls.

License: MIT License

TypeScript 78.34% CSS 10.48% PowerShell 1.33% JavaScript 0.81% HTML 9.06%

pcfcontrols's People

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

pcfcontrols's Issues

dataset empty on initial load

This is for the Calendar control, I've also tested this with the latest version (1.1.0.59)

calendarDataSet is empty ( context.parameters.calendarDataSet.sortedRecordIds.length is 0) when control is loaded initially - re-selecting the view where the control is configured will correctly retrieve the dataset. Console Output looks like this:

// initial load
updateView: updatefromOutput: false
2index.ts:81 updateView: updatefromOutput: false
index.ts:111 updateView: dataSet.sortedRecordIds.length: 0
CalendarControl.tsx:241 asyncCalendarData: dataSet.sortedRecordIds.length: 0
CalendarControl.tsx:547 getCalendarData: eventData.length: 0

// re-selected view
index.ts:81 updateView: updatefromOutput: true
index.ts:81 updateView: updatefromOutput: false
index.ts:111 updateView: dataSet.sortedRecordIds.length: 223
CalendarControl.tsx:241 asyncCalendarData: dataSet.sortedRecordIds.length: 223
CalendarControl.tsx:547 getCalendarData: eventData.length: 223
index.ts:81 updateView: updatefromOutput: false
index.ts:111 updateView: dataSet.sortedRecordIds.length: 223

View Column Header Alignment

On the calendar week view, the date column headers are misaligned with the hour columns below them. The Sunday column header is 30 px to the right of the hours column below. The day and agenda views headers are a bit off too.

Agenda View Date Column

Currently the date column on the agenda view is set with the background color of the first item for the day. When multiple items are listed on the same day and they have different background colors, it seems the date column color seems out of place. I would suggest not setting it with a color and making it transparent in case someone wants to add a brand color behind it. (see example in my playground app)

How to load entity data?

I created a canvas app and added the calendar control.

I selected an event entity and set the field for the event name, id, start date/tim, end date/time.

When I run the app, no event records are displayed in the month I am viewing
(there are records that should show up)

For testing, I added a gallery on the same screen and it populates with all the fields I have selected in the calendar control.

I also tried selecting a view and that didn't return any data either.

I read over your set up docs multiple times. However, it seems I have missed something.
What causes the records to be loaded from a CDS entity in a canvas app?

Thanks

Italian translation for Calendar Control

case 'it':
return {
date: 'Data',
time: 'Ora',
event: 'Evento',
allDay: 'Tutto il giorno',
week: 'Settimana',
work_week: 'Settimana lavorativa',
day: 'Giorno',
month: 'Mese',
previous: 'Indietro',
next: 'Avanti',
yesterday: 'Ieri',
tomorrow: 'Domani',
today: 'Oggi',
agenda: 'Calendario',
noEventsInRange: 'Non ci sono eventi in queste date.',
showMore: total => +${total} altri
}

Updates for NPM security

Update npm packages to address serialize-javascript security vulnerability issues posted by GitHub.

Ability to set color for "today"?

Is there anyway to set the background color of the current date? Currently it displays as light blue in month, day, and week views.

I ❤ File Uploader - Firefox, not so much

I have built an app that includes file uploader. I use a button, to turn on a toggle, that sets a var, to open the window to pick the file I want to upload. It works in chrEdge, no problem. In Firefox, I have added a PopUp exception for "https://apps.powerapps.com". However, if Block All PopUps is enabled, it doesn't work. If I disable the block all, it works.

I have searched for any other type blocking setting, but haven't found anything else.

Any suggestions?

Unique Component Naming

Currently the Calendar component is named generically "Calendar". I can see this causing a bit of confusion when components are added to an app from different creators. Here is an example of adding your calendar along with another one for testing. Both have the same name in the UI. Maybe consider "Calendar RAW" or something else that would make a Power Apps creator confident they were picking the right component.

image

How do I download the zip file?

Apologies for my ignorance, but I was looking for a zip file that I can then import in as a solution, but I can't work out how to get it. How do we do this?

Error

Hey there all,
After I click the download button, it downloads the file but an error occurs:
Error
Failed to load PDF document.
Maybe something in the properties?
Thanks

Hey, With All Your Spare Time, How About a Canvas Text File Uploader and Downloader? 😁

I am trying to figure out a way to have a user select a local text file (with my custom ext name) and upload it into a hidden text control in a canvas app. This way I can patch it to a CDS record text field. I found a data card control, but it is to much work to hide all it's unnecessary bits to make it usable. I just want a button that will let the user pick the file from their HD, upload it into a text control and tell me that it completed successfully. Would be cool the other way too...to be able to save the content of a text or HTML control text to a file. This way you could use PA to build boilerplate text and "export" it to a file.

Please let me know if I have totally missed something that already exists and offers this functionality.

-Art

Calendar does not size correctly in subgrid.

Make the calendar display at a set height when used as a subgrid control. Height will be determined based upon the number of rows the user enters on the form designer multiplied by 1.5em.

Work Week Date Breaking Issue

EventsCalendar.currentRangeEnd are not being updated correctly when you switch views from Week to WorkWeek. It is set the the same as EventsCalendar.currentRangeStart. Then I am not able to use the back/next buttons to move work weeks.

New functionality

Hi Richard,

Sorry I am not reporting an issue but asking for a functionality and I didn't know how to contact you...

I am looking to display records with different pin colors depending on a specific field.
For example, my accounts are categorized (farmers, distributors, prescriptors) and I would like to display them on a map with a different color depending on the category field.

Do you know if this is something that you could easily add in your project ? (Bing or Azure Maps)

Also, I can't see the solution for teh PCF control Azure Maps. Could you create it ?

Thanks in advance for your feedback.
Sebastien.

No Component

Hi Rick, trying out the calendar control. Installed managed solution, but no control visible :(

Calendar Read-Only Views?

Can the calendar be configured to just show scheduled items as read-only? In my case, scheduling of new or editing of existing items would happen via custom UI in a canvas app outside of the calendar control.

Also, is the color for each record passed in as HEX?

Great job on creating this!
Thanks

Using Back/Next Buttons After Switching Calendar View

When I switch views, like from Week to Month, If I then click Next, I have to click it twice to get the calendar to change to the next month. The same is true for all the other views, except Day. While this might be a design issue in my testing app, it would be great if you can test and let me know what you find.

Using the Event Color Field with Calendar Control

Hi Richard,

I'm trying to use the calendar control in a model driven application. Everything works great but I'm not able to use the Event Color field functionality. The field I'm using is an option set containing hex values and referring to it using its logical name. When I leave the Event Color field property empty the calendar works but when I add the option set the calendar is blank.

Could you help me figure out how to make the functionality work?

Thank you,

JS

Expected Record Value

I copied via solution the test calendar I have been developing into a new environment. Now when I run it I get an error of "expected record value" and the calendar is blank. When I look at the collections, all the records expected have been created. This is the app I have shown you and haven't had any problems with.

I created a new app, installed calendar control and copied the code from the original test app to the new one without making any changes. The collections are created and data is displayed as expected.

Any ideas as to what might break an existing app with the control?

image

Calendar localization?

Does the calendar have the ability to be localized for language (E.G. Pass in "DE" and have the calendar control text like "month names", "day of week", "Today" be displayed in German)?

Control Picker Solution?

On the released files download page, there is a solution file named "controlpicker". Is that the Color Picker?

"Today" Background color is being applied to all months

I changed the default Today color and see that it is being applied for the same day number for all months. (e.g. If today is May 19 the color shows on the 19th of every month). This is true in the Month, Week, Work, Week, and Day calendar views. If I remove my custom color, the default blue shows up the same way.

Map Does Not Load

If a user enters a lat or long value that does not fall within the actual range for those values the map will break and the loading spinner never goes away.

Calender control local development issue

When i use the 'npm run start' command to test the control locally i receive the following error in the browser console : Invariant Violation: Minified React error 31; The calender appears for a split second and then dissapears.

Part of the console log
"Invoked method loadNextPage on Paging interface. Parameters: 5000.
index.ts:99 updateView: dataSet.sortedRecordIds.length: 3
CalendarControl.tsx:231 asyncCalendarData: dataSet.sortedRecordIds.length: 3
CalendarControl.tsx:535 getCalendarData: eventData.length: 0
react-dom.production.min.js:117 Invariant Violation: Minified React error 31; visit https://reactjs.org/docs/error-decoder.html?invariant=31&args[]=Sun%20Dec%2030%202018%2000%3A00%3A00%20GMT%2B0100%20(Central%20European%20Standard%20Time)&args[]= for the full message or use the non-minified dev environment for full errors and additional helpful warnings.
at pb (http://127.0.0.1:8181/lib/react-dom.production.min.js:12:454)
at n (http://127.0.0.1:8181/lib/react-dom.production.min.js:13:221)
at Ac (http://127.0.0.1:8181/lib/react-dom.production.min.js:70:369)
at http://127.0.0.1:8181/lib/react-dom.production.min.js:80:190...."

error detail
Which gives me the following information on the React site: Objects are not valid as a React child (found: Sun Dec 30 2018 00:00:00 GMT+0100 (Central European Standard Time)). If you meant to render a collection of children, use an array instead.

'npm run build' passes without any issues.

Am i missing something ?

First day of the week

Hello, and thanks for this awesome control!
It would be nice to choose the first day of the week in the calendar instead of defaulting to Sunday.

For example through a parameter in the control settings or by reading the user's settings in D365.

Thanks

Work Week hates on Current Start/End Range dates, but only on Sundays 😀

Steps to reproduce the error:

-Open calendar Month view

-Click any Sunday Date (opens Day view)
The calendar control current start/end range are both set to the selected Sunday

-Click Work Week view
The Work Week view column dates show as expected
However, the calendar control current start/end dates are wrong.
They are set to the week prior to the selected Sunday date not the week the Sunday is actually in.

This seems to only be an issue when navigating from any Sunday Day view to Work Week view.
Week view works as expected.

image

Color Picker: Enable copy of HEX

It would be great to be able to copy the color HEX code from the UI screen instead of having to open the color picker control. Currently a user is not able to highlight and copy an existing HEX code shown on the UI form.

Scroll To Hour on Day View

Allow the calendar to automatically scroll to a specific hour on the day view calendar.

-Add a new parameters so user can enter hour from 0-24.
-When user clicks on day view scroll the calendar automatically to that hour of the day.

Ability to specifiy scheduled item text color

Currently there is the ability to specify a color which is used as a background color for each scheduled item. It would be great if we could specify the color of the text to be used on the background for each item. Currently the default text is black for all scheduled items. Using black eliminates the ability to use darker colors. (e.g. brown, dark blue, deep purple) as a background.

Dutch Translation for Calendar Control :)

    case 'nl':
        return {
            date: 'Datum',
            time: 'Tijdstip',
            event: 'Evenement',
            allDay: 'De hele dag',
            week: 'Week',
            work_week: 'Werk Week',
            day: 'Dag',
            month: 'Maand',
            previous: 'Terug',
            next: 'Naast',
            yesterday: 'Gisteren',
            tomorrow: 'Morgen',
            today: 'Vandaag',
            agenda: 'Agenda',              
            noEventsInRange: 'Er zijn geen evenementen gepland in deze periode.',              
            showMore: total => `+${total} meer`
        }

All Day Column Width

When using resource columns to group events, all day events can have a wider width than the header. Here is a screenshot showing a column titled "other". Notice that the event is wider than the column header.

image

No Data shown on Calendar in UI Model App

I am trying to get this to work on a view in a model app. When I add the control properties for event name, start and end dates, I get no data back. There are records that show in the read only grid so I know that the view returns records. I am using a text field for the event name. However, for dates, the config property says "SingleLine.Text" for the starting and ending datetime which doesn't make sense to me. Shouldn't it be a date time field and not a text field? I am linking both the start and end date/times it to datetime fields. In the canvas app, I use a datetime field and it works. For the field name, I have tried using the logical name (all lower case), the schema name (mixed case) and column text field. Non of the three options worked for me. What am I missing?

Thanks

image

image

image

image

Add information

On the Model Driven version, how might I show the Contact and/or Account in addition to the name on the calendar?

This is looking pretty good BTW!

All Day Header on Day and Week Views

On the header line right above 12 AM for the day and week views, there is a blank square. To the right of that is where "All day" events are displayed. It would be good to add the text "All day" if you can make it fit. If you decide to do that, here are the translations:

Translations

English: All Day
Dutch: De hele dag
Spanish: Todo el dia
French: Toute la journée
German: Den ganzen Tag
Russian: Весь день

Month View More Links

I scheduled seven items per day for four days (May 18-21). In the month view when you click on the links for each of the four days they all open the day view to May 21. The current calendarDate is set to 5/21.

image

BTW: The new more links look great!

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.