Ejemplo n.º 1
0
 public override BoolMessageItem Execute(object context)
 {            
     string con = @".\SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;User Instance=true";
     //string con = "Server=kishore_pc1;Database=testdb1;User=testuser1;Password=password;"
     ConnectionInfo conn = new ConnectionInfo(con, "System.Data.SqlClient");
     WebModels models = new WebModels(conn);
     var ctx = models.GetModelContext();
     CodeGeneration.CodeBuilder.CreateAll(ctx, "Profile");
     return BoolMessageItem.True;
 }
Ejemplo n.º 2
0
 /// <summary>
 /// Create the sql express|enterprise database schema using the code-generation component.
 /// </summary>
 public void CreateSchema()
 {
     //string con = @"data source=.\SQLEXPRESS;AttachDbFileName=|DataDirectory|cms.mdf;Integrated Security=True;User Instance=True";
     string con = Config.Get<string>("Database", "connectstr");
     WebModels models = new WebModels(new ConnectionInfo(con));
     CodeGeneration.CodeBuilder.CreateDatabase(models.GetModelContext());
 }
Ejemplo n.º 3
0
 public void GiveOwnerItems(WebModels.OwnerTypes OwnerType, List<WebModels.ItemsInfo> listOfItems, Action<string> callback)
 {
 }
Ejemplo n.º 4
0
    public void GiveOwnerItems(WebModels.OwnerTypes OwnerType, List<WebModels.ItemsInfo> listOfItems, Action<string> callback)
    {
        string jsonList = JsonConvert.SerializeObject(listOfItems);

        string url = string.Format("{0}GiveOwnerItems?AppID={1}&OwnerID={2}&OwnerType={3}&listOfItems={4}", cloudGoodsURL, ItemSystemGameData.AppID, ItemSystemGameData.UserID.ToString(), OwnerType.ToString(), jsonList);
        WWW www = new WWW(url);

        StartCoroutine(ServiceGetString(www, callback));
    }