@foreach (var app in Model.Apps)
{
-
diff --git a/src/admin/Bootstrap.Admin/wwwroot/js/settings.js b/src/admin/Bootstrap.Admin/wwwroot/js/settings.js
index d544606a..613a5991 100644
--- a/src/admin/Bootstrap.Admin/wwwroot/js/settings.js
+++ b/src/admin/Bootstrap.Admin/wwwroot/js/settings.js
@@ -161,34 +161,57 @@ $(function () {
});
break;
case 'addApp':
- $('#appKey').val('');
- $('#appName').val('');
+ $('#appKey').val('').removeAttr('readonly');
+ $('#appName').val('').removeAttr('readonly');
$('#appUrl').val('');
+ $('#appTitle').val('');
+ $('#appFooter').val('');
+ $('#appId').val('new');
$dialog.modal('show');
break;
- case 'saveApp':
- var appPath = $(this).parents('.input-group').find(':text').val();
- var appKey = $(this).attr('data-key');
- var appName = $(this).parents('.input-group').prev().text();
- $.bc({
- url: Settings.url + '/AppPath', data: { category: appName, name: appKey, code: appPath, define: 0 }, title: "保存" + appName, method: "post"
- });
- break;
case 'saveNewApp':
var appPath = $('#appUrl').val();
var appKey = $('#appKey').val();
var appName = $('#appName').val();
+ var appTitle = $('#appTitle').val();
+ var appFooter = $('#appFooter').val();
+ var appId = $('#appId').val();
$.bc({
- url: Settings.url + '/AppPath', data: { category: appName, name: appKey, code: appPath }, title: "保存" + appName, method: "post",
+ url: Settings.url, data: { AppName: appName, AppCode: appKey, AppUrl: appPath, AppTitle: appTitle, AppFooter: appFooter, AppId: appId }, title: "保存" + appName, method: "put",
callback: function (result) {
if (result) {
$dialog.modal('hide');
- // 保存成功创建新 dom
- var segment = $.format('