Ejemplo n.º 1
0
        public static string GetSaveView(bool showSaveDetail, long dataId, long pageNo, long itemsPerPage, long dataIndex, string templateSuffix, long dataRefTypeId, long dataRefId, long dataTypeId, string dataValueName, bool enableRefTypeId, bool enableRefId, bool enableDataTypeId, bool showRefType, bool showRefId, bool showDataType, bool showItemHeader, bool showItemEdit, bool showItemAppend, string itemAddName, string itemEditName, string itemAppendName, bool isPublic, out string retConfigToken)
        {
            string configToken;
            string htmlSaveScript = GetSaveScript();

            string htmlSaveDetail = GetSaveDetailView(dataRefTypeId, dataRefId, dataTypeId, dataValueName, enableRefTypeId,enableRefId, enableDataTypeId, showRefType, showRefId, showDataType, showItemHeader, showItemEdit, showItemAppend, itemAddName, itemEditName, itemAppendName, isPublic, 0, dataId, pageNo, itemsPerPage, dataIndex, templateSuffix, out configToken);

            string message;
            var templateSave = new TemplateDataSave
            {
                SaveScript = htmlSaveScript,
                SaveViewHidden = !showSaveDetail,

            };
            string htmlSave = templateSave.GetFilled(templateSuffix, UtilsGeneric.Validate, UtilsGeneric.ThrowException,
                                                                  out message);

            retConfigToken = configToken;
            return htmlSave;
        }
Ejemplo n.º 2
0
        private static string GetSaveScript()
        {
            string message;
            var templateSave = new TemplateDataSave
            {
                ScriptServiceUrl = UtilsGeneric.GetCurrentService(ServiceUrl)
            };

            string htmlScript = templateSave.GetScriptFilled(true, UtilsGeneric.LoadMinJs, UtilsGeneric.Validate, UtilsGeneric.ThrowException,
                                                                  out message);
            return htmlScript;
        }