User Profile & Activity

Yudi Member
Page
of 259

First, Sorry for the delay in sending this.

To filter data using subquery should be done in server. We need to:

  • create/modify a method in server and do subquery
  • using ServiceDescriptor in Core project (client) to construct the request

In my end, I create a project using Business project template and filter Category data using subquery with a simple condition: the app will list categories in a selection list where location is equal to "My Room". Location in my project is a field from Items table (related table)

Following snippet is added into the Controller class.

[HttpGet]
public QueryResult CategoriesByLocation(string location, ODataQueryOptions<Category> options)
{
        EntityContextProvider<InventoryEntities> db2 = new EntityContextProvider<InventoryEntities>();
        List<Item> items = db2.Context.Items.Where(o => o.Location == location).ToList();

    //List<int> categories = items.Select(o => o.CategoryID).Distinct().ToList();

    List<int> categories = new List<int>();
    foreach (var item in items)
    {
        if (!categories.Contains(item.CategoryID))
            categories.Add(item.CategoryID);
    }


    var query = db.Context.Categories.Where(o => categories.Contains(o.CategoryID));
    IQueryable results = options.ApplyTo(query);
    return new QueryResult { Results = results, InlineCount = this.Request.GetInlineCount() };
}

The subquery is done in here. This request: http://[server url]/data/inventory/categoriesbylocation?location=My%20Room will be handled by CategoriesByLocation().

In client, we can use ServiceDescriptor to contruct the request. Simply add following snippet code in ViewModel.

public CategoryListViewModel()
{
    this.ServiceDescriptor = new ServiceDescriptor();
    this.ServiceDescriptor.Parameters.Add("location", "My Room");
    this.ServiceDescriptor.ServiceName = "CategoriesByLocation";
    this.ServiceDescriptor.HttpMethod = HttpMethod.GET;
}

Hope this help. I will prepare the sample that I used in my local end to be uploaded soon.

Glad to hear that the file helps.

Should you need further assistance or run into any problems regarding our controls, feel free to post it into our forum. We would be happy to assist you again.

Posted: January 5, 2015 7:32 AM

I tried to replicate the reported problem by using the modified sent sample and do the following:

  • scroll down to the in the inventory list;
  • delete last 3 items in Android;
  • edit last 3 items in Android;
  • and mark last 3 items in Android.

I have uploaded the modified sample in OneDrive. Please have the uploaded sample evaluated on your end and let me know whether it helps or not.

Currently, the generated code of Web API controller doesn't use async mode. I have forwarded this to Crosslight development team as feature request. It is submitted under CROS-678.

Once implemented, there are no code changes needed in your existing Crosslight mobile project.

I will keep this thread updated with any news I heard from the team regarding CROS-678.

I tried to replicate the reported problem by creating a simple page of WebFileUploader based on the given snippet code and deploy it to IIS. Next, an excel file (with .xlsx file format) is uploaded using the WebFileUploader. Everything worked smoothly and the uploaded file can be accessed without any issues.

For your information, I'm using the same version of WebTextEditor (WebTextEditor 2 build 5) and WebUI.NET Framework 3.

I enclosed the original file of my xlsx file as attachment. Please try to upload this file on your remote web server and let me know whether the problem still persist or not.

Posted: January 2, 2015 8:32 AM

Currently there is no way to make the Drawer slide from the top down. However, I managed to create an Android sample which implements this scenario based on the Xamarin-AndroidSlidingDrawer sample which is discussed in here.

Hope this helps.

I assume that you are using Business project template of Crosslight. To use async mode, you can modify OnNavigated in CategoryListViewModel into the following snippet code:

public override async void Navigated(NavigatedParameter parameter)
{
    base.Navigated(parameter);

    ISelectResult<Category> selectResult = await this.Repository.GetAllAsync();
    this.Items = selectResult.Items.ToObservable();
}

Hope this helps.

It appears that UICarouselView hasn't supported this feature yet (to use navigation when a UICarouselView item is selected) in the current build version of Crosslight, Crosslight 3 Update 1. But the development team are pleased to add this feature to the roadmap.

This feature has been submitted as feature request. It is filed under CROS-672.
I'll keep this thread updated with any news I heard from the team regarding CROS-672.

Posted: December 29, 2014 9:51 AM

Sorry for the delay in sending this.

This problem, missing image in "back" and "forward" arrow of WebCalendar, has been fixed and no longer persist in the most recent build of WebEssentials.

I tested OnlineReservation.aspx sample file of WebCalendar on my local end using WebEssentials 3 build 3 and found that the problem is no longer persist. Following is the detail of my test:

  • browser: IE 11
  • doctype: HTML5 doctype
  • use SmartWebResources

Please try to update your WebEssentials product and let us know whether it helps or not.

Posted: December 29, 2014 8:23 AM

To fix the Crosslight template issue in Visual Studio, please ensure that CrosslightApp.zip is available in: "This PC > Documents > Visual Studio 2013 > Templates > ProjectTemplates > Visual C# > Intersoft Solutions > Mobile".

If the file doesn't exist, do the steps below:

  1. Download Intersoft Solutions.zip file from here;
  2. extract the file;
  3. copy/add the extracted file to: "This PC > Documents > Visual Studio 2013 > Templates > ProjectTemplates > Visual C".

This should helps.

All times are GMT -5. The time now is 3:17 PM.
Previous Next