Fixes the anonymous profile usage

* NpgsqlMembershipProvider.cs: insert a profile record before
  inserting the users record,
to ensure a new foreign key constraint

* NpgsqlProfileProvider.cs: better comments

* YavscController.cs: Fixes the cookies agreement

* HomeController.cs: Finalizes the cookie agreement system.

* YavscHelpers.cs: Adds a "click_action_name" field, to give a text to
  the notification dimissing button.

* App.master: Uses the new field from Notification

* Web.config: No VB code to compile

* Web.csproj: moves Sql files to Sql folder

* LocalizedText.resx:
* LocalizedText.fr.resx:
* LocalizedText.Designer.cs:
* LocalizedText.fr.Designer.cs: I understood ...

* Notification.cs: a new click action name.

* instdbws.sql: permits profile records with no users record
  associated to,
and so, anonymous profiles creation.
This commit is contained in:
Paul Schneider 2015-11-03 12:05:17 +01:00
commit cbb596ca04
17 changed files with 104 additions and 46 deletions

View file

@ -225,12 +225,17 @@ namespace Yavsc.Helpers
JavaScriptSerializer serializer = new JavaScriptSerializer();
return serializer.Serialize(obj);
}
public static void Notify(ViewDataDictionary ViewData, string message, string click_action=null) {
public static void Notify(ViewDataDictionary ViewData, string message, string click_action=null, string clickActionName="Ok") {
Notify(ViewData, new Notification { body = YavscAjaxHelper.QuoteJavascriptString(message),
click_action = click_action, click_action_name = YavscAjaxHelper.QuoteJavascriptString(clickActionName)} ) ;
}
public static void Notify(ViewDataDictionary ViewData, Notification note) {
if (ViewData ["Notifications"] == null)
ViewData ["Notifications"] = new List<Notification> ();
(ViewData ["Notifications"] as List<Notification>).Add (
new Notification { body = YavscAjaxHelper.QuoteJavascriptString(message),
click_action = click_action } ) ;
note ) ;
}
/// <summary>
/// Files the list.