Changes for page Lua Script
Last modified by Devin Chen on 2025/11/10 16:04
From version 7.3
edited by xingzhi lin
on 2025/10/31 11:01
on 2025/10/31 11:01
Change comment:
There is no comment for this version
To version 6.2
edited by xingzhi lin
on 2025/10/31 10:41
on 2025/10/31 10:41
Change comment:
There is no comment for this version
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -7847,86 +7847,12 @@ 7847 7847 7848 7848 == user_secure.usersecure_getInfo == 7849 7849 7850 -**Prototype : **user_secure.usersecure_getInfo() 7851 - 7852 -**Function: **Get all user information 7853 - 7854 -**Return: ** 7855 - 7856 -* Success: User data table 7857 -* Failure: Returns nil 7858 - 7859 -**Example** 7860 - 7861 -{{code language="LUA"}} 7862 -secure = user_secure.usersecure_getInfo() 7863 - for index,j in pairs(secure) do 7864 - for msg,value in pairs(j) do 7865 - if "permission" == msg then 7866 - print("index",index,"msg",msg,"value",table.concat(value,',')) 7867 - else 7868 - print("index",index,"msg",msg,"value",value) 7869 - end 7870 - 7871 - end 7872 - end 7873 - 7874 -{{/code}} 7875 - 7876 7876 == user_secure.usersecure_addInfo == 7877 7877 7878 -**Prototype : **user_secure.usersecure_addInfo(username,password,supassword,desc,hide,permission) 7879 - 7880 -**Function: **Add user information 7881 - 7882 -**Parameters**: 7883 - 7884 -* username(string): New username (16 characters) 7885 -* password(string): Password (8 characters) 7886 -* supassword(string): Confirm password (8 characters) 7887 -* desc(string): Description (10 characters) 7888 -* hide(bool): Controls hiding; true: hide if insufficient permissions 7889 -* permission(table): Permissions; 1 for granted permissions, 0 for no permissions 7890 - 7891 -**Return: ** 7892 - 7893 -* Success: Return 0 7894 -* Failure: Returns nil 7895 - 7896 -**Example** 7897 - 7898 -{{code language="LUA"}} 7899 -tab = {0,1,1,1,1,1,1,1,1,1,1,1} 7900 -user_secure.usersecure_addInfo("user1","123","123","user1",false,"tab") 7901 -{{/code}} 7902 - 7903 7903 == user_secure.usersecure_deleteInfo == 7904 7904 7905 - 7906 -**Prototype : **user_secure.usersecure_deleteInfo(username) 7907 - 7908 -**Function: **Delete user information 7909 - 7910 -**Parameters**: 7911 - 7912 -* username 7913 - 7914 -**Return: ** 7915 - 7916 -* Failure: Returns nil 7917 - 7918 -**Example** 7919 - 7920 -{{code language="LUA"}} 7921 -ret, msg = user_secure.usersecure_deleteInfo("user1") 7922 -{{/code}} 7923 - 7924 -== user_secure.usersecure_updatepermission == 7925 - 7926 7926 == user_secure.usersecure_login == 7927 7927 7928 - 7929 - 7930 7930 == user_secure.usersecure_logout == 7931 7931 7932 7932 == user_secure.usersecure_updatepwd == ... ... @@ -7933,38 +7933,7 @@ 7933 7933 7934 7934 = LuaChart = 7935 7935 7936 -== chart.setAlarmBtnSpacing == 7937 7937 7938 -**Prototype : **user_secure.usersecure_getInfo() 7939 - 7940 -**Function: **Connect to a DB file.(If the file does not exist) 7941 - 7942 -**Parameters**: 7943 - 7944 -* dbFilePath (string): Full path to the DB file to connect to (create) 7945 - 7946 -**Return: ** 7947 - 7948 -* Success: database object 7949 -* Failure: Returns nil and error. 7950 - 7951 -**Example** 7952 - 7953 -{{code language="LUA"}} 7954 -sql = require "Luasqlite" -- Introducing the lua libraries 7955 -env = sql.sqlite3() -- Get the environment class 7956 -{{/code}} 7957 - 7958 -== chart.setAlarmBtnScale == 7959 - 7960 -== chart.setFormulaBtnSpacing == 7961 - 7962 -== chart.setFormulaBtnScale == 7963 - 7964 -== chart.setBarChartBtnSpacing == 7965 - 7966 -== chart.setBarChartBtnScale == 7967 - 7968 7968 = Environment operation = 7969 7969 7970 7970 (% class="wikigeneratedid" id="HGetsqliteenvironment" %)