db.code-snippets 27 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896
  1. {"查询广告位列表": {
  2. "prefix": "ym-db-Advertisment-Find",
  3. "body": [
  4. "List<Advertisment> $1 = db.Advertisment.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  5. "foreach (Advertisment $3 in $1)",
  6. "{",
  7. "}"
  8. ]
  9. },
  10. "查询广告位列表,并取值": {
  11. "prefix": "ym-db-Advertisment-FindWithData",
  12. "body": [
  13. "List<Advertisment> $1 = db.Advertisment.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  14. "foreach (Advertisment $3 in $1)",
  15. "{",
  16. " string Title = $3.Title; //标题",
  17. " string ColId = $3.ColId; //分类",
  18. " string PicPath = $3.PicPath; //图片",
  19. " string Contents = $3.Contents; //内容",
  20. " string Url = $3.Url; //链接地址",
  21. "}"
  22. ]
  23. },
  24. "查询广告位": {
  25. "prefix": "ym-db-Advertisment-Exist",
  26. "body": [
  27. "bool $1 = db.Advertisment.Any(m => m.Id == $2);",
  28. ]
  29. },
  30. "查询某个广告位,并取值": {
  31. "prefix": "ym-db-Advertisment-FindByPrimaryKey",
  32. "body": [
  33. "Advertisment $1 = db.Advertisment.FirstOrDefault(m => m.Id == $2);",
  34. "if ($1 != null)",
  35. "{",
  36. " string Title = $1.Title; //标题",
  37. " string ColId = $1.ColId; //分类",
  38. " string PicPath = $1.PicPath; //图片",
  39. " string Contents = $1.Contents; //内容",
  40. " string Url = $1.Url; //链接地址",
  41. "}"
  42. ]
  43. },
  44. "查询某个广告位,并赋值": {
  45. "prefix": "ym-db-Advertisment-Update",
  46. "body": [
  47. "Advertisment $1 = db.Advertisment.FirstOrDefault(m => m.Id == $2);",
  48. "if ($1 != null)",
  49. "{",
  50. " $1.Title = $2; //标题",
  51. " $1.ColId = $3; //分类",
  52. " $1.PicPath = $4; //图片",
  53. " $1.Contents = $5; //内容",
  54. " $1.Url = $6; //链接地址",
  55. "}"
  56. ]
  57. },
  58. "获取广告位数量": {
  59. "prefix": "ym-db-Advertisment-FindAndCount",
  60. "body": [
  61. "int $1 = db.Advertisment.Count(m => $2);",
  62. ]
  63. },
  64. "添加广告位": {
  65. "prefix": "ym-db-Advertisment-Create",
  66. "body": [
  67. "db.Advertisment.Add(new Advertisment()",
  68. "{",
  69. " CreateDate = DateTime.Now,",
  70. " UpdateDate = DateTime.Now,",
  71. " Title = $1, //标题",
  72. " ColId = $2, //分类",
  73. " PicPath = $3, //图片",
  74. " Contents = $4, //内容",
  75. " Url = $5, //链接地址",
  76. "});"
  77. ]
  78. },"删除某个广告位": {
  79. "prefix": "ym-db-Advertisment-Delete",
  80. "body": [
  81. "Advertisment $1 = db.Advertisment.FirstOrDefault(m => m.Id == $2);",
  82. "if ($1 != null)",
  83. "{",
  84. " db.Advertisment.Remove($1);",
  85. "}"
  86. ]
  87. },
  88. "查询企业入驻审核记录列表": {
  89. "prefix": "ym-db-BussinessAuditRecord-Find",
  90. "body": [
  91. "List<BussinessAuditRecord> $1 = db.BussinessAuditRecord.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  92. "foreach (BussinessAuditRecord $3 in $1)",
  93. "{",
  94. "}"
  95. ]
  96. },
  97. "查询企业入驻审核记录列表,并取值": {
  98. "prefix": "ym-db-BussinessAuditRecord-FindWithData",
  99. "body": [
  100. "List<BussinessAuditRecord> $1 = db.BussinessAuditRecord.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  101. "foreach (BussinessAuditRecord $3 in $1)",
  102. "{",
  103. " int UserId = $3.UserId; //会员",
  104. " int AuditId = $3.AuditId; //审核人",
  105. " string AuditNote = $3.AuditNote; //审核意见",
  106. " string UserRealName = $3.UserRealName; //会员姓名",
  107. " string UserCode = $3.UserCode; //会员编号",
  108. " string UserMobile = $3.UserMobile; //会员手机号",
  109. " string SysAdminName = $3.SysAdminName; //审核人名称",
  110. "}"
  111. ]
  112. },
  113. "查询企业入驻审核记录": {
  114. "prefix": "ym-db-BussinessAuditRecord-Exist",
  115. "body": [
  116. "bool $1 = db.BussinessAuditRecord.Any(m => m.Id == $2);",
  117. ]
  118. },
  119. "查询某个企业入驻审核记录,并取值": {
  120. "prefix": "ym-db-BussinessAuditRecord-FindByPrimaryKey",
  121. "body": [
  122. "BussinessAuditRecord $1 = db.BussinessAuditRecord.FirstOrDefault(m => m.Id == $2);",
  123. "if ($1 != null)",
  124. "{",
  125. " int UserId = $1.UserId; //会员",
  126. " int AuditId = $1.AuditId; //审核人",
  127. " string AuditNote = $1.AuditNote; //审核意见",
  128. " string UserRealName = $1.UserRealName; //会员姓名",
  129. " string UserCode = $1.UserCode; //会员编号",
  130. " string UserMobile = $1.UserMobile; //会员手机号",
  131. " string SysAdminName = $1.SysAdminName; //审核人名称",
  132. "}"
  133. ]
  134. },
  135. "查询某个企业入驻审核记录,并赋值": {
  136. "prefix": "ym-db-BussinessAuditRecord-Update",
  137. "body": [
  138. "BussinessAuditRecord $1 = db.BussinessAuditRecord.FirstOrDefault(m => m.Id == $2);",
  139. "if ($1 != null)",
  140. "{",
  141. " $1.UserId = $2; //会员",
  142. " $1.AuditId = $3; //审核人",
  143. " $1.AuditNote = $4; //审核意见",
  144. " $1.UserRealName = $5; //会员姓名",
  145. " $1.UserCode = $6; //会员编号",
  146. " $1.UserMobile = $7; //会员手机号",
  147. " $1.SysAdminName = $8; //审核人名称",
  148. "}"
  149. ]
  150. },
  151. "获取企业入驻审核记录数量": {
  152. "prefix": "ym-db-BussinessAuditRecord-FindAndCount",
  153. "body": [
  154. "int $1 = db.BussinessAuditRecord.Count(m => $2);",
  155. ]
  156. },
  157. "添加企业入驻审核记录": {
  158. "prefix": "ym-db-BussinessAuditRecord-Create",
  159. "body": [
  160. "db.BussinessAuditRecord.Add(new BussinessAuditRecord()",
  161. "{",
  162. " CreateDate = DateTime.Now,",
  163. " UpdateDate = DateTime.Now,",
  164. " UserId = $1, //会员",
  165. " AuditId = $2, //审核人",
  166. " AuditNote = $3, //审核意见",
  167. " UserRealName = $4, //会员姓名",
  168. " UserCode = $5, //会员编号",
  169. " UserMobile = $6, //会员手机号",
  170. " SysAdminName = $7, //审核人名称",
  171. "});"
  172. ]
  173. },"删除某个企业入驻审核记录": {
  174. "prefix": "ym-db-BussinessAuditRecord-Delete",
  175. "body": [
  176. "BussinessAuditRecord $1 = db.BussinessAuditRecord.FirstOrDefault(m => m.Id == $2);",
  177. "if ($1 != null)",
  178. "{",
  179. " db.BussinessAuditRecord.Remove($1);",
  180. "}"
  181. ]
  182. },
  183. "查询分类设置列表": {
  184. "prefix": "ym-db-Col-Find",
  185. "body": [
  186. "List<Col> $1 = db.Col.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  187. "foreach (Col $3 in $1)",
  188. "{",
  189. "}"
  190. ]
  191. },
  192. "查询分类设置列表,并取值": {
  193. "prefix": "ym-db-Col-FindWithData",
  194. "body": [
  195. "List<Col> $1 = db.Col.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  196. "foreach (Col $3 in $1)",
  197. "{",
  198. " string ColId = $3.ColId; //编号",
  199. " string ColName = $3.ColName; //名称",
  200. " string ColPicPath = $3.ColPicPath; //图标",
  201. " string ColDetail = $3.ColDetail; //简介",
  202. " ulong Recommend = $3.Recommend; //推荐",
  203. " string ColEnName = $3.ColEnName; //英文名",
  204. " string Contents = $3.Contents; //详细内容",
  205. " string Url = $3.Url; //第三方链接",
  206. "}"
  207. ]
  208. },
  209. "查询分类设置": {
  210. "prefix": "ym-db-Col-Exist",
  211. "body": [
  212. "bool $1 = db.Col.Any(m => m.Id == $2);",
  213. ]
  214. },
  215. "查询某个分类设置,并取值": {
  216. "prefix": "ym-db-Col-FindByPrimaryKey",
  217. "body": [
  218. "Col $1 = db.Col.FirstOrDefault(m => m.Id == $2);",
  219. "if ($1 != null)",
  220. "{",
  221. " string ColId = $1.ColId; //编号",
  222. " string ColName = $1.ColName; //名称",
  223. " string ColPicPath = $1.ColPicPath; //图标",
  224. " string ColDetail = $1.ColDetail; //简介",
  225. " ulong Recommend = $1.Recommend; //推荐",
  226. " string ColEnName = $1.ColEnName; //英文名",
  227. " string Contents = $1.Contents; //详细内容",
  228. " string Url = $1.Url; //第三方链接",
  229. "}"
  230. ]
  231. },
  232. "查询某个分类设置,并赋值": {
  233. "prefix": "ym-db-Col-Update",
  234. "body": [
  235. "Col $1 = db.Col.FirstOrDefault(m => m.Id == $2);",
  236. "if ($1 != null)",
  237. "{",
  238. " $1.ColId = $2; //编号",
  239. " $1.ColName = $3; //名称",
  240. " $1.ColPicPath = $4; //图标",
  241. " $1.ColDetail = $5; //简介",
  242. " $1.Recommend = $6; //推荐",
  243. " $1.ColEnName = $7; //英文名",
  244. " $1.Contents = $8; //详细内容",
  245. " $1.Url = $9; //第三方链接",
  246. "}"
  247. ]
  248. },
  249. "获取分类设置数量": {
  250. "prefix": "ym-db-Col-FindAndCount",
  251. "body": [
  252. "int $1 = db.Col.Count(m => $2);",
  253. ]
  254. },
  255. "添加分类设置": {
  256. "prefix": "ym-db-Col-Create",
  257. "body": [
  258. "db.Col.Add(new Col()",
  259. "{",
  260. " CreateDate = DateTime.Now,",
  261. " UpdateDate = DateTime.Now,",
  262. " ColId = $1, //编号",
  263. " ColName = $2, //名称",
  264. " ColPicPath = $3, //图标",
  265. " ColDetail = $4, //简介",
  266. " Recommend = $5, //推荐",
  267. " ColEnName = $6, //英文名",
  268. " Contents = $7, //详细内容",
  269. " Url = $8, //第三方链接",
  270. "});"
  271. ]
  272. },"删除某个分类设置": {
  273. "prefix": "ym-db-Col-Delete",
  274. "body": [
  275. "Col $1 = db.Col.FirstOrDefault(m => m.Id == $2);",
  276. "if ($1 != null)",
  277. "{",
  278. " db.Col.Remove($1);",
  279. "}"
  280. ]
  281. },
  282. "查询小程序版本库列表": {
  283. "prefix": "ym-db-MiniProgramVersions-Find",
  284. "body": [
  285. "List<MiniProgramVersions> $1 = db.MiniProgramVersions.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  286. "foreach (MiniProgramVersions $3 in $1)",
  287. "{",
  288. "}"
  289. ]
  290. },
  291. "查询小程序版本库列表,并取值": {
  292. "prefix": "ym-db-MiniProgramVersions-FindWithData",
  293. "body": [
  294. "List<MiniProgramVersions> $1 = db.MiniProgramVersions.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  295. "foreach (MiniProgramVersions $3 in $1)",
  296. "{",
  297. " int UserId = $3.UserId; //会员",
  298. " int AuditId = $3.AuditId; //审核人",
  299. " string AuditNote = $3.AuditNote; //审核意见",
  300. " string UserRealName = $3.UserRealName; //会员姓名",
  301. " string UserCode = $3.UserCode; //会员编号",
  302. " string UserMobile = $3.UserMobile; //会员手机号",
  303. " string SysAdminName = $3.SysAdminName; //审核人名称",
  304. " int ProjectId = $3.ProjectId; //项目",
  305. " string ProjectName = $3.ProjectName; //项目名称",
  306. " string VerNum = $3.VerNum; //版本号",
  307. " int UpdateKind = $3.UpdateKind; //更新类型",
  308. " string UpdateNote = $3.UpdateNote; //更新备注",
  309. " int VerType = $3.VerType; //版本类型",
  310. " DateTime AuditDate = $3.AuditDate; //审核时间",
  311. " DateTime PublishDate = $3.PublishDate; //发布时间",
  312. " string SourceFilePath = $3.SourceFilePath; //资源文件路径",
  313. "}"
  314. ]
  315. },
  316. "查询小程序版本库": {
  317. "prefix": "ym-db-MiniProgramVersions-Exist",
  318. "body": [
  319. "bool $1 = db.MiniProgramVersions.Any(m => m.Id == $2);",
  320. ]
  321. },
  322. "查询某个小程序版本库,并取值": {
  323. "prefix": "ym-db-MiniProgramVersions-FindByPrimaryKey",
  324. "body": [
  325. "MiniProgramVersions $1 = db.MiniProgramVersions.FirstOrDefault(m => m.Id == $2);",
  326. "if ($1 != null)",
  327. "{",
  328. " int UserId = $1.UserId; //会员",
  329. " int AuditId = $1.AuditId; //审核人",
  330. " string AuditNote = $1.AuditNote; //审核意见",
  331. " string UserRealName = $1.UserRealName; //会员姓名",
  332. " string UserCode = $1.UserCode; //会员编号",
  333. " string UserMobile = $1.UserMobile; //会员手机号",
  334. " string SysAdminName = $1.SysAdminName; //审核人名称",
  335. " int ProjectId = $1.ProjectId; //项目",
  336. " string ProjectName = $1.ProjectName; //项目名称",
  337. " string VerNum = $1.VerNum; //版本号",
  338. " int UpdateKind = $1.UpdateKind; //更新类型",
  339. " string UpdateNote = $1.UpdateNote; //更新备注",
  340. " int VerType = $1.VerType; //版本类型",
  341. " DateTime AuditDate = $1.AuditDate; //审核时间",
  342. " DateTime PublishDate = $1.PublishDate; //发布时间",
  343. " string SourceFilePath = $1.SourceFilePath; //资源文件路径",
  344. "}"
  345. ]
  346. },
  347. "查询某个小程序版本库,并赋值": {
  348. "prefix": "ym-db-MiniProgramVersions-Update",
  349. "body": [
  350. "MiniProgramVersions $1 = db.MiniProgramVersions.FirstOrDefault(m => m.Id == $2);",
  351. "if ($1 != null)",
  352. "{",
  353. " $1.UserId = $2; //会员",
  354. " $1.AuditId = $3; //审核人",
  355. " $1.AuditNote = $4; //审核意见",
  356. " $1.UserRealName = $5; //会员姓名",
  357. " $1.UserCode = $6; //会员编号",
  358. " $1.UserMobile = $7; //会员手机号",
  359. " $1.SysAdminName = $8; //审核人名称",
  360. " $1.ProjectId = $9; //项目",
  361. " $1.ProjectName = $10; //项目名称",
  362. " $1.VerNum = $11; //版本号",
  363. " $1.UpdateKind = $12; //更新类型",
  364. " $1.UpdateNote = $13; //更新备注",
  365. " $1.VerType = $14; //版本类型",
  366. " $1.AuditDate = $15; //审核时间",
  367. " $1.PublishDate = $16; //发布时间",
  368. " $1.SourceFilePath = $17; //资源文件路径",
  369. "}"
  370. ]
  371. },
  372. "获取小程序版本库数量": {
  373. "prefix": "ym-db-MiniProgramVersions-FindAndCount",
  374. "body": [
  375. "int $1 = db.MiniProgramVersions.Count(m => $2);",
  376. ]
  377. },
  378. "添加小程序版本库": {
  379. "prefix": "ym-db-MiniProgramVersions-Create",
  380. "body": [
  381. "db.MiniProgramVersions.Add(new MiniProgramVersions()",
  382. "{",
  383. " CreateDate = DateTime.Now,",
  384. " UpdateDate = DateTime.Now,",
  385. " UserId = $1, //会员",
  386. " AuditId = $2, //审核人",
  387. " AuditNote = $3, //审核意见",
  388. " UserRealName = $4, //会员姓名",
  389. " UserCode = $5, //会员编号",
  390. " UserMobile = $6, //会员手机号",
  391. " SysAdminName = $7, //审核人名称",
  392. " ProjectId = $8, //项目",
  393. " ProjectName = $9, //项目名称",
  394. " VerNum = $10, //版本号",
  395. " UpdateKind = $11, //更新类型",
  396. " UpdateNote = $12, //更新备注",
  397. " VerType = $13, //版本类型",
  398. " AuditDate = $14, //审核时间",
  399. " PublishDate = $15, //发布时间",
  400. " SourceFilePath = $16, //资源文件路径",
  401. "});"
  402. ]
  403. },"删除某个小程序版本库": {
  404. "prefix": "ym-db-MiniProgramVersions-Delete",
  405. "body": [
  406. "MiniProgramVersions $1 = db.MiniProgramVersions.FirstOrDefault(m => m.Id == $2);",
  407. "if ($1 != null)",
  408. "{",
  409. " db.MiniProgramVersions.Remove($1);",
  410. "}"
  411. ]
  412. },
  413. "查询单页内容列表": {
  414. "prefix": "ym-db-PageInfo-Find",
  415. "body": [
  416. "List<PageInfo> $1 = db.PageInfo.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  417. "foreach (PageInfo $3 in $1)",
  418. "{",
  419. "}"
  420. ]
  421. },
  422. "查询单页内容列表,并取值": {
  423. "prefix": "ym-db-PageInfo-FindWithData",
  424. "body": [
  425. "List<PageInfo> $1 = db.PageInfo.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  426. "foreach (PageInfo $3 in $1)",
  427. "{",
  428. " string Title = $3.Title; //标题",
  429. " string ColId = $3.ColId; //分类",
  430. " string Contents = $3.Contents; //内容",
  431. "}"
  432. ]
  433. },
  434. "查询单页内容": {
  435. "prefix": "ym-db-PageInfo-Exist",
  436. "body": [
  437. "bool $1 = db.PageInfo.Any(m => m.Id == $2);",
  438. ]
  439. },
  440. "查询某个单页内容,并取值": {
  441. "prefix": "ym-db-PageInfo-FindByPrimaryKey",
  442. "body": [
  443. "PageInfo $1 = db.PageInfo.FirstOrDefault(m => m.Id == $2);",
  444. "if ($1 != null)",
  445. "{",
  446. " string Title = $1.Title; //标题",
  447. " string ColId = $1.ColId; //分类",
  448. " string Contents = $1.Contents; //内容",
  449. "}"
  450. ]
  451. },
  452. "查询某个单页内容,并赋值": {
  453. "prefix": "ym-db-PageInfo-Update",
  454. "body": [
  455. "PageInfo $1 = db.PageInfo.FirstOrDefault(m => m.Id == $2);",
  456. "if ($1 != null)",
  457. "{",
  458. " $1.Title = $2; //标题",
  459. " $1.ColId = $3; //分类",
  460. " $1.Contents = $4; //内容",
  461. "}"
  462. ]
  463. },
  464. "获取单页内容数量": {
  465. "prefix": "ym-db-PageInfo-FindAndCount",
  466. "body": [
  467. "int $1 = db.PageInfo.Count(m => $2);",
  468. ]
  469. },
  470. "添加单页内容": {
  471. "prefix": "ym-db-PageInfo-Create",
  472. "body": [
  473. "db.PageInfo.Add(new PageInfo()",
  474. "{",
  475. " CreateDate = DateTime.Now,",
  476. " UpdateDate = DateTime.Now,",
  477. " Title = $1, //标题",
  478. " ColId = $2, //分类",
  479. " Contents = $3, //内容",
  480. "});"
  481. ]
  482. },"删除某个单页内容": {
  483. "prefix": "ym-db-PageInfo-Delete",
  484. "body": [
  485. "PageInfo $1 = db.PageInfo.FirstOrDefault(m => m.Id == $2);",
  486. "if ($1 != null)",
  487. "{",
  488. " db.PageInfo.Remove($1);",
  489. "}"
  490. ]
  491. },
  492. "查询项目审核记录列表": {
  493. "prefix": "ym-db-ProjectAuditRecord-Find",
  494. "body": [
  495. "List<ProjectAuditRecord> $1 = db.ProjectAuditRecord.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  496. "foreach (ProjectAuditRecord $3 in $1)",
  497. "{",
  498. "}"
  499. ]
  500. },
  501. "查询项目审核记录列表,并取值": {
  502. "prefix": "ym-db-ProjectAuditRecord-FindWithData",
  503. "body": [
  504. "List<ProjectAuditRecord> $1 = db.ProjectAuditRecord.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  505. "foreach (ProjectAuditRecord $3 in $1)",
  506. "{",
  507. " int UserId = $3.UserId; //会员",
  508. " int AuditId = $3.AuditId; //审核人",
  509. " string AuditNote = $3.AuditNote; //审核意见",
  510. " string UserRealName = $3.UserRealName; //会员姓名",
  511. " string UserCode = $3.UserCode; //会员编号",
  512. " string UserMobile = $3.UserMobile; //会员手机号",
  513. " string SysAdminName = $3.SysAdminName; //审核人名称",
  514. " int ProjectId = $3.ProjectId; //项目",
  515. " string ProjectName = $3.ProjectName; //项目名称",
  516. "}"
  517. ]
  518. },
  519. "查询项目审核记录": {
  520. "prefix": "ym-db-ProjectAuditRecord-Exist",
  521. "body": [
  522. "bool $1 = db.ProjectAuditRecord.Any(m => m.Id == $2);",
  523. ]
  524. },
  525. "查询某个项目审核记录,并取值": {
  526. "prefix": "ym-db-ProjectAuditRecord-FindByPrimaryKey",
  527. "body": [
  528. "ProjectAuditRecord $1 = db.ProjectAuditRecord.FirstOrDefault(m => m.Id == $2);",
  529. "if ($1 != null)",
  530. "{",
  531. " int UserId = $1.UserId; //会员",
  532. " int AuditId = $1.AuditId; //审核人",
  533. " string AuditNote = $1.AuditNote; //审核意见",
  534. " string UserRealName = $1.UserRealName; //会员姓名",
  535. " string UserCode = $1.UserCode; //会员编号",
  536. " string UserMobile = $1.UserMobile; //会员手机号",
  537. " string SysAdminName = $1.SysAdminName; //审核人名称",
  538. " int ProjectId = $1.ProjectId; //项目",
  539. " string ProjectName = $1.ProjectName; //项目名称",
  540. "}"
  541. ]
  542. },
  543. "查询某个项目审核记录,并赋值": {
  544. "prefix": "ym-db-ProjectAuditRecord-Update",
  545. "body": [
  546. "ProjectAuditRecord $1 = db.ProjectAuditRecord.FirstOrDefault(m => m.Id == $2);",
  547. "if ($1 != null)",
  548. "{",
  549. " $1.UserId = $2; //会员",
  550. " $1.AuditId = $3; //审核人",
  551. " $1.AuditNote = $4; //审核意见",
  552. " $1.UserRealName = $5; //会员姓名",
  553. " $1.UserCode = $6; //会员编号",
  554. " $1.UserMobile = $7; //会员手机号",
  555. " $1.SysAdminName = $8; //审核人名称",
  556. " $1.ProjectId = $9; //项目",
  557. " $1.ProjectName = $10; //项目名称",
  558. "}"
  559. ]
  560. },
  561. "获取项目审核记录数量": {
  562. "prefix": "ym-db-ProjectAuditRecord-FindAndCount",
  563. "body": [
  564. "int $1 = db.ProjectAuditRecord.Count(m => $2);",
  565. ]
  566. },
  567. "添加项目审核记录": {
  568. "prefix": "ym-db-ProjectAuditRecord-Create",
  569. "body": [
  570. "db.ProjectAuditRecord.Add(new ProjectAuditRecord()",
  571. "{",
  572. " CreateDate = DateTime.Now,",
  573. " UpdateDate = DateTime.Now,",
  574. " UserId = $1, //会员",
  575. " AuditId = $2, //审核人",
  576. " AuditNote = $3, //审核意见",
  577. " UserRealName = $4, //会员姓名",
  578. " UserCode = $5, //会员编号",
  579. " UserMobile = $6, //会员手机号",
  580. " SysAdminName = $7, //审核人名称",
  581. " ProjectId = $8, //项目",
  582. " ProjectName = $9, //项目名称",
  583. "});"
  584. ]
  585. },"删除某个项目审核记录": {
  586. "prefix": "ym-db-ProjectAuditRecord-Delete",
  587. "body": [
  588. "ProjectAuditRecord $1 = db.ProjectAuditRecord.FirstOrDefault(m => m.Id == $2);",
  589. "if ($1 != null)",
  590. "{",
  591. " db.ProjectAuditRecord.Remove($1);",
  592. "}"
  593. ]
  594. },
  595. "查询后台管理员列表": {
  596. "prefix": "ym-db-SysAdmin-Find",
  597. "body": [
  598. "List<SysAdmin> $1 = db.SysAdmin.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  599. "foreach (SysAdmin $3 in $1)",
  600. "{",
  601. "}"
  602. ]
  603. },
  604. "查询后台管理员列表,并取值": {
  605. "prefix": "ym-db-SysAdmin-FindWithData",
  606. "body": [
  607. "List<SysAdmin> $1 = db.SysAdmin.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  608. "foreach (SysAdmin $3 in $1)",
  609. "{",
  610. " string AdminName = $3.AdminName; //用户名",
  611. " string Password = $3.Password; //密码",
  612. " string RealName = $3.RealName; //名称",
  613. " string Role = $3.Role; //角色",
  614. " DateTime LastLoginDate = $3.LastLoginDate; //最后登录时间",
  615. "}"
  616. ]
  617. },
  618. "查询后台管理员": {
  619. "prefix": "ym-db-SysAdmin-Exist",
  620. "body": [
  621. "bool $1 = db.SysAdmin.Any(m => m.Id == $2);",
  622. ]
  623. },
  624. "查询某个后台管理员,并取值": {
  625. "prefix": "ym-db-SysAdmin-FindByPrimaryKey",
  626. "body": [
  627. "SysAdmin $1 = db.SysAdmin.FirstOrDefault(m => m.Id == $2);",
  628. "if ($1 != null)",
  629. "{",
  630. " string AdminName = $1.AdminName; //用户名",
  631. " string Password = $1.Password; //密码",
  632. " string RealName = $1.RealName; //名称",
  633. " string Role = $1.Role; //角色",
  634. " DateTime LastLoginDate = $1.LastLoginDate; //最后登录时间",
  635. "}"
  636. ]
  637. },
  638. "查询某个后台管理员,并赋值": {
  639. "prefix": "ym-db-SysAdmin-Update",
  640. "body": [
  641. "SysAdmin $1 = db.SysAdmin.FirstOrDefault(m => m.Id == $2);",
  642. "if ($1 != null)",
  643. "{",
  644. " $1.AdminName = $2; //用户名",
  645. " $1.Password = $3; //密码",
  646. " $1.RealName = $4; //名称",
  647. " $1.Role = $5; //角色",
  648. " $1.LastLoginDate = $6; //最后登录时间",
  649. "}"
  650. ]
  651. },
  652. "获取后台管理员数量": {
  653. "prefix": "ym-db-SysAdmin-FindAndCount",
  654. "body": [
  655. "int $1 = db.SysAdmin.Count(m => $2);",
  656. ]
  657. },
  658. "添加后台管理员": {
  659. "prefix": "ym-db-SysAdmin-Create",
  660. "body": [
  661. "db.SysAdmin.Add(new SysAdmin()",
  662. "{",
  663. " CreateDate = DateTime.Now,",
  664. " UpdateDate = DateTime.Now,",
  665. " AdminName = $1, //用户名",
  666. " Password = $2, //密码",
  667. " RealName = $3, //名称",
  668. " Role = $4, //角色",
  669. " LastLoginDate = $5, //最后登录时间",
  670. "});"
  671. ]
  672. },"删除某个后台管理员": {
  673. "prefix": "ym-db-SysAdmin-Delete",
  674. "body": [
  675. "SysAdmin $1 = db.SysAdmin.FirstOrDefault(m => m.Id == $2);",
  676. "if ($1 != null)",
  677. "{",
  678. " db.SysAdmin.Remove($1);",
  679. "}"
  680. ]
  681. },
  682. "查询后台管理员角色列表": {
  683. "prefix": "ym-db-SysAdminRole-Find",
  684. "body": [
  685. "List<SysAdminRole> $1 = db.SysAdminRole.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  686. "foreach (SysAdminRole $3 in $1)",
  687. "{",
  688. "}"
  689. ]
  690. },
  691. "查询后台管理员角色列表,并取值": {
  692. "prefix": "ym-db-SysAdminRole-FindWithData",
  693. "body": [
  694. "List<SysAdminRole> $1 = db.SysAdminRole.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  695. "foreach (SysAdminRole $3 in $1)",
  696. "{",
  697. " string Name = $3.Name; //名称",
  698. " string Details = $3.Details; //描述",
  699. " string RightInfo = $3.RightInfo; //权限设置",
  700. "}"
  701. ]
  702. },
  703. "查询后台管理员角色": {
  704. "prefix": "ym-db-SysAdminRole-Exist",
  705. "body": [
  706. "bool $1 = db.SysAdminRole.Any(m => m.Id == $2);",
  707. ]
  708. },
  709. "查询某个后台管理员角色,并取值": {
  710. "prefix": "ym-db-SysAdminRole-FindByPrimaryKey",
  711. "body": [
  712. "SysAdminRole $1 = db.SysAdminRole.FirstOrDefault(m => m.Id == $2);",
  713. "if ($1 != null)",
  714. "{",
  715. " string Name = $1.Name; //名称",
  716. " string Details = $1.Details; //描述",
  717. " string RightInfo = $1.RightInfo; //权限设置",
  718. "}"
  719. ]
  720. },
  721. "查询某个后台管理员角色,并赋值": {
  722. "prefix": "ym-db-SysAdminRole-Update",
  723. "body": [
  724. "SysAdminRole $1 = db.SysAdminRole.FirstOrDefault(m => m.Id == $2);",
  725. "if ($1 != null)",
  726. "{",
  727. " $1.Name = $2; //名称",
  728. " $1.Details = $3; //描述",
  729. " $1.RightInfo = $4; //权限设置",
  730. "}"
  731. ]
  732. },
  733. "获取后台管理员角色数量": {
  734. "prefix": "ym-db-SysAdminRole-FindAndCount",
  735. "body": [
  736. "int $1 = db.SysAdminRole.Count(m => $2);",
  737. ]
  738. },
  739. "添加后台管理员角色": {
  740. "prefix": "ym-db-SysAdminRole-Create",
  741. "body": [
  742. "db.SysAdminRole.Add(new SysAdminRole()",
  743. "{",
  744. " CreateDate = DateTime.Now,",
  745. " UpdateDate = DateTime.Now,",
  746. " Name = $1, //名称",
  747. " Details = $2, //描述",
  748. " RightInfo = $3, //权限设置",
  749. "});"
  750. ]
  751. },"删除某个后台管理员角色": {
  752. "prefix": "ym-db-SysAdminRole-Delete",
  753. "body": [
  754. "SysAdminRole $1 = db.SysAdminRole.FirstOrDefault(m => m.Id == $2);",
  755. "if ($1 != null)",
  756. "{",
  757. " db.SysAdminRole.Remove($1);",
  758. "}"
  759. ]
  760. },
  761. "查询系统设置列表": {
  762. "prefix": "ym-db-SystemSet-Find",
  763. "body": [
  764. "List<SystemSet> $1 = db.SystemSet.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  765. "foreach (SystemSet $3 in $1)",
  766. "{",
  767. "}"
  768. ]
  769. },
  770. "查询系统设置列表,并取值": {
  771. "prefix": "ym-db-SystemSet-FindWithData",
  772. "body": [
  773. "List<SystemSet> $1 = db.SystemSet.Where(m => $2).OrderByDescending(m => m.Id).ToList();",
  774. "foreach (SystemSet $3 in $1)",
  775. "{",
  776. " string WebUrl = $3.WebUrl; //网站地址",
  777. " string WebName = $3.WebName; //网站名称",
  778. " string IndexKeyword = $3.IndexKeyword; //首页关键词",
  779. " string IndexDescription = $3.IndexDescription; //首页简介",
  780. " string UploadExt = $3.UploadExt; //允许上传类型",
  781. " int UploadMaxSize = $3.UploadMaxSize; //允许最大上传",
  782. " ulong UploadAutoZoom = $3.UploadAutoZoom; //自动缩略图",
  783. " int UploadAutoZoomWidth = $3.UploadAutoZoomWidth; //自动缩略图宽",
  784. " int UploadAutoZoomHeight = $3.UploadAutoZoomHeight; //自动缩略图高",
  785. " ulong UploadAutoWater = $3.UploadAutoWater; //自动水印",
  786. " string UploadWaterPosition = $3.UploadWaterPosition; //水印位置",
  787. " string UploadWaterPath = $3.UploadWaterPath; //水印图片",
  788. " string RightInfo = $3.RightInfo; //版权信息",
  789. " string Address = $3.Address; //企业地址",
  790. " string Phone = $3.Phone; //联系电话",
  791. " string WebStatCode = $3.WebStatCode; //网站统计代码",
  792. " string Logo = $3.Logo; //Logo图片",
  793. "}"
  794. ]
  795. },
  796. "查询系统设置": {
  797. "prefix": "ym-db-SystemSet-Exist",
  798. "body": [
  799. "bool $1 = db.SystemSet.Any(m => m.Id == $2);",
  800. ]
  801. },
  802. "查询某个系统设置,并取值": {
  803. "prefix": "ym-db-SystemSet-FindByPrimaryKey",
  804. "body": [
  805. "SystemSet $1 = db.SystemSet.FirstOrDefault(m => m.Id == $2);",
  806. "if ($1 != null)",
  807. "{",
  808. " string WebUrl = $1.WebUrl; //网站地址",
  809. " string WebName = $1.WebName; //网站名称",
  810. " string IndexKeyword = $1.IndexKeyword; //首页关键词",
  811. " string IndexDescription = $1.IndexDescription; //首页简介",
  812. " string UploadExt = $1.UploadExt; //允许上传类型",
  813. " int UploadMaxSize = $1.UploadMaxSize; //允许最大上传",
  814. " ulong UploadAutoZoom = $1.UploadAutoZoom; //自动缩略图",
  815. " int UploadAutoZoomWidth = $1.UploadAutoZoomWidth; //自动缩略图宽",
  816. " int UploadAutoZoomHeight = $1.UploadAutoZoomHeight; //自动缩略图高",
  817. " ulong UploadAutoWater = $1.UploadAutoWater; //自动水印",
  818. " string UploadWaterPosition = $1.UploadWaterPosition; //水印位置",
  819. " string UploadWaterPath = $1.UploadWaterPath; //水印图片",
  820. " string RightInfo = $1.RightInfo; //版权信息",
  821. " string Address = $1.Address; //企业地址",
  822. " string Phone = $1.Phone; //联系电话",
  823. " string WebStatCode = $1.WebStatCode; //网站统计代码",
  824. " string Logo = $1.Logo; //Logo图片",
  825. "}"
  826. ]
  827. },
  828. "查询某个系统设置,并赋值": {
  829. "prefix": "ym-db-SystemSet-Update",
  830. "body": [
  831. "SystemSet $1 = db.SystemSet.FirstOrDefault(m => m.Id == $2);",
  832. "if ($1 != null)",
  833. "{",
  834. " $1.WebUrl = $2; //网站地址",
  835. " $1.WebName = $3; //网站名称",
  836. " $1.IndexKeyword = $4; //首页关键词",
  837. " $1.IndexDescription = $5; //首页简介",
  838. " $1.UploadExt = $6; //允许上传类型",
  839. " $1.UploadMaxSize = $7; //允许最大上传",
  840. " $1.UploadAutoZoom = $8; //自动缩略图",
  841. " $1.UploadAutoZoomWidth = $9; //自动缩略图宽",
  842. " $1.UploadAutoZoomHeight = $10; //自动缩略图高",
  843. " $1.UploadAutoWater = $11; //自动水印",
  844. " $1.UploadWaterPosition = $12; //水印位置",
  845. " $1.UploadWaterPath = $13; //水印图片",
  846. " $1.RightInfo = $14; //版权信息",
  847. " $1.Address = $15; //企业地址",
  848. " $1.Phone = $16; //联系电话",
  849. " $1.WebStatCode = $17; //网站统计代码",
  850. " $1.Logo = $18; //Logo图片",
  851. "}"
  852. ]
  853. },
  854. "获取系统设置数量": {
  855. "prefix": "ym-db-SystemSet-FindAndCount",
  856. "body": [
  857. "int $1 = db.SystemSet.Count(m => $2);",
  858. ]
  859. },
  860. "添加系统设置": {
  861. "prefix": "ym-db-SystemSet-Create",
  862. "body": [
  863. "db.SystemSet.Add(new SystemSet()",
  864. "{",
  865. " CreateDate = DateTime.Now,",
  866. " UpdateDate = DateTime.Now,",
  867. " WebUrl = $1, //网站地址",
  868. " WebName = $2, //网站名称",
  869. " IndexKeyword = $3, //首页关键词",
  870. " IndexDescription = $4, //首页简介",
  871. " UploadExt = $5, //允许上传类型",
  872. " UploadMaxSize = $6, //允许最大上传",
  873. " UploadAutoZoom = $7, //自动缩略图",
  874. " UploadAutoZoomWidth = $8, //自动缩略图宽",
  875. " UploadAutoZoomHeight = $9, //自动缩略图高",
  876. " UploadAutoWater = $10, //自动水印",
  877. " UploadWaterPosition = $11, //水印位置",
  878. " UploadWaterPath = $12, //水印图片",
  879. " RightInfo = $13, //版权信息",
  880. " Address = $14, //企业地址",
  881. " Phone = $15, //联系电话",
  882. " WebStatCode = $16, //网站统计代码",
  883. " Logo = $17, //Logo图片",
  884. "});"
  885. ]
  886. },"删除某个系统设置": {
  887. "prefix": "ym-db-SystemSet-Delete",
  888. "body": [
  889. "SystemSet $1 = db.SystemSet.FirstOrDefault(m => m.Id == $2);",
  890. "if ($1 != null)",
  891. "{",
  892. " db.SystemSet.Remove($1);",
  893. "}"
  894. ]
  895. },
  896. }