Пример #1
0
        public ActionResult changeStatus(string accountID, string status)
        {
            accCtrl acc = new accCtrl(accountID);

            acc.changeStauts(status);
            var json = new
            {
                acc.code,
                acc.result
            };

            return(Json(json, "text/html", JsonRequestBehavior.AllowGet));
        }
Пример #2
0
        public ActionResult delRole(string accountID)
        {
            accCtrl acc = new accCtrl(accountID);

            acc.delAcc();
            var json = new
            {
                acc.code,
                acc.result
            };

            return(Json(json, "text/html", JsonRequestBehavior.AllowGet));
        }
Пример #3
0
        public ActionResult editRole(string accountID, string accountName, string remark)
        {
            accCtrl acc = new accCtrl(accountID);

            acc.account.accountName = accountName;
            acc.account.remark      = remark;
            acc.modify();
            var json = new
            {
                acc.code,
                acc.result
            };

            return(Json(json, "text/html", JsonRequestBehavior.AllowGet));
        }
Пример #4
0
        public ActionResult creatRole(string accountName, string databasePath, string remark)
        {
            accCtrl acc = new accCtrl();

            acc.account              = new Account();
            acc.account.accountName  = accountName;
            acc.account.databasePath = databasePath;
            acc.account.remark       = remark;
            acc.creatNew();
            var resulst = new
            {
                acc.code,
                acc.result
            };

            return(Json(resulst, JsonRequestBehavior.AllowGet));
        }